AMROC Main     Blockstructured Adaptive Mesh Refinement in object-oriented C++


Main Page   Class Hierarchy   Compound List   File List  

Makefile  combl.f  cuser.i  init2.f  physbd2.f  rpn2eug.f  flx2eu.f  rec2eu.f  chk2eu.f  flg2eu.f  Problem.h  amr_main.C 

applications/euler/2d/BackwardFacingStep/src/init2.f


c
c
c
c     =====================================================
       subroutine ic(maxmx,maxmy,meqn,mbc,mx,my,x,y,dx,dy,q)
c     =====================================================
c
       implicit double precision (a-h,o-z)
c
       include  "cuser.i"
c
       dimension q(meqn, 1-mbc:maxmx+mbc, 1-mbc:maxmy+mbc)
       dimension x(1-mbc:maxmx+mbc),y(1-mbc:maxmy+mbc)
c
       do 60 i = 1-mbc, mx+mbc
          do 60 j = 1-mbc, my+mbc
             call cellave(x(i)-dx/2.d0,y(j)-dy/2.d0,dx,dy,wl)
             do 60 m = 1,meqn
                rho = (1.d0-wl)*rhoamb  + wl*rhoshk
                u =   (1.d0-wl)*uamb 	+ wl*ushk
                v =   (1.d0-wl)*vamb	+ wl*vshk
                p =   (1.d0-wl)*pamb	+ wl*pshk
                q(1,i,j) = rho
                q(2,i,j) = rho * u
                q(3,i,j) = rho * v
                q(4,i,j) = p/gamma1 + .5d0*rho*(u**2+v**2)
 60    continue         
c
       return
       end


Quickstart     Users Guide     Programmers Reference     Installation      Examples     Download



AMROC Main      Home      Contact
last update: 06/01/04