This site is supported by donations to The OEIS Foundation.

Template:Mf/doc

This documentation subpage contains instructions, categories, or other information for Template:Mf. [<Edit> Template:Mf]

[⧼Purge⧽ Template:Mf/doc]

The {{mf}} (mathematical function) mathematical formatting template formats a mathematical function.

Usage

{{mf|mathematical function}}

or

{{mf|mathematical function|format}}

where format is among

Examples

Code Result Comment
{{mf|f}} f@fnsp@
{{mf|f|tex}} f@fnsp@
{{mf|f|mml}} <mo>f</mo> (MathML doesn't use the mf tagname)
{{mf|sin}} sin@fnsp@
{{mf|sin|tex}} {\rm sin }@fnsp@
{{mf|sin|mml}} <mo>sin</mo> (MathML doesn't use the mf tagname)

HTML+CSS examples

The code

: {{math|{{mf|f|htm}}({{mi|x|htm}}){{mo|def|htm}}{{mf|g|htm}}({{mi|x|htm}}){{mo}}{{mf|h|htm}}({{mi|x|htm}})|&}}


yields

 f (x) := g (x) h (x)

while the code

: {{math|{{mf|f|htm}}({{mi|x|htm}}){{mo|def|htm}}{{mf|g|htm}}({{mi|x|htm}}){{mo}}{{mf|h|htm}}({{mi|x|htm}})|&&}}


yields

 f (x):=g (x)h (x)

The code

: {{math|({{mf|sin|htm}}{{mi|x|htm}}){{^|{{mn|2|htm}}|htm}}{{mo|+|htm}}({{mf|sin|htm}}{{mi|y|htm}}){{^|{{mn|2|htm}}|htm}}{{mo|{{=}}|htm}}{{mn|1|htm}}|&}}


yields

 (sin x) 2 + (sin y) 2  Undefined symbol: =  1

while the code

: {{math|({{mf|sin|htm}}{{mi|x|htm}}){{^|{{mn|2|htm}}|htm}}{{mo|+|htm}}({{mf|sin|htm}}{{mi|y|htm}}){{^|{{mn|2|htm}}|htm}}{{mo|{{=}}|htm}}{{mn|1|htm}}|&&}}


yields

 (sin x) 2+(sin y) 2 Undefined symbol: = 1

TeX examples

The code

: {{math|{{mf|f|tex}}({{mi|x|tex}}){{mo|def|tex}}{{mf|g|tex}}({{mi|x|tex}}){{mo|tex}}{{mf|h|tex}}({{mi|x|tex}})|\$}}


yields

${\displaystyle \textstyle {f{\;\;\!\!\!}(x){\,}{\rm {:=}}{\,}g{\;\;\!\!\!}(x){\,}h{\;\;\!\!\!}(x)}}$

while the code

: {{math|{{mf|f|tex}}({{mi|x|tex}}){{mo|def|tex}}{{mf|g|tex}}({{mi|x|tex}}){{mo|tex}}{{mf|h|tex}}({{mi|x|tex}})|$$}}  yields ${\displaystyle {\begin{array}{l}\displaystyle {f(x){\rm {:=}}g(x)h(x)}\end{array}}}$ The code : {{math|({{mf|sin|tex}}{{mi|x|tex}}){{^|{{mn|2|tex}}|tex}}{{mo|+|tex}}({{mf|sin|tex}}{{mi|y|tex}}){{^|{{mn|2|tex}}|tex}}{{mo|{{=}}|tex}}{{mn|1|tex}}|}}  yields ${\displaystyle \textstyle {({\rm {sin}}{\;\;\!\!\!}x)^{2}{\,}{\rm {+}}{\,}({\rm {sin}}{\;\;\!\!\!}y)^{2}{\,}{\rm {\color {red}{\text{ Undefined symbol: = }}}}{\,}1}}$ while the code : {{math|({{mf|sin|tex}}{{mi|x|tex}}){{^|{{mn|2|tex}}|tex}}{{mo|+|tex}}({{mf|sin|tex}}{{mi|y|tex}}){{^|{{mn|2|tex}}|tex}}{{mo|{{=}}|tex}}{{mn|1|tex}}|$$}}


yields

${\displaystyle {\begin{array}{l}\displaystyle {({\rm {sin}}x)^{2}{\rm {+}}({\rm {sin}}y)^{2}{\rm {\color {red}{\text{ Undefined symbol: = }}}}1}\end{array}}}$

MathML examples

The code

: {{math|{{mf|f|mml}}({{mi|x|mml}}){{mo|def|mml}}{{mf|g|mml}}({{mi|x|mml}}){{mo|mml}}{{mf|h|mml}}({{mi|x|mml}})|mml &}}


yields

[[Category:Pages using the math template without the tex argument|Mf/doc]] <span class="math, textstyle" style="display: inline-block; margin: 0 0 -0.75ex 0; padding: 0; white-space: nowrap; position: relative; vertical-align: -0.1ex; font-size: 1.15em; font-family: 'Computer Modern', STIXGeneral, 'Times New Roman';" title="vertical-align: baseline; No LaTeX code provided."><span style="display: inline-block; margin: 0; padding: 0; position: relative; vertical-align: -0.6ex;"><table style="display: inline-table; position: relative; vertical-align: baseline; margin: 0; padding: 0; border-width: 0; border-spacing: 0; background: transparent;"><tr><td style="margin: 0; padding: 0;"><mo>f</mo>(<mi>x</mi>)<mo>'''<span style="margin-right: 0.1em; font-size: 0.6em; vertical-align: 0.6ex;">:</span>'''=</mo><mo>g</mo>(<mi>x</mi>)<mo>⁢</mo><mo>h</mo>(<mi>x</mi>)</td></tr></table></span></span>


while the code

: {{math|{{mf|f|mml}}({{mi|x|mml}}){{mo|def|mml}}{{mf|g|mml}}({{mi|x|mml}}){{mo|mml}}{{mf|h|mml}}({{mi|x|mml}})|mml &&}}


yields

[[Category:Pages using the math template without the tex argument|Mf/doc]] <span class="math, textstyle" style="display: inline-block; margin: 0 0 -0.75ex 0; padding: 0; white-space: nowrap; position: relative; vertical-align: -0.1ex; font-size: 1.15em; font-family: 'Computer Modern', STIXGeneral, 'Times New Roman';" title="vertical-align: baseline; No LaTeX code provided."><span style="display: inline-block; margin: 0; padding: 0; position: relative; vertical-align: -0.6ex;"><table style="display: inline-table; position: relative; vertical-align: baseline; margin: 0; padding: 0; border-width: 0; border-spacing: 0; background: transparent;"><tr><td style="margin: 0; padding: 0;"><mo>f</mo>(<mi>x</mi>)<mo>'''<span style="margin-right: 0.1em; font-size: 0.6em; vertical-align: 0.6ex;">:</span>'''=</mo><mo>g</mo>(<mi>x</mi>)<mo>⁢</mo><mo>h</mo>(<mi>x</mi>)</td></tr></table></span></span>


The code

{{math|({{mf|sin|mml}}{{mi|x|mml}}){{^|{{mn|2|mml}}}}{{mo|+|mml}}({{mf|sin|mml}}{{mi|y|mml}}){{^|{{mn|2|mml}}}}{{mo|{{=}}|mml}}{{mn|1|mml}}|mml &}}


yields

[[Category:Pages using the math template without the tex argument|Mf/doc]] <span class="math, textstyle" style="display: inline-block; margin: 0 0 -0.75ex 0; padding: 0; white-space: nowrap; position: relative; vertical-align: -0.1ex; font-size: 1.15em; font-family: 'Computer Modern', STIXGeneral, 'Times New Roman';" title="vertical-align: baseline; No LaTeX code provided."><span style="display: inline-block; margin: 0; padding: 0; position: relative; vertical-align: -0.6ex;"><table style="display: inline-table; position: relative; vertical-align: baseline; margin: 0; padding: 0; border-width: 0; border-spacing: 0; background: transparent;"><tr><td style="margin: 0; padding: 0;">(<mo>sin</mo><mi>x</mi>)<span style="position: relative; vertical-align: 1.25ex; line-height: 0.75ex; font-size: 0.75em;"><span style="position: relative; vertical-align: middle;"> <mn>2</mn></span></span><mo>+</mo>(<mo>sin</mo><mi>y</mi>)<span style="position: relative; vertical-align: 1.25ex; line-height: 0.75ex; font-size: 0.75em;"><span style="position: relative; vertical-align: middle;"> <mn>2</mn></span></span><mo>=</mo><mn>1</mn></td></tr></table></span></span>


while the code

{{math|({{mf|sin|mml}}{{mi|x|mml}}){{^|{{mn|2|mml}}}}{{mo|+|mml}}({{mf|sin|mml}}{{mi|y|mml}}){{^|{{mn|2|mml}}}}{{mo|{{=}}|mml}}{{mn|1|mml}}|mml &&}}


yields

[[Category:Pages using the math template without the tex argument|Mf/doc]] <span class="math, textstyle" style="display: inline-block; margin: 0 0 -0.75ex 0; padding: 0; white-space: nowrap; position: relative; vertical-align: -0.1ex; font-size: 1.15em; font-family: 'Computer Modern', STIXGeneral, 'Times New Roman';" title="vertical-align: baseline; No LaTeX code provided."><span style="display: inline-block; margin: 0; padding: 0; position: relative; vertical-align: -0.6ex;"><table style="display: inline-table; position: relative; vertical-align: baseline; margin: 0; padding: 0; border-width: 0; border-spacing: 0; background: transparent;"><tr><td style="margin: 0; padding: 0;">(<mo>sin</mo><mi>x</mi>)<span style="position: relative; vertical-align: 1.25ex; line-height: 0.75ex; font-size: 0.75em;"><span style="position: relative; vertical-align: middle;"> <mn>2</mn></span></span><mo>+</mo>(<mo>sin</mo><mi>y</mi>)<span style="position: relative; vertical-align: 1.25ex; line-height: 0.75ex; font-size: 0.75em;"><span style="position: relative; vertical-align: middle;"> <mn>2</mn></span></span><mo>=</mo><mn>1</mn></td></tr></table></span></span>


Code