SED navigation bar go to SED home page go to Dataplot home page go to NIST home page SED Home Page SED Staff SED Projects SED Products and Publications Search SED Pages
Dataplot Vol 2 Vol 1

MAX

Name:
    MAX (LET)
Type:
    Library Function
Purpose:
    Return the maximum of 2 to 8 numbers.
Syntax:
    LET <yout> = MAX(<y1>,..., <yk>)
                            <SUBSET/EXCEPT/FOR qualification>
    where <y1>, ..., <yk> is a list of one to eight variable or parameters;
                <yout> is a variable or a parameter (depending on what <y1> ... <yk> are) where the computed response values are stored;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.
Examples:
    LET A = MAX(14,10)
    LET A = MAX(A1,A2)
    LET A = MAX(A1,A2,A3,A4)
    LET X2 = MAX(X1,X4)
    LET X2 = MAX(X1-4,X2+6)
Note:
    This function is distinct from the LET subcommand MAXIMUM. This command compares two through eight parameters (or a pairwise comparison of the corresponding elements in two through eight variables) while MAXIMUM returns the largest value in a single variable.
Note:
    The 2010/12 version of Dataplot added support for up to eight input arguments. For example,

      LET AMAX = MAX(A1,A2,A3,A4,A5,A6,A7,A8)

    Versions prior to this only accepted two input arguments.

Default:
    None
Synonyms:
    None
Related Commands:
    MIN = Compute the minimum of two through eight numbers.
    MAXIMUM = Compute the maximum value in a variable.
    MINIMUM = Compute the minimum value in a variable.
    ABS = Compute the absolute value of a number.
Applications:
    Data Management
Implementation Date:
    Pre-1987
    2010/12: Support for up to eight input arguments
Program:
     
    LET X = SEQUENCE 0 .1 3
    LET Y1 = X**2
    LET Y2 = X**(1/2)
    LET Y3 = MAX(Y1,Y2)
    PRINT Y1 Y2 Y3
        
    The following output is generated.
     ---------------------------------------------
                  Y1             Y2             Y3
     ---------------------------------------------
             0.00000        0.00000        0.00000
             0.01000        0.31623        0.31623
             0.04000        0.44721        0.44721
             0.09000        0.54772        0.54772
             0.16000        0.63246        0.63246
             0.25000        0.70711        0.70711
             0.36000        0.77460        0.77460
             0.49000        0.83666        0.83666
             0.64000        0.89443        0.89443
             0.81000        0.94868        0.94868
             1.00000        1.00000        1.00000
             1.21000        1.04881        1.21000
             1.44000        1.09545        1.44000
             1.69000        1.14018        1.69000
             1.96000        1.18322        1.96000
             2.25000        1.22474        2.25000
             2.56000        1.26491        2.56000
             2.89000        1.30384        2.89000
             3.24000        1.34164        3.24000
             3.61000        1.37840        3.61000
             4.00000        1.41421        4.00000
             4.41000        1.44914        4.41000
             4.84000        1.48324        4.84000
             5.29000        1.51658        5.29000
             5.76000        1.54919        5.76000
             6.25000        1.58114        6.25000
             6.76000        1.61245        6.76000
             7.29000        1.64317        7.29000
             7.84000        1.67332        7.84000
             8.41000        1.70294        8.41000
             9.00000        1.73205        9.00000
        

Privacy Policy/Security Notice
Disclaimer | FOIA

NIST is an agency of the U.S. Commerce Department.

Date created: 06/28/2021
Last updated: 06/28/2021

Please email comments on this WWW page to alan.heckert@nist.gov.