The first algorithms to calculate pi up to record-setting lengths of several million digits were based on formulae Srinivasa Ramanujan published in 1914