lambdaway
::
formulas
3
|
list
|
login
|
load
|
|
{require lib_math} _h1 diplaying math | [[maxwell]] equations _p The [[lib_math]] page is an {b editable and extendable library} containing currently 6 functions: {pre {center \math, \cell, \sqrt, \frac, \table, \paren}} _p This a first example of application, writing {pre '{\math x = {\frac {\cell -b ± {\sqrt b{sup 2} - 4ac}} {\cell 2a} }} } _p displays {{BLOCK 1} {\math x = {\frac {\cell -b ± {\sqrt b{sup 2} - 4ac}} 2a}} } _h2 Some other tests _p Writing {pre °° R{sub μν} - {\frac {\cell 1} {\cell 2}}g{sub μν}R = T{sub μν} °°} _p displays {{BLOCK 2} {\math R{sub μν} - {\frac {\cell 1} {\cell 2}}g{sub μν}R = T{sub μν}} } _p writing {pre M = '{\math {\paren [ 4.0} {{\table} {tr {td cos(θ)} {td sin(θ)}} {tr {td -sin(θ)} {td cos(θ)}} } {\paren ] 4.0}} } _p displays {{BLOCK 1} M = {\math {\paren [ 4.0} {{\table} {tr {td cos(θ)} {td sin(θ)}} {tr {td -sin(θ)} {td cos(θ)}} } {\paren ] 4.0}} } _p writing {pre E = '{\math {\sigma i=0 ∞ 3}{\frac 1 i!} = {E}} } _p displays {{BLOCK 1} E = {\math {\sigma i=0 ∞ 3} {\frac 1 i!} = {E}} } _p writing {pre S = '{\math {\frac {\cell 1 + x{sup 2} - y{sup 2} + sin(x)} {\cell 1 + {\sqrt x{sup 2} + y {sup 2}} }}} } _p displays {{BLOCK 1} S = {\math {\frac {\cell 1 + x{sup 2} - y{sup 2} + sin(x)} {\cell 1 + {\sqrt x{sup 2} + y {sup 2}} }}} } _p writing {pre '{def phi {lambda {:n} {if {= :n 0} then {\frac 1 1+...} else {\frac {\cell 1} {\cell {span {@ style="vertical-align:top; line-height:3.5em;"} 1+}{phi {- :n 1}}}}}}} -> {def phi {lambda {:n} {if {= :n 0} then {\frac 1 1+...} else {\frac {\cell 1} {\cell {span {@ style="vertical-align:top; line-height:3.5em;"}1+}{phi {- :n 1}}}}}}} '{table {tr {@ style="vertical-align:top; line-height:2.8em;"} {td Φ=} {td {\math {phi 20}}}}} } _p displays {{BLOCK 1} {center {table {tr {@ style="vertical-align:top; line-height:2.8em;"}{td Φ_=} {td {\math {phi 20}}}}} }} _h2 what about MathML? _p Remember that this [[MathML|https://en.wikipedia.org/wiki/MathML]] expression {pre < math> < mrow> < mi>x< /mi> < mo>=< /mo> < mfrac> < mrow> < mrow> < mo>-< /mo> < mi>b< /mi> < /mrow> < mo>±< /mo> < msqrt> < mrow> < msup> < mi>b< /mi> < mn>2< /mn> < /msup> < mo>-< /mo> < mrow> < mn>4< /mn> < mo>< /mo> < mi>a< /mi> < mo>< /mo> < mi>c< /mi> < /mrow> < /mrow> < /msqrt> < /mrow> < mrow> < mn>2< /mn> < mo>< /mo> < mi>a< /mi> < /mrow> < /mfrac> < /mrow> < /math> } _p displays {div {@ style="font-size:2.0em; text-align:center;"}
x
=
-
b
±
b
2
-
4
a
c
2
a
} _p to be compared with this '{lambda speech} expression {pre '{\math x = {\frac {\cell -b ± {\sqrt b{sup 2} - 4ac}} {\cell 2a} }} } _p Note that « Google removed support of MathML claiming architectural security issues and low usage do not justify their engineering time. » _p So MathML can't be the good choice. {{hide} {def BLOCK {lambda {:s} div {@ style="font-size::sem; text-align:center; font-style:italic;"}}} } {style pre { box-shadow:0 0 8px #000; padding: 10px; } #page_content div { background:#eee; padding: 10px; } }
lambdaway v.20211111