IFinance.Npv

Syntax

Npv(Rate: Double; Values: Array): Double;

Parameters

Parameters Description Constraints
Rate Discount rate for one period. Cannot be equal to 0
Values An array of arguments, representing costs and profits. It is required to use an array of the Double.

Description

The Npv method returns net present value of an investment, using a discount rate as well as the values of future payments (negative values) and inpayments (positive values).

Comments

It is considered that an investment, the value of which is calculated by the Npv function, starts one period before the first monetary payment of Values and ends with the last payment in the list. The Npv function calculations are based on future payments. If the first payment is in the beginning of the first period, the first value should be added to the result of the Npv function, but not included in the list of arguments.

Npv is calculated using the following formula:

Where n – the quantity of numbers in the Values argument.

Example

To execute the example, add a link to the MathFin system assembly.

Sub UserProc;
Var
    r: Double;
    Arr: Array[3Of Double;
Begin
    Arr[0] := -1;
    Arr[1] := 1.5;
    Arr[2] := 2.5;
    r := Finance.
Npv(0.15, Arr);
    Debug.WriteLine(r);
End Sub UserProc;

After executing the example the console window displays the value of net present value of investment equal to 1.9084.

See also:

IFinance