Programmer Guide/Command Reference/EVAL/init: Difference between revisions
From STX Wiki
< Programmer Guide | Command Reference | EVAL
Jump to navigationJump to search
No edit summary |
No edit summary |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 3: | Line 3: | ||
;Usage: <code>init(<var>n</var> {, <var>m</var> {, <var>v</var>}})</code> | ;Usage: <code>init(<var>n</var> {, <var>m</var> {, <var>v</var>}})</code> | ||
:;<var>n</var>: number of rows, ''n''>1 | :;<var>n</var>: number of rows, ''n''>1 | ||
:;<var>m</var>: number of columns, ''m'' | :;<var>m</var>: number of columns, ''m''≥1 (default='''1''') | ||
:;<var>v</var>: initialization value (default='''0''') | :;<var>v</var>: initialization value (default='''0''') | ||
:All arguments are scalars! | |||
;Result: The result is a numerical object with ''n'' rows and ''m'' columns. All elements are set to ''v''. | ;Result: The result is a numerical object with ''n'' rows and ''m'' columns. All elements are set to ''v''. | ||
;See also: [[ | ;See also: [[../fill|fill]], [[../rand|rand]] | ||
[[ | [[../#Functions|<function list>]] | ||
Latest revision as of 19:17, 21 April 2011
Create a vector or a matrix and initialize it with a particular value.