We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
julia> x = collect(1.0:5.0) 5-element Vector{Float64}: 1.0 2.0 3.0 4.0 5.0 julia> y = x.^2 5-element Vector{Float64}: 1.0 4.0 9.0 16.0 25.0 julia> cumul_integrate(x, y) 5-element Vector{Float64}: 2.5 5.0 11.5 24.0 44.5
The result is different from https://www.mathworks.com/help/matlab/ref/cumtrapz.html
Should we expect an array like [2.5, 9.0, 21.5, 42.0] from cumul_integrate?
[2.5, 9.0, 21.5, 42.0]
cumul_integrate
The text was updated successfully, but these errors were encountered:
This is late, but I know what you have to do to get the cumtrapz result, which is the correct result.
You need to do z = cumul_integrate(x, y) and then do z = z[2:end] .- z[1]
z = cumul_integrate(x, y)
z = z[2:end] .- z[1]
I'll see if the original owner is still active.
Sorry, something went wrong.
No branches or pull requests
The result is different from
https://www.mathworks.com/help/matlab/ref/cumtrapz.html
Should we expect an array like
[2.5, 9.0, 21.5, 42.0]
fromcumul_integrate
?The text was updated successfully, but these errors were encountered: