|
[Sponsors] |
December 6, 2011, 06:14 |
Accessing Themo Data on a Boundary Patch
|
#1 |
New Member
Bill
Join Date: Jun 2011
Location: UK
Posts: 16
Rep Power: 15 |
Hello
Simple-ish question, this. I'm writing a boundary condition for reactingFoam. Typically, when I want to get values on said boundary, I do something like this, Code:
const fvPatchField<scalar>& p = patch().lookupPatchField<volScalarField, scalar>("p"); const fvPatchField<vector>& U = patch().lookupPatchField<volVectorField, vector>("U"); I can't seem use this method to get the specific heat, Cp. If I try I get the error, Code:
--> FOAM FATAL ERROR: request for volScalarField Cp from objectRegistry region0 failed available objects of type volScalarField are Does anyone know how can I get Cp (and by extension other thermophysical data) on a boundary patch in this sort of context? Many thanks in advance |
|
December 16, 2011, 05:25 |
|
#2 |
New Member
Bill
Join Date: Jun 2011
Location: UK
Posts: 16
Rep Power: 15 |
Bump. Still none the wiser. Anyone? Is this even possible? How about getting thermophysical values in the cells adjacent to the boundary?
|
|
December 16, 2011, 15:17 |
|
#3 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
I think Cp is one of those that needs to be calculated from your mixture. You might need to do something like this (this is rough pseudocode ).
Code:
fvPatchField<scalarField> Cp = 0; forAll(Y,specI) { Cp+=Y[speci].thePatchFieldYouWant*Cp.listOfSpecies[index for specI] } |
|
April 13, 2012, 18:56 |
|
#4 |
New Member
Nikhil
Join Date: Sep 2011
Posts: 11
Rep Power: 15 |
Hello
I know this is an old post. Just in case.. I guess you need to add 'Cp' as a volScalarField in createFields.H file and update it every iteration. Hope this helps. |
|
Tags |
boundary, capacity, condition, heat, specific |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Gmsh] Import problem | ARC | OpenFOAM Meshing & Mesh Conversion | 0 | February 27, 2010 11:56 |
[Other] StarToFoam error | Kart | OpenFOAM Meshing & Mesh Conversion | 1 | February 4, 2010 05:38 |
RPM in Wind Turbine | Pankaj | CFX | 9 | November 23, 2009 05:05 |
How to update polyPatchbs localPoints | liu | OpenFOAM Running, Solving & CFD | 6 | December 30, 2005 18:27 |
[Commercial meshers] Trimmed cell and embedded refinement mesh conversion issues | michele | OpenFOAM Meshing & Mesh Conversion | 2 | July 15, 2005 05:15 |