00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 subroutine psmile_print_grid_info ( grid_id )
00012
00013
00014
00015 use PRISM_constants
00016 use PSMILe, dummy_interface => PSMILe_Print_grid_info
00017
00018 implicit none
00019
00020
00021
00022 integer,Intent(In) :: grid_id
00023
00024
00025
00026
00027
00028 Type (Corner_Block), Pointer :: corner_pointer
00029
00030 character(len=22), save :: name_status (PSMILe_Status_free:
00031 PSMILe_Status_commited)
00032 character(len=17), save :: name_grid (PSMILe_Grid_Block:
00033 PSMILe_Grid_Block)
00034
00035 data name_status /'PSMILe_Status_free', 'PSMILe_status_defined', &
00036 'PSMILe_Status_commited'/
00037 data name_grid /'PSMILe_Grid_Block'/
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056 Character(len=len_cvs_string), save :: mycvs =
00057 '$Id: psmile_print_grid_info.F90 2687 2010-10-28 15:15:52Z coquart $'
00058
00059
00060
00061 write (*, 9000) trim(ch_id), grid_id
00062
00063
00064
00065 if (grid_id > Number_of_Grids_allocated .or. &
00066 grid_id < 1) then
00067
00068 write (*, 9010) 'Is an invalid grid id'
00069
00070 call psmile_flushstd ()
00071 return
00072 endif
00073
00074 if (Grids(grid_id)%status == PSMILe_status_free) then
00075 write (*, 9010) 'Is currently free'
00076
00077 call psmile_flushstd ()
00078 return
00079 endif
00080
00081 if (Grids(grid_id)%status >= PSMILe_Status_free .and. &
00082 Grids(grid_id)%status <= PSMILe_status_commited) then
00083 write (*, 9020) 'status', Grids(grid_id)%status, &
00084 name_status (Grids(grid_id)%status)
00085 else
00086 write (*, 9020) 'status', Grids(grid_id)%status
00087 endif
00088
00089
00090
00091 write (*, 9020) 'comp_id', Grids(grid_id)%comp_id
00092
00093 if (Grids(grid_id)%grid_type >= PSMILe_Grid_Block .and. &
00094 Grids(grid_id)%grid_type <= PSMILe_Grid_Block) then
00095 write (*, 9020) 'grid_type', Grids(grid_id)%grid_type, &
00096 name_grid (Grids(grid_id)%grid_type)
00097 else
00098 write (*, 9020) 'grid_type', Grids(grid_id)%grid_type
00099 endif
00100
00101 write (*, 9020) 'grid_structure', Grids(grid_id)%grid_structure
00102 write (*, 9020) 'n_dim ' , Grids(grid_id)%n_dim
00103 write (*, 9020) 'size' , Grids(grid_id)%size
00104 write (*, 9030) 'grid name is ' , trim(Grids(grid_id)%grid_name)
00105
00106 Nullify ( corner_pointer )
00107 corner_pointer => Grids(grid_id)%corner_pointer
00108 write (*, 9050) 'size of corner', &
00109 corner_pointer%corner_shape(1:2,1:Grids(grid_id)%n_dim)
00110
00111 if (Associated(Grids(grid_id)%partition)) then
00112 write (*, 9030) 'partition pointer', 'is associated'
00113 write (*, 9060) 'partition is ', Grids(grid_id)%partition
00114 else
00115 write (*, 9030) 'partition pointer', 'is not associated'
00116 endif
00117
00118 if (Associated(corner_pointer%corners_real(1)%vector)) then
00119 write (*, 9030) 'corners_real(1)%vector pointer', 'is associated'
00120 else
00121 write (*, 9030) 'corners_real(1)%vector pointer', 'is not associated'
00122 endif
00123 if (Associated(corner_pointer%corners_dble(1)%vector)) then
00124 write (*, 9030) 'corners_dble(1)%vector pointer', 'is associated'
00125 else
00126 write (*, 9030) 'corners_dble(1)%vector pointer', 'is not associated'
00127 endif
00128
00129 if (Associated(corner_pointer%corners_real(2)%vector)) then
00130 write (*, 9030) 'corners_real(2)%vector pointer', 'is associated'
00131 else
00132 write (*, 9030) 'corners_real(2)%vector pointer', 'is not associated'
00133 endif
00134 if (Associated(corner_pointer%corners_dble(2)%vector)) then
00135 write (*, 9030) 'corners_dble(2)%vector pointer', 'is associated'
00136 else
00137 write (*, 9030) 'corners_dble(2)%vector pointer', 'is not associated'
00138 endif
00139
00140 if (Associated(corner_pointer%corners_real(3)%vector)) then
00141 write (*, 9030) 'corners_real(3)%vector pointer', 'is associated'
00142 else
00143 write (*, 9030) 'corners_real(3)%vector pointer', 'is not associated'
00144 endif
00145 if (Associated(corner_pointer%corners_dble(3)%vector)) then
00146 write (*, 9030) 'corners_dble(3)%vector pointer', 'is associated'
00147 else
00148 write (*, 9030) 'corners_dble(3)%vector pointer', 'is not associated'
00149 endif
00150
00151
00152
00153
00154 write (*, 9010)
00155
00156 call psmile_flushstd ()
00157
00158
00159
00160
00161
00162 9000 format (/1x, a, ': Info on grid handle', i3, ':', &
00163 /1x, 40('-'))
00164 9010 format (1x, a)
00165 9020 format (1x, a30, ' = ', i7, : 1x, a)
00166 9030 format (1x, a30, 3x, a)
00167 9050 format (1x, a30, ' = ', 3(i4, ':', i4, :, ','))
00168 9060 format (1x, a30, ' = ', 2(i8, ';'),i8)
00169
00170 end subroutine PSMILe_Print_grid_info