| 9 | 
      & A_glen_isothermal, n_glen, eps_glen_min, | 
      & A_glen_isothermal, n_glen, eps_glen_min, | 
| 10 | 
      & C_basal_fric_const, n_basal_friction, streamice_input_flux_unif, | 
      & C_basal_fric_const, n_basal_friction, streamice_input_flux_unif, | 
| 11 | 
      & streamice_vel_update, streamice_cg_tol, streamice_nonlin_tol, | 
      & streamice_vel_update, streamice_cg_tol, streamice_nonlin_tol, | 
| 12 | 
      & streamice_CFL_factor | 
      & streamice_nonlin_tol_fp, | 
| 13 | 
  | 
      & streamice_CFL_factor, streamice_adjDump,  | 
| 14 | 
  | 
      & streamice_bg_surf_slope_x, streamice_bg_surf_slope_y, | 
| 15 | 
  | 
      & streamice_kx_b_init, streamice_ky_b_init | 
| 16 | 
       _RL streamice_density, streamice_density_ocean_avg | 
       _RL streamice_density, streamice_density_ocean_avg | 
| 17 | 
       _RL A_glen_isothermal, n_glen, eps_glen_min | 
       _RL A_glen_isothermal, n_glen, eps_glen_min | 
| 18 | 
       _RL C_basal_fric_const | 
       _RL C_basal_fric_const | 
| 20 | 
       _RL streamice_input_flux_unif | 
       _RL streamice_input_flux_unif | 
| 21 | 
       _RL streamice_vel_update  | 
       _RL streamice_vel_update  | 
| 22 | 
       _RL streamice_cg_tol, streamice_nonlin_tol | 
       _RL streamice_cg_tol, streamice_nonlin_tol | 
| 23 | 
  | 
       _RL streamice_nonlin_tol_fp | 
| 24 | 
       _RL streamice_CFL_factor | 
       _RL streamice_CFL_factor | 
| 25 | 
  | 
       _RL streamice_adjDump | 
| 26 | 
  | 
       _RL streamice_bg_surf_slope_x, streamice_bg_surf_slope_y | 
| 27 | 
  | 
       _RL streamice_kx_b_init, streamice_ky_b_init | 
| 28 | 
        | 
        | 
| 29 | 
 C     parms for parameterized initial thickness | 
 C     parms for parameterized initial thickness | 
| 30 | 
 C     SHELF_MAX_DRAFT: max thickness of ice in m | 
 C     SHELF_MAX_DRAFT: max thickness of ice in m | 
| 51 | 
  | 
  | 
| 52 | 
 C     -------------------------- INT PARAMS --------------------------------------------------- | 
 C     -------------------------- INT PARAMS --------------------------------------------------- | 
| 53 | 
  | 
  | 
| 54 | 
  | 
       INTEGER streamice_max_nl | 
| 55 | 
  | 
       PARAMETER ( streamice_max_nl = 100 ) | 
| 56 | 
  | 
  | 
| 57 | 
       COMMON /STREAMICE_PARMS_I/ | 
       COMMON /STREAMICE_PARMS_I/ | 
| 58 | 
      &     streamice_max_cg_iter, streamice_max_nl_iter, | 
      &     streamice_max_cg_iter, streamice_max_nl_iter, | 
| 59 | 
      &     streamice_vel_upd_counter, streamice_nstep_velocity, | 
      &     streamice_vel_upd_counter, streamice_nstep_velocity, | 
| 67 | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEthickFile | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEthickFile | 
| 68 | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEthickInit | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEthickInit | 
| 69 | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEcalveMaskFile | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEcalveMaskFile | 
| 70 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEsigcoordInit | 
| 71 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEsigcoordFile | 
| 72 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEdelsigFile | 
| 73 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEbasalTracConfig | 
| 74 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEbasalTracFile | 
| 75 | 
  | 
       CHARACTER*(MAX_LEN_FNAM) STREAMICEvelOptimFile | 
| 76 | 
       COMMON /STREAMICE_PARM_C/  | 
       COMMON /STREAMICE_PARM_C/  | 
| 77 | 
      &     STREAMICEthickInit, | 
      &     STREAMICEthickInit, | 
| 78 | 
      &     STREAMICEthickFile, | 
      &     STREAMICEthickFile, | 
| 79 | 
      &     STREAMICEcalveMaskFile | 
      &     STREAMICEcalveMaskFile, | 
| 80 | 
  | 
      &     STREAMICEsigcoordInit, | 
| 81 | 
  | 
      &     STREAMICEsigcoordFile, | 
| 82 | 
  | 
      &     STREAMICEdelsigFile, | 
| 83 | 
  | 
      &     STREAMICEbasalTracConfig, | 
| 84 | 
  | 
      &     STREAMICEbasalTracFile, | 
| 85 | 
  | 
      &     STREAMICEvelOptimFile | 
| 86 | 
       | 
       | 
| 87 | 
 C     -------------------------- LOGICAL PARAMS --------------------------------------------------- | 
 C     -------------------------- LOGICAL PARAMS --------------------------------------------------- | 
| 88 | 
  | 
  | 
| 93 | 
       LOGICAL STREAMICE_tave_mnc | 
       LOGICAL STREAMICE_tave_mnc | 
| 94 | 
       LOGICAL STREAMICE_GL_regularize, STREAMICE_move_front | 
       LOGICAL STREAMICE_GL_regularize, STREAMICE_move_front | 
| 95 | 
       LOGICAL STREAMICE_calve_to_mask | 
       LOGICAL STREAMICE_calve_to_mask | 
| 96 | 
 !       LOGICAL STREAMICE_construct_matrix | 
       LOGICAL STREAMICE_construct_matrix | 
| 97 | 
       LOGICAL STREAMICE_lower_cg_tol | 
       LOGICAL STREAMICE_lower_cg_tol | 
| 98 | 
  | 
       LOGICAL STREAMICE_diagnostic_only | 
| 99 | 
  | 
        | 
| 100 | 
  | 
 C     The following parameters specify periodic boundary conditions.  | 
| 101 | 
  | 
 C     For now this will completely override all other boundary conditions | 
| 102 | 
  | 
 C     and apply to the entire boundary | 
| 103 | 
  | 
  | 
| 104 | 
  | 
       LOGICAL STREAMICE_NS_periodic | 
| 105 | 
  | 
       LOGICAL STREAMICE_EW_periodic | 
| 106 | 
  | 
        | 
| 107 | 
  | 
 C      LOGICAL STREAMICE_hybrid_stress | 
| 108 | 
  | 
        | 
| 109 | 
       COMMON /STREAMICE_PARM_L/ | 
       COMMON /STREAMICE_PARM_L/ | 
| 110 | 
      & STREAMICEison, | 
      & STREAMICEison, | 
| 111 | 
      & STREAMICE_dump_mdsio, STREAMICE_tave_mdsio, | 
      & STREAMICE_dump_mdsio, STREAMICE_tave_mdsio, | 
| 112 | 
      & STREAMICE_dump_mnc, STREAMICE_tave_mnc, | 
      & STREAMICE_dump_mnc, STREAMICE_tave_mnc, | 
| 113 | 
      & STREAMICE_GL_regularize, STREAMICE_move_front, | 
      & STREAMICE_GL_regularize, STREAMICE_move_front, | 
| 114 | 
      & STREAMICE_calve_to_mask, | 
      & STREAMICE_calve_to_mask, | 
| 115 | 
 !     & STREAMICE_construct_matrix, | 
      & STREAMICE_construct_matrix, | 
| 116 | 
      & STREAMICE_lower_cg_tol | 
      & STREAMICE_lower_cg_tol, | 
| 117 | 
  | 
      & STREAMICE_NS_periodic, STREAMICE_EW_periodic, | 
| 118 | 
  | 
      & STREAMICE_diagnostic_only | 
| 119 | 
  | 
  | 
| 120 | 
 C     -------------------------- AND NOW ARRAYS --------------------------------------------------- | 
 C     -------------------------- AND NOW ARRAYS --------------------------------------------------- | 
| 121 | 
  | 
  | 
| 204 | 
      &     u_bdry_values_SI, | 
      &     u_bdry_values_SI, | 
| 205 | 
      &     v_bdry_values_SI, | 
      &     v_bdry_values_SI, | 
| 206 | 
      &     STREAMICE_dummy_array, | 
      &     STREAMICE_dummy_array, | 
| 207 | 
      &     C_basal_friction | 
      &     C_basal_friction, | 
| 208 | 
  | 
      &     A_glen, | 
| 209 | 
  | 
      &     BDOT_streamice, | 
| 210 | 
  | 
      &     streamice_taubx, streamice_tauby, | 
| 211 | 
  | 
      &     streamice_u_surf, streamice_v_surf, | 
| 212 | 
  | 
      &     visc_streamice_full, streamice_omega, streamice_basal_geom, | 
| 213 | 
  | 
      &     streamice_vert_shear_uz, streamice_vert_shear_vz, | 
| 214 | 
  | 
      &     streamice_sigma_coord, streamice_delsigma | 
| 215 | 
       _RL H_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL H_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 216 | 
       _RL U_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL U_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 217 | 
       _RL V_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL V_streamice           (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 228 | 
       _RL u_bdry_values_SI    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL u_bdry_values_SI    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 229 | 
       _RL v_bdry_values_SI    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL v_bdry_values_SI    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 230 | 
       _RL C_basal_friction    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL C_basal_friction    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 231 | 
  | 
       _RL A_glen    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 232 | 
  | 
        | 
| 233 | 
  | 
 C      The following arrays are used for the hybrid stress balance       | 
| 234 | 
  | 
        | 
| 235 | 
  | 
       _RL streamice_taubx (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 236 | 
  | 
       _RL streamice_tauby (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 237 | 
  | 
       _RL streamice_u_surf (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 238 | 
  | 
       _RL streamice_v_surf (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 239 | 
  | 
       _RL streamice_omega (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 240 | 
  | 
       _RL streamice_basal_geom  | 
| 241 | 
  | 
      & (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 242 | 
  | 
       _RL visc_streamice_full  | 
| 243 | 
  | 
      & (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy) | 
| 244 | 
  | 
       _RL streamice_vert_shear_uz (Nr) | 
| 245 | 
  | 
       _RL streamice_vert_shear_vz (Nr) | 
| 246 | 
  | 
       _RL streamice_sigma_coord (Nr) | 
| 247 | 
  | 
       _RL streamice_delsigma (Nr) | 
| 248 | 
  | 
        | 
| 249 | 
  | 
 !! IMPORTANT: MELT RATE IN METERS PER YEAR | 
| 250 | 
  | 
 !! POSITIVE WHERE MELTING | 
| 251 | 
  | 
       _RL BDOT_streamice (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 252 | 
        | 
        | 
| 253 | 
       _RL STREAMICE_dummy_array (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
       _RL STREAMICE_dummy_array (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) | 
| 254 | 
        | 
        |