Page 1 of 1

Add system in other Galaxy

Posted: 13.02.2004, 10:54
by Starfighter
Hello,

How to add system in other Galaxy?
It's possible?
If not, Why and where in source can i modify the code for this?

Thank You

Posted: 13.02.2004, 11:38
by ElPelado
AFAIK, you can only put starts as far as 16000 ly from our sun, so, you cant put stars even in the magallanic clouds...

Posted: 04.12.2007, 05:22
by Larre
In the Celestia Source Code, the most likely culprit in limiting Celestia's ability to sender stars beyond 16000 ly, is the "Octree.cpp" file. This is the settings file for the Octree, to which a star database is rendered. I do not know much about this file, since I am just a beginner at understanding the C++ programming language, but I am studying the file very closely, as well as it's counterpart, the "Octree.h" header file.

I hope this helps, and good luck at deciphering the code. Please post results when you figure out the problem. Do lots of tests!

Peace, Larre :wink:

Posted: 04.12.2007, 19:44
by chris
Larre wrote:In the Celestia Source Code, the most likely culprit in limiting Celestia's ability to sender stars beyond 16000 ly, is the "Octree.cpp" file. This is the settings file for the Octree, to which a star database is rendered. I do not know much about this file, since I am just a beginner at understanding the C++ programming language, but I am studying the file very closely, as well as it's counterpart, the "Octree.h" header file.

I hope this helps, and good luck at deciphering the code. Please post results when you figure out the problem. Do lots of tests!

Peace, Larre :wink:


You can easily modify the value STAR_OCTREE_ROOT_SIZE in stardb.cpp to allow placing stars further from Earth than 15k light years. However, you are likely to run into jitteriness caused by the limitations of single precision floating point math if you place a star much further away than this. Switching octree.cpp to use double precision would solve the problem be incur a cost in storage and memory usage. Since we don't have reliable distance estimates for such distance stars, I opted early on to use single precision.

--Chris

Posted: 05.12.2007, 00:43
by ajtribick
Apparently there are a couple of systems for which orbital parameters and distances are known in M31 and M33 (though the distance errors are of the order of tens of kiloparsecs). Not sure how many such systems are known in the Magellanic clouds though.

See this thread for details and papers.

Re: Add system in other Galaxy

Posted: 02.06.2009, 13:31
by Larre
Well, I finally got Celestia compiled with a few minor errors. Now, I will be testing some theories that I have when it comes to the root of the Star Octree.

My test is to create multiple Star Octrees, which represent the multiple galaxies in the local group. My standard size for these Octrees will be about twice the distance that Celestia is currently able to handle. In other words, these Octrees will be able to support rendering of stars as far as 32000 ly.

Here is the code I have altered from stardb.cpp:

Code: Select all

static const float STAR_OCTREE_ROOT_SIZE  = 20000000.0f;

static const float STAR_OCTREE_MAGNITUDE  = 12.0f;


The factor, 20000000.0f, represents the Octree's capability to render stars up to 32000 ly from the sun. The magnitude is probably for special rendering of these stars. The Octree root Size was originally at 10000000.0f, and the magnitude at 6.0f.

I have run this successfully, and now the task is to figure the math of where the stars are from the center of the current galaxy that I am working on, rather than from the Sun, which is what Celestia is currently able to handle. This may take a while, since there are over 2M stars in the current Octree.

Peace, Larre..

Re: Add system in other Galaxy

Posted: 02.06.2009, 13:54
by chris
Larre wrote:Well, I finally got Celestia compiled with a few minor errors. Now, I will be testing some theories that I have when it comes to the root of the Star Octree.

My test is to create multiple Star Octrees, which represent the multiple galaxies in the local group. My standard size for these Octrees will be about twice the distance that Celestia is currently able to handle. In other words, these Octrees will be able to support rendering of stars as far as 32000 ly.

Here is the code I have altered from stardb.cpp:

Code: Select all

static const float STAR_OCTREE_ROOT_SIZE  = 20000000.0f;

static const float STAR_OCTREE_MAGNITUDE  = 12.0f;


The factor, 20000000.0f, represents the Octree's capability to render stars up to 32000 ly from the sun. The magnitude is probably for special rendering of these stars. The Octree root Size was originally at 10000000.0f, and the magnitude at 6.0f.

I have run this successfully, and now the task is to figure the math of where the stars are from the center of the current galaxy that I am working on, rather than from the Sun, which is what Celestia is currently able to handle. This may take a while, since there are over 2M stars in the current Octree.

Stars beyond 16000 light years are already working in Celestia 1.6.0. That value from stardb.cpp indicates that the size of the octree is 10 million light years--not the size of the visible universe, but much larger than the local group of galaxies.

--Chris

Re: Add system in other Galaxy

Posted: 03.06.2009, 17:51
by Larre
Thank you Chris, for the clarification. Now to figure out how to center the star octree to the center of the Milky Way galaxy, rather than to center it with the Sun. I have tried it with the configuration file Celestia.cfg, as well as the stars.txt, and starnames.dat files, and none of those work.

I will proceed to look into the source code itself to find the means. If anyone has any ideas as to where it is, please post here.


Thank you very much and Peace,
Larre.. :mrgreen:

Re: Add system in other Galaxy

Posted: 03.06.2009, 18:01
by chris
Larre wrote:Thank you Chris, for the clarification. Now to figure out how to center the star octree to the center of the Milky Way galaxy, rather than to center it with the Sun. I have tried it with the configuration file Celestia.cfg, as well as the stars.txt, and starnames.dat files, and none of those work.

I will proceed to look into the source code itself to find the means. If anyone has any ideas as to where it is, please post here.

How come you want to change the center? I don't think what there is to gain by moving the star octree to the center of the galaxy. You'll simply end up with a version of Celestia that isn't compatible with existing star catalogs.

--Chris

Re: Add system in other Galaxy

Posted: 03.06.2009, 23:57
by Larre
Chris, You are right on this. It would not be compatible with current star catalogs.

We might have to wait until newer catalogs come out where they are actually mapping the galaxy, rather than the stars that are close to earth.

Peace, Larre.. :(

Re: Add system in other Galaxy

Posted: 04.06.2009, 07:01
by t00fri
Larre wrote:Chris, You are right on this. It would not be compatible with current star catalogs.

We might have to wait until newer catalogs come out where they are actually mapping the galaxy, rather than the stars that are close to earth.

Peace, Larre.. :(

Larre,

we do know the orbits of a number of stars encircling the central black hole (SGR A*) in our galaxy, with distances from us being beyond the former 16k light year limit of Celestia.

http://www.mpe.mpg.de/ir/GC/index.php
On their page, the MPI scientists used Celestia to display their central star orbits!

Image

Here is their original publication containing the orbit parameters
http://arxiv.org/pdf/0810.4674v1

I suppose you have looked into my thread that Andrew was referring to above. There you also find the reference to my corresponding thread in our CelestialMatters site:

http://forum.celestialmatters.org/viewt ... 10&start=0

where I parametrized 373 central stars orbiting the MilkyWay black hole (SGR A*), using galactic coordinates and even made various videos that you might look at. Later the user Cham used the actually measured orbits of these central stars and produced a corresponding Celestia add-on.

My respective "games" in CelestialMatters including also orbiting stars in the Andromeda galaxy M 31 were the first concrete exercises beyond the former 16k light year limit of Celestia... There I also randomly generated 10000 binary systems with random orbital parameters, color classes and magnitudes, which you may download

http://www.celestialmatters.org/users/t ... 00.stc.zip

Here is a non-animated image from the resulting star cluster with 10000 entries and the nearby LMC galaxy in the background:
Image

and here a MP4 video of the 10000 orbiting stars
http://www.celestialmatters.org/users/t ... s10000.avi

All this I did 1.5 years ago already...
In all these cases there was no need to modify the star octree (I didn't really use too many stars anyway) ...

Fridger