For arbitrary precision mathematics PHP offers the Binary Calculator which supports numbers of any size and precision, represented as strings.