# grn2eqa

Convert from Greenwich to equal area coordinates

## Syntax

[x,y] = grn2eqa(lat,lon)
[x,y] = grn2eqa(lat,lon,origin)
[x,y] = grn2eqa(lat,lon,origin,ellipsoid)
[x,y] = grn2eqa(lat,lon,origin,units)
mat = grn2eqa(lat,lon,origin...)

## Description

[x,y] = grn2eqa(lat,lon) converts the Greenwich coordinates lat and lon to the equal-area coordinate points x and y.

[x,y] = grn2eqa(lat,lon,origin) specifies the location in the Greenwich system of the x-y origin (0,0). The two-element vector origin must be of the form [latitude, longitude]. The default places the origin at the Greenwich coordinates (0º,0º).

[x,y] = grn2eqa(lat,lon,origin,ellipsoid) specifies the ellipsoidal model of the figure of the Earth using ellipsoid. ellipsoid is a referenceSphere, referenceEllipsoid, or oblateSpheroid object, or a vector of the form [semimajor_axis eccentricity]. The ellipsoid is spherical by default.

[x,y] = grn2eqa(lat,lon,origin,units) specifies the units for the inputs, where units is any valid angle units value. The default value is 'degrees'.

mat = grn2eqa(lat,lon,origin...) packs the outputs into a single variable.

The grn2eqa function converts data from Greenwich-based latitude-longitude coordinates to equal-area x-y coordinates. The opposite conversion can be performed with eqa2grn.

## Examples

lats = [56 34]; longs = [-140 23];
[x,y] = grn2eqa(lats,longs)

x =
-2.4435    0.4014
y =
0.8290    0.5592