|
[Sponsors] |
Excel like goal-seek type functionality in OpenFOAM |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
April 30, 2010, 17:02 |
Excel like goal-seek type functionality in OpenFOAM
|
#1 |
Senior Member
Ben K
Join Date: Feb 2010
Location: Ottawa, Canada
Posts: 140
Rep Power: 19 |
This is a long shot, but is there an excel like goal-seek functionality in OpenFoam?
In one of my custom made solvers I have a non-linear algebraic equation and I need to iterate for a value inside the equation, like: Val = [exp(b*a) + exp(-c*a)] I know everything except a, which I want to find. |
|
April 30, 2010, 17:40 |
|
#2 |
Senior Member
Ben K
Join Date: Feb 2010
Location: Ottawa, Canada
Posts: 140
Rep Power: 19 |
I guess I'm looking for a built in Newton's method in OpenFoam. It's fairly easy to implement actually (as long as the analytical derivative is known).
|
|
April 30, 2010, 17:46 |
Root finding
|
#3 |
Senior Member
Daniel P. Combest
Join Date: Mar 2009
Location: St. Louis, USA
Posts: 621
Rep Power: 0 |
Openfoam has a root finding method that I have never used but noticed while looking around in the source. Take a look at:
/OpenFOAM/OpenFOAM-1.5-dev/src/ODE/findRoot/BisectionRoot and /OpenFOAM/OpenFOAM-1.5-dev/src/ODE/findRoot/RiddersRoot of course this is in your particular version, mine being the 1.5-dev type. You could also do some sort of newton-raphson type root finding or many others that are in the Numerical recipes books with: lhs-rhs=0 and find the root of your function of a. Hope this helps. Dan |
|
April 30, 2010, 17:50 |
|
#4 |
Senior Member
Ben K
Join Date: Feb 2010
Location: Ottawa, Canada
Posts: 140
Rep Power: 19 |
Interesting, I'll take a look at that. Thanks.
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Commercial meshers] Fluent3DMeshToFoam | simvun | OpenFOAM Meshing & Mesh Conversion | 50 | January 19, 2020 16:33 |
OpenFOAM - Validation of Results | Ahmed | OpenFOAM Running, Solving & CFD | 10 | May 13, 2018 19:28 |
boundary conditions for simpleFoam calculation | foam_noob | OpenFOAM Running, Solving & CFD | 8 | July 1, 2015 09:07 |
[Other] StarToFoam error | Kart | OpenFOAM Meshing & Mesh Conversion | 1 | February 4, 2010 05:38 |
Problems with Turbulence Modeling | ezsoal | OpenFOAM Running, Solving & CFD | 4 | November 26, 2009 16:12 |