JuliaQuantumControl / QuantumPropagators.jl

Propagators for Quantum Dynamics and Optimal Control
https://juliaquantumcontrol.github.io/QuantumPropagators.jl/
MIT License
17 stars 5 forks source link

Ensure copy in discretization routines #45

Closed goerz closed 1 year ago

goerz commented 1 year ago

The discretize and discretize_on_midpoints routines should not return the exact input array if the input is already correctly discretized. At least, they should make a copy. Doing so avoids the problem described in https://github.com/JuliaQuantumControl/Krotov.jl/issues/28

codecov[bot] commented 1 year ago

Codecov Report

Merging #45 (42d31d1) into master (6d32578) will decrease coverage by 3.62%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master      #45      +/-   ##
==========================================
- Coverage   84.18%   80.57%   -3.62%     
==========================================
  Files          16       16              
  Lines        1189     1189              
==========================================
- Hits         1001      958      -43     
- Misses        188      231      +43     
Impacted Files Coverage Δ
src/controls.jl 87.09% <100.00%> (ø)

... and 5 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.