This site is supported by donations to The OEIS Foundation.

Template:Sequence/doc

From OeisWiki
Jump to: navigation, search

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

[⧼Purge⧽ Template:Sequence/doc]

The {{sequence}} (or {{seq}}) OEIS Wiki utility template shows a tooltip with the sequence name when the mouse rolls over the corresponding A-number. (It uses the {{sequence/list/names}} sequence names database template containing a "database" of A-numbers and their associated sequence names to obtain the sequence name.)

Note: Many web browsers (such as Firefox, Google Chrome, Internet Explorer, Opera, Safari) are enabled to show a tooltip when a user hovers over the text. However, this behavior is not guaranteed and should not be relied on.

Warning: In the sequence name, a vertical pipe cannot be used (you must use the the &#x007C; numeric entity), e.g. for absolute value, otherwise the name gets truncated in the name string produced by this template and/or in the tooltip produced by the {{sequence}} template. (See A000099 in the {{sequence}} template page.)

Usage

{{sequence|A-number}}

or

{{seq|A-number}}

Examples

Examples with valid input

Code Result
{{seq|A0}} A000000
{{seq|A1}} A000001
{{seq|A01}} A000001
{{seq|A2}} A000002
{{seq|A002}} A000002
{{seq|A3}} A000003
{{seq|A12}} A000012
{{seq|A012}} A000012
{{seq|A37}} A000037
{{seq|A037}} A000037

Code Result Comment
{{seq|A000000}} A000000
{{seq|A000001}} A000001
{{seq|A000002}} A000002
{{seq|A000003}} A000003
{{seq|A000004}} A000004
{{seq|A000095}} A000095
{{seq|A000096}} A000096
{{seq|A000097}} A000097
{{seq|A000098}} A000098
{{seq|A000099}} A000099 (The vertical pipe must be replaced by the &#x007C; numeric entity.)

Code Result
{{seq|A000100}} A000100
{{seq|A000101}} A000101
{{seq|A000102}} A000102
{{seq|A000103}} A000103
{{seq|A000104}} A000104
{{seq|A000195}} A000195
{{seq|A000196}} A000196
{{seq|A000197}} A000197
{{seq|A000198}} A000198
{{seq|A000199}} A000199

Code Result
{{seq|A000200}} A000200
{{seq|A000201}} A000201
{{seq|A000202}} A000202
{{seq|A000203}} A000203
{{seq|A000204}} A000204
{{seq|A000295}} A000295
{{seq|A000296}} A000296
{{seq|A000297}} A000297
{{seq|A000298}} A000298
{{seq|A000299}} A000299

Code Result
{{seq|A000300}} A000300
{{seq|A000301}} A000301
{{seq|A000302}} A000302
{{seq|A000303}} A000303
{{seq|A000304}} A000304
{{seq|A000395}} A000395
{{seq|A000396}} A000396
{{seq|A000397}} A000397
{{seq|A000398}} A000398
{{seq|A000399}} A000399

Code Result
{{seq|A000500}} A000500
{{seq|A000501}} A000501
{{seq|A000502}} A000502
{{seq|A000503}} A000503
{{seq|A000504}} A000504
{{seq|A000595}} A000595
{{seq|A000596}} A000596
{{seq|A000597}} A000597
{{seq|A000598}} A000598
{{seq|A000599}} A000599

Code Result
{{seq|A000700}} A000700
{{seq|A000701}} A000701
{{seq|A000702}} A000702
{{seq|A000703}} A000703
{{seq|A000704}} A000704
{{seq|A000795}} A000795
{{seq|A000796}} A000796
{{seq|A000797}} A000797
{{seq|A000798}} A000798
{{seq|A000799}} A000799

Code Result
{{seq|A000900}} A000900
{{seq|A000901}} A000901
{{seq|A000902}} A000902
{{seq|A000903}} A000903
{{seq|A000904}} A000904
{{seq|A000995}} A000995
{{seq|A000996}} A000996
{{seq|A000997}} A000997
{{seq|A000998}} A000998
{{seq|A000999}} A000999

Code Result
{{seq|A001000}} A001000
{{seq|A002000}} A002000
{{seq|A005000}} A005000
{{seq|A010000}} A010000
{{seq|A020000}} A020000
{{seq|A050000}} A050000
{{seq|A100000}} A100000
{{seq|A200000}} A200000
{{seq|A500000}} A500000

Examples with invalid input

Code Result
{{seq}} Sequence error: Argument must be an A-number!
{{seq|}} Sequence error: Argument must be an A-number!
{{seq|45}} Sequence error: Argument must be an A-number!
{{seq|a-100}} Sequence error: Argument must be an A-number!
{{seq|a100000}} Sequence error: Argument must be an A-number!
{{seq|B100000}} Sequence error: Argument must be an A-number!
{{seq|A1000000}} Sequence error: Argument must be an A-number between A000000 and A999999!
{{seq|A}} Sequence error: Argument must be an A-number!
{{seq|A100012!}} Sequence error: Argument must be an A-number!

Code

<noinclude>{{documentation}}</noinclude><includeonly><!--

Uses Template:Sequence/list/names sequence names "database" template (which uses sequence names "database" tables templates (of [[A-numbers]] and their respective sequence names).
 
-->{{#ifeq: {{#pos:{{{1|}}}|A}} | 0
| {{ifinteger| ( {{#if: {{#sub:{{{1|}}}|1}} | {{#sub:{{{1|}}}|1}} | NOTINT! }} )
  | {{#ifexpr: ( ( {{#sub:{{{1|}}}|1}} ) >= 0 ) and ( ( {{#sub:{{{1|}}}|1}} ) <= 999999 )   
    | {{tooltip| A{{repeat|{{#expr: 7 - {{#len:{{{1|}}}}} }}|0}}{{#sub:{{{1|}}}|1}} | {{Sequence/list/names| A{{repeat|{{#expr: 7 - {{#len:{{{1|}}}}} }}|0}}{{#sub:{{{1|}}}|1}} }} }}
    | {{error| Sequence error: Argument must be an [[A-number]] between A000000 and A999999! }} 
    }}
  | {{error| Sequence error: Argument must be an [[A-number]]! }}
  }}
| {{error| Sequence error: Argument must be an [[A-number]]! }} 
}}</includeonly>