CosmicStudioSoftware / OMMBV

Orthogonal Multipole Magnetic Basis Vectors - Complete orthogonal vector basis with accurate field-line mapping of electric fields and ion drifts within multipole magnetic fields
BSD 3-Clause "New" or "Revised" License
10 stars 7 forks source link

BUG/ENH: Improvements to step_until_intersect and bug fix for field_line_trace #17

Closed rstoneback closed 5 years ago

rstoneback commented 5 years ago

A user ran into a calculation failure when the number of steps allowed for field_line_trace was large enough that the integration terminated early, resulting in downstream calculation errors. Corrected this by filtering outputs after the minimum distance to the desired termination height is reached. Downside: the extra calls to the ECEF/Geodetic conversion slow things down. Conversion to Fortran is worth it.

While investigating this issue, a problem with step_until_intersect was found and corrected. The method now does a better job searching for the closest distance. More accurate and more robust to changes in parameters. A tolerance keyword, 'tol', was added.

Corrected a small pysat version bug.

To be completed:

rstoneback commented 5 years ago

Addresses issue #16

rstoneback commented 5 years ago

Test failures are related to some configuration issues on Travis CI. The code itself is fine.

rstoneback commented 5 years ago

Review requested from @bharding512

rstoneback commented 5 years ago

Some of the features here have been supplanted by the next pull. Next pull needs a bit of documentation work but the underlying code changes are good to go.

rstoneback commented 5 years ago

No rush as I've already delivered results to ICON.

rstoneback commented 5 years ago

Closed per feedback and notes in pull #26