[Proj] Novice Examples?
Frank Warmerdam
warmerdam at pobox.com
Tue Oct 4 18:25:31 EST 2011
On Tue, Oct 4, 2011 at 4:05 PM, Michael Speth
<spethm at landcareresearch.co.nz> wrote:
> Greetings,
> I am a new proj.4 user and I would like to try some simple examples.
> I have been reading the user doc as well as the update (proj.4.3.pdf);
> however, I have been unsuccessful with executing the examples listed.
>
> ---- [ System Information] ----
> System: Ubuntu 11.04 64-bit
> Kernel: 2.6.38-11-generic
> Proj.4 Version: 4.7.0 compiled from tarball
>
> Here are two examples that show my problem:
> ---- [Example 1] ----
> /opt/proj-4.7.0/src$ ./proj +proj=poly +lon_0=-66 +lat_0=40 -v
> Rel. 4.7.1, 23 September 2009
> <lt-proj>:
> projection initialization failure
> cause: major axis or radius = 0 or not given
> program abnormally terminated
>
> ---- [Example 2] -----
> /opt/proj-4.7.0/src$ ./proj +proj=poly +lon_0=-60 -E <<EOF
> > # sample points
> > 65W 43d15N
> > -55 37.33
> > EOF
> Rel. 4.7.1, 23 September 2009
> <lt-proj>:
> projection initialization failure
> cause: major axis or radius = 0 or not given
> program abnormally terminated
> ---------------------------
>
> It seems that I am not providing the radius or major axis. Is this
> correct, if so, how do I provide this information?
Michael,
You can specify the earth model several ways, but adding +ellps=WGS84
is a fairly simple way.
eg.
./proj +proj=poly +lon_0=-60 +ellps=WGS84 -E <<EOF
Note that PROJ usually picks up the default ellipsoid from an initialization
file but that doesn't work if you are running proj locally instead of first
installing it. The main thing fetched from the defaults initialization file
is a default ellipsoid.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Software Developer
More information about the Proj
mailing list