You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Neutral grid mapping in geographic coordinates onto periodic GEMINI #104
The neutral=4 (geographic coordinates) cannot be properly mapped onto periodic GEMINI grid. This can result from the way it is replicating the glat/glon variables there and then using them to interpolate the neutral data in space. It works fine in neutral=3 though.
The block that should potentially be the issue is:
!> assign a reference meridian alt,lat,lon across periodic grid
subroutine set_periodic(self,flagperiodic,refalt,refglon,refglat)
class(curvmesh), intent(inout) :: self
integer, intent(in) :: flagperiodic
real(wp), dimension(:,:), intent(in) :: refalt,refglon,refglat
integer :: ix3
! flag appropriately
if (flagperiodic/=0) then
self%flagper=.true.
else
self%flagper=.false.
end if
! In the special case where the user wants flagperiodic==1, we take the additional step of forcing
! glat/glon to be the same across the x3 dimension so that the neutral atmosphere and photoionization
! will be constant vs. x3. This is most typically used in instability simulations when one wants to
! explicitly remove any dependence of background parameters on the x3 direction. One would not want to use
! this when simply trying to model an angular coordinate (e.g. longitude) across the full globe as the
! atmospheric and SZA changes are needed to realistically capture the system.
! force periodicity in geographic locations using reference meridian data
!! FIXME: specify ghost cells for glat/glon arrays?
if (flagperiodic==1) then
do ix3=1,self%lx3
self%glat(1:self%lx1,1:self%lx2,ix3)=refglat(:,:)
self%glon(1:self%lx1,1:self%lx2,ix3)=refglon(:,:)
self%alt(1:self%lx1,1:self%lx2,ix3)=refalt(:,:)
end do
end if
end subroutine set_periodic
I think when I was doing my initial tests with neutral forcing of bubble I was using interptype=3. I think that is probably the only way to use neutral perturbations with periodic grids because geographic input neutral perturbations will not along with the longitude coordinate in the model. So they need to be aperiodic, but I'm not sure that would work for plasma bubble simulations because there is a tendency for things to grow on the edges of the domain.
Activity
mattzett commentedon Jul 25, 2023
I think when I was doing my initial tests with neutral forcing of bubble I was using interptype=3. I think that is probably the only way to use neutral perturbations with periodic grids because geographic input neutral perturbations will not along with the longitude coordinate in the model. So they need to be aperiodic, but I'm not sure that would work for plasma bubble simulations because there is a tendency for things to grow on the edges of the domain.