Main Content

utmzone

UTM zone from latitude and longitude

    Description

    zone = utmzone opens the Pick UTM Zone dialog box, which enables you to interactively identify a Universal Transverse Mercator (UTM) zone by clicking a world map. For more information about UTM zones, see Create UTM Maps.

    example

    zone = utmzone(lat,lon) identifies the UTM zone that contains the latitude-longitude coordinates specified by lat and lon. When you specify the coordinates of more than one point, the function identifies the UTM zone using the geographic mean of the points.

    example

    [latlim,lonlim] = utmzone(queryZone) identifies the latitude and longitude limits of the UTM zone queryZone.

    Examples

    collapse all

    Specify the geographic coordinates of the MathWorks Lakeside Campus in Natick, MA. Then, find the UTM zone that contains the coordinates.

    lat = 42.3013;
    lon = -71.3782;
    zone = utmzone(lat,lon)
    zone = 
    '19T'
    

    Identify the latitude and longitude limits of UTM zone 19F, which contains the southern tip of South America. Specify the UTM zone using a zone number and latitude band letter.

    [latlim,lonlim] = utmzone("19F")
    latlim = 1×2
    
       -56   -48
    
    
    lonlim = 1×2
    
       -72   -66
    
    

    Input Arguments

    collapse all

    Latitude coordinates in degrees, specified as scalar, vector, or matrix. Each latitude coordinate must be in the range [–80, 84].

    • When lat and lon define a single point, the utmzone function finds the UTM zone containing the point.

    • When lat and lon define multiple points, the utmzone function finds the UTM zone containing the geographic mean of the points.

    The sizes of lat and lon must match.

    Data Types: single | double

    Longitude coordinates in degrees, specified as scalar, vector, or matrix. Each longitude coordinate must be in the range [–180, 180].

    • When lat and lon define a single point, the utmzone function finds the UTM zone containing the point.

    • When lat and lon define multiple points, the utmzone function finds the UTM zone containing the geographic mean of the points.

    The sizes of lat and lon must match.

    Data Types: single | double

    UTM zone, specified as a character vector or a string scalar in one of these forms:

    • Zone number — An integer from 1 to 60, such as "19".

    • Zone number and latitude band letter — An integer from 1 to 60 followed by a letter from C to X (excluding I and O), such as "19T". The letters are case-insensitive. The letters N and S refer to latitude band letters, not the northern and southern hemispheres.

    Data Types: char | string

    Output Arguments

    collapse all

    UTM zone, returned as a character vector.

    • When lat and lon are scalars, zone is the UTM zone that contains the coordinates.

    • When lat and lon are vectors or matrices, zone is the UTM zone that contains the geographic mean of the coordinates.

    The UTM zone returned by the utmzone function contains a zone number from 1 to 60 and a latitude band letter from C to X (excluding I and O). The letters N and S refer to latitude band letters, not the northern and southern hemispheres.

    Data Types: char

    Latitude limits of the UTM zone, returned as a two-element vector.

    Data Types: double

    Longitude limits of the UTM zone, returned as a two-element vector.

    Data Types: double

    Alternative Functionality

    To identify a UTM zone by clicking a map, use the utmzoneui function.

    Version History

    Introduced before R2006a

    expand all

    See Also

    Functions