Add Lagrange interpolation subroutine and update calls in prolongrestrict modules

This commit is contained in:
2026-02-27 12:46:39 +08:00
parent 94d236385d
commit c001939461
3 changed files with 30 additions and 8 deletions

View File

@@ -217,7 +217,6 @@
real*8,dimension(2*ghost_width) :: X,Y,Z
real*8, dimension(2*ghost_width,2*ghost_width) :: tmp2
real*8, dimension(2*ghost_width) :: tmp1
real*8 :: ddy
#if (ghost_width == 2)
real*8, parameter :: C1=-1.d0/16,C2=9.d0/16
@@ -470,7 +469,7 @@
tmp1(cxB(1)+ghost_width-i+1:cxT(1)+ghost_width-i+1) = fh(cxB(1):cxT(1),j,k)
call polint(X,tmp1,0.d0,funf(i,j,k),ddy,2*ghost_width)
call polint0(X,tmp1,funf(i,j,k),2*ghost_width)
! for y direction
elseif (fg(2) .eq. 0)then
@@ -529,7 +528,7 @@
tmp1(cxB(2)+ghost_width-j+1:cxT(2)+ghost_width-j+1) = fh(i,cxB(2):cxT(2),k)
call polint(Y,tmp1,0.d0,funf(i,j,k),ddy,2*ghost_width)
call polint0(Y,tmp1,funf(i,j,k),2*ghost_width)
! for z direction
else
@@ -588,7 +587,7 @@
tmp1(cxB(3)+ghost_width-k+1:cxT(3)+ghost_width-k+1) = fh(i,j,cxB(3):cxT(3))
call polint(Z,tmp1,0.d0,funf(i,j,k),ddy,2*ghost_width)
call polint0(Z,tmp1,funf(i,j,k),2*ghost_width)
endif