[FLASH-USERS] MHD (8wave & USM): Refinement region boundaries - spurious waves when B field is oblique to jumps in refinement.
Klaus Weide
klaus at flash.uchicago.edu
Thu May 12 13:59:04 EDT 2016
On Thu, 12 May 2016, Jonathan Thurgood wrote:
> 2) Changing the prol_method.
>
> This makes no difference as far as I can tell (not even a slight change in the current amplitudes). I wondered if that in of itself was not strange?
>
> Is it possible that the that special prolongation is only being applied
> when a block is refined to a lower level, but not when blocks of
> different levels of refinement compute guard cell data, but rather only
> some simple interpolation?
Hi Jonathan,
Your suspicion is correct that face variable interpolation may use
different methods between the two situations:
(a) filling cells (here: cell faces) that have been newly created with data;
(b) computing values for guard cell faces at refinement boundaries.
in particular, the runtime parameter 'prol_method' appears to affect only
case (a).
This can be seen in the code:
* Case (a) involves routine amr_prolong(mpi_amr_prolong.F90); the code
path for handling "BALSARA" prolongation looks like this:
If ( prol_fc_dbz) Then
.....
Call amr_1blk_fc_prol_dbz(.....)
.....
* Case (b) involves routine mpi_amr_1blk_guardcell_c_to_f. Here, the
corresponding calls to amr_1blk_fc_prol_dbz() are commented out.
(See also 1-line comments in that file if your are curious.)
I can't speak about reasons for this different treatment, but it is no
doubt based on experience (not mine) with applications.
> I did wonder if it might be worth changing NGUARD (thus, how many cells
> the coarse side of the boundary needs to be interpolated into) but for
> the life of me I couldn’t figure out where you actually change this in
> the code (is it a setup argument? Flash.par didn’t seem to accept it).
> Can someone please let me know how to do this?
NGUARD can be changed by putting a line like
GUARDCELLS 6
in a Config file. Note that the file
source/physics/Hydro/HydroMain/unsplit/Config
already contains such a line, and you have to avoid putting a
conflicting line in your own Config. See the following close to the
end of that Config:
# Number of guard cells at each boundary
USESETUPVARS SupportPpmUpwind
IF SupportPpmUpwind
GUARDCELLS 6 # the Unsplit Hydro/MHD solver requires 6 guard cells to support PPM Upwind!
ELSE
GUARDCELLS 4 # the Unsplit Hydro/MHD solver requires 4 guard cell layers!
ENDIF
So to get 6 instead of 4 leayers of guard cells (and also enable the upwind variant of PPM),
add SupportPpmUpwind=True to your setup command.
Klaus
More information about the flash-users
mailing list