[R] How to solve this complex equation
S Ellison
S.Ellison at LGCGroup.com
Tue Feb 10 11:39:22 CET 2015
> -----Original Message-----
> I want to use R to calculate the variable x which is in a complex equation in
> below:
>
> 2
> Σ[exp(-x/2)*(x^k)/(2^k*k!)]=0.05
> k=0
>
> how to solve this equation to get the exact x in R?
For a _numerical_ solution, if f(x) is your function, use uniroot to find a root of (f(x) - 0.05)
That will normally need you to define a new function g(x) = f(x)-0.05 and apply uniroot to g(x)
S Ellison
*******************************************************************
This email and any attachments are confidential. Any use, copying or
disclosure other than by the intended recipient is unauthorised. If
you have received this message in error, please notify the sender
immediately via +44(0)20 8943 7000 or notify postmaster at lgcgroup.com
and delete this message and any copies from your computer and network.
LGC Limited. Registered in England 2991879.
Registered office: Queens Road, Teddington, Middlesex, TW11 0LY, UK
More information about the R-help
mailing list