Feature/stokes drag
@toba will need to study a new type of particle, described by second order equations. These are particles for which the equations are the following:
where
As far as the implementation is concerned, these particles have a 6-dimensional state vector just like the particles with orientation, but the equations are fundamentally different.
See also issue #33 (closed) that I originally opened to discuss this.
The branch I want to merge here is my attempt to expand the API to handle this type of particle.
Before merging I would like
- @bbramas to have a quick look to see whether my changes don't mess up the API.
- @toba to design a sanity check that we can then implement and use to validate the implementation.
Sidenote: I was somewhat overeager to better organize testing for TurTLE, therefore this branch also contains a new CMake testing configuration. This somewhat addresses issue #22 (closed).
Merge request reports
Activity
Ideally both. Initially please think of only Stokes drag (in a velocity field that is 0). And then we should put in some analytic velocity field (a couple of sines and cosines) for which we can integrate Stokes particles in python independently, and do a convergence test. We need a convergence test anyway for Stokes particles in TurTLE since I'm concerned about the timescales.
So:
- Write custom initialization code where the velocity is started with 0, and initial particle velocities are non-zero, then confirm TurTLE reproduces the exponential decay of the particle velocities.
- Based on 1 write something where the velocity is a reasonably complex expression involving sines and cosines (not necessarily Taylor-Green or ABC flow, but something similar). Launch code for this with random velocities. Write independent python code that integrates Stokes particles in the same field, and run it on the TurTLE particle initial conditions. Confirm that the two solutions converge in the limit of decreasing time-step and increasing spatial resolution.
We can discuss the details of 2 in person, please let me know if 1 is already clear. I guess we should also discuss the timeline in person, but my impression is we'd like to validate the code with both tests within a week or two.
added 1 commit
- 13a38dd8 - bugfix: NSVE_Stokes_particles uses correct Loop in step()
@clalescu for
dt=0.01the exponential for inertia particles in a quiescent flow is reproduced until drag coefficients\approx30added 1 commit
- 1515de8f - test for different drag coefficients in quiescent flow
added 36 commits
-
1515de8f...6ddcee26 - 27 commits from branch
develop
- f9597a28 - add test commands to CMake config
- dea79bc3 - clean up testing
- 23cb8afc - [WIP] add Stokes drag particles
- 8628541d - hide some debug messages
- 1eac6344 - adds initialisation for Stokes particles
- 29536d38 - [WIP] add simple test
- c54d2b4a - bugfix: NSVE_Stokes_particles uses correct Loop in step()
- 48bfdd45 - correct drag coefficient is used
- 3ad8cf2d - test for different drag coefficients in quiescent flow
Toggle commit list-
1515de8f...6ddcee26 - 27 commits from branch