CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

Why my code is ok with single processor but doesnbt work in openmpi

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

Reply
 
LinkBack Thread Tools Display Modes
Old   November 23, 2007, 14:44
Default Hi, I need compute wallshe
  #1
New Member
 
xiuying
Join Date: Mar 2009
Posts: 24
Rep Power: 8
xiuying is on a distinguished road
Hi,

I need compute wallshearstress and wrote a code as followings. when I use single processor, it worked well. But if I use openmpi and multiprocessor, it couldn't work and there was not wallshearstress data written. Could you inform me how to deal with the problem? Thanks.

volSymmTensorField R(turbulence->R());

volVectorField wallShearStress
(
IOobject
(
"wallShearStress",
runTime.timeName(),
mesh,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
mesh,
dimensionedVector("wallShearStress", R.dimensions(), vector::zero)
);

//label patchA = mesh.boundaryMesh().findPatchID("lowerWall");

//patchID=0;
// Info<< "End2\n" << endl;


forAll(wallShearStress.boundaryField(), patchi)
{
wallShearStress.boundaryField()[3] =
(
-mesh.Sf().boundaryField()[3]
/mesh.magSf().boundaryField()[3]
) & R.boundaryField()[3];
}

if(runTime.outputTime())
{

wallShearStress.write();
}

kang
xiuying 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
Cases with small length scale work fine on a single processor but fail in parallel adona058 OpenFOAM Bugs 5 April 17, 2009 04:41
Why the noslip doesnbt work corenc OpenFOAM Running, Solving & CFD 9 August 26, 2008 07:26
Max mesh size on single processor? JP CFX 2 November 4, 2007 18:02
Install doesnbt work hplum OpenFOAM Bugs 7 August 14, 2007 04:45
Why doesnbt the macro forall work for the volVectorField variable siwen OpenFOAM Running, Solving & CFD 2 February 24, 2006 16:27


All times are GMT -4. The time now is 00:43.