Documentation:Reference:TDI NO - MdsWiki
Navigation
Personal tools

From MdsWiki

(Difference between revisions)
Jump to: navigation, search
Revision as of 21:40, 22 January 2007 (edit)
WikiSysop (Talk | contribs)

← Previous diff
Revision as of 03:52, 23 January 2007 (edit)
WikiSysop (Talk | contribs)

Next diff →
Line 12: Line 12:
Logical Elemental. Negation of logical intersection of elements. <br /> Usual Forms L NAND M. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. False if both are true; otherwise, true. <br /><br /> Example. [0,0,1,1] &amp;&amp; [0,1,0,1] is [$TRUE,$TRUE,$TRUE,$FALSE]. <br /><br /> Logical Elemental. Negation of logical intersection of elements. <br /> Usual Forms L NAND M. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. False if both are true; otherwise, true. <br /><br /> Example. [0,0,1,1] &amp;&amp; [0,1,0,1] is [$TRUE,$TRUE,$TRUE,$FALSE]. <br /><br />
- 
-<span id=“nand_not“></span> 
-==NAND_NOT (L,M)== 
- 
-Logical Elemental. Negation of logical intersection of first with <br /> negation of second. Logically equivalent to NOT(L) OR M. <br /> Accepted Form. L NAND_NOT M. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. True if L is false or M is true; otherwise, false. <br /> Example. [0,0,1,1] NAND_NOT [0,1,0,1] is <br /> [$TRUE,$TRUE,$FALSE,$TRUE]. <br /><br /> 
- 
-<span id=“ndesc“></span> 
-==NDESC (A)== 
- 
-MDS Information. The number of descriptors in an MDS record. <br /><br /> Argument. A must be an MDS class-R descriptor. <br /><br /> Signals. None. <br /> Units... None. <br /> Form.... Byte unsigned scalar. <br /> Result.. The number of descriptors in the class-R descriptor. <br /> Descriptor data types (DSC$K_DTYPE_DSC) are removed. <br /> Use NDESC for count without NID, PATH, or variable. <br /> Use NDESC_OF for count including them. <br /><br /> Examples. NDESC($VALUE) is 0. NDESC(A+B) may be error. <br /><br /> 
- 
-<span id=“ndesc_of“></span> 
-==NDESC_OF (A)== 
- 
-MDS Information. The number of descriptors in an MDS record. <br /><br /> Argument. A must be an MDS class-R descriptor. <br /><br /> Signals. None. <br /> Units... None. <br /> Form.... Byte unsigned scalar. <br /><br /> Result.. The number of descriptors in the class-R descriptor. <br /> Descriptor data types (DSC$K_DTYPE_DSC) are removed. <br /> Use NDESC for count without NID, PATH, or variable. <br /> Use NDESC_OF for count including them. <br /><br /> Examples. NDESC_OF($VALUE) is 0. NDESC_OF(A+B) is 2. <br /><br /> 
- 
-<span id=“ndims“></span> 
-==NDIMS (A)== 
- 
-MDS Information. The number of dimensions in an array or signal. <br /><br /> Argument. A can be a scalar, array or signal. <br /><br /> Result.. The number of dimensions in an array or signal. <br /> If A is a scalar, NDIMS returns 0.<br /> If A is an array or signal, NDIMS returns the number of dimensions.<br /><br /> Examples. NDIMS(42) is 0. NDIMS(ZERO([3,3],0)) is 2. NDIMS(BUILD_SIGNAL(1,*,3,4,5)) is 3.<br /><br /> 
- 
-<span id=“ne“></span> 
-==NE (X,Y)== 
- 
-Logical Elemental. Tests for inequality of two values. <br /> Usual Forms X != Y, X &lt;&gt; Y, X NE Y. F90 form /= is not allowed. <br /> Function Form NE(X,Y). <br /><br /> Arguments X and Y must both be numeric or character. <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. True if X and Y are the unequal; otherwise, false. <br /> $ROPRAND is not unequal to any value, thus gives false. <br /> &gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;WARNING, floating point operations may not match an exact <br /> calculation for nonterminating binary fractions. <br /> You cannot predict that .1+.1!=.2 will be false. <br /><br /> Example. 2&lt;&gt;2. is $FALSE. <br /><br /> 
- 
-<span id=“nearest“></span> 
-==nearest (X,S)== 
- 
-F90 Numeric Elemental. Nearest different machine represntable number in <br /> a given direction. <br /><br /> Arguments <br /> X real. <br /> S real and not zero. <br /><br /> Signals. Single signal or smaller data. <br /> Units... Same as X. <br /> Form.... Same as X. <br /><br /> Result.. The machine representable number distinct from X and <br /> nearest to it in the direction to the infinity of the <br /> same sign as S. <br /><br /> Example. NEAREST(3.0,2.0) is 3+2^(-22). <br /><br /> 
- 
-<span id=“neqv“></span> 
-==NEQV (L,M)== 
- 
-Logical Elemental. Test that logical values are unequal. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /> Result.. True if exactly one of X and Y are true; <br /> otherwise, false. <br /><br /> Example. 2&gt;3 NEQV 3&gt;4 is $FALSE. <br /><br /> 
- 
-<span id=“nint“></span> 
-==NINT (A,[KIND])== 
- 
-F90 Numeric Elemental. Nearest integer. <br /><br /> Argument. Optional: KIND. <br /> A real. Complex numbers are an error. <br /> Integers are passed. <br /> KIND scalar integer type number, for example, KIND(1). <br /> (Today. Ignored, always returns LONG.) <br /><br /> Signals. Same as A. <br /> Units... Same as A. <br /> Form.... Integer. <br /><br /> Result.. If A&gt;0, NINT(A) is INT(A+0.5); else it is INT(A-0.5). <br /><br /> Examples. NINT(2.783) is 3. NINT(-2.783) is -3. <br /><br /> 
- 
-<span id=“nor“></span> 
-==NOR (L,M)== 
- 
-Logical Elemental. Negation of logical union of elements. <br /> Usual Forms L NOR M. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. False if either is true; otherwise, true. <br /><br /> Example. [0,0,1,1] &amp;&amp; [0,1,0,1] is [$TRUE,$FALSE,$FALSE,$FALSE]. <br /><br /> 
- 
-<span id=“nor_not“></span> 
-==NOR_NOT (L,M)== 
- 
-Logical Elemental. Negation of logical union of first with negation <br /> of second. Logically equivalent to NOT(L) AND M. <br /> Accepted Form. L NOR_NOT M. <br /><br /> Arguments L and M must be logical (lowest bit is 1 for true). <br /><br /> Signals. Single signal or smaller data. <br /> Units... None unless both have units and they don't match. <br /> Form.... Logical of compatible shape. <br /><br /> Result.. True if L is false and M is true; otherwise, false. <br /><br /> Example. [0,0,1,1] NOR_NOT [0,1,0,1] is <br /> [$FALSE,$TRUE,$FALSE,$FALSE]. <br /><br /> 
- 
-<span id=“not“></span> 
-==NOT (L)== 
- 
-Logical Elemental. Negate a logical. True is 1BU, False is 0BU. <br /> Usual Form ! L or NOT L. <br /> Function Form NOT(L). <br /><br /> Argument. L must be logical. <br /><br /> Signals. Same as L. <br /> Units... Same as L. <br /> Form.... Logical. <br /><br /> Result.. True if lowest bit of converted integer is off. <br /> &gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;WARNING, do not confuse this with the bit-wise INOT(J). <br /> What F90 calls NOT, we call INOT. <br /><br /> Example. NOT([1,2,3]) is [$FALSE,$TRUE,$FALSE]). <br /><br /> 
- 
-<span id=“object_of“></span> 
-==OBJECT_OF (A)== 
- 
-MDS Operation. Get the object field. <br /><br /> Argument. Descriptor as below. <br /><br /> Result.. A is searched for this: <br /> DSC$K_DTYPE_METHOD, the object field. <br /> Otherwise, an error. <br /><br /> 
- 
-<span id=“octaword“></span> 
-==OCTAWORD (A)== 
- 
-Conversion Elemental. Convert to octaword (16-byte) integer. <br /><br /> Argument. A must be numeric. <br /><br /> Signals. Same as A. <br /> Units... Same as A. <br /> Form.... Octaword-length integer. <br /><br /> Result.. The truncated whole part of A. <br /> Immediate at compilation. <br /> &gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;WARNING, truncation does not cause an error. <br /><br /> Examples. OCTAWORD(123) is 123O. OCTAWORD(65537) is 65537O. <br /><br /> 
- 
-<span id=“octaword_unsigned“></span> 
-==OCTAWORD_UNSIGNED (A)== 
- 
-Conversion Elemental. Convert to octaword (16-byte) unsigned integer. <br /><br /> Argument. A must be numeric. <br /><br /> Signals. Same as A. <br /> Units... Same as A. <br /> Form.... Octaword-length unsigned integer. <br /><br /> Result.. The truncated whole part of A. <br /> Immediate at compilation. <br /> &gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;WARNING, truncation does not cause an error. <br /> Example. OCTAWORD_UNSIGNED(123) is 123oU. <br /><br /> 
- 
-<span id=“on_error“></span> 
-==on_error ([A])== 
- 
-Miscellaneous. On an error do the action A. <br /><br /> Argument. Optional: A. <br /> A may be any expression. The default is to cancel previous <br /> setting. <br /><br /> Result.. The result of action A. <br /> Example. ?? if ever. <br /><br /> 
- 
-<span id=“opcode_builtin“></span> 
-==OPCODE_BUILTIN (I)== 
- 
-MDS Information. The string name of a builtin's opcode. <br /><br /> Argument. I must be an unsigned word scalar. It must be from 0 to <br /> the number of defined opcodes less one. <br /><br /> Signals. Same as I. <br /> Units... Same as I. <br /> Form.... Character scalar of same shape. <br /> Result.. The uppercase name for the opcode. <br /><br /> Example. OPCODE_BUILTIN(0) is "$". <br /><br /> 
- 
-<span id=“opcode_string“></span> 
-==OPCODE_STRING (I)== 
- 
-MDS Information. The string name of an opcode. <br /><br /> Argument. I must be an unsigned word scalar. It must be from 0 to <br /> the number of defined opcodes less one. <br /><br /> Signals. Same as I. <br /> Units... Same as I. <br /> Form.... Character scalar of same shape. <br /><br /> Result.. The uppercase name for the opcode. <br /><br /> Example. OPCODE_STRING(0) is "OPC$$". <br /><br /> 
<span id=“or“></span> <span id=“or“></span>

Revision as of 03:52, 23 January 2007

NAME_OF (A)

MDS Operation. Get the name field.

Argument. Descriptor as below.

Result.. A is searched for this:
DSC$K_DTYPE_CONGLOM, the name field.
Otherwise, an error.

NAND (L,M)

Logical Elemental. Negation of logical intersection of elements.
Usual Forms L NAND M.

Arguments L and M must be logical (lowest bit is 1 for true).

Signals. Single signal or smaller data.
Units... None unless both have units and they don't match.
Form.... Logical of compatible shape.

Result.. False if both are true; otherwise, true.

Example. [0,0,1,1] && [0,1,0,1] is [$TRUE,$TRUE,$TRUE,$FALSE].

OR (L,M)

Logical Elemental. Logical union of elements.
Usual Forms L || M, L OR M.
Function Form OR(L,M).

Arguments L and M must be logical (lowest bit is 1 for true).

Signals. Single signal or smaller data.
Units... None unless both have units and they don't match.
Form.... Logical of compatible shape.

Result.. True if either is true; otherwise, false.
>>>>>>>>>WARNING, do not confuse with | which is bit-wise IOR.

Example. [0,0,1,1] || [0,1,0,1] is [$FALSE,$TRUE,$TRUE,$TRUE].

OR_NOT (L,M)

Logical Elemental. Logical union of first with negation of second.
Accepted Form. L OR_NOT M.

Arguments L and M must be logical (lowest bit is 1 for true).

Signals. Single signal or smaller data.
Units... None unless both have units and they don't match.
Form.... Logical of compatible shape.

Result.. True if L is true or M is false; otherwise, false.

Example. [0,0,1,1] OR_NOT [0,1,0,1] is [$TRUE,$FALSE,$TRUE,$TRUE].