Difference between revisions of "Max Command"
From GeoGebra Manual
Line 1: | Line 1: | ||
<noinclude>{{Manual Page|version=4.0}}[[Category:Manual (official)|{{PAGENAME}}]]</noinclude> | <noinclude>{{Manual Page|version=4.0}}[[Category:Manual (official)|{{PAGENAME}}]]</noinclude> | ||
{{command|algebra}} | {{command|algebra}} | ||
− | ; Max[Number a, Number b]: Yields the maximum of the given numbers ''a'' and ''b''. | + | ;Max[Number a, Number b] |
− | ; Max[List of Numbers]: Yields the maximum of the numbers within the list. | + | :Yields the maximum of the given numbers ''a'' and ''b''. |
− | {{ | + | ;Max[List of Numbers] |
+ | :Yields the maximum of the numbers within the list. | ||
+ | {{note| If the input consists of non-numeric objects, then Max[] considers the numbers associated with those objects. For example, Max[List of Segments] will yield the maximum segment length.}} | ||
;Max[ Function, left-x, right-x ] | ;Max[ Function, left-x, right-x ] | ||
:Calculates the maximum point for function in the given interval. Function should only have on maximum point in the interval. | :Calculates the maximum point for function in the given interval. Function should only have on maximum point in the interval. | ||
− | {{ | + | {{note|See also [[Extremum Command]] and [[Function Inspector Tool]].}} |
;Max[ Interval ] | ;Max[ Interval ] | ||
:Returns the upper bound of the interval, e.g. <code>Max[2<x<3]</code> returns 3. It is the same for open and closed intervals. | :Returns the upper bound of the interval, e.g. <code>Max[2<x<3]</code> returns 3. It is the same for open and closed intervals. | ||
==CAS Syntax== | ==CAS Syntax== | ||
− | ; Max[Number a, Number b]: Yields the maximum of the given numbers ''a'' and ''b''. | + | ;Max[Number a, Number b] |
− | ; Max[List of Numbers]: Yields the maximum of the numbers within the list. | + | :Yields the maximum of the given numbers ''a'' and ''b''. |
+ | :{{example| 1=<div><code><nowiki>Max[12, 15]</nowiki></code> yields ''15''.</div>}} | ||
+ | ;Max[List of Numbers] | ||
+ | :Yields the maximum of the numbers within the list. | ||
+ | :{{example| 1=<div><code><nowiki>Max[{-2, 12, -23, 17, 15}]</nowiki></code> yields ''17''.</div>}} |
Revision as of 13:40, 18 August 2011
- Max[Number a, Number b]
- Yields the maximum of the given numbers a and b.
- Max[List of Numbers]
- Yields the maximum of the numbers within the list.
Note: If the input consists of non-numeric objects, then Max[] considers the numbers associated with those objects. For example, Max[List of Segments] will yield the maximum segment length.
- Max[ Function, left-x, right-x ]
- Calculates the maximum point for function in the given interval. Function should only have on maximum point in the interval.
Note: See also Extremum Command and Function Inspector Tool.
- Max[ Interval ]
- Returns the upper bound of the interval, e.g.
Max[2<x<3]
returns 3. It is the same for open and closed intervals.
CAS Syntax
- Max[Number a, Number b]
- Yields the maximum of the given numbers a and b.
- Example:
Max[12, 15]
yields 15.
- Max[List of Numbers]
- Yields the maximum of the numbers within the list.
- Example:
Max[{-2, 12, -23, 17, 15}]
yields 17.