Message-ID: <Pine.GSO.4.10.10208301438550.23267-100000@quetelet.stat.ucla.edu>
Date: 2002-08-30T21:40:28Z
From: Roger D. Peng
Subject: solving equations
In-Reply-To: <002f01c2506c$2c9a6080$39cffea9@batata>
You could try using 'uniroot':
> f <- function(F) { F - (25*(F+0.2)/22.2/(exp(F+0.2)-1)) }
> uniroot(f, c(0, 1))$root
[1] 0.6959678
-roger
_______________________________
UCLA Department of Statistics
rpeng at stat.ucla.edu
http://www.stat.ucla.edu/~rpeng
On Fri, 30 Aug 2002, Antonio Olinto wrote:
> Dear R-users,
>
> I'm trying to solve the following equation:
>
> F=25*(F+0.2)/22.2/(EXP(F+0.2)-1)
>
> In Excel I found F=0.696176718 but I'd like to know how to use R to solve
> it. I tried, without success, to use "solve".
>
> Thanks a lot,
>
> Antonio Olinto
>
>
>
>
>
>
> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
> r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
>
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._