It looks like you want to integrate what appears to be a sine wave. You did that, expecting to get a pure cosine wave, Right?
After all, int(sin(x)) would be -cos(x), right?
The problem is, it is NOT exactly so. The actual integral of sin(x) is -cos(x)+C, where C is an undetermined constant. That constant term is so easily forgettable.
We can see that by
x = linspace(0,10*pi,1000);
plot(x,y,'r',x,cumtrapz(x,y),'b')
And as you can see, the blus curve is shifted upwards. What we see there is actually -cos(x)+1. But how can that be, because we all think the integral of sin(x) is -cos(x), right?
You can think of the cumulative integration as the solution to a differential equation, which I always feel makes this very clear.
ODE = diff(Y) == sin(t)
ODE(t) =

Now, if we solve it, without the specification of an initial condition, we get this:
dsolve(ODE)
ans = 
Do you see? The solution does indeed show that constant of integration. Of course, if we specify an initial value for the ODE, we can get what you expected to see, sans constant of integration:
dsolve(ODE,Y(0) == -1)
ans = 
The problem does not lie in MATLAB/SIMULINK. It lies in your expectation. You cannot just forget that basic fact about integration. Integration comes with a constant as baggage. Sadly, even int seems to forget about it too.
int(sin(x))
ans = 
But if you read the help on int, it explicitly states the pesky constant of integration is not generated.
"For indefinite integrals, int does not return a constant of integration in the result."
I don't know of a flag I can set in the call to int to make it include the constant of integration. Oh well. Maybe it is time for a feature request, to make that an option. As I showed, you can always use dsolve as I did, because dsolve does understand constants of integration. Or you can add in the constant of integration afterwards.