gcDestination            package:maptools            R Documentation

_F_i_n_d _d_e_s_t_i_n_a_t_i_o_n _i_n _g_e_o_g_r_a_p_h_i_c_a_l _c_o_o_r_d_i_n_a_t_e_s

_D_e_s_c_r_i_p_t_i_o_n:

     Find the destination in geographical coordinates at distance dist
     and for the given bearing from the starting point given by lon and
     lat.

_U_s_a_g_e:

     gcDestination(lon, lat, bearing, dist, dist.units = "km",
      model = NULL, Vincenty = FALSE)

_A_r_g_u_m_e_n_t_s:

     lon: longitude (Eastings) in decimal degrees (either scalar or
          vector)

     lat: latitude (Northings) in decimal degrees (either scalar or
          vector)

 bearing: bearing from 0 to 360 degrees (either scalar or vector)

    dist: distance travelled (scalar)

dist.units: units of distance "km" (kilometers), "nm" (nautical miles),
          "mi" (statute miles)

   model: choice of ellipsoid model ("WGS84", "GRS80", "Airy",
          "International", "Clarke", "GRS67"

Vincenty: logical flag, default FALSE

_D_e_t_a_i_l_s:

     The bearing argument may be a vector when lon and lat are scalar,
     representing a single point.

_V_a_l_u_e:

     A matrix of decimal degree coordinates with Eastings in the first
     column and Northings in the second column.

_A_u_t_h_o_r(_s):

     Eric Archer and Roger Bivand

_R_e_f_e_r_e_n_c_e_s:

     <URL:
     http://www.movable-type.co.uk/scripts/latlong.html#ellipsoid>, 

     <URL: http://williams.best.vwh.net/avform.htm>, 

     <URL:
     http://www.movable-type.co.uk/scripts/latlong-vincenty-direct.html>, 

     Original reference <URL:
     http://www.ngs.noaa.gov/PUBS_LIB/inverse.pdf>:

     Vincenty, T. 1975.  Direct and inverse solutions of geodesics on 
     the ellipsoid with application of nested equations. Survey Review
     22(176):88-93

_S_e_e _A_l_s_o:

     'gzAzimuth'

_E_x_a_m_p_l_e_s:

     data(state)
     res <- gcDestination(state.center$x, state.center$y, 45, 250, "km")
     plot(state.center$x, state.center$y, asp=1, pch=16)
     arrows(state.center$x, state.center$y, res[,1], res[,2], length=0.05)
     llist <- vector(mode="list", length=length(state.center$x))
     for (i in seq(along=llist)) llist[[i]] <- gcDestination(state.center$x[i],
       state.center$y[i], seq(0, 360, 5), 250, "km")
     plot(state.center$x, state.center$y, asp=1, pch=3)
     nll <- lapply(llist, lines)

