[R] computing functions with Euler's number (e^n)
armstrong.wou at gmail.com
Thu Jul 14 18:54:16 CEST 2011
I solved this in two ways:
1. "**" was necessary to raise (-dummy + 1) to the power of B. "^" doesn't
work here, for some reason.
2. I needed to use "as.complex" which greatly simplified my code and
produces the correct response. (I had to revisit math that I had not used
in many years.)
W <- as.complex(((fq/cf[j])**B[j])*(exp(-(fq/cf[j])+1)**B[j]))
View this message in context: http://r.789695.n4.nabble.com/computing-functions-with-Euler-s-number-e-n-tp3655205p3668125.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help