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

topoChangerFvMesh doesn't work in parallel

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 21, 2014, 06:35
Default topoChangerFvMesh doesn't work in parallel
  #1
New Member
 
NaiXian Leslie Lu
Join Date: Jun 2009
Location: France
Posts: 26
Rep Power: 8
LESlie is on a distinguished road
Hi Foamers,

I am working on needle transient motion of injectors and I have implemented my own class with layer removal based on movingTopoFvMesh. The injector mesh is converted from a fluent mesh. What I did is to find the patch, say NEEDLE with


Quote:
label patchID = boundaryMesh().findPatchID("NEEDLE");

Info << "patchID = " << patchID << endl;

const polyPatch& cPatch = boundaryMesh()[patchID];
then put the faces of this polyPatch as extrusion faces for the mesh modifier, and also mark the points on these faces for the motion, so that only these points will be moved.

The code is working in serial mode (attached pictures), however failed in parallel.

Serial log file
Create mesh for time = 0.0002

Selecting dynamicFvMesh needleTopoFvMesh
Initial time:0.0002 Initial curMotionVel_0 0 1)
Time = 0.0002

Adding zones and modifiers to the mesh

patchID = 1
cPatch =
type wall;
nFaces 20732;
startFace 3529376;

number of face in zone1 20732

Adding mesh zones.
Adding 1 mesh modifiers
patchID = 1
number of points marked 20986

.... reading data....

time:0.0002000017749 curMotionVel_0 0 1)
No topology change
Executing mesh motion
Execution time for mesh.update() = 1.67 s

..... flow calculation .....

Total Volume change = -3.598473946e-15
ExecutionTime = 31.52 s


Parallel log file

Selecting dynamicFvMesh needleTopoFvMesh
[0] Initial time:0.0002 Initial curMotionVel_0 0 1)
Time = 0.0002
Adding zones and modifiers to the mesh
[1] Initial time:0.0002 Initial curMotionVel_0 0 1)
[2] Initial time:0.0002 Initial curMotionVel_0 0 1)
[3] Initial time:0.0002 Initial curMotionVel_0 0 1)

patchID = 1
cPatch =
type wall;
nFaces 0;
startFace 879157;

number of face in zone1 0


Adding mesh zones.
Adding 1 mesh modifiers
patchID = 1
number of points marked 0

.... reading data....

time:0.0002000017749 curMotionVel_0 0 1)
No topology change
Executing mesh motion
Execution time for mesh.update() = 1.67 s

..... flow calculation .....

Total Volume change = 0

ExecutionTime = 14.72 s


Apparently when running in parallel (4 procs), polyPatch& cPatch = boundaryMesh()[patchID] failed to create the polyPatch. I am running on 2.2.x. I would really appreciate some help on this!

Have a nice day!
Attached Images
File Type: jpg 1.jpg (97.5 KB, 21 views)
File Type: jpg 2.jpg (97.2 KB, 17 views)
File Type: jpg 3.jpg (97.6 KB, 16 views)
__________________
Cheers,
Leslie LU

LESlie is offline   Reply With Quote

Old   January 21, 2014, 06:48
Default
  #2
New Member
 
NaiXian Leslie Lu
Join Date: Jun 2009
Location: France
Posts: 26
Rep Power: 8
LESlie is on a distinguished road
Quote:
Originally Posted by LESlie View Post
Hi Foamers,

The code is working in serial mode (attached pictures), however failed in parallel.

I am running on 2.2.x.

However I did a test with a simple mesh created by blockMesh (attached pictures). In that case the code IS WORKING in PARALLEL!

I am using scotch decomposition method. I checked that in this simple test case, the moving patch is distributed evenly on 4 processors.

In case/constant/polyMesh/boundary

NEEDLE
{
type wall;
nFaces 80;
startFace 4770;


And the parallel log file:
Create mesh for time = 0

Selecting dynamicFvMesh needleTopoFvMesh
[1] Initial time:0 Initial curMotionVel_0 0.1 0)
[2] Initial time:0 Initial curMotionVel_0 0.1 0)
[3] Initial time:0 Initial curMotionVel_0 0.1 0)
[0] Initial time:0 Initial curMotionVel_0 0.1 0)
Time = 0
Adding zones and modifiers to the mesh
patchID = 1

cPatch =
type wall;
nFaces 20;
startFace 1170;

number of face in zone1 20

Adding mesh zones.
Adding 1 mesh modifiers
patchID = 1
number of points marked 42


What is the mysterious reason behind all of this?
Attached Images
File Type: jpg simple1.jpg (37.8 KB, 13 views)
File Type: jpg simple2.jpg (37.4 KB, 11 views)
File Type: jpg simple3.jpg (36.8 KB, 12 views)
__________________
Cheers,
Leslie LU

LESlie is offline   Reply With Quote

Old   January 21, 2014, 11:42
Default
  #3
New Member
 
NaiXian Leslie Lu
Join Date: Jun 2009
Location: France
Posts: 26
Rep Power: 8
LESlie is on a distinguished road
Quote:
Originally Posted by LESlie View Post
However I did a test with a simple mesh created by blockMesh (attached pictures). In that case the code IS WORKING in PARALLEL!

I am using scotch decomposition method. I checked that in this simple test case, the moving patch is distributed evenly on 4 processors.
It's me again.

The 2nd simple case works in parallel only when it is 2D. When I run it in 3D, parallelization failed also.
__________________
Cheers,
Leslie LU

LESlie is offline   Reply With Quote

Old   January 22, 2014, 09:04
Default
  #4
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,758
Rep Power: 21
hjasak will become famous soon enough
You need foam-extend-3.0 Parallel topo changes are one of the new things I have done for this release. Please beware: if you have written your own dynamic fvMesh class, you may need to update it to handle parallelisation as well.

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   February 10, 2014, 11:42
Default
  #5
New Member
 
NaiXian Leslie Lu
Join Date: Jun 2009
Location: France
Posts: 26
Rep Power: 8
LESlie is on a distinguished road
Quote:
Originally Posted by hjasak View Post
You need foam-extend-3.0 Parallel topo changes are one of the new things I have done for this release. Please beware: if you have written your own dynamic fvMesh class, you may need to update it to handle parallelisation as well.

Hrv
Thanks for the reply.

However the movingConeTopo tutorial crashes, log file indicates:

Volume: new = 1.768551e-09 old = 1.768573998e-09 change = 2.299798524e-14
Courant Number mean: 196.2985037 max: 1992315.801 velocity magnitude: 1077.436077
deltaT = 1.277645154e-09
Time = 0.4066660041



--> FOAM FATAL ERROR:
negative cell volume. Error in mesh motion before topological change.

From function bool layerAdditionRemoval::changeTopology() const
in file polyMeshModifiers/layerAdditionRemoval/layerAdditionRemoval.C at line 295.

FOAM aborting

Aborted (core dumped)
__________________
Cheers,
Leslie LU

LESlie is offline   Reply With Quote

Old   February 10, 2014, 13:11
Default
  #6
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,758
Rep Power: 21
hjasak will become famous soon enough
Fixed and about to push:

BUGFIX/cellLayering

Apologies,

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak 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
Parallel processing problem newbie29 OpenFOAM Running, Solving & CFD 1 June 22, 2012 04:23
error while running in parallel using openmpi on local mc 6 processors suryawanshi_nitin OpenFOAM 5 May 21, 2012 14:13
CFX parallel multi-node jobs fail w/ SLURM on Ubuntu 10.04 danieru CFX 0 February 17, 2012 07:20
Cases with small length scale work fine on a single processor but fail in parallel adona058 OpenFOAM Bugs 5 April 17, 2009 04:41
IcoFoam parallel woes msrinath80 OpenFOAM Running, Solving & CFD 9 July 22, 2007 02:58


All times are GMT -4. The time now is 21:42.