- **OpenFOAM**
(*https://www.cfd-online.com/Forums/openfoam/*)

- - **Regarding the adaptation of scalarTransport Foam as well as general openFOAM logic.**
(*https://www.cfd-online.com/Forums/openfoam/79039-regarding-adaptation-scalartransport-foam-well-general-openfoam-logic.html*)

Regarding the adaptation of scalarTransport Foam as well as general openFOAM logic.Hello openFOAM Users!
I am attempting to implement the scalarTransport Foam to model gas separation using high speed centrifuges. I believe that I am close, real close, but I have a few unresolved issues with the fluid velocity field that I could use some help with. Here is the equation I am trying to solve: solve ( fvc::ddt(rho) -fvm::laplacian(DT,rho) +fvm::div(phi,rho) ); Where: rho: fluid density at a given point DT: diffusion coefficient phi: fluid velocity (This I have some questions on as well) In the most simple form the problem can be modeled in one dimension. Therefore, I am declaring the y and z faces to be "empty" (this I learned from the user guide). Under these conditions the fluid velocity is described by the following term: U=A*x (where A is a collection of constants with units of (1/s)) Under more complicated conditions (i.e. with circulation of the fluid in the cylinder) the fluid velocity terms will take the form: U=(A*x+v(x), 0, v(z)) (where v(x) and v(z) are velocity components in the x and z direction, the problem assumes there is always symmetry about the y plane). //==========================// Questions: First, how is U related to phi? I can see there has to be a relationship, perhaps something like phi is generated from U, but I can't find the code that does it (perhaps I don't need/want to?). Second, how do I make the x component of U a function of x? I think I understand how to make U constant by using "uniform". I would like to do something like this: /////////////////////////////////// FoamFile { version 2.0; format ascii; class volVectorField; object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 1 -1 0 0 0 0]; internalField uniform (A*x 0 0);////////////////////////////////// But this obviously doesn't work. How do I go about generating U as a function of x? Finally, there is another form of my equation which looks more or less something like this: solve ( fvc::ddt(N) -fvm::laplacian(DT,N) +fvm::div(phi,N(1-N)) ); Where N is the number of particles. However, openFOAM won't compile the this as a solver. In fact it won't compile any solver in which the term, (N) in this case, has any operator on it (i.e 2*N, N+1, N-N^2). I am positive that there is some sound mathematical/CFD reasoning for this, and I would like to understand it. If there is a way around it I would really like to know about it. The answers to these questions would really help me get my project off the ground. Please feel free to contact me with any questions, or comments if I have not made something clear. Thank you for your time. |

All times are GMT -4. The time now is 19:22. |