[R] finding roots of multivariate equation

Ravi Varadhan rvaradhan at jhmi.edu
Wed Jun 20 19:56:40 CEST 2007


R does not really have a dedicated solver for nonlinear systems of
equations, but instead you can use optim(), which is a minimizer.  Suppose
your system is F(x) = 0, where x \in R^p and F is a mapping from R^p to R^p,
then you minimize the norm of F.  The problem with this approach is that it
can sometimes yield local minima which are not the zeros of the original
system.  However, this can be easily remedied by using different starting
values.

Ravi.

----------------------------------------------------------------------------
-------

Ravi Varadhan, Ph.D.

Assistant Professor, The Center on Aging and Health

Division of Geriatric Medicine and Gerontology 

Johns Hopkins University

Ph: (410) 502-2619

Fax: (410) 614-9625

Email: rvaradhan at jhmi.edu

Webpage:  http://www.jhsph.edu/agingandhealth/People/Faculty/Varadhan.html

 

----------------------------------------------------------------------------
--------


-----Original Message-----
From: r-help-bounces at stat.math.ethz.ch
[mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Bill Shipley
Sent: Wednesday, June 20, 2007 1:37 PM
To: r-help at stat.math.ethz.ch
Subject: [R] finding roots of multivariate equation

Hello,
I want to find the roots of an equation in two variables.  I am aware of the
uniroot function, which can do this for a function with a single variable
(as I
understand it...) but cannot find a function that does this for an equation
with more than one variable.  I am looking for something implementing
similar
to a Newton-Raphson algorithm.
Thanks.

-- 
Bill Shipley
North American Editor for Annals of Botany
Subject Editor for Ecology
Département de biologie
Université de Sherbrooke
Sherbrooke (Québec) J1K 2R9
Canada

______________________________________________
R-help at stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list