00001
00002
00003
00004
00005 include '../Include_file/include_modulefiles_RQS_CF_qeos.f90'
00006 include '../Include_file/include_interface_modulefiles_RQS_CF_qeos.f90'
00007 include '../Include_file/include_subroutines_RQS_CF_qeos.f90'
00008 include '../Include_file/include_QEOS_modulefile.f90'
00009 include '../Include_file/include_QEOS_subroutines.f90'
00010 include '../Include_file/include_QEOS_functions.f90'
00011 include '../Include_file/include_functions.f90'
00012
00013
00014
00015
00016 PROGRAM Main_RQS_CF_qeos
00017
00018 use grid_parameter, only : indata_type, outdata_type, &
00019 & iter_max, num_sol_seq, &
00020 & sw_mass_iter, sw_art_deform
00021 use def_matter
00022 use def_matter_parameter, only : rhoc_qs, rhos_qs
00023 use def_qeos_parameter
00024 implicit none
00025 integer :: flag_restmass, count_adj
00026 integer :: iseq, iter_count, total_iteration
00027
00028 call coordinate_patch_kit_grav
00029 call read_parameter_drot
00030 call allocate_metric_and_matter_qeos
00031 call allocate_metric_on_SFC_CF
00032 if (indata_type.eq.'1D') call IO_input_initial_1D_qeos
00033 if (indata_type.eq.'3D') call IO_input_initial_3D_qeos
00034 call qeos_initialize
00035 rhoc_qs = rhoini_gcm1
00036 rhos_qs = rhosurf_gcm1
00037 if (sw_mass_iter.eq.'y') rhoc_qs = rhof(0,0,0)
00038
00039 if (sw_art_deform.eq.'y') call artificial_deformation
00040
00041
00042
00043
00044 do iseq = 1, num_sol_seq
00045 total_iteration = 0
00046 flag_restmass = 0
00047
00048
00049 count_adj = 0
00050 do
00051 call iteration_qeos(iter_count)
00052 total_iteration = total_iteration + iter_count
00053 write(6,*)'-- Total # of iteration --', total_iteration
00054 call calc_physical_quantities_qeos
00055 call printout_physq_console_qeos
00056 if (total_iteration.ge.iter_max) exit
00057 if (sw_mass_iter.ne.'y') exit
00058 call adjust_rest_mass_qeos(flag_restmass,count_adj)
00059 if (flag_restmass.eq.2) exit
00060 end do
00061 write(6,*)'== Solution sequence # == ', iseq
00062 if (total_iteration.ge.iter_max) then
00063 write(6,*)' ** Solution did not converge **'
00064 else
00065 if (sw_mass_iter.ne.'y') flag_restmass = 999
00066 end if
00067 call calc_physical_quantities_qeos
00068 call calc_quad_pole_qeos
00069
00070 call printout_physq_peos(iseq,flag_restmass)
00071 call printout_quad_pole(iseq)
00072 call printout_physq_plot(iseq,flag_restmass)
00073
00074 call printout_NS_shape_seq(iseq)
00075 call next_solution
00076 end do
00077 if (outdata_type.eq.'1D') call IO_output_solution_1D_qeos
00078 if (outdata_type.eq.'3D') call IO_output_solution_3D_qeos
00079
00080 call printout_NS_shape
00081
00082 END PROGRAM Main_RQS_CF_qeos