da_set_merc.inc
References to this file elsewhere.
1 subroutine da_set_merc(proj)
2
3 !--------------------------------------------------------------------------
4 ! Purpose: Sets up the remaining basic elements for the mercator projection
5 !--------------------------------------------------------------------------
6
7 implicit none
8
9 type(proj_info), intent(inout) :: proj
10
11 real :: clain
12
13 if (trace_use) call da_trace_entry("da_set_merc")
14
15 ! Preliminary variables
16
17 clain = COS(rad_per_deg*proj%truelat1)
18 proj%dlon = proj%dx / (earth_radius_m * clain)
19
20 ! Compute distance from equator to origin, and store in the
21 ! proj%rsw tag.
22
23 proj%rsw = 0.0
24 if (proj%lat1 .NE. 0.0) then
25 proj%rsw = (alog(tan(0.5*((proj%lat1+90.)*rad_per_deg))))/proj%dlon
26 end if
27
28 if (trace_use) call da_trace_exit("da_set_merc")
29
30 end subroutine da_set_merc
31
32