189 class(Mesh2dDisExportType),
intent(inout) :: this
190 class(ExportPackageType),
pointer,
intent(in) :: export_pkg
191 type(InputParamDefinitionType),
pointer :: idt
192 integer(I4B),
dimension(:),
pointer,
contiguous :: int1d
193 real(DP),
dimension(:),
pointer,
contiguous :: dbl1d, nodes
194 real(DP),
dimension(:, :),
pointer,
contiguous :: dbl2d
195 character(len=LINELENGTH) :: nc_tag
196 integer(I4B) :: iaux, iparam, nvals
198 integer(I4B),
pointer :: nbound
204 do iparam = 1, export_pkg%nparam
206 if (export_pkg%param_reads(iparam)%invar < 1) cycle
211 export_pkg%mf6_input%component_type, &
212 export_pkg%mf6_input%subcomponent_type, &
213 'PERIOD', export_pkg%param_names(iparam),
'')
216 nc_tag = this%input_attribute(export_pkg%mf6_input%subcomponent_name, &
220 select case (idt%datatype)
222 call mem_setptr(int1d, idt%mf6varname, export_pkg%mf6_input%mempath)
223 this%var_ids%export(1) = export_pkg%varids_param(iparam, 1)
224 call nc_export_int1d(int1d, this%ncid, this%dim_ids, this%x_dim, &
225 this%y_dim, this%var_ids, this%dis, idt, &
226 export_pkg%mf6_input%mempath, nc_tag, &
227 export_pkg%mf6_input%subcomponent_name, &
228 this%gridmap_name, this%deflate, this%shuffle, &
229 this%chunk_face,
kper, this%nc_fname)
231 call mem_setptr(dbl1d, idt%mf6varname, export_pkg%mf6_input%mempath)
232 select case (idt%shape)
234 this%var_ids%export(1) = export_pkg%varids_param(iparam, 1)
235 call nc_export_dbl1d(dbl1d, this%ncid, this%dim_ids, this%x_dim, &
236 this%y_dim, this%var_ids, this%dis, idt, &
237 export_pkg%mf6_input%mempath, nc_tag, &
238 export_pkg%mf6_input%subcomponent_name, &
239 this%gridmap_name, this%deflate, this%shuffle, &
240 this%chunk_face,
kper, iaux, this%nc_fname)
242 nvals = this%dis%nodesuser
243 allocate (nodes(nvals))
245 do k = 1, this%dis%nlay
246 this%var_ids%export(k) = export_pkg%varids_param(iparam, k)
248 call mem_setptr(dbl1d, idt%mf6varname, export_pkg%mf6_input%mempath)
249 call mem_setptr(int1d,
'NODEULIST', export_pkg%mf6_input%mempath)
250 call mem_setptr(nbound,
'NBOUND', export_pkg%mf6_input%mempath)
252 nodes(int1d(n)) = dbl1d(n)
254 call nc_export_dbl1d(nodes, this%ncid, this%dim_ids, this%x_dim, &
255 this%y_dim, this%var_ids, this%dis, idt, &
256 export_pkg%mf6_input%mempath, nc_tag, &
257 export_pkg%mf6_input%subcomponent_name, &
258 this%gridmap_name, this%deflate, this%shuffle, &
259 this%chunk_face,
kper, iaux, this%nc_fname)
264 call mem_setptr(dbl2d, idt%mf6varname, export_pkg%mf6_input%mempath)
265 select case (idt%shape)
267 nvals = this%dis%nrow * this%dis%ncol
268 allocate (nodes(nvals))
269 do iaux = 1,
size(dbl2d, dim=1)
270 this%var_ids%export(1) = export_pkg%varids_aux(iaux, 1)
272 nodes(n) = dbl2d(iaux, n)
274 call nc_export_dbl1d(nodes, this%ncid, this%dim_ids, this%x_dim, &
275 this%y_dim, this%var_ids, this%dis, idt, &
276 export_pkg%mf6_input%mempath, nc_tag, &
277 export_pkg%mf6_input%subcomponent_name, &
278 this%gridmap_name, this%deflate, this%shuffle, &
279 this%chunk_face,
kper, iaux, this%nc_fname)
283 nvals = this%dis%nodesuser
284 allocate (nodes(nvals))
285 call mem_setptr(int1d,
'NODEULIST', export_pkg%mf6_input%mempath)
286 call mem_setptr(nbound,
'NBOUND', export_pkg%mf6_input%mempath)
287 do iaux = 1,
size(dbl2d, dim=1)
289 do k = 1, this%dis%nlay
290 this%var_ids%export(k) = export_pkg%varids_aux(iaux, k)
293 nodes(int1d(n)) = dbl2d(iaux, n)
295 call nc_export_dbl1d(nodes, this%ncid, this%dim_ids, this%x_dim, &
296 this%y_dim, this%var_ids, this%dis, idt, &
297 export_pkg%mf6_input%mempath, nc_tag, &
298 export_pkg%mf6_input%subcomponent_name, &
299 this%gridmap_name, this%deflate, this%shuffle, &
300 this%chunk_face,
kper, iaux, this%nc_fname)
312 call nf_verify(nf90_put_var(this%ncid, this%var_ids%time, &
317 call nf_verify(nf90_sync(this%ncid), this%nc_fname)
This module contains the DefinitionSelectModule.
type(inputparamdefinitiontype) function, pointer, public get_param_definition_type(input_definition_types, component_type, subcomponent_type, blockname, tagname, filename)
Return parameter definition.
This module contains the NCModelExportModule.
real(dp), pointer, public totim
time relative to start of simulation