1 subroutine da_llxy_merc(lat, lon, proj, x, y)
3 !-----------------------------------------------------------------------
4 ! Purpose: Compute x,y coordinate from lat lon for mercator projection
5 !-----------------------------------------------------------------------
9 real, intent(in) :: lat
10 real, intent(in) :: lon
11 type(proj_info),intent(in) :: proj
16 if (trace_use_frequent) call da_trace_entry("da_llxy_merc")
18 deltalon = lon - proj%lon1
19 if (deltalon < -180.0) deltalon = deltalon + 360.0
20 if (deltalon > 180.0) deltalon = deltalon - 360.0
21 x = 1.0 + (deltalon/(proj%dlon*deg_per_rad))
22 y = 1.0 + (ALOG(TAN(0.5*((lat + 90.0) * rad_per_deg)))) / &
25 if (trace_use_frequent) call da_trace_exit("da_llxy_merc")
27 end subroutine da_llxy_merc