Hello,
I´m modifying the Advection-Diffusion solver for a problem in blood oxygen transport. Given the advection velocity field v, I need to calculate a global parameter m from the equation
integral f(v,m) dA / integral f(v,m)v dA = given constant
where the integrals are over the outflow boundary of the vessel segment and f is a given function.
If I try to do this inside the solver, do the Elmer libraries contain any such root-finding routines, or, if not, can you recommend any Fortran libraries to link to the Solver? I did a quick test linking to MINPACK, but it segfaulted.
Thank you!
David
Root-finding within a solver
-
- Site Admin
- Posts: 4832
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: Root-finding within a solver
Hi David
Would this be something where you test for different values of m and then tune it to have the desired effect? So you run at least one full iteration for each new estimate of m?
The closest I can think of being ready in Elmer is the secant search of FindOptimum routine. There you can set a add hoc target value to any quantity. There is just one test case "LubricationTunedForce". In that a distance is chosen such that the force is the desired.
-Peter
Would this be something where you test for different values of m and then tune it to have the desired effect? So you run at least one full iteration for each new estimate of m?
The closest I can think of being ready in Elmer is the secant search of FindOptimum routine. There you can set a add hoc target value to any quantity. There is just one test case "LubricationTunedForce". In that a distance is chosen such that the force is the desired.
-Peter