The mathematical constants
,
and imaginary unit
are represented by
e, pi, and i
respectively,
and can be used directly. For example:
>> cos(pi)
-1
>> sin( pi)
1.224606354e-16
Note that the exact answer to
is 0 and what we are given here is only an
approximate answer since
is just an approximate representation of
,
and the
function uses numerical method.
oz
2009-12-22