|
[Sponsors] |
January 6, 2014, 21:37 |
repeating variables in one equation
|
#1 |
New Member
Join Date: Sep 2010
Location: Windsor, Ontario
Posts: 17
Rep Power: 15 |
I am trying to introduce Cf as a volScalarField but I get errors when I compile the code. The issue is that there is another Cf in the right hand side of the equation!
volScalarField Cf = 1.0/(((mm*ubulk/nul)*Cf)/0.435+5.05); When I remove the Cf from the right hand side every thing works well. Any idea about writing this equation in OpenFOAM format? Thanks. |
|
January 8, 2014, 06:06 |
|
#2 |
New Member
Michael Ranft
Join Date: Jun 2012
Location: Karlsruhe
Posts: 3
Rep Power: 13 |
The problem is not the equation. You can modify variables in this way.
But first you have to define Cf before you can use it on the right hand side of the equation. Code:
// define Cf volScalarField Cf = ...here an initial expression // modify Cf Cf = 1.0/(((mm*ubulk/nul)*Cf)/0.435+5.05); |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
mass flow in is not equal to mass flow out | saii | CFX | 12 | March 19, 2018 05:21 |
Calculation of the Governing Equations | Mihail | CFX | 7 | September 7, 2014 06:27 |
Wave Action Equation Solver for OpenFOAM | chyczewski | OpenFOAM Programming & Development | 7 | September 4, 2013 11:06 |
How to add bodyforce in momentum equation in viscoelasticFluidFoam? | arshoon | OpenFOAM Running, Solving & CFD | 0 | April 9, 2013 10:03 |
Boundary conditions in a Poisson's equation? | vincent | Main CFD Forum | 4 | April 16, 1999 02:19 |