13 subroutine qg_field_create_c(c_key_self, c_key_geom, c_vars) bind(c,name='qg_field_create_f90')
19 integer(c_int),
intent(inout) :: c_key_self
20 integer(c_int),
intent(in) :: c_key_geom
21 integer(c_int),
dimension(*),
intent(in) :: c_vars
23 type(qg_field),
pointer :: self
24 type(qg_geom),
pointer :: geom
34 call create(self, geom, vars)
44 integer(c_int),
intent(inout) :: c_key_self
45 type(qg_field),
pointer :: self
61 integer(c_int),
intent(in) :: c_key_self
62 type(qg_field),
pointer :: self
71 subroutine qg_field_dirac_c(c_key_self,c_conf) bind(c,name='qg_field_dirac_f90')
75 integer(c_int),
intent(in) :: c_key_self
76 type(c_ptr),
intent(in) :: c_conf
77 type(qg_field),
pointer :: self
80 call dirac(self,c_conf)
90 integer(c_int),
intent(in) :: c_key_self
91 type(qg_field),
pointer :: self
100 subroutine qg_field_copy_c(c_key_self,c_key_rhs) bind(c,name='qg_field_copy_f90')
104 integer(c_int),
intent(in) :: c_key_self
105 integer(c_int),
intent(in) :: c_key_rhs
107 type(qg_field),
pointer :: self
108 type(qg_field),
pointer :: rhs
122 integer(c_int),
intent(in) :: c_key_self
123 integer(c_int),
intent(in) :: c_key_rhs
125 type(qg_field),
pointer :: self
126 type(qg_field),
pointer :: rhs
140 integer(c_int),
intent(in) :: c_key_self
141 integer(c_int),
intent(in) :: c_key_rhs
143 type(qg_field),
pointer :: self
144 type(qg_field),
pointer :: rhs
158 integer(c_int),
intent(in) :: c_key_self
159 integer(c_int),
intent(in) :: c_key_rhs
161 type(qg_field),
pointer :: self
162 type(qg_field),
pointer :: rhs
177 integer(c_int),
intent(in) :: c_key_self
178 real(c_double),
intent(in) :: c_zz
179 type(qg_field),
pointer :: self
180 real(kind=kind_real) :: zz
191 subroutine qg_field_axpy_c(c_key_self,c_zz,c_key_rhs) bind(c,name='qg_field_axpy_f90')
196 integer(c_int),
intent(in) :: c_key_self
197 real(c_double),
intent(in) :: c_zz
198 integer(c_int),
intent(in) :: c_key_rhs
200 type(qg_field),
pointer :: self
201 type(qg_field),
pointer :: rhs
202 real(kind=kind_real) :: zz
208 call axpy(self,zz,rhs)
214 subroutine qg_field_dot_prod_c(c_key_fld1,c_key_fld2,c_prod) bind(c,name='qg_field_dot_prod_f90')
219 integer(c_int),
intent(in) :: c_key_fld1, c_key_fld2
220 real(c_double),
intent(inout) :: c_prod
221 real(kind=kind_real) :: zz
222 type(qg_field),
pointer :: fld1, fld2
239 integer(c_int),
intent(in) :: c_key_self
240 integer(c_int),
intent(in) :: c_key_rhs
241 type(qg_field),
pointer :: self
242 type(qg_field),
pointer :: rhs
253 subroutine qg_field_diff_incr_c(c_key_lhs,c_key_x1,c_key_x2) bind(c,name='qg_field_diff_incr_f90')
257 integer(c_int),
intent(in) :: c_key_lhs
258 integer(c_int),
intent(in) :: c_key_x1
259 integer(c_int),
intent(in) :: c_key_x2
260 type(qg_field),
pointer :: lhs
261 type(qg_field),
pointer :: x1
262 type(qg_field),
pointer :: x2
278 integer(c_int),
intent(in) :: c_key_fld
279 integer(c_int),
intent(in) :: c_key_rhs
280 type(qg_field),
pointer :: fld, rhs
291 subroutine qg_field_ug_coord_c(c_key_fld, c_key_ug, c_colocated) bind (c,name='qg_field_ug_coord_f90')
296 integer(c_int),
intent(in) :: c_key_fld
297 integer(c_int),
intent(in) :: c_key_ug
298 integer(c_int),
intent(in) :: c_colocated
299 type(qg_field),
pointer :: fld
300 type(unstructured_grid),
pointer :: ug
305 colocated = c_colocated
313 subroutine qg_field_field_to_ug_c(c_key_fld, c_key_ug, c_colocated) bind (c,name='qg_field_field_to_ug_f90')
318 integer(c_int),
intent(in) :: c_key_fld
319 integer(c_int),
intent(in) :: c_key_ug
320 integer(c_int),
intent(in) :: c_colocated
321 type(qg_field),
pointer :: fld
322 type(unstructured_grid),
pointer :: ug
327 colocated = c_colocated
340 integer(c_int),
intent(in) :: c_key_fld
341 integer(c_int),
intent(in) :: c_key_ug
342 type(qg_field),
pointer :: fld
343 type(unstructured_grid),
pointer :: ug
360 integer(c_int),
intent(in) :: c_key_fld
361 type(c_ptr),
intent(in) :: c_conf
362 type(c_ptr),
intent(inout) :: c_dt
364 type(qg_field),
pointer :: fld
365 type(datetime) :: fdate
368 call c_f_datetime(c_dt, fdate)
382 integer(c_int),
intent(in) :: c_key_fld
383 integer(c_int),
intent(in) :: c_key_geom
384 type(c_ptr),
intent(in) :: c_conf
385 type(c_ptr),
intent(inout) :: c_dt
387 type(qg_field),
pointer :: fld
388 type(qg_geom),
pointer :: geom
389 type(datetime) :: fdate
393 call c_f_datetime(c_dt, fdate)
407 integer(c_int),
intent(in) :: c_key_fld
408 type(c_ptr),
intent(in) :: c_conf
409 type(c_ptr),
intent(in) :: c_dt
411 type(qg_field),
pointer :: fld
412 type(datetime) :: fdate
415 call c_f_datetime(c_dt, fdate)
422 subroutine qg_field_gpnorm_c(c_key_fld, kf, pstat) bind(c,name='qg_field_gpnorm_f90')
427 integer(c_int),
intent(in) :: c_key_fld
428 integer(c_int),
intent(in) :: kf
429 real(c_double),
intent(inout) :: pstat(3*kf)
431 type(qg_field),
pointer :: fld
432 real(kind=kind_real) :: zstat(3, kf)
433 integer :: jj, js, jf
437 call gpnorm(fld, kf, zstat)
442 pstat(jj) = zstat(js,jf)
450 subroutine qg_field_getpoint_c(c_key_fld, c_key_iter, c_nval, c_vals) bind(c,name='qg_field_getpoint_f90')
456 integer(c_int),
intent(in) :: c_key_fld
457 integer(c_int),
intent(in) :: c_key_iter
458 integer(c_int),
intent(in) :: c_nval
459 real(c_double),
intent(inout) :: c_vals(c_nval)
461 type(qg_field),
pointer :: fld
462 type(qg_geom_iter),
pointer :: iter
474 if (fld%nf*fld%nl /= c_nval)
then 475 print *,
'qg_field_getpoint ERROR: array sizes are different: ', fld%nf*fld%nl, c_nval
479 c_vals = fld%gfld3d(iter%ilon, iter%ilat, :)
485 subroutine qg_field_rms_c(c_key_fld, prms) bind(c,name='qg_field_rms_f90')
490 integer(c_int),
intent(in) :: c_key_fld
491 real(c_double),
intent(inout) :: prms
493 type(qg_field),
pointer :: fld
494 real(kind=kind_real) :: zz
506 subroutine qg_field_interp_tl_c(c_key_fld,c_key_loc,c_vars,c_key_gom) bind(c,name='qg_field_interp_tl_f90')
513 integer(c_int),
intent(in) :: c_key_fld
514 integer(c_int),
intent(in) :: c_key_loc
515 integer(c_int),
dimension(*),
intent(in) :: c_vars
516 integer(c_int),
intent(in) :: c_key_gom
517 type(qg_field),
pointer :: fld
518 type(qg_locs),
pointer :: locs
519 type(qg_goms),
pointer :: gom
520 type(qg_vars) :: vars
533 subroutine qg_field_interp_ad_c(c_key_fld,c_key_loc,c_vars,c_key_gom) bind(c,name='qg_field_interp_ad_f90')
540 integer(c_int),
intent(in) :: c_key_fld
541 integer(c_int),
intent(in) :: c_key_loc
542 integer(c_int),
dimension(*),
intent(in) :: c_vars
543 integer(c_int),
intent(in) :: c_key_gom
544 type(qg_field),
pointer :: fld
545 type(qg_locs),
pointer :: locs
546 type(qg_goms),
pointer :: gom
547 type(qg_vars) :: vars
560 subroutine qg_fieldnum_c(c_key_fld, c_nx, c_ny, c_nf, c_nb, c_nl) bind(c,name='qg_field_sizes_f90')
564 integer(c_int),
intent(in) :: c_key_fld
565 integer(kind=c_int),
intent(inout) :: c_nx, c_ny, c_nf, c_nb, c_nl
566 type(qg_field),
pointer :: fld
575 if (fld%lbc) c_nb = 2
subroutine, public self_mul(self, zz)
subroutine qg_field_field_from_ug_c(c_key_fld, c_key_ug)
subroutine, public axpy(self, zz, rhs)
Fortran module handling geometry iterator for the QG model.
type(registry_t), public qg_field_registry
Linked list interface - defines registry_t type.
subroutine, public read_file(fld, c_conf, vdate)
subroutine qg_field_diff_incr_c(c_key_lhs, c_key_x1, c_key_x2)
subroutine qg_field_ug_coord_c(c_key_fld, c_key_ug, c_colocated)
subroutine qg_field_read_file_c(c_key_fld, c_conf, c_dt)
subroutine qg_field_getpoint_c(c_key_fld, c_key_iter, c_nval, c_vals)
subroutine qg_field_gpnorm_c(c_key_fld, kf, pstat)
type(registry_t), public qg_locs_registry
Linked list interface - defines registry_t type.
subroutine, public copy(self, rhs)
subroutine, public create(self, geom, vars)
Linked list implementation.
subroutine qg_field_change_resol_c(c_key_fld, c_key_rhs)
subroutine qg_field_random_c(c_key_self)
subroutine qg_field_interp_ad_c(c_key_fld, c_key_loc, c_vars, c_key_gom)
subroutine qg_field_add_incr_c(c_key_self, c_key_rhs)
subroutine, public random(self)
type(registry_t), public qg_geom_registry
Linked list interface - defines registry_t type.
subroutine, public self_schur(self, rhs)
subroutine qg_field_self_add_c(c_key_self, c_key_rhs)
subroutine, public self_add(self, rhs)
subroutine qg_field_rms_c(c_key_fld, prms)
subroutine qg_field_self_schur_c(c_key_self, c_key_rhs)
subroutine qg_field_axpy_c(c_key_self, c_zz, c_key_rhs)
subroutine, public add_incr(self, rhs)
subroutine qg_field_create_c(c_key_self, c_key_geom, c_vars)
Interfaces to be called from C++ for Fortran handling of QG model fields.
subroutine, public interp_tl(fld, locs, vars, gom)
subroutine qg_field_interp_tl_c(c_key_fld, c_key_loc, c_vars, c_key_gom)
Fortran module handling geometry for the QG model.
subroutine qg_fieldnum_c(c_key_fld, c_nx, c_ny, c_nf, c_nb, c_nl)
subroutine, public diff_incr(lhs, x1, x2)
subroutine, public dirac(self, c_conf)
subroutine, public ug_coord(self, ug, colocated)
subroutine, public field_to_ug(self, ug, colocated)
subroutine, public qg_vars_create(self, kvars)
Linked list implementation.
Fortran module handling observation locations.
subroutine, public write_file(fld, c_conf, vdate)
type(registry_t), public qg_geom_iter_registry
Linked list interface - defines registry_t type.
subroutine qg_field_zero_c(c_key_self)
subroutine qg_field_dot_prod_c(c_key_fld1, c_key_fld2, c_prod)
type(registry_t), public qg_goms_registry
Linked list interface - defines registry_t type.
subroutine qg_field_self_mul_c(c_key_self, c_zz)
subroutine, public field_from_ug(self, ug)
subroutine qg_field_self_sub_c(c_key_self, c_key_rhs)
subroutine, public interp_ad(fld, locs, vars, gom)
type(registry_t), public unstructured_grid_registry
Linked list interface - defines registry_t type.
subroutine, public dot_prod(fld1, fld2, zprod)
Fortran module to handle variables for the QG model.
Handle fields for the QG model.
subroutine, public analytic_init(fld, geom, config, vdate)
Analytic Initialization for the QG model.
subroutine, public zeros(self)
subroutine qg_field_write_file_c(c_key_fld, c_conf, c_dt)
subroutine, public fldrms(fld, prms)
subroutine, public self_sub(self, rhs)
subroutine qg_field_dirac_c(c_key_self, c_conf)
subroutine, public change_resol(fld, rhs)
Fortran module handling interpolated (to obs locations) model variables.
subroutine qg_field_copy_c(c_key_self, c_key_rhs)
Fortran module for handling generic unstructured grid.
subroutine, public gpnorm(fld, nf, pstat)
subroutine qg_field_delete_c(c_key_self)
subroutine qg_field_field_to_ug_c(c_key_fld, c_key_ug, c_colocated)
subroutine qg_field_analytic_init_c(c_key_fld, c_key_geom, c_conf, c_dt)
subroutine, public delete(self)