Arithmetic

A worked XIRR, without the spreadsheet fog

Three dated investments, one current value, and the rate that makes the discounted pile equal zero. Load the longer SIP sample on the calculator if you want Priya’s 24-month folio.

The cash flows

Aman puts ₹25,000 into a flexi-cap fund on 5 January each year from 2022 to 2024, then checks the folio on 22 September 2026. It is worth ₹1,15,000. He has not redeemed anything yet, so that last number is treated as a redeem — “if I sold today, this is the inflow.”

DateTypeAmount
5 Jan 2022Invest−₹25,000
5 Jan 2023Invest−₹25,000
5 Jan 2024Invest−₹25,000
22 Sep 2026Current value+₹1,15,000

Invested: ₹75,000. Returned / value: ₹1,15,000. Net:₹40,000 over 4.72 years.

The equation

Let t be years from 5 Jan 2022, using actual days ÷ 365. XIRR is the rate r that solves:

−25000 / (1+r)0 − 25000 / (1+r)t₂ − 25000 / (1+r)t₃ + 115000 / (1+r)t₄ = 0

That left-hand side is the net present value (NPV) of the folio at rate r. We want the r that drives NPV to zero.

Guess, then correct — Newton–Raphson

Excel and XirrRupee start near 10% and walk downhill. You can see the same path by evaluating NPV at a few nearby rates:

Trial rateNPV of Aman’s flowsMeaning
8%+₹10,421Too cheap — the folio is worth more than an 8% hurdle.
10%+₹4,983Still a bit cheap.
12%+₹144Almost there.
12.06%₹0XIRR. Newton lands here in four iterations.
14%−₹4,167Too expensive — that hurdle overstates the return.

Each Newton step is r ← r − NPV(r) / NPV′(r). If the derivative vanishes or the walk jumps below −100%, XirrRupee bisects the bracket instead. Aman’s folio never needs that fallback.

Why “CAGR on the pile” is 9.49%

If you ignore dates and compute (115000 / 75000)1/4.72 − 1 you get9.49%. That pretends all ₹75,000 arrived on 5 Jan 2022. The 2023 and 2024 cheques did not. XIRR at 12.06% is the honest personal rate. The gap is the whole point of an XIRR calculator — see XIRR vs CAGR.

The longer sample (Priya)

The home-page Load sample button uses a noisier folio: ₹8,000 on the 5th for 24 months, a ₹50,000 lump on 12 Mar 2023, a ₹30,000 partial redeem on 18 Aug 2024, and a ₹2,85,000 value on 22 Sep 2026. Invested ₹2,42,000, inflows ₹3,15,000, XIRR10.19% p.a. Naive CAGR on that pile is 7.35%. Same lesson, more rows.

Type Aman’s four lines into the xirr calculator — or paste them as CSV — and you should land on 12.06%. If you do not, check the signs first.