[Proj] Proj command usage

Herve Baille hb at meteorage.com
Wed Sep 5 00:28:50 PDT 2007


Frank

Great!
It remains 5 meters of difference but this is acceptable for a lightning 
location system.
Thanks
Hervé

 Warmerdam a écrit :
> Herve Baille wrote:
>> Hello
>>
>> New in this list.
>> We are changing our own projection functions for a standard tool, 
>> libproj4, on Sun Sparc Solaris 10.
>> We project (latitude=45, longitude=0) to a Lambert conic conform 
>> projection called "extended Lamber II" used in France.
>> Our program gives (x=415728.737817, y=2002668.173285), which is very 
>> close to the result of the National Geograpgic Institute.
>> The "proj" command (with correct projection parameters):
>> echo 0 45 | proj +proj=lcc +lon_0=2.3372917 +lat_0=46.8 
>> +lat_2=45.8989 +lat_1=47.696 +x_0=600000 +y_0=2200000 +ellps=clrk80
>> gives:
>> 415663.74       2002665.67
>> We are not very far on Y axis but 65 meter away on X axis.
>> If I specify the XYZ offset between WGS84 and NTF (dx=-168, dy=-60, 
>> dz=320) with option +towgs84
>> the command:
>> echo 0 45 | proj +proj=lcc +lon_0=2.3372917 +lat_0=46.8 
>> +lat_2=45.8989 +lat_1=47.696 +x_0=600000 +y_0=2200000 +ellps=clrk80 
>> +towgs84=-168,-60,320,0,0,0,0
>> gives exatly the same result
>> 415663.74       2002665.67
>> as if the option +towgs84 is not used.
>>
>> Where could be the mistake?
>> Is there an other way to specify the translation?
>
> Herve,
>
> Gerald's libproj4 does not do datum shifts, by design.
>
> The "proj" command also does not do datum shifts, only reprojection
> on the same datum.
>
> You can use the PROJ.4 cs2cs command to do the transformation
> (equivelent to the pj_transform() API call).
>
> eg.
>
> cs2cs +proj=latlong +datum=WGS84 \
>   +to +proj=lcc +lon_0=2.3372917 +lat_0=46.8 +lat_2=45.8989 \
>       +lat_1=47.696 +x_0=600000 +y_0=2200000 +ellps=clrk80 \
>       +towgs84=-168,-60,320,0,0,0,0
>
> I get 415723.87       2002668.31 as a result with this command.
>
> Best regards,


-- 
***************************

Hervé BAILLE <herve.baille at meteorage.com>
Software development manager

Sté Météorage
2 av Angot
64053 PAU
France

CATS support <support at meteorage.com>
***************************




More information about the Proj mailing list