23 subroutine limiter(maxm,meqn,mwaves,mbc,mx,wave,s,mthlim)
27 implicit double precision (a-h,o-z)
29 dimension wave(meqn,
mwaves, 1-mbc:maxm+mbc)
30 dimension s(
mwaves, 1-mbc:maxm+mbc)
34 if (
mthlim(mw) .eq. 0)
go to 50
41 wnorm2 = wnorm2 + wave(m,mw,i)**2
42 dotr = dotr + wave(m,mw,i)*wave(m,mw,i+1)
45 if (wnorm2.eq.0.d0)
go to 40
47 if (s(mw,i) .gt. 0.d0)
then 54 wave(m,mw,i) = wlimitr * wave(m,mw,i)
integer, dimension(:), allocatable mthlim
subroutine limiter(maxm, meqn, mwaves, mbc, mx, wave, s, mthlim)
double precision function philim(a, b, meth)