2^N -2^(-N) = C (constant) Solve for N.
I can solve this iteratively for a given C, but does it have a closed form solution? TIA.
2^N -2^(-N) = C (constant) Solve for N.
I can solve this iteratively for a given C, but does it have a closed form solution? TIA.
Usually, a little transformation will do the trick on this sort.
[tex]2^{N} - \dfrac{1}{2^{N}} = C[/tex]
[tex]2^{2N} - 1 = C\cdot 2^{N}[/tex]
Do you see it, yet?
Last edited by tkhunny; 12-05-2017 at 10:14 PM.
"Unique Answers Don't Care How You Find Them." - Many may have said it, but I hear it most from me.
The "trick" for these is to multiply through by 2^N to convert this to a quadratic form. (No, I didn't figure this out on my own, either; somebody had to show me.) It looks like this:
. . . . .[tex]2^N\, -\, 2^{-N}\, =\, C[/tex]
. . . . .[tex]2^N\, \big(2^N\, -\, 2^{-N}\big)\, =\, 2^N\, (C)[/tex]
. . . . .[tex]2^{N+N}\, -\, 2^{N-N}\, =\, 2^N\, C[/tex]
. . . . .[tex]2^{2N}\, -\, 1\, =\, 2^N\, C[/tex]
. . . . .[tex]2^{2N}\, -\, 2^N\, C\, -\, 1\, =\, 0[/tex]
. . . . .[tex](2^N)^2\, -\, (2^N)\,C\, -\, 1\, =\, 0[/tex]
This is a quadratic in 2^N, with a = 1, b = -C, and c = -1. You can solve (using the Quadratic Formula) for 2^N. Then solve the two exponential equations for N in terms of C.
If you get stuck, please reply showing your steps, starting with the last step I displayed above. Thank you!
That was a great help. The answer I get is
N = (log(C +/- sqrt(C^2 + 4)))/log2 - 1
which gives the answers I was expecting.
Bookmarks