<A NAME=num_solve>
<TITLE>num_solve</TITLE></A>
<b><a href=r37_idx.html>INDEX</a></b><p><p>
<B>NUM_SOLVE</B> _ _ _ _ _ _ _ _ _ _ _ _ <B>operator</B><P>
<P>
<P>
<P>
An adaptively damped Newton iteration is used to find
an approximative root of a function (function vector) or the
solution of an
<A HREF=r37_0045.html>equation</A> (equation system). The expressions
must have continuous derivatives for all variables.
A starting point for the iteration can be given. If not given
random values are taken instead. When the number of
forms is not equal to the number of variables, the
Newton method cannot be applied. Then the minimum
of the sum of absolute squares is located instead.
<P>
<P>
With
<A HREF=r37_0274.html>complex</A> on, solutions with imaginary parts can be
found, if either the expression(s) or the starting point
contain a nonzero imaginary part.
<P>
<P>
<P> <H3>
syntax: </H3>
<em>num_solve</em>(<exp>, <var>[=<val>][,accuracy=<a>][,
iterations=<i>])
<P>
<P>
or
<P>
<P>
<em>num_solve</em>({<exp>,...,<exp>}, <var>[=<val>],...,
<var>[=<val>]
[,accuracy=<a>][,iterations=<i>])
<P>
<P>
or
<P>
<P>
<em>num_solve</em>({<exp>,...,<exp>}, {<var>[=<val>],...
,<var>[=<val>]}
[,accuracy=<a>][,iterations=<i>])
<P>
<P>
<P>
<P>
where <exp> are function expressions,
<var> are the variables,
<val> are optional start values.
For <a> and <i> see
<A HREF=r37_0423.html>numeric accuracy</A>.
<P>
<P>
<em>num_solve</em>tries to find a zero/solution of the expression(s).
Result is a list of equations, where the variables are
equated to the coordinates of the result point.
<P>
<P>
The <em>Jacobian matrix</em> is stored as side effect the shared
variable <em>jacobian</em>.
<P>
<P>
<P> <H3>
examples: </H3>
<P><PRE><TT>
num_solve({sin x=cos y, x + y = 1},{x=1,y=2});
{X= - 1.8561957251,Y=2.856195584}
jacobian;
[COS(X) SIN(Y)]
[ ]
[ 1 1 ]
</TT></PRE><P>