සැකිල්ල:Math/doc
Appearance
This is a documentation subpage for සැකිල්ල:Math. It may contain usage information, categories and other content that is not part of the original සැකිල්ල page. |
The Math template formats HTML- or wikimarkup generated mathematical formulas in the same manner as HTML based TeX formulas, which uses a serif-based font. The generated formula is displayed using the same-size font as the adjoining text. The template will prevent line-wrapping.
Use this template for non-complex formulas as an alternative to using the "math" tag format "<math>...</math> (see: HELP:Math).
Usage
[සංස්කරණය]Use this template to wrap an inline formula in wikitext. Examples:
{{math|''x''<sup>2</sup> + ''y''<sup>2</sup> {{=}} ''r''<sup>2</sup>}}
- produces: x2 + y2 = r2
{{math|{{mapply|sin <i>π</i>}} {{=}} 0}}
- produces: සැකිල්ල:Mapply = 0. The coding "<i>" puts italic font, same as "<var>".
{{math|{{minteg|0|+∞|{{mexp|−''x''}} d''x''}} {{=}} 1}}
- produces: සැකිල්ල:Minteg = 1
'''{{math|{{frac|1|2}} − {{frac|1|3}} {{=}} {{frac|1|6}}}}'''
- produces: 1⁄2 − 1⁄3 = 1⁄6. Note the triple-apostrophes have set the whole formula as bold.
{{math|({{mrad|2}})<sup>2</sup> {{=}} 2}}
- produces: (සැකිල්ල:Mrad)2 = 2.
Use of equals-sign
[සංස්කරණය]If a single equals-sign ("=") is used, it will fail to render, instead showing "{{{1}}}". For example, the following template-coding would be invalid:
{{math|1 + 2 = 3}}
- produces: , which is invalid code
To resolve this, either: (a) Start the formula with "1=
" as in:
{{math|1=1 + 2 = 3}}
- produces: 1 + 2 = 3, or else, (b) include the equals-sign in double-braces "{{=}}" as in:
{{math|1 + 2 {{=}} 3}}
- produces: 1 + 2 = 3.
Parameters
[සංස්කරණය]The following parameters are optional:
big=1
– This wil render the formula in a bigger fontsize, increased 156%.size=font-size
– Use this to specify your own fontsize.
{{math|big=1|1 + 2 {{=}} 3}}
- produces: 1 + 2 = 3
See also
[සංස්කරණය]- {{bigmath}} is a template for stand-alone formulas, using a bigger font to match PNG rendered TeX formulas.