65 USE stel_kinds,
only : rprec, iprec, cprec
66 USE stel_constants,
only : pi, twopi, one, zero
73 USE bsc_cdf,
only : bsc_cdf_define_coil, bsc_cdf_write_coil,
87 PRIVATE rprec, iprec, cprec, pi, twopi, one, zero
93 CHARACTER (LEN=*),
PRIVATE,
PARAMETER ::
96 & vn_units =
'mddc_desc_units',
97 & vn_sigma_default =
'mddc_desc_sigma_default',
98 & vn_l_mdcoil_def =
'mddc_desc_l_mdcoil_def',
99 & vn_mddc_type =
'mddc_desc_mddc_type',
100 & vn_flux_factor =
'mddc_desc_flux_factor'
102 CHARACTER (LEN=64),
PRIVATE ::
111 CHARACTER (LEN=*),
PRIVATE,
PARAMETER ::
112 'mddc_data_desc_s_name'
114 CHARACTER (LEN=64),
PRIVATE ::
117 CHARACTER (LEN=*),
PRIVATE,
PARAMETER ::
118 'mddc_mrf_code_name',
119 'mddc_mrf_code_version',
120 & vn_date_run =
'mddc_mrf_date_run',
121 & vn_field_coils_id =
'mddc_mrf_field_coils_id',
122 & vn_n_field_cg =
'mddc_mrf_n_field_cg',
123 & vn_rdiag_coilg_1 =
'mddc_mrf_rdiag_coilg_1',
124 & vn_extcur_mg =
'mddc_mrf_extcur_mg',
125 & vn_ir =
'mddc_mrf_ir',
126 & vn_jz =
'mddc_mrf_jz',
127 & vn_kp =
'mddc_mrf_kp',
128 & vn_kp_store =
'mddc_mrf_kp_store',
129 & vn_rmin =
'mddc_mrf_rmin',
130 & vn_rmax =
'mddc_mrf_rmax',
131 & vn_zmin =
'mddc_mrf_zmin',
132 & vn_zmax =
'mddc_mrf_zmax',
133 & vn_n_field_periods =
'mddc_mrf_n_field_periods',
134 & vn_lstell_sym =
'mddc_mrf_lstell_sym',
135 & vn_a_r =
'mddc_mrf_a_r',
136 & vn_a_f =
'mddc_mrf_a_f',
137 & vn_a_z =
'mddc_mrf_a_z',
138 & vn_use_con_shell =
'mddc_mrf_use_con_shell',
139 & vn_a_s_r =
'mddc_mrf_a_s_r',
140 & vn_a_s_f =
'mddc_mrf_a_s_f',
141 & vn_a_s_z =
'mddc_mrf_a_s_z',
142 & vn_kp_shell =
'mddc_mrf_kp_shell',
143 & vn_kp_shell_store =
'mddc_mrf_kp_shell_store'
145 CHARACTER (LEN=64),
PRIVATE ::
176 INTEGER,
PARAMETER,
PRIVATE :: type_len=10
177 INTEGER,
PARAMETER,
PRIVATE :: sn_len=30
178 INTEGER,
PARAMETER,
PRIVATE :: ln_len=80
179 INTEGER,
PARAMETER,
PRIVATE :: units_len=30
192 MODULE PROCEDURE mddc_cdf_define_desc,
193 & mddc_cdf_define_mrf
200 MODULE PROCEDURE mddc_cdf_write_desc,
208 MODULE PROCEDURE mddc_cdf_read_desc,
220 SUBROUTINE mddc_cdf_define_desc(this,iou,prefix)
226 TYPE (mddc_desc),
INTENT (in) :: this
227 INTEGER,
INTENT(in) :: iou
228 CHARACTER (len=*),
INTENT(in),
OPTIONAL :: prefix
237 CHARACTER(len=*),
PARAMETER :: sub_name = &
238 &
'mddc_cdf_define_desc: '
239 CHARACTER(len=32) :: prefix_use
246 IF (
PRESENT(prefix))
THEN
247 prefix_use = trim(adjustl(prefix))
253 CALL mddc_cdf_defvn_desc(prefix_use)
256 CALL cdf_define(iou, trim(vn_s_name_use), this % s_name)
257 CALL cdf_define(iou, trim(vn_l_name_use), this % l_name)
258 CALL cdf_define(iou, trim(vn_units_use), this % units)
259 CALL cdf_define(iou, trim(vn_sigma_default_use),
260 & this % sigma_default)
261 CALL cdf_define(iou, trim(vn_l_mdcoil_def_use),
262 & this % l_mdcoil_def)
263 CALL cdf_define(iou, trim(vn_mddc_type_use),
265 CALL cdf_define(iou, trim(vn_flux_factor_use),
266 & this % flux_factor)
269 IF (this % l_mdcoil_def)
THEN
270 CALL bsc_cdf_define_coil(this % mdcoil,iou,prefix)
277 END SUBROUTINE mddc_cdf_define_desc
281 SUBROUTINE mddc_cdf_define_mrf(this,iou,prefix)
287 TYPE (mddc_mrf),
INTENT (in) :: this
288 INTEGER,
INTENT(in) :: iou
289 CHARACTER (len=*),
INTENT(in),
OPTIONAL :: prefix
298 CHARACTER(len=*),
PARAMETER :: sub_name = &
299 &
'mddc_cdf_define_mrf: '
300 CHARACTER(len=32) :: prefix_use
307 IF (
PRESENT(prefix))
THEN
308 prefix_use = trim(adjustl(prefix))
314 CALL mddc_cdf_defvn_mrf(prefix_use)
317 CALL cdf_define(iou, trim(vn_code_name_use), this % code_name)
318 CALL cdf_define(iou, trim(vn_code_version_use),
319 & this % code_version)
320 CALL cdf_define(iou, trim(vn_date_run_use), this % date_run)
321 CALL cdf_define(iou, trim(vn_field_coils_id_use),
322 & this % field_coils_id)
323 CALL cdf_define(iou, trim(vn_n_field_cg_use),
325 CALL cdf_define(iou, trim(vn_rdiag_coilg_1_use),
326 & this % rdiag_coilg_1)
327 CALL cdf_define(iou, trim(vn_extcur_mg_use), this % extcur_mg)
328 CALL cdf_define(iou, trim(vn_ir_use), this % ir)
329 CALL cdf_define(iou, trim(vn_jz_use), this % jz)
330 CALL cdf_define(iou, trim(vn_kp_use), this % kp)
331 CALL cdf_define(iou, trim(vn_kp_store_use), this % kp_store)
332 CALL cdf_define(iou, trim(vn_rmin_use), this % rmin)
333 CALL cdf_define(iou, trim(vn_rmax_use), this % rmax)
334 CALL cdf_define(iou, trim(vn_zmin_use), this % zmin)
335 CALL cdf_define(iou, trim(vn_zmax_use), this % zmax)
336 CALL cdf_define(iou, trim(vn_n_field_periods_use),
337 & this % n_field_periods)
338 CALL cdf_define(iou, trim(vn_lstell_sym_use),
340 CALL cdf_define(iou, trim(vn_a_r_use), this % a_r)
341 CALL cdf_define(iou, trim(vn_a_f_use), this % a_f)
342 CALL cdf_define(iou, trim(vn_a_z_use), this % a_z)
344 CALL cdf_define(iou, trim(vn_use_con_shell_use),
345 & this%use_con_shell)
346 IF (this%use_con_shell)
THEN
347 CALL cdf_define(iou, trim(vn_kp_shell_use), this % kp_shell)
348 CALL cdf_define(iou, trim(vn_a_s_r_use), this % a_s_r)
349 CALL cdf_define(iou, trim(vn_a_s_f_use), this % a_s_f)
350 CALL cdf_define(iou, trim(vn_a_s_z_use), this % a_s_z)
355 END SUBROUTINE mddc_cdf_define_mrf
363 SUBROUTINE mddc_cdf_write_desc(this,iou,prefix)
369 TYPE (mddc_desc),
INTENT (in) :: this
370 INTEGER,
INTENT (in) :: iou
371 CHARACTER (len=*),
INTENT (in),
OPTIONAL :: prefix
380 CHARACTER(len=*),
PARAMETER :: sub_name = &
381 &
'mddc_cdf_write_desc: '
382 CHARACTER(len=32) :: prefix_use
388 IF (
PRESENT(prefix))
THEN
389 prefix_use = trim(adjustl(prefix))
395 CALL mddc_cdf_defvn_desc(prefix_use)
398 CALL cdf_write(iou, trim(vn_s_name_use), this % s_name)
399 CALL cdf_write(iou, trim(vn_l_name_use), this % l_name)
400 CALL cdf_write(iou, trim(vn_units_use), this % units)
401 CALL cdf_write(iou, trim(vn_sigma_default_use),
402 & this % sigma_default)
403 CALL cdf_write(iou, trim(vn_l_mdcoil_def_use),
404 & this % l_mdcoil_def)
405 CALL cdf_write(iou, trim(vn_mddc_type_use),
407 CALL cdf_write(iou, trim(vn_flux_factor_use),
408 & this % flux_factor)
411 IF (this % l_mdcoil_def)
THEN
412 CALL bsc_cdf_write_coil(this % mdcoil,iou,prefix)
419 END SUBROUTINE mddc_cdf_write_desc
423 SUBROUTINE mddc_cdf_write_mrf(this,iou,prefix)
429 TYPE (mddc_mrf),
INTENT (in) :: this
430 INTEGER,
INTENT(in) :: iou
431 CHARACTER (len=*),
INTENT(in),
OPTIONAL :: prefix
440 CHARACTER(len=*),
PARAMETER :: sub_name = &
441 &
'mddc_cdf_write_mrf: '
442 CHARACTER(len=32) :: prefix_use
449 IF (
PRESENT(prefix))
THEN
450 prefix_use = trim(adjustl(prefix))
456 CALL mddc_cdf_defvn_mrf(prefix_use)
459 CALL cdf_write(iou, trim(vn_code_name_use), this % code_name)
460 CALL cdf_write(iou, trim(vn_code_version_use),
461 & this % code_version)
462 CALL cdf_write(iou, trim(vn_date_run_use), this % date_run)
463 CALL cdf_write(iou, trim(vn_field_coils_id_use),
464 & this % field_coils_id)
465 CALL cdf_write(iou, trim(vn_n_field_cg_use),
467 CALL cdf_write(iou, trim(vn_rdiag_coilg_1_use),
468 & this % rdiag_coilg_1)
469 CALL cdf_write(iou, trim(vn_extcur_mg_use), this % extcur_mg)
470 CALL cdf_write(iou, trim(vn_ir_use), this % ir)
471 CALL cdf_write(iou, trim(vn_jz_use), this % jz)
472 CALL cdf_write(iou, trim(vn_kp_use), this % kp)
473 CALL cdf_write(iou, trim(vn_kp_store_use), this % kp_store)
474 CALL cdf_write(iou, trim(vn_rmin_use), this % rmin)
475 CALL cdf_write(iou, trim(vn_rmax_use), this % rmax)
476 CALL cdf_write(iou, trim(vn_zmin_use), this % zmin)
477 CALL cdf_write(iou, trim(vn_zmax_use), this % zmax)
478 CALL cdf_write(iou, trim(vn_n_field_periods_use),
479 & this % n_field_periods)
480 CALL cdf_write(iou, trim(vn_lstell_sym_use),
482 CALL cdf_write(iou, trim(vn_a_r_use), this % a_r)
483 CALL cdf_write(iou, trim(vn_a_f_use), this % a_f)
484 CALL cdf_write(iou, trim(vn_a_z_use), this % a_z)
486 CALL cdf_write(iou, trim(vn_use_con_shell_use),
487 & this%use_con_shell)
488 IF (this%use_con_shell)
THEN
489 CALL cdf_write(iou, trim(vn_kp_shell_use), this % kp_shell)
490 CALL cdf_write(iou, trim(vn_kp_shell_store_use),
491 & this % kp_shell_store)
493 CALL cdf_write(iou, trim(vn_a_s_r_use), this % a_s_r)
494 CALL cdf_write(iou, trim(vn_a_s_f_use), this % a_s_f)
495 CALL cdf_write(iou, trim(vn_a_s_z_use), this % a_s_z)
500 END SUBROUTINE mddc_cdf_write_mrf
508 SUBROUTINE mddc_cdf_read_desc(this,iou,prefix)
514 TYPE (mddc_desc),
INTENT (inout) :: this
515 INTEGER,
INTENT (in) :: iou
516 CHARACTER (len=*),
INTENT (in),
OPTIONAL :: prefix
525 CHARACTER(len=*),
PARAMETER :: sub_name = &
526 &
'mddc_cdf_read_desc: '
527 CHARACTER(len=32) :: prefix_use
528 INTEGER,
DIMENSION(3) :: dimlens
530 CHARACTER (len=sn_len) :: s_name
531 CHARACTER (len=ln_len) :: l_name
532 CHARACTER (len=units_len) :: units
533 CHARACTER (len=30) :: mddc_type
534 LOGICAL :: l_mdcoil_def
535 REAL(rprec) :: sigma_default
536 REAL(rprec) :: flux_factor
537 TYPE (bsc_coil) :: mdcoil
538 TYPE (mddc_mrf) :: mrf
545 IF (
PRESENT(prefix))
THEN
546 prefix_use = trim(adjustl(prefix))
552 CALL mddc_cdf_defvn_desc(prefix_use)
556 CALL cdf_read(iou, trim(vn_s_name_use), s_name)
557 CALL cdf_read(iou, trim(vn_l_name_use), l_name)
558 CALL cdf_read(iou, trim(vn_units_use), units)
560 CALL cdf_read(iou, trim(vn_sigma_default_use), sigma_default)
561 CALL cdf_read(iou, trim(vn_l_mdcoil_def_use),l_mdcoil_def)
562 CALL cdf_read(iou, trim(vn_mddc_type_use),mddc_type)
563 CALL cdf_read(iou, trim(vn_flux_factor_use),flux_factor)
566 IF (l_mdcoil_def)
THEN
567 CALL bsc_cdf_read_coil(mdcoil,iou,prefix)
574 CALL mddc_desc_construct(this,s_name,l_name,units,
575 & sigma_default,mddc_type,mdcoil,mrf,flux_factor)
583 END SUBROUTINE mddc_cdf_read_desc
587 SUBROUTINE mddc_cdf_read_mrf(this,iou,prefix)
593 TYPE (mddc_mrf),
INTENT (inout) :: this
594 INTEGER,
INTENT (in) :: iou
595 CHARACTER (len=*),
INTENT (in),
OPTIONAL :: prefix
604 CHARACTER(len=32) :: prefix_use
605 INTEGER,
DIMENSION(3) :: dimlens
606 INTEGER,
DIMENSION(2) :: dimlens2
608 CHARACTER(len=80) :: code_name
609 CHARACTER(len=80) :: code_version
610 CHARACTER(len=80) :: date_run
611 CHARACTER(len=80) :: field_coils_id
612 INTEGER :: n_field_cg
613 REAL(rprec),
DIMENSION(:),
ALLOCATABLE :: rdiag_coilg_1
614 REAL(rprec),
DIMENSION(:),
ALLOCATABLE :: extcur_mg
623 INTEGER :: n_field_periods
624 LOGICAL :: lstell_sym
625 REAL(rprec),
DIMENSION(:,:,:),
ALLOCATABLE :: a_r
626 REAL(rprec),
DIMENSION(:,:,:),
ALLOCATABLE :: a_f
627 REAL(rprec),
DIMENSION(:,:,:),
ALLOCATABLE :: a_z
629 LOGICAL :: use_con_shell
630 REAL(rprec),
DIMENSION(:,:),
ALLOCATABLE :: a_s_r
631 REAL(rprec),
DIMENSION(:,:),
ALLOCATABLE :: a_s_f
632 REAL(rprec),
DIMENSION(:,:),
ALLOCATABLE :: a_s_z
634 INTEGER :: kp_shell_store
637 INTEGER :: ir1, ir2, ir3, if1, if2, if3, iz1, &
639 INTEGER :: ier1, ier2, ier3
640 INTEGER :: n_field_cg_decl
642 CHARACTER(len=*),
PARAMETER :: sub_name = &
643 &
'mddc_cdf_read_data: '
650 IF (
PRESENT(prefix))
THEN
651 prefix_use = trim(adjustl(prefix))
657 CALL mddc_cdf_defvn_mrf(prefix_use)
663 CALL cdf_read(iou, trim(vn_code_name_use), code_name)
664 CALL cdf_read(iou, trim(vn_code_version_use),code_version)
665 CALL cdf_read(iou, trim(vn_date_run_use), date_run)
666 CALL cdf_read(iou, trim(vn_field_coils_id_use),field_coils_id)
667 CALL cdf_read(iou, trim(vn_n_field_cg_use),n_field_cg)
669 CALL cdf_inquire(iou, trim(vn_rdiag_coilg_1_use),dimlens)
670 n_field_cg_decl = dimlens(1)
672 & sub_name //
'Unexpected rdiag_coilg_1 dimensions')
673 CALL assert_eq(n_field_cg,n_field_cg_decl,
674 & sub_name //
'Disagreement rdiag_coilg_1 dimensions')
675 ALLOCATE(rdiag_coilg_1(n_field_cg),stat=ier1)
676 CALL assert_eq(0,ier1,sub_name //
'alloc rdiag_coilg_1')
677 CALL cdf_read(iou, trim(vn_rdiag_coilg_1_use), rdiag_coilg_1)
679 CALL cdf_inquire(iou, trim(vn_extcur_mg_use),dimlens)
680 n_field_cg_decl = dimlens(1)
682 & sub_name //
'Unexpected extcur_mg dimensions')
683 CALL assert_eq(n_field_cg,n_field_cg_decl,
684 & sub_name //
'Disagreement extcur_mg dimensions')
685 ALLOCATE(extcur_mg(n_field_cg),stat=ier1)
686 CALL assert_eq(0,ier1,sub_name //
'alloc extcur_mg')
687 CALL cdf_read(iou, trim(vn_extcur_mg_use), extcur_mg)
689 CALL cdf_read(iou, trim(vn_ir_use), ir)
690 CALL cdf_read(iou, trim(vn_jz_use), jz)
691 CALL cdf_read(iou, trim(vn_kp_use), kp)
692 CALL cdf_read(iou, trim(vn_kp_store_use), kp_store)
693 CALL cdf_read(iou, trim(vn_rmin_use), rmin)
694 CALL cdf_read(iou, trim(vn_rmax_use), rmax)
695 CALL cdf_read(iou, trim(vn_zmin_use), zmin)
696 CALL cdf_read(iou, trim(vn_zmax_use), zmax)
697 CALL cdf_read(iou, trim(vn_n_field_periods_use), n_field_periods)
698 CALL cdf_read(iou, trim(vn_lstell_sym_use), lstell_sym)
700 CALL cdf_inquire(iou, trim(vn_a_r_use),dimlens)
705 & sub_name //
'Disagreement ir a_r dimensions')
707 & sub_name //
'Disagreement jz a_r dimensions')
709 & sub_name //
'Disagreement kp_store a_r dimensions')
710 ALLOCATE(a_r(ir1,ir2,ir3),stat=ier1)
711 CALL assert_eq(0,ier1,sub_name //
'alloc a_r')
712 CALL cdf_read(iou, trim(vn_a_r_use), a_r)
714 CALL cdf_inquire(iou, trim(vn_a_f_use),dimlens)
719 & sub_name //
'Disagreement ir a_f dimensions')
721 & sub_name //
'Disagreement jz a_f dimensions')
723 & sub_name //
'Disagreement kp_store a_f dimensions')
724 ALLOCATE(a_f(if1,if2,if3),stat=ier1)
725 CALL assert_eq(0,ier1,sub_name //
'alloc a_f')
726 CALL cdf_read(iou, trim(vn_a_f_use), a_f)
728 CALL cdf_inquire(iou, trim(vn_a_z_use),dimlens)
733 & sub_name //
'Disagreement ir a_z dimensions')
735 & sub_name //
'Disagreement jz a_z dimensions')
737 & sub_name //
'Disagreement kp_store a_z dimensions')
738 ALLOCATE(a_z(iz1,iz2,iz3),stat=ier1)
739 CALL assert_eq(0,ier1,sub_name //
'alloc a_z')
740 CALL cdf_read(iou, trim(vn_a_z_use), a_z)
743 SELECT CASE (code_version)
745 CASE (
'MRC 2014-09-28')
746 CALL cdf_read(iou, trim(vn_use_con_shell_use),
749 IF (use_con_shell)
THEN
750 CALL cdf_read(iou, trim(vn_kp_shell_use), kp_shell)
752 CALL cdf_inquire(iou, trim(vn_a_r_use), dimlens2)
755 ALLOCATE(a_s_r(ir1,ir2))
756 CALL cdf_read(iou, trim(vn_a_s_r_use), a_s_r)
758 CALL cdf_inquire(iou, trim(vn_a_f_use), dimlens2)
761 ALLOCATE(a_s_r(if1,if2))
762 CALL cdf_read(iou, trim(vn_a_s_f_use), a_s_f)
764 CALL cdf_inquire(iou, trim(vn_a_z_use), dimlens2)
767 ALLOCATE(a_s_r(iz1,iz2))
768 CALL cdf_read(iou, trim(vn_a_s_z_use), a_s_z)
772 use_con_shell = .false.
777 CALL mddc_mrf_construct(this,code_name,code_version,
778 & date_run,field_coils_id,rdiag_coilg_1,extcur_mg,kp,
779 & rmin,rmax,zmin,zmax,n_field_periods,lstell_sym,a_r,a_f,a_z,
780 & use_con_shell, a_s_r, a_s_f, a_s_z, kp_shell)
783 DEALLOCATE(rdiag_coilg_1,extcur_mg,stat=ier1)
784 CALL assert_eq(0,ier1,sub_name //
'dealloc 1')
785 DEALLOCATE(a_r,a_f,a_z,stat=ier1)
786 CALL assert_eq(0,ier1,sub_name //
'dealloc 2')
788 IF (
ALLOCATED(a_s_r))
DEALLOCATE(a_s_r)
789 IF (
ALLOCATED(a_s_f))
DEALLOCATE(a_s_f)
790 IF (
ALLOCATED(a_s_z))
DEALLOCATE(a_s_z)
794 END SUBROUTINE mddc_cdf_read_mrf
802 SUBROUTINE mddc_cdf_defvn_desc(prefix_use)
810 CHARACTER (len=*),
INTENT (in) :: prefix_use
818 CHARACTER(len=*),
PARAMETER :: sub_name = &
819 &
'mddc_cdf_defvn_desc: '
826 vn_s_name_use = mddc_cdf_mknam(prefix_use,vn_s_name)
827 vn_l_name_use = mddc_cdf_mknam(prefix_use,vn_l_name)
828 vn_units_use = mddc_cdf_mknam(prefix_use,vn_units)
829 vn_sigma_default_use = mddc_cdf_mknam(prefix_use,
831 vn_l_mdcoil_def_use = mddc_cdf_mknam(prefix_use,
833 vn_mddc_type_use = mddc_cdf_mknam(prefix_use,
835 vn_flux_factor_use = mddc_cdf_mknam(prefix_use,
840 END SUBROUTINE mddc_cdf_defvn_desc
844 SUBROUTINE mddc_cdf_defvn_mrf(prefix_use)
852 CHARACTER (len=*),
INTENT (in) :: prefix_use
860 CHARACTER(len=*),
PARAMETER :: sub_name = &
861 &
'mddc_cdf_defvn_mrf: '
868 vn_code_name_use = mddc_cdf_mknam(prefix_use,vn_code_name)
869 vn_code_version_use = mddc_cdf_mknam(prefix_use,
871 vn_date_run_use = mddc_cdf_mknam(prefix_use,vn_date_run)
872 vn_field_coils_id_use = mddc_cdf_mknam(prefix_use,
874 vn_n_field_cg_use = mddc_cdf_mknam(prefix_use,
876 vn_rdiag_coilg_1_use = mddc_cdf_mknam(prefix_use,
878 vn_extcur_mg_use = mddc_cdf_mknam(prefix_use,vn_extcur_mg)
879 vn_ir_use = mddc_cdf_mknam(prefix_use,vn_ir)
880 vn_jz_use = mddc_cdf_mknam(prefix_use,vn_jz)
881 vn_kp_use = mddc_cdf_mknam(prefix_use,vn_kp)
882 vn_kp_store_use = mddc_cdf_mknam(prefix_use,vn_kp_store)
883 vn_rmin_use = mddc_cdf_mknam(prefix_use,vn_rmin)
884 vn_rmax_use = mddc_cdf_mknam(prefix_use,vn_rmax)
885 vn_zmin_use = mddc_cdf_mknam(prefix_use,vn_zmin)
886 vn_zmax_use = mddc_cdf_mknam(prefix_use,vn_zmax)
887 vn_n_field_periods_use = mddc_cdf_mknam(prefix_use,
888 & vn_n_field_periods)
889 vn_lstell_sym_use = mddc_cdf_mknam(prefix_use,vn_lstell_sym)
890 vn_a_r_use = mddc_cdf_mknam(prefix_use,vn_a_r)
891 vn_a_f_use = mddc_cdf_mknam(prefix_use,vn_a_f)
892 vn_a_z_use = mddc_cdf_mknam(prefix_use,vn_a_z)
893 vn_use_con_shell_use = mddc_cdf_mknam(prefix_use,vn_use_con_shell)
894 vn_a_s_r_use = mddc_cdf_mknam(prefix_use,vn_a_s_r)
895 vn_a_s_f_use = mddc_cdf_mknam(prefix_use,vn_a_s_f)
896 vn_a_s_z_use = mddc_cdf_mknam(prefix_use,vn_a_s_z)
897 vn_kp_shell_use = mddc_cdf_mknam(prefix_use,vn_kp_shell)
898 vn_kp_shell_store_use = mddc_cdf_mknam(prefix_use,
903 END SUBROUTINE mddc_cdf_defvn_mrf
907 FUNCTION mddc_cdf_mknam(c1,c2)
913 CHARACTER(LEN=64) mddc_cdf_mknam
918 CHARACTER(LEN=*),
INTENT (in) :: c1,c2
923 IF (len_trim(c1) .eq. 0)
THEN
924 mddc_cdf_mknam = trim(c2)
926 mddc_cdf_mknam = adjustl(trim(c1) //
'_' // trim(c2))
931 END FUNCTION mddc_cdf_mknam