mountaindust / Planktos

ABM framework for dispersal modeling
https://planktos.readthedocs.io
GNU General Public License v3.0
5 stars 3 forks source link

Implement FTLE #30

Closed mountaindust closed 3 years ago

mountaindust commented 3 years ago

Being able to solve for FTLEs would provide a generalized framework for computing the FTLE in a large variety of particle behavior scenarios.

mountaindust commented 3 years ago

Should only need to implement a forward solver, and calculate both the largest and smallest FTLE for repelling and attracting LCSs respectively. See Haller and Sapsis (2011). Also, the Shadden Lab's tutorial has a really easy-to-understand walkthrough on how to compute FTLE!

mountaindust commented 3 years ago

The latest wrinkle: this is going to require implementing an RK45 solver because scipy.integrate.RK45 does not give access to the norm used when calculating error. It's likely taking a 2-norm over the entire list of position deviations, which blows up the error and results in ridiculously small step sizes (~1e-160). The proper norm is probably something like the max 2-norm of every agent's deviation.

mountaindust commented 3 years ago

This is being down-graded to medium priority due to stubborn run-time bugs which refuse to give the same result as the VisIt FTLE solver for 2D tracer particles. Visualization of the flow field is needed to aid in debugging.

mountaindust commented 3 years ago

RK45 solver has been fixed and the results of tracer particles now largely agree with VisIt. FTLE also works for supplied ode generator function. Interaction with immersed boundaries also appears to be working, but is VERY slow. See #42. Just need to test a passed in swarm object!