0
votes
0answers
27 views

Function plotting

I have a function $f(x)=\binom{N}{K} \ln(1-F(x)), x \geq 0$, where $F(x)$ is a cumulative distribution function. Then, $\ln(1-F(x))$ is negative for various values of $x$ as $F(x) \geq 0$. Also, ...
1
vote
2answers
65 views

Exponential of a 3x3 lower bidiagonal matrix

I have a 3x3 matrix with non-zero entries ONLY along the main diagonal and the diagonal above. There are exactly two non zero diagonals in the matrix like this \begin{pmatrix} a & 0 & 0 \\ d ...
3
votes
4answers
135 views

Computing a large exp(x) in a numerically robust way.

I'm trying to compute $\lfloor e^x \rfloor$, where x is a 64-bit integer. The problem is that the result of the computation may be close to 2^64. In this range, 64-bit floating point numbers will be ...
1
vote
0answers
55 views

Algorithm for finding power

I has been searching for a high precision library in PHP to do calculations like $$232323232323^{121212.2232323232}$$ etc (ie, with very large numbers, including decimals), but failed to get any. ...
29
votes
1answer
552 views

How do I calculate the 2nd term of continued fraction for the power tower ${^5}e=e^{e^{e^{e^{e}}}}$

I need to find the 2nd term of continued fraction for the power tower ${^5}e=e^{e^{e^{e^{e}}}}$ ( i.e. $\lfloor\{e^{e^{e^{e^{e}}}}\}^{-1}\rfloor$), or even higher towers. The number is too big to ...
2
votes
3answers
263 views

Calculating powers

I was thinking how I could program powers into my application. And I want to do this without using the default math libraries. I want to use only +,-,* and /. So I wondered what is the definition of a ...
1
vote
1answer
139 views

Solve for variable inside multiple power in terms of the powers.

I'm a programmer working to write test software. Currently estimates the values it needs with by testing with a brute force algorithm. I'm trying to improve the math behind the software so that I can ...
6
votes
4answers
259 views

What is a nice way to compute $f(x) = x / (\exp(x) - 1)$?

I want it to be stable near $f(0) = 1$. Is there a nice function that does this already, like maybe a hyperbolic trig function or something like expm1, or should I just check if $x$ is near zero and ...
3
votes
0answers
81 views

Numerically estimate $a^b$ [duplicate]

Possible Duplicate: How can I calculate non-integer exponents? What is the most efficient way to estimate $a^b$ ($a > 0$) numerically? My goal is not to use built-in math functions (like ...
1
vote
5answers
169 views

How can I find $c=d^x$ using only basic computer functions?

Since this seems more like a math question than programming, I'm placing it here instead of on SO I'm trying to find $x$ when $c$ and $d$ are known constants (user input and iteration counter, ...
5
votes
2answers
2k views

How can I calculate non-integer exponents?

I can calculate the result of $x^y$ provided that $y \in\mathbb{N}, x \neq 0$ using a simple recursive function: $$ f(x,y) = \begin {cases} 1 & y = 0 \\ (x)f(x, y-1) & y > 0 \end ...
12
votes
9answers
4k views

How to calculate $e^x$ with a standard calculator

Is there a simple method for calculating the $e^x$ ($x\in\mathbb{R}$) with a basic add/subtract/multiply/divide calculator that converges in reasonable time, preferably without having to memorize ...
2
votes
1answer
199 views

Extended Lambert W function?

I need to solve something like this $$\exp(-a x) = \frac1{x^b}$$ where $a$ and $b$ are positive real values. Do other results exist when $b > 1$ or do I have to rely on numerical inspection?