Best calculator?

The place to discuss creating, porting and modifying Celestia's source code.
Topic author
rthorvald
Posts: 1223
Joined: 20.10.2003
With us: 21 years 1 month
Location: Norway

Best calculator?

Post #1by rthorvald » 14.10.2005, 13:32

What is the best calculator for converting time units for use in Celestia?
I have tried several, needing to convert years to hours, but different ones do not give the exact same results, and over a period of thousands of years the discrepancy becomes too big to be practical.

I need to compute a stable relationship between two bodies for about 6000 years.

A web-based utility would be optimal... Alternately a win or OSX app.

-rthorvald

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 9 months
Location: Seattle, WA USA

Re: Best calculator?

Post #2by hank » 14.10.2005, 16:21

rthorvald wrote:What is the best calculator for converting time units for use in Celestia?
I have tried several, needing to convert years to hours, but different ones do not give the exact same results, and over a period of thousands of years the discrepancy becomes too big to be practical.


What kind of years? (Julian, Gregorian, tropical, sidereal, anomalistic, ... )

- Hank

ANDREA
Posts: 1543
Joined: 01.06.2002
With us: 22 years 5 months
Location: Rome, ITALY

Post #3by ANDREA » 14.10.2005, 16:58

rthorvald, something like this?

Code: Select all

http://www.onlineconversion.com/time.htm

Or what else?
Bye

Andrea :D
"Something is always better than nothing!"
HP Omen 15-DC1040nl- Intel® Core i7 9750H, 2.6/4.5 GHz- 1TB PCIe NVMe M.2 SSD+ 1TB SATA 6 SSD- 32GB SDRAM DDR4 2666 MHz- Nvidia GeForce GTX 1660 Ti 6 GB-WIN 11 PRO

ANDREA
Posts: 1543
Joined: 01.06.2002
With us: 22 years 5 months
Location: Rome, ITALY

Post #4by ANDREA » 14.10.2005, 16:59

Ot this one? :wink:

Code: Select all

http://www.onlineconversion.com/date_time.htm
Bye

Andrea :D
"Something is always better than nothing!"
HP Omen 15-DC1040nl- Intel® Core i7 9750H, 2.6/4.5 GHz- 1TB PCIe NVMe M.2 SSD+ 1TB SATA 6 SSD- 32GB SDRAM DDR4 2666 MHz- Nvidia GeForce GTX 1660 Ti 6 GB-WIN 11 PRO

buggs_moran
Posts: 835
Joined: 27.09.2004
With us: 20 years 1 month
Location: Massachusetts, USA

Post #5by buggs_moran » 14.10.2005, 18:20

I brought this up in an earlier post http://www.shatters.net/forum/viewtopic.php?t=8001

there is a link there to a freeware converter...
Homebrew:
WinXP Pro SP2
Asus A7N8X-E Deluxe
AMD Athlon XP 3000/333 2.16 GHz
1 GB Crucial RAM
80 GB WD SATA drive
ATI AIW 9600XT 128M

Topic author
rthorvald
Posts: 1223
Joined: 20.10.2003
With us: 21 years 1 month
Location: Norway

Post #6by rthorvald » 14.10.2005, 23:30

ANDREA wrote:http://www.onlineconversion.com/time.htm[/code]


Yes, this is the one i normally use. But how exact is it? It gives one terrestrial year as 8760 hours, while a time converter that came with my OS gives 8766 hours. What i am looking for is really a formula that matches how Celestia measures time...

-rthorvald

ANDREA
Posts: 1543
Joined: 01.06.2002
With us: 22 years 5 months
Location: Rome, ITALY

Post #7by ANDREA » 14.10.2005, 23:38

rthorvald wrote: What i am looking for is really a formula that matches how Celestia measures time... -rthorvald

Perhaps this page

Code: Select all

http://www.absoluteastronomy.com/encyclopedia/y/ye/year.htm

will give you the answer you need (but, alas, there is more than one, as you'll see). :wink:
Hope this will help.
Bye

Andrea :D
"Something is always better than nothing!"
HP Omen 15-DC1040nl- Intel® Core i7 9750H, 2.6/4.5 GHz- 1TB PCIe NVMe M.2 SSD+ 1TB SATA 6 SSD- 32GB SDRAM DDR4 2666 MHz- Nvidia GeForce GTX 1660 Ti 6 GB-WIN 11 PRO

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 9 months
Location: Seattle, WA USA

Post #8by hank » 14.10.2005, 23:42

rthorvald wrote:
ANDREA wrote:http://www.onlineconversion.com/time.htm[/code]

Yes, this is the one i normally use. But how exact is it? It gives one terrestrial year as 8760 hours, while a time converter that came with my OS gives 8766 hours. What i am looking for is really a formula that matches how Celestia measures time...

-rthorvald

An ordinary year is 8760 hours (365 days * 24 hours). A leap year is 8784 hours (366 days * 24 hours). An average year (with 1 out of 4 years a leap year) is 8766 hours (365.25 * 24 hours).

Can you give us a better idea of what you're trying to do? Are you sure Celestia itself has the required precision?

- Hank

Topic author
rthorvald
Posts: 1223
Joined: 20.10.2003
With us: 21 years 1 month
Location: Norway

Post #9by rthorvald » 15.10.2005, 01:11

hank wrote:An average year (with 1 out of 4 years a leap year) is 8766 hours (365.25 * 24 hours)
Well, i have assumed that this is what Celestia takes to be one year.


hank wrote:Are you sure Celestia itself has the required precision?
No, that is what i am trying to find out.

hank wrote:Can you give us a better idea of what you're trying to do?

Spesificially, i have a planet with a period of 0.3450137 years. I am trying to align this with the rotationperiod of the star, so that it passes a certain spot on the star surface at spesific dates - but over time it drifts off. I don??t know if it is the calculator or Celestia yet.

-rthorvald

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 9 months
Location: Seattle, WA USA

Post #10by hank » 15.10.2005, 02:15

rthorvald wrote:Specificially, I have a planet with a period of 0.3450137 years. I am trying to align this with the rotationperiod of the star, so that it passes a certain spot on the star surface at spesific dates - but over time it drifts off. I don??t know if it is the calculator or Celestia yet.

-rthorvald

From the code it looks like Celestia uses years of 365.25 days for the orbital period and 24 per day hours for the rotation period. I'd guess your problem is due to imprecision in the math calculations.

- Hank

Topic author
rthorvald
Posts: 1223
Joined: 20.10.2003
With us: 21 years 1 month
Location: Norway

Post #11by rthorvald » 16.10.2005, 02:34

hank wrote:From the code it looks like Celestia uses years of 365.25 days for the orbital period and 24 per day hours for the rotation period. I'd guess your problem is due to imprecision in the math calculations.


Thank you.

- rthorvald

Avatar
t00fri
Developer
Posts: 8772
Joined: 29.03.2002
Age: 22
With us: 22 years 7 months
Location: Hamburg, Germany

Post #12by t00fri » 16.10.2005, 10:36

++++++++++++++++++++++++
Since you happen to talk about Celestia's precision, there is a known typo in Celestia, concerning the numerical value of the speed of light.

The astrophysical consequences of this slightly incorrect value have so far not been explored. They could be significant notably on long time scales.

We have not yet replaced the value by the correct one, since this would invalidate a number of existing stuff, like CEL://urls .This issue definitely calls for a clean solution!

+++++++++++++++++++++++++

Cheers,
Bye Fridger

hank
Developer
Posts: 645
Joined: 03.02.2002
With us: 22 years 9 months
Location: Seattle, WA USA

Post #13by hank » 16.10.2005, 15:38

t00fri wrote:We have not yet replaced the value by the correct one, since this would invalidate a number of existing stuff, like CEL: urls.

Wasn't there a change in the universal coordinate system in 1.4.0 that also invalidates CEL: urls? So that perhaps now is the time to make this fix?

- Hank


Return to “Development”