46 module horiz_interp_bicubic_mod
51 use constants_mod,
only: pi
52 use platform_mod,
only: r4_kind, r8_kind
67 module procedure horiz_interp_bicubic_new_1d_r8
68 module procedure horiz_interp_bicubic_new_1d_s_r8
69 module procedure horiz_interp_bicubic_new_1d_r4
70 module procedure horiz_interp_bicubic_new_1d_s_r4
75 module procedure horiz_interp_bicubic_r4
76 module procedure horiz_interp_bicubic_r8
83 #include<file_version.h>
84 logical :: module_is_initialized = .false.
85 integer :: verbose_bicubic = 0
105 module procedure fill_xy_r4
106 module procedure fill_xy_r8
110 module procedure bcuint_r4
111 module procedure bcuint_r8
115 module procedure bcucof_r4
116 module procedure bcucof_r8
121 module procedure indl_r4
122 module procedure indl_r8
127 module procedure indu_r4
128 module procedure indu_r8
136 if(module_is_initialized)
return
138 module_is_initialized = .true.
139 tpi = real(2.0_r8_kind*pi, r8_kind)
148 if(interp%horizInterpReals8_type%is_allocated)
then
149 if(
allocated(interp%horizInterpReals8_type%rat_x))
deallocate ( interp%horizInterpReals8_type%rat_x )
150 if(
allocated(interp%horizInterpReals8_type%rat_y))
deallocate ( interp%horizInterpReals8_type%rat_y )
151 if(
allocated(interp%horizInterpReals8_type%lon_in))
deallocate ( interp%horizInterpReals8_type%lon_in )
152 if(
allocated(interp%horizInterpReals8_type%lat_in))
deallocate ( interp%horizInterpReals8_type%lat_in )
153 if(
allocated(interp%horizInterpReals8_type%wti))
deallocate ( interp%horizInterpReals8_type%wti )
154 else if(interp%horizInterpReals4_type%is_allocated)
then
155 if(
allocated(interp%horizInterpReals4_type%rat_x))
deallocate ( interp%horizInterpReals4_type%rat_x )
156 if(
allocated(interp%horizInterpReals4_type%rat_y))
deallocate ( interp%horizInterpReals4_type%rat_y )
157 if(
allocated(interp%horizInterpReals4_type%lon_in))
deallocate ( interp%horizInterpReals4_type%lon_in )
158 if(
allocated(interp%horizInterpReals4_type%lat_in))
deallocate ( interp%horizInterpReals4_type%lat_in )
159 if(
allocated(interp%horizInterpReals4_type%wti))
deallocate ( interp%horizInterpReals4_type%wti )
161 if(
allocated(interp%i_lon) )
deallocate( interp%i_lon )
162 if(
allocated(interp%j_lat) )
deallocate( interp%j_lat )
164 interp%horizInterpReals8_type%is_allocated = .false.
165 interp%horizInterpReals4_type%is_allocated = .false.
169 #include "horiz_interp_bicubic_r4.fh"
170 #include "horiz_interp_bicubic_r8.fh"
172 end module horiz_interp_bicubic_mod
subroutine, public write_version_number(version, tag, unit)
Prints to the log file (or a specified unit) the version id string and tag name.
subroutine, public horiz_interp_bicubic_del(Interp)
Free memory from a horiz_interp_type used for bicubic interpolation (allocated via horiz_bicubic_new)
subroutine, public horiz_interp_bicubic_init
Initializes module and writes version number to logfile.out.
Creates a new horiz_interp_type for bicubic interpolation. Allocates space and initializes a derived-...
find the lower neighbour of xf in field xc, return is the index
find the upper neighbour of xf in field xc, return is the index
Holds data pointers and metadata for horizontal interpolations, passed between the horiz_interp modul...
integer function stdout()
This function returns the current standard fortran unit numbers for output.
integer function mpp_pe()
Returns processor ID.
Perform bicubic horizontal interpolation.