In all of the literature that I've found, numerical integration is used to approximate the value of the integral of some function over an interval. I'm trying to do something a little different:
I have a bunch of sampled values coming in at varying, small time steps. At each time step, I want to return the integral of the input for that time step.
So, for each time step, I simply add the new value multiplied by $\Delta t$ to a running total, and return the total for that time step.
This seems to produce the result that I want. However, is this the best way to do this? Without having the entire history of the input, is there a method of integrating that can reduce the error of the output for each time step?