Added two methods to the class Signal, to do integration of samples