CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > SU2

How to assign values to halos in parallel

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 13, 2021, 09:05
Default How to assign values to halos in parallel
  #1
Member
 
Zhen ZHANG
Join Date: Jun 2018
Location: Beijing, China
Posts: 56
Rep Power: 7
Zhen ZHANG is on a distinguished road
Hi all,

I want to read the turbulent Prandtl number at each grid point from a file, but I got some problem in the parallel calculation.

I basically mimic CSolver::Read_SU2_Restart_ASCII. Loop for the global point index, and if geometry->GetGlobal_to_Local_Point(iPoint_Global) > -1, set the value to a VectorType Prt_Val in the variable class.

The series calculation goes well, but the parallel one diverges. I find that the Prandtl number is assigned to the Domain part of the Prt_Val but not to the halo part. So the turbulent Prandtl number keeps the initial value at some points, which leads to the divergence.

Please help me to solve this problem. If I am not clear, please let me know.

Thanks a lot!

Zhen
Zhen ZHANG is offline   Reply With Quote

Old   October 14, 2021, 11:19
Default
  #2
Member
 
na
Join Date: Jul 2018
Posts: 83
Rep Power: 7
TKatt is on a distinguished road
Hi,



as a first shot I would guess you are missing some InitiateComms and CompleteComms calls on PRANDTL_TURB. That should take care of that communication once the stuff is read for each rank correctly.


See e.g. CFVMFlowSolverBase.inl in the LoadRestart_impl where first the correct solution (e.g. rho, rho*u, rho*v, ... for compressible) is read in their respective container and then SOLUTION is then communicated around over the ranks.


There are implementations for a multitude of quantities but of course not PRANDTL_TURB, so that is what you would have to implement yourself.


When you work so closely on the code, you might want to use github a bit more. This is usually the case where coding related questions are meant to go ... but of course it is not an issue to post here



Best Tobi

Last edited by TKatt; October 15, 2021 at 04:34.
TKatt is offline   Reply With Quote

Old   October 14, 2021, 23:43
Default
  #3
Member
 
Zhen ZHANG
Join Date: Jun 2018
Location: Beijing, China
Posts: 56
Rep Power: 7
Zhen ZHANG is on a distinguished road
Hi Tobi,

It helps and is very convenient to implement. Very nice design.

Thank you for your help!

As for Github, I will try to use it. But it is a little hard to visit it in China

Zhen
Zhen ZHANG is offline   Reply With Quote

Reply


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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Update Pressure values for unsteady, multiphase, parallel - not updating properly dhaya400 Fluent UDF and Scheme Programming 6 June 7, 2021 01:43
Can not run OpenFOAM in parallel in clusters, help! ripperjack OpenFOAM Running, Solving & CFD 5 May 6, 2014 15:25
simpleFoam in parallel issue plucas OpenFOAM Running, Solving & CFD 3 July 17, 2013 11:30
strange node values @ solid/fluid interface - help JB FLUENT 2 November 1, 2008 12:04
Parallel Computing Classes at San Diego Supercomputer Center Jan. 20-22 Amitava Majumdar Main CFD Forum 0 January 5, 1999 12:00


All times are GMT -4. The time now is 17:13.