Skilled (#3) - [BDY] setting up a new configuration - issues with boundary conditions (#106) - Message List
Dear all,
I'm trying to set up a new regional configuration with open boundaries, using release 4.0.5.
After quite some testing some questions remain, for which I hope to get some input from the community. In the following, I try to summarize, what I did so far, what works and what doesn't.
- First of all, installing the code and reproducing the test configuration AMM12 works!
- The new configuration has three strait open boundaries (N,W,S) that I define using the nambdy_index option with automatic definition of the boundary locations by setting nbdyind = -1 in all three nambdy_index. From ocean.output, I see that these boundaries are correctly identified.
- As a first test, I provide constant boundary data (3D U,V,T,S) on the native model grid. These seem to be read.
, at least for the western and southern boundaries; there's no print for the northern boundary in ocean.output (independently from the order in which I define the boundaries - it's always the northern that seems to be "silent"; the loop is entered the correct number of times but nothing is printed in the case of the northern boundary). Should I worry about this? If so, what might be going wrong here?
- The velocities are full velocities, so I set ln_full_vel = .true. . Doing so leads to segmentation faults. This seems to be connected to undefined dta_alias%u2d and dta_alias%v2d in SUBROUTINE bdy_dta IF( bf_alias(jp_bdyu3d)%ltotvel ). I can overcome this by setting cn_dyn2d to something else than 'none', although 'none' would be the logical choice, and nn_dyn2d_dta = 0 . Is this a bug or am I misunderstanding something here?
- Furthermore, I'd also like to prescribe SSH but this is not possible with full velocities - correct?
Below are the respective bdy namelists (couldn't find an attache-button).
In the next step, I'd like to use temporally varying boundary conditions, preferably on their own grid. Is this in general implemented? Vertical interpolation seems to work. However I have the impression (from ocean.output, some reading through the code and additionally implemented print-statements, horizontal interpolation - in this case only in one direction, along each boundary - is not implemented. Is this correct? Or in other words: is it mandatory for the boundary conditions to be provided on the same horizontal grid as the model itself?
I've been using NEMO for quite a while now but am new to BDY and appreciate any input that might help to get me through this process.
Best regards, Franziska
!----------------------------------------------------------------------- &nambdy ! unstructured open boundaries (default: OFF) !----------------------------------------------------------------------- ln_bdy = .true. ! Use unstructured open boundaries nb_bdy = 3 ! number of open boundary sets ln_coords_file = .false.,.false.,.false. ! =T : read bdy coordinates from file cn_coords_file = '','','' ! bdy coordinates files ln_mask_file = .false. ! =T : read mask from file cn_mask_file = '' ! name of mask file (if ln_mask_file=.TRUE.) cn_dyn2d = 'frs','frs','frs' ! <-- FUS: supposed to be none? nn_dyn2d_dta = 0,0,0 ! = 0, bdy data are equal to the initial state cn_dyn3d = 'specified','specified','specified' ! FUS: also tested 'frs','frs','frs' and 'none','none','none' ("closed boundaries") nn_dyn3d_dta = 1,1,1 ! FUS: 0,0,0 with closed boundaries cn_tra = 'specified','specified','specified' ! FUS: also tested 'frs','frs','frs' and 'none','none','none' ("closed boundaries") nn_tra_dta = 1,1,1 ! FUS: 0,0,0 with closed boundaries cn_ice = 'none','none','none' ! nn_ice_dta = 0,0,0 ! = 0, bdy data are equal to the initial state ln_tra_dmp =.false.,.false.,.false. ! open boudaries conditions for tracers ln_dyn3d_dmp =.false.,.false.,.false. ! open boundary condition for baroclinic velocities rn_time_dmp = 1,1,1 ! Damping time scale in days rn_time_dmp_out = 1,1,1 ! Outflow damping time scale nn_rimwidth = 1,1,1 ! FUS: also tested higher values and 0,0,0 ln_vol = .false. ! total volume correction (see nn_volctl parameter) nn_volctl = 1 ! = 0, the total water flux across open boundaries is zero / !----------------------------------------------------------------------- &nambdy_index ! index list for open boundaries (added by hand - see NEMO book) !----------------------------------------------------------------------- ctypebdy = 'W' nbdyind = -1 nbdybeg = 0 nbdyend = 0 / !----------------------------------------------------------------------- &nambdy_index ! index list for open boundaries (added by hand - see NEMO book) !----------------------------------------------------------------------- ctypebdy = 'S' nbdyind = -1 nbdybeg = 0 nbdyend = 0 / !----------------------------------------------------------------------- &nambdy_index ! index list for open boundaries (added by hand - see NEMO book) !----------------------------------------------------------------------- ctypebdy = 'N' nbdyind = -1 nbdybeg = 0 nbdyend = 0 / !!----------------------------------------------------------------------- &nambdy_dta ! open boundaries - external data !----------------------------------------------------------------------- ln_zinterp = .false. ! T if a vertical interpolation is required. Variables gdep[tuv] and e3[tuv] must exist in the file ! ! automatically defined to T if the number of vertical levels in bdy dta /= jpk ln_full_vel = .true. ! T if [uv]3d are "full" velocities and not only its baroclinic components ! ! in this case, baroclinic and barotropic velocities will be recomputed -> [uv]2d not needed ! cn_dir = './' ! root directory for the BDY data location !___________!_________________________!___________________!___________!_____________!________!___________!__________________!__________!_______________! ! ! file name ! frequency (hours) ! variable ! time interp.! clim ! 'yearly'/ ! weights filename ! rotation ! land/sea mask ! ! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! ! pairing ! filename ! bn_ssh = 'init_fields_l120wonly.nc' , -12 , 'zos' , .false. , .true. , 'yearly' , '' , '' , '' bn_u2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_v2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_u3d = 'init_fields_l120wonly.nc' , -12 , 'uo' , .false. , .true. , 'yearly' , '' , '' , '' bn_v3d = 'init_fields_l120wonly.nc' , -12 , 'vo' , .false. , .true. , 'yearly' , '' , '' , '' bn_tem = 'init_fields_l120wonly.nc' , -12 , 'thetao' , .false. , .true. , 'yearly' , '' , '' , '' bn_sal = 'init_fields_l120wonly.nc' , -12 , 'so' , .false. , .true. , 'yearly' , '' , '' , '' / !----------------------------------------------------------------------- &nambdy_dta ! open boundaries - external data !----------------------------------------------------------------------- ln_zinterp = .false. ! T if a vertical interpolation is required. Variables gdep[tuv] and e3[tuv] must exist in the file ! ! automatically defined to T if the number of vertical levels in bdy dta /= jpk ln_full_vel = .true. ! T if [uv]3d are "full" velocities and not only its baroclinic components ! ! in this case, baroclinic and barotropic velocities will be recomputed -> [uv]2d not needed ! cn_dir = './' ! root directory for the BDY data location !___________!_________________________!___________________!___________!_____________!________!___________!__________________!__________!_______________! ! ! file name ! frequency (hours) ! variable ! time interp.! clim ! 'yearly'/ ! weights filename ! rotation ! land/sea mask ! ! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! ! pairing ! filename ! bn_ssh = 'init_fields_l120sonly.nc' , -12 , 'zos' , .false. , .true. , 'yearly' , '' , '' , '' bn_u2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_v2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_u3d = 'init_fields_l120sonly.nc' , -12 , 'uo' , .false. , .true. , 'yearly' , '' , '' , '' bn_v3d = 'init_fields_l120sonly.nc' , -12 , 'vo' , .false. , .true. , 'yearly' , '' , '' , '' bn_tem = 'init_fields_l120sonly.nc' , -12 , 'thetao' , .false. , .true. , 'yearly' , '' , '' , '' bn_sal = 'init_fields_l120sonly.nc' , -12 , 'so' , .false. , .true. , 'yearly' , '' , '' , '' / !----------------------------------------------------------------------- &nambdy_dta ! open boundaries - external data !----------------------------------------------------------------------- ln_zinterp = .false. ! T if a vertical interpolation is required. Variables gdep[tuv] and e3[tuv] must exist in the file ! ! automatically defined to T if the number of vertical levels in bdy dta /= jpk ln_full_vel = .true. ! T if [uv]3d are "full" velocities and not only its baroclinic components ! ! in this case, baroclinic and barotropic velocities will be recomputed -> [uv]2d not needed ! cn_dir = './' ! root directory for the BDY data location !___________!_________________________!___________________!___________!_____________!________!___________!__________________!__________!_______________! ! ! file name ! frequency (hours) ! variable ! time interp.! clim ! 'yearly'/ ! weights filename ! rotation ! land/sea mask ! ! ! ! (if <0 months) ! name ! (logical) ! (T/F) ! 'monthly' ! ! pairing ! filename ! bn_ssh = 'init_fields_l120nonly.nc' , -12 , 'zos' , .false. , .true. , 'yearly' , '' , '' , '' bn_u2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_v2d = 'NOT USED' , -12 , '' , .false. , .true. , 'yearly' , '' , '' , '' bn_u3d = 'init_fields_l120nonly.nc' , -12 , 'uo' , .false. , .true. , 'yearly' , '' , '' , '' bn_v3d = 'init_fields_l120nonly.nc' , -12 , 'vo' , .false. , .true. , 'yearly' , '' , '' , '' bn_tem = 'init_fields_l120nonly.nc' , -12 , 'thetao' , .false. , .true. , 'yearly' , '' , '' , '' bn_sal = 'init_fields_l120nonly.nc' , -12 , 'so' , .false. , .true. , 'yearly' , '' , '' , ''