Skip to content
Snippets Groups Projects
Verified Commit 2ba62b2c authored by Michiel Cottaar's avatar Michiel Cottaar
Browse files

Fix second_der calculation

parent 2ac53c3f
No related branches found
No related tags found
No related merge requests found
Pipeline #23674 failed
......@@ -113,6 +113,9 @@ function split_timestep(gp::GenericPulse, precision)
max_second_der = 0.
for index in 2:length(arr)-1
poly = fit(gp.time[index-1:index+1], arr[index-1:index+1])
if iszero(length(poly.coeffs))
continue
end
second_der = abs(poly.coeffs[end])
if second_der > max_second_der
max_second_der = second_der
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment