[Proj] Novice Examples?
Mikael Rittri
Mikael.Rittri at carmenta.com
Fri Oct 7 03:00:11 PDT 2011
Hello Michael,
I believe +R_A does not take any value; it is enough if it is present.
And the +e=0.5 looks strange. Isn't +e the eccentricity of the ellipsoid?
You should not need to specify +e, since you have already specified the
ellipsoid to be WGS84 (which is overridden by R_A which says to use a
sphere with the same area as the WGS84 ellipsoid).
Anyway, the value of +e for the Earth should be something like 0.082.
A value of 0.5 is so far outside the usual range that some projections
may stop working, I believe.
If I use
>proj +proj=cea +lon_0=0 +R_A +ellps=WGS84
I get
in: 0 0
out: 0.00 0.00
in: 30 30
out: 3335851.56 3185503.59
in: 0 90
out: 0.00 6371007.18
in: 90 0
out: 10007554.68 0.00
Don't know if these values are what you want (I am not so familiar with +proj=cea),
but at least it doesn't crash.
Best regards,
Mikael Rittri
Carmenta
Sweden
http://www.carmenta.com
________________________________
From: proj-bounces at lists.maptools.org [mailto:proj-bounces at lists.maptools.org] On Behalf Of Michael Speth
Sent: Friday, October 07, 2011 1:05 AM
To: proj at lists.maptools.org
Subject: Re: [Proj] Novice Examples?
Thank you Frank for helping me with the initial parameters for testing Spheroids! I am now trying to test Ellipsoidals and I have a problem with the parameters I am passing proj.4.
Here are the arguments that I am trying to use:
./proj +proj=cea +lon_0=0 +e=0.5 +R_A=1 +ellps=WGS84 -E <<EOF
0 0
EOF
And the resulting output:
Rel. 4.7.1, 23 September 2009
<lt-proj>:
projection initialization failure
cause: invalid boolean param argument
program abnormally terminated
Anyone know what I've done incorrectly?
Thank you for your help.
On 05/10/11 12:25, Frank Warmerdam wrote:
On Tue, Oct 4, 2011 at 4:05 PM, Michael Speth
<spethm at landcareresearch.co.nz> <mailto: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,
More information about the Proj
mailing list