redplanet.helper_functions.coordinates._plon2slon
Convert positive longitudes (in range [0, 360]) to signed longitudes (in range [-180, 180]). Inputs in range [-180, 0] are returned as is.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
plon
|
float | list | np.ndarray
|
Longitude value(s) in positive format. |
required |
Returns:
Type | Description |
---|---|
float | list | np.ndarray
|
Converted longitude value(s) in signed format. The return type matches the input type. |
Notes
Actual mapping over the full input range:
- [-180, 180) --> [-180, 180)
- [180, 360] --> [-180, 0]
Self reminder:
- Signed longitude [-180, 180] --> Arabia Terra in middle & Hellas on right.
- Positive longitude [0, 360] --> Olympus Mons in middle & Hellas on left.