Calculates the definite integral of a given function over a given range using a Riemann sum or trapezoidal sum. The user defines the number of partitions to be made for the Riemann/trapezoidal sum (more partitions means a more accurate answer, but also increases the computation time). The user is also able to define whether LRAM, MRAM, or RRAM is used for the Riemann sum.
NOTE: There are floating point errors.