Thanks Jeff, that's actually what I wanted to know.
Unfortunately I guess, there is a small difference between Transverse
Mercator and Universal Transverse Mercator Projections
Do I have the possibility to define somewere the UTM zone and the Datum
of my Projection.
I tried it like Jeff suggested,

map1 = Basemap(projection='tmerc',
resolution='i',llcrnrlon=-128.3841365,llcrnrlat=68.3952899,urcrnrlon=-121.5846218,urcrnrlat=70.7793990,
lon_0=-124.98437915,lat_0=69.587344449999989)

lons,lats = map1(X_utm,Y_utm,inverse='True')

but the lons and lats
look like this:

In [53]: lons
Out[53]:
array([[-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915],
       [-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915],
       [-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915],
       ...,
       [-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915],
       [-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915],
       [-124.98437915, -124.98437915, -124.98437915, ..., -124.98437915,
        -124.98437915, -124.98437915]])

In [54]: lats
Out[54]:
array([[ 90.,  90.,  90., ...,  90.,  90.,  90.],
       [ 90.,  90.,  90., ...,  90.,  90.,  90.],
       [ 90.,  90.,  90., ...,  90.,  90.,  90.],
       ...,
       [ 90.,  90.,  90., ...,  90.,  90.,  90.],
       [ 90.,  90.,  90., ...,  90.,  90.,  90.],
       [ 90.,  90.,  90., ...,  90.,  90.,  90.]])

Has anyone an idea?

-- 
Anja Roesel
Center for Marine and Atmospheric Research
Institute of Oceanography, University of Hamburg
Bundesstrasse 53
D-20146 Hamburg
Germany
Tel. +49 40 42838 5430 Fax: +49 40 42838 7471


> 
> Anja:  You need to pass the latitude and longitude values (in degrees)
> to the Basemap instance when converting to projection coordinates.  So,
> to convert from UTM coordinates to polar stereographic coordinates you
> will need to do something like this:
> 
> map1 = Basemap(<parameters for transverse mercator projection>)
> 
> lons, lats = map1(x, y, inverse=True) # x and y are projection
> coordinates on original UTM grid.
> 
> # lons and lats are now latitudes and longitudes of UTM grid (in degrees)
> 
> map2 =
> 
> Basemap(resolution='i',projection='npstere',lon_0=-45,boundinglat=70)
> 
> x, y = map2(lons, lats)
> 
> # x,y are now polar stereo coordinates of UTM grid.
> 
> Or, if you already have the latitudes and logintudes of the original UTM
> grid you can skip the first two lines and just pass those to the
> stereographic Basemap instance.
> 
> -Jeff
> 

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to