13-12
Using mathematical functions
Example
For
x
4
+2x
3
–25x
2
–26x+120
:
POLYEVAL([1,2,-25,-26,120],8)
returns
3432
.
POLYFORM
Polynomial form. Creates a polynomial in
variable1
from
expression.
POLYFORM
(
expression
,
variable1
)
Example
POLYFORM((X+1)^2+1,X)
returns
X^2+2*X+2
.
POLYROOT
Polynomial roots. Returns the roots for the
n
th-order
polynomial with the specified
n
+1
coefficients
.
POLYROOT
([
coefficients
])
Example
For
x
4
+2x
3
–25x
2
–26x+120
:
POLYROOT([1,2,-25,-26,120])
returns
[2,-3,4,-5]
.
H I N T
The results of POLYROOT will often not be easily seen in
HOME due to the number of decimal places, especially if
they are complex numbers. It is better to store the results
of POLYROOT to a matrix.
For example,
POLYROOT([1,0,0,-8]
M1
will
store the three complex cube roots of 8 to matrix M1 as
a complex vector. Then you can see them easily by going
to the Matrix Catalog. and access them individually in
calculations by referring to M1(1), M1(2) etc.
Probability functions
COMB
Number of combinations (without regard to order) of
n
things taken
r
at a time:
n!/(r!(n-r))
.
COMB
(n, r)
Example
COMB(5,2)
returns
10
. That is, there are ten
different ways that five things can be combined two
at a time.!
hp40g+.book Page 12 Friday, December 9, 2005 1:03 AM
Summary of Contents for 40gs
Page 10: ...hp40g book Page x Friday December 9 2005 1 03 AM ...
Page 64: ...hp40g book Page 22 Friday December 9 2005 1 03 AM ...
Page 80: ...hp40g book Page 4 Friday December 9 2005 1 03 AM ...
Page 86: ...hp40g book Page 4 Friday December 9 2005 1 03 AM ...
Page 100: ...hp40g book Page 4 Friday December 9 2005 1 03 AM ...
Page 126: ...hp40g book Page 22 Friday December 9 2005 1 03 AM ...
Page 182: ...hp40g book Page 28 Friday December 9 2005 1 03 AM ...
Page 274: ...hp40g book Page 22 Friday December 9 2005 1 03 AM ...
Page 303: ...Step by Step Examples 16 29 hp40g book Page 29 Friday December 9 2005 1 03 AM ...
Page 304: ...hp40g book Page 30 Friday December 9 2005 1 03 AM ...
Page 314: ...hp40g book Page 10 Friday December 9 2005 1 03 AM ...
Page 330: ...hp40g book Page 16 Friday December 9 2005 1 03 AM ...
Page 392: ...hp40g book Page 44 Friday December 9 2005 1 03 AM ...
Page 420: ...hp40g book Page 22 Friday December 9 2005 1 03 AM ...
Page 428: ...hp40g book Page 8 Friday December 9 2005 1 03 AM ...
Page 444: ...hp40g book Page 16 Friday December 9 2005 1 03 AM ...