2D AMRCLAW
Functions/Subroutines
coarsen.f File Reference

Go to the source code of this file.

Functions/Subroutines

subroutine coarsen (valdub, midub, mjdub, valbgc, mi2tot, mj2tot, nvar)
 

Function/Subroutine Documentation

◆ coarsen()

subroutine coarsen ( dimension(nvar,midub, mjdub)  valdub,
  midub,
  mjdub,
dimension(nvar,mi2tot,mj2tot)  valbgc,
  mi2tot,
  mj2tot,
  nvar 
)

coarsen the fine grid data (with double the usual number of ghost cells to prepare coarsened grid for error estimation.

Definition at line 5 of file coarsen.f.

Referenced by prepbigstep().

5 
6  implicit double precision (a-h, o-z)
7 
8  dimension valdub(nvar,midub, mjdub)
9  dimension valbgc(nvar,mi2tot,mj2tot)
10 
11 c :::::::::::::::::::::::: coarsen ::::::::::::::::::::::::::::::::
15 c :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
16 
17  do 10 j = 1, mj2tot
18 
19  jfine = 2*(j-1) + 1
20 
21  do 10 i = 1, mi2tot
22  ifine = 2*(i-1) + 1
23 
24  do 10 ivar = 1, nvar
25 
26  valbgc(ivar,i,j) = (valdub(ivar,ifine,jfine) +
27  & valdub(ivar,ifine+1,jfine)+
28  & valdub(ivar,ifine,jfine+1) +
29  & valdub(ivar,ifine+1,jfine+1))/4.d0
30 10 continue
31 
32  return
subroutine coarsen(valdub, midub, mjdub, valbgc, mi2tot, mj2tot, nvar)
Definition: coarsen.f:5
Here is the caller graph for this function: