Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update from main #8

Merged
merged 4 commits into from
Jun 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions cice.setup
Original file line number Diff line number Diff line change
Expand Up @@ -572,6 +572,13 @@ EOF
continue
endif

# unset env variables that might not exist in env machine file
# to avoid any carry over during multi compiler suites
unsetenv ICE_MACHINE_MAXTHREADS
unsetenv ICE_MACHINE_MAXPES
unsetenv ICE_MACHINE_QUIETMODE
unsetenv ICE_MACHINE_CPPDEFS
unsetenv ICE_MACHINE_QSTAT
source ${ICE_SCRIPTS}/machines/env.${machcomp} -nomodules || exit 2

# Obtain the test name, sets, grid, and PE information from .ts file
Expand Down Expand Up @@ -782,6 +789,11 @@ EOF
set quietmode = ${ICE_MACHINE_QUIETMODE}
endif

set cppdefs = ""
if ($?ICE_MACHINE_CPPDEFS) then
set cppdefs = ${ICE_MACHINE_CPPDEFS}
endif

if (${acct} == ${spval}) then
if (-e ~/.cice_proj) then
set acct = `head -1 ~/.cice_proj`
Expand Down Expand Up @@ -884,6 +896,7 @@ setenv ICE_BASELINE ${basedir_tmp}
setenv ICE_BASEGEN ${baseGen}
setenv ICE_BASECOM ${baseCom}
setenv ICE_SPVAL ${spval}
setenv ICE_CPPDEFS ${cppdefs}
setenv ICE_QUIETMODE ${quietmode}
setenv ICE_TEST ${test}
setenv ICE_TESTNAME ${testname_noid}
Expand Down
27 changes: 11 additions & 16 deletions cicecore/cicedynB/dynamics/ice_transport_remap.F90
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
module ice_transport_remap

use ice_kinds_mod
use ice_blocks, only: nx_block, ny_block
use ice_communicate, only: my_task
use ice_constants, only: c0, c1, c2, c12, p333, p4, p5, p6, &
eps13, eps16, &
Expand Down Expand Up @@ -254,7 +255,6 @@ module ice_transport_remap
subroutine init_remap

use ice_domain, only: nblocks
use ice_blocks, only: nx_block, ny_block
use ice_grid, only: xav, yav, xxav, yyav
! dxt, dyt, xyav, &
! xxxav, xxyav, xyyav, yyyav
Expand Down Expand Up @@ -324,7 +324,7 @@ subroutine horizontal_remap (dt, ntrace, &
use ice_boundary, only: ice_halo, ice_HaloMask, ice_HaloUpdate, &
ice_HaloDestroy
use ice_domain, only: nblocks, blocks_ice, halo_info, maskhalo_remap
use ice_blocks, only: block, get_block, nghost, nx_block, ny_block
use ice_blocks, only: block, get_block, nghost
use ice_grid, only: HTE, HTN, dxu, dyu, &
tarear, hm, &
xav, yav, xxav, yyav
Expand Down Expand Up @@ -384,8 +384,7 @@ subroutine horizontal_remap (dt, ntrace, &
integer (kind=int_kind), dimension(0:ncat,max_blocks) :: &
icellsnc ! number of cells with ice

integer (kind=int_kind), &
dimension(nx_block*ny_block,0:ncat) :: &
integer (kind=int_kind), dimension(nx_block*ny_block,0:ncat) :: &
indxinc, indxjnc ! compressed i/j indices

real (kind=dbl_kind), dimension(nx_block,ny_block) :: &
Expand All @@ -403,13 +402,11 @@ subroutine horizontal_remap (dt, ntrace, &
real (kind=dbl_kind), dimension(nx_block,ny_block,0:ncat) :: &
mmask ! = 1. if mass is present, = 0. otherwise

real (kind=dbl_kind), &
dimension (nx_block,ny_block,ntrace,ncat,max_blocks) :: &
real (kind=dbl_kind), dimension (nx_block,ny_block,ntrace,ncat,max_blocks) :: &
tc ,&! tracer values at geometric center of cell
tx, ty ! limited derivative of tracer wrt x and y

real (kind=dbl_kind), &
dimension (nx_block,ny_block,ntrace,ncat) :: &
real (kind=dbl_kind), dimension (nx_block,ny_block,ntrace,ncat) :: &
tmask ! = 1. if tracer is present, = 0. otherwise

real (kind=dbl_kind), dimension (nx_block,ny_block,0:ncat) :: &
Expand All @@ -424,19 +421,19 @@ subroutine horizontal_remap (dt, ntrace, &
real (kind=dbl_kind), dimension (nx_block,ny_block,0:nvert,ngroups) :: &
xp, yp ! x and y coordinates of special triangle points
! (need 4 points for triangle integrals)

integer (kind=int_kind), &
dimension (nx_block,ny_block,ngroups) :: &
integer (kind=int_kind), dimension (nx_block,ny_block,ngroups) :: &
iflux ,&! i index of cell contributing transport
jflux ! j index of cell contributing transport

integer (kind=int_kind), dimension(ngroups,max_blocks) :: &
icellsng ! number of cells with ice

integer (kind=int_kind), &
dimension(nx_block*ny_block,ngroups) :: &
integer (kind=int_kind), dimension(nx_block*ny_block,ngroups) :: &
indxing, indxjng ! compressed i/j indices

integer (kind=int_kind), dimension(nx_block,ny_block,max_blocks) :: &
halomask ! temporary mask for fast halo updates

logical (kind=log_kind) :: &
l_stop ! if true, abort the model

Expand All @@ -446,9 +443,6 @@ subroutine horizontal_remap (dt, ntrace, &
character (len=char_len) :: &
edge ! 'north' or 'east'

integer (kind=int_kind), &
dimension(nx_block,ny_block,max_blocks) :: halomask

type (ice_halo) :: halo_info_tracer

type (block) :: &
Expand Down Expand Up @@ -515,6 +509,7 @@ subroutine horizontal_remap (dt, ntrace, &
mmask (:,:,0) )

! ice categories

do n = 1, ncat

call construct_fields(nx_block, ny_block, &
Expand Down
Loading