https://github.com/paulrberg/prb-math Here is example usage: https://github.com/ethereum/solidity/blob/develop/test/libsolidity/semanticTests/externalContracts/ramanujan_pi.sol.