Bug 100762 - NPV function, second parameter array
Summary: NPV function, second parameter array
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Winfried Donkers
Whiteboard: target:5.3.0
Depends on:
Reported: 2016-07-04 14:47 UTC by raal
Modified: 2016-10-25 18:39 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Note You need to log in before you can comment on or make changes to this bug.
Description raal 2016-07-04 14:47:37 UTC
=NPV(0,0875;{10;20;30}) throws error in Calc, return result in Excel. 

ODF spec:
  *Summary:* Compute the net present value (NPV) for a series of periodic cash
  *Syntax:* NPV( /Number/ Rate ; { /NumberSequenceList/ Value } + )
Comment 1 Dennis Roczek 2016-07-04 15:13:04 UTC




Same for Excel: 
does not work here (Excel 2013)
Comment 2 Dennis Roczek 2016-07-04 15:14:24 UTC
@raal: the spec is nothing saying about brackets. This is the annotation that there can be inserted multiple values in that formula. see the helpwiki link
Comment 3 Dennis Roczek 2016-07-04 15:25:41 UTC
sry for the noise.

CONFIRMED: Arrays are really not yet integrated in Calc.
Comment 4 Eike Rathke 2016-07-04 18:03:30 UTC
Be careful with the separators, =NPV(0.0875,{10,20,30}) or =NPV(0.0875,{10;20;30}) work in Excel.
Comment 5 Winfried Donkers 2016-07-08 05:42:36 UTC
Will add support for array arguments.
Comment 6 Commit Notification 2016-07-12 12:39:29 UTC
Winfried Donkers committed a patch related to this issue.
It has been pushed to "master":


tdf#100762 Add support for array arguments to NPV.

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:

Affected users are encouraged to test the fix and report feedback.