\mindpowered\financecalculatorFinanceCalculator

A library for performing various finance calculations

Summary

Methods
Properties
Constants
__construct()
PresentValueOfFutureMoney()
PresentValueOfDeposits()
FutureValue()
NetPresentValue()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

__construct()

__construct() 

FinanceCalculator

PresentValueOfFutureMoney()

PresentValueOfFutureMoney(float  $futureValue, float  $numPeriods, float  $interestRate) : object

Calculate present value of future money

Parameters

float $futureValue

Future Value

float $numPeriods

Number of Periods

float $interestRate

Interest Rate

Returns

object —

object containing Present Value and Total Interest

PresentValueOfDeposits()

PresentValueOfDeposits(float  $numPeriods, float  $interestRate, float  $depositAmount, boolean  $depositAtBeginning) : object

Calculate the present value of future deposits

Parameters

float $numPeriods

Number of Periods

float $interestRate

Interest Rate

float $depositAmount

Periodic Deposit Amount

boolean $depositAtBeginning

Periodic Deposits made at beginning of period

Returns

object —

object containing Present Value, Total Principal, and Total Interest

FutureValue()

FutureValue(float  $presentValue, float  $numPeriods, float  $interestRate, float  $timesCompoundedPerPeriod, float  $depositAmount, boolean  $depositAtBeginning) : object

Calculate the future value of money and/or deposits

Parameters

float $presentValue

Present Value

float $numPeriods

Number of Periods

float $interestRate

Interest rate as a percentage

float $timesCompoundedPerPeriod

Times interest is compounded per period

float $depositAmount

Periodic Deposit Amount

boolean $depositAtBeginning

Periodic Deposits made at beginning of period

Returns

object —

object containing Future Value and Total Interest

NetPresentValue()

NetPresentValue(float  $initialInvestment, float  $discountRate, float  $timesCompoundedPerPeriod, float  $cashFlowsAtBeginning, array  $cashFlow) : float

Calculate net present value

Parameters

float $initialInvestment

Initial Investment

float $discountRate

Discount Rate (eg. Interest Rate)

float $timesCompoundedPerPeriod

Times discount/interest is compounded per period

float $cashFlowsAtBeginning
array $cashFlow

List of cash flows per period

Returns

float —

Net Present Value