|
[Sponsors] |
July 18, 2016, 10:38 |
question about parallelization
|
#1 |
Member
ERMACORA Florian
Join Date: May 2016
Posts: 39
Rep Power: 10 |
Hello,
I want to parallelize some UDFs. I read the guide and I understand that I have to put the compiler directives(if RP_HOST!,if RP_NODE!, if RP_PARALLEL!, ...) when its process perform but I don't understand when host or node processes will perform. So I don't even know when I must write each parallel compiler. Thanks you for your help. |
|
July 18, 2016, 13:35 |
|
#2 |
Member
Join Date: Jun 2016
Posts: 66
Rep Power: 11 |
What you are asking would need a very long answer that you can find in the Fluent Guides. I will give only a very short overview.
To understand when you need to parallelize the UDFs, you need to understand how the computer works when running in parallel first. When you start a computation with, let's say, two parallel processes, the computational mesh is split between the two nodes. Your code is executed on each node separately. Imagine situation 1 - you have a UDF that defines a drag coefficient. The coefficient is calculated in every single cell, no matter what node the specific cell resides at. So there is no need to parallelize the code. Now imagine situation 2 - you want to integrate a quantity over the whole domain. However, you have part of the domain on Node 0 and another part of the domain on Node 1. If you run a serial code here, you get one result for one node and another result for the other node. That's not what you want though. So here you need to parallelize - tell the computer to run the code on Node 0 and 1, then send the result from Node 1 to Node 0 and sum it here. If you want to print it, you need to send it to host, if I remember well. Simply put, whenever passing data between nodes is required, you need to parallelize your UDF. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Question about symmetry in Autodesk Cfd 2016 | ecto | Autodesk Simulation CFD | 0 | October 20, 2015 05:16 |
small question about the functionalities of topological changes in OpenFoam | ngj | OpenFOAM Running, Solving & CFD | 2 | February 28, 2013 11:02 |
Question Re Engineering Data Source | imnull | ANSYS | 0 | March 5, 2012 14:51 |
internal field question - PitzDaily Case | atareen64 | OpenFOAM Running, Solving & CFD | 2 | January 26, 2011 16:26 |
Poisson Solver question | Suresh | Main CFD Forum | 3 | August 12, 2005 05:37 |