Шаблон:Нумерованная формула/doc
Шаблон:Закончить переводШаблон:DocpageЭтот шаблон создаёт нумерованные формулы.
Параметры
Параметры {{{1}}}, {{{2}}}, и {{{3}}} шаблона обязательны. Дополнительно, есть две возможных опции {{{RawN}}} и {{{LnSty}}}.
{{{1}}}: Определяет отступ. Чем больше здесь двоеточий (:), тем дальше вправо сдвинется блок. Поддерживается не более 20 двоеточий. Этот параметр может быть пустой.
{{{2}}}: Сама формула, оформленная тэгами <math> или <chem>.
{{{3}}}: Номер формулы.
{{{RawN}}}: Если непустой, то убирает скобки и форматирование номера формулы.
{{{LnSty}}}: Стиль линии.
Примеры
Equations may render HTML | ||
|---|---|---|
|
|
||
|
|
||
|
|
||
Абзац | ||
|
|
||
|
|
||
|
|
||
|
|
||
Форматирование номера формулы | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
Стиль линий | ||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
|
||
Positioning relative to surrounding imagesNumbered blocks should be able to be placed around images that take up space on the left or right side of the screen. To ensure numbered block has access to the entire line, consider using a Шаблон:Tl-like template. To illustrate, consider the example:
Table caveatBecause Шаблон:Tl is implemented as a table, putting Шаблон:Tl within a table yields a nested table. Due to a bug in Mediawiki's handling of nested tables, Шаблон:Tl must be used carefully in this case. In particular, when indentation for the outer table is desired, use explicit <dl><dd> and </dd></dl> tags for indentation instead of a leading colon (:). For example, <dl><dd>
{|
|<math>(f * g)[n]\,</math>
|{{Нумерованная формула||<math>\stackrel{\mathrm{def}}{=}\sum_{m=-\infty}^{\infty} f[m]\cdot g[n - m]\,</math>|
3=<font color=darkred>'''(Eq.1)'''</font>|RawN=.}}
|-
|
|<math>= \sum_{m=-\infty}^{\infty} f[n-m]\cdot g[m].\,</math> ([[Convolution#Commutativity|commutativity]])
|}
</dd></dl>
produces which shows how the outer <dl><dd> and </dd></dl> tags give the same indentation as a single colon (:) preceding the table should. For another example, <dl><dd>
<dl><dd>
{|
|-
|The first parameter for indentation still works when used inside table.
{{Нумерованная формула|::::|<math>ax^2+bx+c=0</math>|Level 4}}
{{Нумерованная формула|:::|<math>ax^2+bx+c=0</math>|Level 3}}
{{Нумерованная формула|::|<math>ax^2+bx+c=0</math>|Level 2}}
{{Нумерованная формула|:|<math>ax^2+bx+c=0</math>|Level 1}}
{{Нумерованная формула||<math>ax^2+bx+c=0</math>|Level 0}}
|-
|}
</dd></dl>
</dd></dl>
produces
which uses two sets of explicit tags to give the same indentation as two colons (::). | ||