|
[Sponsors] |
March 1, 2015, 08:03 |
to obtain a new variable value in each cell
|
#1 |
New Member
ARUN
Join Date: Jan 2015
Location: Kerala
Posts: 18
Rep Power: 11 |
Hi Members
I want to obtain the mass transfer in each cell of my mesh. I have added the necessary equations. I have included a no_read, auto_write command in createField.H,bt it seems that it writes only a single value for the entire time per run. hw do i calculate the mdot for each cell???? is there any changes to be made in the runtime loop of solver.C file too? And also is there any way to change volScalarField to dimensionedScalarField? |
|
March 1, 2015, 09:13 |
|
#2 |
Senior Member
Hesam
Join Date: Feb 2015
Posts: 139
Rep Power: 11 |
Hi arun. D is a scalar and change in each cell per time
volScalarField D ( IOobject ( "D", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE ), mesh, dimensionedScalar("D",dimensionSet(0,2,-1,0,0,0,0), scalar(0.0)) ); |
|
March 1, 2015, 10:46 |
|
#3 |
New Member
ARUN
Join Date: Jan 2015
Location: Kerala
Posts: 18
Rep Power: 11 |
Hi Alireza,
I have done a similar thing as you told --> volScalarField massflow ( IOobject ( "massflow", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE ), mesh, dimensionedScalar("massflow", dimensionSet(1, -1.25, 0.5, 0, 0), scalar(0.0)) ); but the problem is it shows the value zero in the write files in each time intervals do we have to change smthng else too. I have seperately named a header file containing masstransfer containing the equation for mass flow. still i get all values as zero |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Cell Reynolds Number | laliong | Main CFD Forum | 12 | September 17, 2019 03:18 |
I know the cell ID, how do I find the cell coordinates? | simpomann | OpenFOAM Programming & Development | 6 | June 30, 2014 10:29 |
Solution Diverging with Trimmer Mesh | rietuk | STAR-CCM+ | 8 | February 27, 2013 04:50 |
[Commercial meshers] Trimmed cell and embedded refinement mesh conversion issues | michele | OpenFOAM Meshing & Mesh Conversion | 2 | July 15, 2005 04:15 |
Defining and assigning a variable to a cell | Robi | FLUENT | 0 | July 13, 2005 18:27 |