CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Pre-Processing

Regarding preprocessing

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   May 25, 2016, 19:18
Default Regarding preprocessing
  #1
Member
 
Zhiheng Wang
Join Date: Mar 2016
Posts: 41
Rep Power: 2
Zhiheng Wang is on a distinguished road
Hi, I have stuck in code where I am preprocesing Temperature values.

label patchID = mesh.boundaryMesh().findPatchID("inlet");
scalarField InletTGrad=T.boundaryField()[patchID].snGrad();
const scalarField HEIGHT = 1.0/mesh.deltaCoeffs().boundaryField()[patchID];
const fvBoundaryMesh& myBoundary = mesh.boundary();
forAll( myBoundary, fvPatchID ) /
{
const fvPatch& myPatch = myBoundary[patchID];
const vectorField& position = myPatch.Cf();
forAll( myPatch, i)
{
Ts.boundaryField()[fvPatchID][i] = Ts.boundaryField()[patchID][i]+HEIGHT*InletTGrad;
}
Problem is Ts is volScalarField and Height*InleGrad is scalarField
How can I update my boundary values using this code
plese Send your valuable suggetions.
Attached Files
File Type: c Preprocess.C (591 Bytes, 2 views)
Zhiheng Wang is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Preprocessing for complex conjugate heat transfer (CHT) akidess OpenFOAM Pre-Processing 0 November 12, 2015 04:35
Preprocessing unstructured grids (tetrahedral mesh) rakshith Main CFD Forum 4 May 15, 2010 13:43
Preprocessing unstructured grids (tetrahedral mesh) rakshith Main CFD Forum 0 January 18, 2010 14:40
StarDesign preprocessing error Nick CD-adapco 0 May 24, 2008 22:56
Gambit preprocessing for periodic geometry Karl Kevala FLUENT 7 February 12, 2001 07:44


All times are GMT -4. The time now is 05:54.