Dynadot โ€” .com Transfer

Question for php pros

SpaceshipSpaceship
Watch

DomMike

Established Member
Impact
0
Hi,
I was wondering if any of you pros could help me, translate this function so I can use it in a php script.
Thanks
=========
To calculate it, you would first calculate 1 + J then take that to the -N (minus N) power, subtract that from the number 1. Now take the inverse of that (if you have a 1/X button on your calculator push that). Then multiply the result times J and then times P.

The one-liner for a program would be (adjust for your favorite language):

M = P * ( J / (1 - (1 + J) ** -N))
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
Unstoppable Domains โ€” AI StorefrontUnstoppable Domains โ€” AI Storefront
M = P * ( J / (1 - (1 + J) ** -N))

PHP:
$m = $p*($j/(1-(1+$j)**-$n));

i think thats what u need?

i didnt try this... but i think its what u want. http://php.net/ and look at there math functions im sure you can figure it out....
 
0
•••
axilant said:
PHP:
$m = $p*($j/(1-(1+$j)**-$n));

i think thats what u need?

i didnt try this... but i think its what u want. http://php.net/ and look at there math functions im sure you can figure it out....

all you have done is put a $ before the letters. somehow i do not think doing that will suddenly solve his problem.
 
0
•••
This is from the function you showed:

PHP:
$M = $P*($J/(1-(pow((1+$J), (-1*$N)))))

This is from the word description:

PHP:
$M = $P*($J*(1/(1-(pow((1+$J), (-1*$N))))))

There is a slight difference between the two, because you say J * the inverse of (1-((1+J)^-N)). But the function you put at the bottom just says J / (1-((1+J)^-N)).

Let me know if this helps.
 
Last edited:
0
•••
ok im no php pro but it looks like one of you guys solved it lol
 
0
•••
Thanks a lot eagle12.
I'll try and let you know.
Mike
 
0
•••
Dynadot โ€” .com TransferDynadot โ€” .com Transfer
CatchedCatched
Escrow.com
Spaceship
Rexus Domain
CryptoExchange.com
Domain Recover
CatchDoms
DomDB
NameFit
  • The sidebar remains visible by scrolling at a speed relative to the pageโ€™s height.
Back