|
7.10.6.4 ncratDefine
Procedure from library ncrat.lib (see ncrat_lib).
- Usage:
- ncrat f = ncratDefine(s, l);
string s contains kind, list l contains expressions
- Return:
- ncrat with kind s and expressions l
- Note:
- assignment operator '=' for ncrat is overloaded
with this procedure, hence
ncrat f = s, l;
yields the same result as
ncrat f = ncratDefine(s, l);
Example:
| LIB "ncrat.lib";
ncInit(list("x", "y", "z"));
number n = 5;
ncrat f = ncratDefine("Const", list(n));
typeof(f);
==> ncrat
f.kind;
==> Const
f.expr;
==> [1]:
==> 5
f;
==> 5
==>
ncrat g = "Const", list(n);
g;
==> 5
==>
|
|