1 | <?php |
||
9 | class EqualPrincipalPaymentAmountCalculator extends PaymentAmountCalculator |
||
10 | { |
||
11 | /** |
||
12 | * @param array $periods |
||
13 | * @param float $presentValue |
||
14 | * @param float $interestRate |
||
15 | * @param float $futureValue |
||
16 | * @return array |
||
17 | */ |
||
18 | 4 | public function getPaymentAmounts( |
|
44 | |||
45 | /** |
||
46 | * @param float $presentValue |
||
47 | * @param float $futureValue |
||
48 | * @param int $noOfPeriods |
||
49 | * @return float |
||
50 | */ |
||
51 | 4 | private function getPrincipalPart(float $presentValue, float $futureValue, int $noOfPeriods): float |
|
57 | |||
58 | /** |
||
59 | * @param float $presentValue |
||
60 | * @param float $futureValue |
||
61 | * @param float $ratePerPeriod |
||
62 | * @param int $numberOfPeriods |
||
63 | * @return float |
||
64 | */ |
||
65 | 4 | private function getPaymentAmount( |
|
81 | } |
||
82 |