# [Proj] Convert a planetographic latitude to a planetocentric latitude

Kristian Evers kreve at sdfe.dk
Sat Aug 18 15:11:24 EST 2018

```Jean-Christophe,

You can do that transformation with PROJ, yes. I can see why you get confused though. It is not really apparent but to do this type of transformation cs2cs needs some hint that it is doing a change in reference frame (which this essentially is). You can do that by adding +towgs84=0,0,0 to both CRS1 and CRS2. When I do that I get the following:

\$ echo 0 80 0 | cs2cs +proj=latlong +R=3396190 +towgs84=0,0,0 +to +proj=latlong +a=3396190 +b=3376200 +towgs84=0,0,0
0dE     80d6'51.824"N 19392.342

It is not unreasonable to expect cs2cs to figure this out on it’s own. I’ll give it some thoughts the next couple of days and see if I can come up with a simple solution that handles this particular case.

/Kristian

On 18 Aug 2018, at 21:30, Jean-Christophe Malapert <jcmalapert at gmail.com<mailto:jcmalapert at gmail.com>> wrote:

Hello,

I am quite new to the use of  Proj4. I spend a few days to investigate a problem but I have no clue how to solve it. So that's why I am writing to you.  I hope you will be able to answer me.

I have 2 different CRS for the same planet : one is based on the sphere (CRS1, radius=3396190) and another one based on the ellipse (CRS2, a=3396190 b=3376200). When I give the (longitude, latitude) in the CRS1 as inputs (planetocentric latitude = planetographic latitude), I want to get the planetographic latitude expressed in the CRS2. So, I wrote the following command :
cs2cs +proj=latlong +a=3396190 +b=3396190 +to +proj=latlong +a=3396190 +b=3376200
> 0 80  # longitude latitude

I get the following result "0dE 80dN 0.000" . The latitude should change but it is not the case !!! Should I add some options ?  Is it possible to do this kind of transformation with proj4 ?