Changeset 373 for trunk


Ignore:
Timestamp:
08/08/08 16:11:31 (16 years ago)
Author:
pinsard
Message:

improvements of headers (examples and results)

Location:
trunk/SRC/Matrix
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/SRC/Matrix/different.pro

    r372 r373  
    22; 
    33; @file_comments 
    4 ; calculate the different elements of 2 matrix of positive whole numbers. 
     4; find the different elements of 2 matrixes of positive whole numbers. 
     5; 
     6; see also <pro>union</pro> and <pro>inter</pro>. 
    57; 
    68; @categories 
     
    1618; 
    1719; @returns 
    18 ; tableau 
     20; an array containing the set of values in only a. 
    1921; 
    20 ; @restrictions 
    2122; The empty set is denoted by an array with the first element equal to 
    2223; -1. 
     
    3233;   IDL> a = [2,4,6,8] 
    3334;   IDL> b = [6,1,3,2] 
    34 ;   IDL> different(a,b) = [ 4, 8]         ; Elements in A but not in B 
     35; 
     36;   IDL> res=different(a,b)  
     37;              4           8 
     38; Right because 4 and 8 are in a but not in b ! 
     39; 
     40;   IDL> res=different(b,a) 
     41;   IDL> print,res 
     42;              1           3 
     43; 
     44; Right because 1 and 3 are in b but not in a ! 
    3545; 
    3646; @history 
  • trunk/SRC/Matrix/extrac2.pro

    r372 r373  
    3333; 
    3434; @param array {in}{required} 
    35 ; a 1,2,3 or 4 dim input array 
     35; a 1d, 2d, 3d or 4d input array 
    3636; 
    3737; @param index1 {in}{required} 
     
    5757; 
    5858; @examples 
    59 ; I have a dim 2 matrix named A. I want extract a small intersection 
     59; I have a 2d matrix named A. I want extract a small intersection 
    6060; matrix 2d of the line 2, 3 and 7 and of the column 0 and 1: 
    6161; 
  • trunk/SRC/Matrix/inter.pro

    r371 r373  
    22; 
    33; @file_comments 
    4 ; calculate the intersection between 2 matrices of whole numbers 
     4; find the intersection between 2 matrices of whole numbers 
     5; 
     6; see also <pro>difference</pro> and <pro>union</pro> 
    57; 
    68; @categories 
     
    1618; 
    1719; @returns 
    18 ; tableau 
     20; an array containing the set of values in both a and b. 
    1921; 
    20 ; @restrictions  
    2122; The empty set is denoted by an array with the first element equal to 
    2223; -1. 
     
    3334;   IDL> a = [2,4,6,8] 
    3435;   IDL> b = [6,1,3,2] 
    35 ;   IDL> inter(a,b) = [ 2, 6]       ; Common elements 
     36;   IDL> res=inter(a,b) 
     37;              2           6 
     38; Right because 2 and 6 are in a and B. 
    3639; 
    3740; @history 
  • trunk/SRC/Matrix/union.pro

    r372 r373  
    22; 
    33; @file_comments 
    4 ; calculate the union between 2 matrices of whole numbers 
     4; find the union between 2 matrices of whole numbers 
    55; 
     6; see also <pro>difference</pro> and <pro>inter</pro>. 
     7 
    68; @categories 
    79; Calculation 
     
    1618; 
    1719; @returns 
    18 ; tableau 
    19 ; 
    20 ; @restrictions 
    21 ; The empty set is denoted by an array with the first element equal to -1. 
     20; an array containing the set of values in a and b. 
    2221; 
    2322; @restrictions  
     
    3231;   IDL> a = [2,4,6,8] 
    3332;   IDL> b = [6,1,3,2] 
    34 ;   IDL> union(a,b) = [ 1, 2, 3, 4, 6, 8]  ; Elements in either set 
     33;   IDL> res=union(a,b)  
     34;   IDL> print, res 
     35;           1           2           3           4           5           6 
     36           8 
     37; this is the list ao all elements in either sets. 
    3538; 
    3639; @history 
  • trunk/SRC/Matrix/zero_one.pro

    r325 r373  
    66; Matrix 
    77; 
    8 ; @param n1 {in}{required} 
     8; @param n1 {in}{required} {type=integer} 
    99; number of elements in the first dimension 
    1010; 
    11 ; @param n2 {in}{required} 
     11; @param n2 {in} {type=integer} 
    1212; number of elements in the second dimension 
    1313; 
     14; @examples 
     15; 
     16;   IDL> a=zero_one(3)    
     17;   IDL> help,a 
     18;   A               FLOAT     = Array[3] 
     19;   IDL> print,a 
     20;         0.00000      1.00000      0.00000 
     21; 
     22;   IDL> a=zero_one(2,3)    
     23;   IDL> help,a 
     24;   A               FLOAT     = Array[2, 3] 
     25;   IDL> print,a 
     26;      0.00000      1.00000 
     27;      1.00000      0.00000 
     28;      0.00000      1.00000 
     29; 
    1430; @returns 
    15 ; result 
     31; an array of n1 dimension or n1xn2 dimensions 
    1632; 
    1733; @history 
Note: See TracChangeset for help on using the changeset viewer.