[petsc-users] Two DMDAs for conjugate heat transfer

Barry Smith bsmith at mcs.anl.gov
Tue Apr 15 13:08:08 CDT 2014


On Apr 15, 2014, at 12:09 PM, Xiao, Jianjun (IKET) <jianjun.xiao at kit.edu> wrote:

> Dear Barry,
> 
> Yes, I have structured grid.
> 
> Say, we totally have one million cells (100*100*100). 100,000 cells are solid cells, and the shape of the solid is irregular. The other cells are fluid cells.
> 
> In principle, we could use one DMDA. And give the property to each cell. It means the code knows which cell is solid and which is fluid. Then the problem of load balancing occurs: if all  the solid cells accumulates, say at a corner, the work load will not be balanced.
> 
> Maybe you have some other good ideas. Thank you

   My recommendation in this case is to use a regular grid (since you want to) but use an unstructured representation using DMPlex. This way the cells can be partitioned out among processes for load balancing anyway you want. DMDA (and most “structured grid” representation codes) don’t have support for dynamic “odd” partitioning for load balance since they wish to partition the regular grid into nice smaller regular grids.

   Barry

> 
> JJ
> ________________________________________
> From: Barry Smith [bsmith at mcs.anl.gov]
> Sent: Tuesday, April 15, 2014 6:30 PM
> To: Xiao, Jianjun (IKET)
> Cc: petsc-users at mcs.anl.gov
> Subject: Re: [petsc-users] Two DMDAs for conjugate heat transfer
> 
>   DMDA are for structured grids. That is each DMDA represents a structured grid. Do you have fluid everywhere and solid everywhere or are some cells fluid and some cells solid?
> 
>   Barry
> 
> 
> 
> On Apr 15, 2014, at 11:12 AM, Xiao, Jianjun (IKET) <jianjun.xiao at kit.edu> wrote:
> 
>> Dear developers,
>> 
>> I am writing a CFD code to simulate the conjugate heat transfer. I would like to use two DMDAs: one is for the fluid cells, and the other one is for the solid cells.
>> 
>> Here are the questions:
>> 
>> 1.  Is it possible to have two different DMDAs for such a purpose? How the data in these two DMDAs communicate with each other? Are there any similar examples?
>> 
>> 2.  How to deal with the load balancing if DMDA is used? Or it is simply impossible?
>> 
>> Thank you.
>> 
>> Best regards
>> JJ
> 



More information about the petsc-users mailing list