A recurrence relation is a rule that builds a sequence by defining each new term from the ones before it, and this calculator works through the most important type, the second-order linear recurrence, generating the sequence and the term you want from two starting values. Enter the two coefficients of the rule, the two initial terms, and which term you would like, and it returns that term along with the sequence up to it, updating as you type. The rule it handles says that each term equals p times the previous term plus q times the term before that, a compact recipe that captures a surprising variety of sequences. The most famous of all is the Fibonacci sequence, where both coefficients are one and the sequence starts at zero and one, so each term is simply the sum of the two before it, producing 0, 1, 1, 2, 3, 5, 8, 13 and onward, a pattern that shows up in sunflowers, pinecones and the golden ratio. Change the coefficients and starting values and you can produce the Lucas numbers, Pell numbers, geometric-like growth, oscillating sequences and many others, all from the same simple machinery. Computing a far-off term by hand means applying the rule over and over, carefully carrying the two most recent values each time, which is exactly the kind of repetitive work a calculator should take off your hands. That makes this tool genuinely useful for students meeting sequences, series and recurrence relations in algebra and discrete maths and checking homework, for exploring how coefficients shape a sequence's growth or oscillation, and for anyone needing a specific term of a linear recurrence quickly. The rule and a worked example are explained clearly below.
The rule is a(n) = p times a(n-1) plus q times a(n-2), starting from a(0) and a(1). The calculator applies it step by step, each time using the two most recent terms to find the next, until it reaches term n, listing the sequence as it goes.
With p = 1, q = 1, a(0) = 0 and a(1) = 1, this is the Fibonacci rule. The sequence runs 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, so term 10 is 55.
If you've found a bug, or would like to contact us, or learn more about James Graham and Calculate.co.nz.
Calculate.co.nz is partnered with Interest.co.nz for New Zealand's highest quality calculators and financial analysis.
All calculators and tools are provided for educational and indicative purposes only and do not constitute financial advice.
Calculate.co.nz is proudly part of the Realtor.co.nz group, New Zealand's leading property transaction literacy platform, helping Kiwis understand the home buying and selling process from start to finish. Whether you're a first home buyer navigating your first property purchase, an investor evaluating your next acquisition, or a homeowner planning to sell, Realtor.co.nz provides clear, independent, and trustworthy guidance on every step of the New Zealand property transaction journey.
Calculate.co.nz is also partnered with Health Based Building and Premium Homes to promote informed choices that lead to better long-term outcomes for Kiwi households.
Calculate.co.nz is hosted in Auckland via SiteHost new Zealand.
All content on this website, including calculators, tools, source code, and design, is protected under the Copyright Act 1994 (New Zealand). No part of this site may be reproduced, copied, distributed, stored, or used in any form without prior written permission from the owner.
About & trust: Why Calculate is NZ's most comprehensive · By the Numbers · How we compare · Editorial standards · How we keep data current · NZ finance glossary · Research & data · Financial literacy NZ · About
Reviewed and maintained. Last reviewed 2026-06-05 and checked on a twice-monthly cycle against IRD, RBNZ and Stats NZ. How we keep data current.
© 2019 to 2026 Calculate.co.nz. All rights reserved.