This site is supported by donations to The OEIS Foundation.

Template:Atop

From OeisWiki
Jump to: navigation, search

The {{atop}} mathematical formatting template typesets (in either HTML+CSS or LaTeX) an expression above another expression, surrounded by optional fences (parentheses, double parentheses, [square] brackets, double [square] brackets, [angle] brackets, double [angle] brackets, [curly] braces or double [curly] braces). It is equivalent to the { {{{1|}}} \atop {{{2|}}} } LaTeX command, not considering the [optional] fences.

Usage

{{atop|expression above|expression below|format}}

or

{{atop|expression above|expression below|fences|format}}

where [optional third argument, default: no fences] fences is among

  • ( ): parentheses, or
  • (( )): double parentheses, or
  • [ ]: [square] brackets, or
  • [[ ]]: double [square] brackets, or
  • < >: [angle] brackets, or
  • << >>: double [angle] brackets, or
  • { }: [curly] braces, or
  • {{ }}: double [curly] braces;

and where [optional last argument] format is among

  • htm: HTML+CSS text style (default), or
  • HTM: HTML+CSS display style, or
  • tex: LaTeX text style, or
  • TEX: LaTeX display style.

Examples

The code

: {{repeat|12|yadda}}{{nl}}{{repeat|12|yadda}}{{nl}}before {{math|{{atop|''n''|''k''}}, {{atop|''n''|''k''|( )}}, {{atop|''n''|''k''|(( ))}}, {{atop|''n''|''k''|[ ]}}, {{atop|''n''|''k''|[[ ]]}}, <!--
-->{{atop|''n''|''k''|< >}}, {{atop|''n''|''k''|<< >>}}, {{atop|''n''|''k''|{ }|htm}}, {{atop|''n''|''k''|{{ }}|htm}},
|tex = {{atop|n|k|tex}}, {{atop|n|k|( )|tex}}, {{atop|n|k|(( ))|tex}}, {{atop|n|k|[ ]|tex}}, {{atop|n|k|[[ ]]|tex}}, {{atop|n|k|< >|tex}}, {{atop|n|k|<< >>|tex}}, {{atop|n|k|{ }|tex}}, {{atop|n|k|{{ }}|tex}},|&}} <!--
-->and after{{nl}}{{repeat|12|yadda}}{{nl}}{{repeat|12|yadda}}

yields the text style HTML+CSS

yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
before
  nk  , (  nk  ), ((  nk  )), [  nk  ], [[  nk  ]],   〈  nk    ,   〈 〈  nk   〉  , {  nk  }, {{  nk  }},
and after
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda

The code

: {{repeat|12|yadda}}{{nl}}{{repeat|12|yadda}}{{nl}}before {{math|{{atop|''n''|''k''}}, {{atop|''n''|''k''|( )}}, {{atop|''n''|''k''|(( ))}}, {{atop|''n''|''k''|[ ]}}, {{atop|''n''|''k''|[[ ]]}}, <!--
-->{{atop|''n''|''k''|< >}}, {{atop|''n''|''k''|<< >>}}, {{atop|''n''|''k''|{ }|htm}}, {{atop|''n''|''k''|{{ }}|htm}},
|tex = {{atop|n|k|tex}}, {{atop|n|k|( )|tex}}, {{atop|n|k|(( ))|tex}}, {{atop|n|k|[ ]|tex}}, {{atop|n|k|[[ ]]|tex}}, {{atop|n|k|< >|tex}}, {{atop|n|k|<< >>|tex}}, {{atop|n|k|{ }|tex}}, {{atop|n|k|{{ }}|tex}},|$}} <!--
-->and after{{nl}}{{repeat|12|yadda}}{{nl}}{{repeat|12|yadda}}

yields the text style LaTeX

yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
before and after
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda
yaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayaddayadda

The code (broken in 2 to avoid the 10000 character limit for template arguments)

{{indent}}{{math|{{atop|''n''|''k''|HTM}}, {{atop|''n''|''k''|( )|HTM}}, {{atop|''n''|''k''|(( ))|HTM}}, {{atop|''n''|''k''|[ ]|HTM}}, {{atop|''n''|''k''|[[ ]]|HTM}},
|tex = {{atop|n|k|TEX}}, {{atop|n|k|( )|TEX}}, {{atop|n|k|(( ))|TEX}}, {{atop|n|k|[ ]|TEX}}, {{atop|n|k|[[ ]]|TEX}},|&&}} <!--
-->{{math|{{atop|''n''|''k''|< >|HTM}}, {{atop|''n''|''k''|<< >>|HTM}}, {{atop|''n''|''k''|{ }|HTM}}, {{atop|''n''|''k''|{{ }}|HTM}}, ...
|tex = {{atop|n|k|< >|TEX}}, {{atop|n|k|<< >>|TEX}}, {{atop|n|k|{ }|TEX}}, {{atop|n|k|{{ }}|TEX}}, \ldots|&&}}

yields the display style HTML+CSS

     
n
k
, (
n
k
), ((
n
k
)), [
n
k
], [[
n
k
]],
  〈
n
k
  ,   〈 〈
n
k
 〉  , {
n
k
}, {{
n
k
}}, ...

The code

{{indent}}{{math|{{atop|''n''|''k''|HTM}}, {{atop|''n''|''k''|( )|HTM}}, {{atop|''n''|''k''|(( ))|HTM}}, {{atop|''n''|''k''|[ ]|HTM}}, {{atop|''n''|''k''|[[ ]]|HTM}}, <!--
-->{{atop|''n''|''k''|< >|HTM}}, {{atop|''n''|''k''|<< >>|HTM}}, {{atop|''n''|''k''|{ }|HTM}}, {{atop|''n''|''k''|{{ }}|HTM}}, ...
|tex = {{atop|n|k|TEX}}, {{atop|n|k|( )|TEX}}, {{atop|n|k|(( ))|TEX}}, {{atop|n|k|[ ]|TEX}}, {{atop|n|k|[[ ]]|TEX}}, {{atop|n|k|< >|TEX}}, {{atop|n|k|<< >>|TEX}}, {{atop|n|k|{ }|TEX}}, {{atop|n|k|{{ }}|TEX}}, \ldots|$$}}

yields the display style LaTeX

     

Examples of mathematical notations

The code (see permutation)

: The permutation {{math|''{{Gr|sigma}}'' {{=}} {{atop|''a''{{sp|7}}''b''{{sp|7}}''c''|''b''{{sp|7}}''c''{{sp|7}}''a''|( )}}|tex = \sigma = {{atop|a \ b \ c|b \ c \ a|( )|tex}}|&}} is one of 6...

yields the text style HTML+CSS

The permutation
σ = (  a  b  cb  c  a  )
is one of 6...

The code

: The permutation {{math|''{{Gr|sigma}}'' {{=}} {{atop|''a''{{sp|7}}''b''{{sp|7}}''c''|''b''{{sp|7}}''c''{{sp|7}}''a''|( )}}|tex = \sigma = {{atop|a \ b \ c|b \ c \ a|( )|tex}}|$}} is one of 6...

yields the text style LaTeX

The permutation is one of 6...

See also