MFC
Exascale flow solver
Loading...
Searching...
No Matches
m_amr_frame Module Reference

Block-frame swap (fine grid state in/out of the shared solver). More...

Functions/Subroutines

impure subroutine, public s_amr_fine_enter ()
 Swap to the current fine block and load its solver frame amr_cons_br; paired with s_amr_fine_leave.
impure subroutine, public s_amr_fine_leave ()
 Store the solver frame back to the fine block and restore the coarse grid.
impure subroutine, public s_amr_swap_to_fine (widen)
 Swap the global grid state to the fine block. Must be paired with s_amr_restore_coarse.
impure subroutine s_amr_extend_ghost_coords (d, cb, cc, dd, ext, glb, gcb)
 Extend one axis of the installed fine grid into the ghost shell with the same parent-cell bisection the interior uses: boundary jg belongs to parent cell cl = isect_lo + floor(jg/rr), and k = modulo(jg, rr) picks the rr-way split. The parent boundaries are gcb for a level-1 block; a level>=2 block's parent grid is rebuilt from replicated metadata (the parent's own arrays exist only on its owner). Blocks stay buff_size inside the domain, so every ghost parent is an in-domain cell.
impure subroutine, public s_amr_restore_coarse (sync_device)
 Restore the global grid state saved by s_amr_swap_to_fine.
impure subroutine s_amr_igr_swap_sigma ()
 Save the coarse jac/jac_old and seed the (already swapped-in) fine block's sigma by piecewise-constant parent injection from the saved coarse sigma: interior = initial guess, ghost shell = frozen Dirichlet coupling data.
impure subroutine s_amr_igr_restore_sigma ()
 Restore the coarse jac/jac_old saved by s_amr_igr_swap_sigma (bounds already restored).

Detailed Description

Block-frame swap (fine grid state in/out of the shared solver).

Function/Subroutine Documentation

◆ s_amr_extend_ghost_coords()

impure subroutine m_amr_frame::s_amr_extend_ghost_coords ( integer, intent(in) d,
real(wp), dimension(-1 - buff_size:), intent(inout) cb,
real(wp), dimension(-buff_size:), intent(inout) cc,
real(wp), dimension(-buff_size:), intent(inout) dd,
integer, intent(in) ext,
integer, intent(in) glb,
real(wp), dimension(glb:), intent(in) gcb )
private

Extend one axis of the installed fine grid into the ghost shell with the same parent-cell bisection the interior uses: boundary jg belongs to parent cell cl = isect_lo + floor(jg/rr), and k = modulo(jg, rr) picks the rr-way split. The parent boundaries are gcb for a level-1 block; a level>=2 block's parent grid is rebuilt from replicated metadata (the parent's own arrays exist only on its owner). Blocks stay buff_size inside the domain, so every ghost parent is an in-domain cell.

Definition at line 555 of file m_amr_frame.fpp.f90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ s_amr_fine_enter()

impure subroutine, public m_amr_frame::s_amr_fine_enter

Swap to the current fine block and load its solver frame amr_cons_br; paired with s_amr_fine_leave.

Definition at line 392 of file m_amr_frame.fpp.f90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ s_amr_fine_leave()

impure subroutine, public m_amr_frame::s_amr_fine_leave

Store the solver frame back to the fine block and restore the coarse grid.

Definition at line 403 of file m_amr_frame.fpp.f90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ s_amr_igr_restore_sigma()

impure subroutine m_amr_frame::s_amr_igr_restore_sigma
private

Restore the coarse jac/jac_old saved by s_amr_igr_swap_sigma (bounds already restored).

Definition at line 871 of file m_amr_frame.fpp.f90.

Here is the caller graph for this function:

◆ s_amr_igr_swap_sigma()

impure subroutine m_amr_frame::s_amr_igr_swap_sigma
private

Save the coarse jac/jac_old and seed the (already swapped-in) fine block's sigma by piecewise-constant parent injection from the saved coarse sigma: interior = initial guess, ghost shell = frozen Dirichlet coupling data.

Definition at line 630 of file m_amr_frame.fpp.f90.

Here is the caller graph for this function:

◆ s_amr_restore_coarse()

impure subroutine, public m_amr_frame::s_amr_restore_coarse ( logical, intent(in), optional sync_device)

Restore the global grid state saved by s_amr_swap_to_fine.

Parameters
[in]sync_device.false. only from the batched stage when another batch follows at once (its swap re-pushes the grid state)

Definition at line 590 of file m_amr_frame.fpp.f90.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ s_amr_swap_to_fine()

impure subroutine, public m_amr_frame::s_amr_swap_to_fine ( logical, intent(in), optional widen)

Swap the global grid state to the fine block. Must be paired with s_amr_restore_coarse.

Parameters
[in]widenalso widen idwint to the ghost shells (the RHS conversion range)

Definition at line 414 of file m_amr_frame.fpp.f90.

Here is the call graph for this function:
Here is the caller graph for this function: