POV-Ray : Newsgroups : povray.advanced-users : Calculating planet positions : Re: Calculating planet positions Server Time
19 Apr 2024 22:55:53 EDT (-0400)
  Re: Calculating planet positions  
From: Le Forgeron
Date: 15 Sep 2018 15:03:32
Message: <5b9d5784$1@news.povray.org>
Le 15/09/2018 à 19:07, Mike Horvath a écrit :
> I'm trying to adapt the following PDF to POV-Ray code for my
> planetarium/orrery.
> 
> https://ssd.jpl.nasa.gov/txt/aprx_pos_planets.pdf
> 
> How do I calculate the modulus -180 <= M <= +180?
> 

180 degrees, really ?
Can't they use a decent measure of angle, in Grades !

> Is it equal to this?
> 
>     mod(number+180,360)-180

Probably, as long as number is above -180 at start.

I never understood mod of negative value, and there might be divergent
definitions.

They seem to be using a referential for M to describe a full "circle",
so yes, they want to reduce the range of M to be between -180 and +180.

> 
> 
> Mike


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.