octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #61086] [octave forge] (octproj) UTM zone need


From: Rafael Laboissiere
Subject: [Octave-bug-tracker] [bug #61086] [octave forge] (octproj) UTM zone needs to be specified with PROJ 8.1.1RC1
Date: Fri, 27 Aug 2021 03:49:43 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36

URL:
  <https://savannah.gnu.org/bugs/?61086>

                 Summary: [octave forge] (octproj) UTM zone needs to be
specified with PROJ 8.1.1RC1
                 Project: GNU Octave
            Submitted by: rlaboiss
            Submitted on: Fri 27 Aug 2021 07:49:41 AM UTC
                Category: Octave Forge Package
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Unexpected Error or Warning
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
                 Release: other
         Discussion Lock: Any
        Operating System: Any

    _______________________________________________________

Details:

When the octproj package is built against the release candidate 8.1.1RC1
<https://download.osgeo.org/proj/proj-8.1.1RC1.tar.gz> of the PROJ library,
the first unit test in inst/op_transform.m file fails with the following error
message:


octave:1> pkg load octproj
octave:2> test op_transform
proj_create: Invalid zone number
***** test 
  [x,y,h,t]=op_transform(-6,43,1000,10,...
                         '+proj=latlong +ellps=GRS80',...
                         '+proj=utm +lon_0=3w +ellps=GRS80');
  [lon,lat,H,T]=op_transform(x,y,h,t,'+proj=utm +lon_0=3w +ellps=GRS80',...
                           '+proj=latlong +ellps=GRS80');
  assert(x,255466.98,1e-2)
  assert(y,4765182.93,1e-2)
  assert(h,1000.0,1e-15)
  assert(lon,-6,1e-8)
  assert(lat,43,1e-8)
  assert(H,1000.0,1e-15)
  assert(T,10.0,1e-15)
!!!!! test failed

        In function op_transform:
        In function _op_transform:
        Error in definition parameters
        +proj=latlong +ellps=GRS80
        +proj=utm +lon_0=3w +ellps=GRS80
        Unknown error (code 4096)


It seems that the UTM zone must be explicitly specified when option +proj=utm
is used. The patch attached to this bug report fixes the problem. I
empirically discovered that the correct value for the UTM zone is 30, hence
the added options +zone=30 in the patch. It seems that this value (30) was
taken as default for versions of PROJ previous to 8.1.1.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Fri 27 Aug 2021 07:49:41 AM UTC  Name: specify-utm-zone.patch  Size:
7KiB   By: rlaboiss

<http://savannah.gnu.org/bugs/download.php?file_id=51825>

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?61086>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]