For Celestia Users

View previous topic View next topic Go down

For Celestia Users

Post by Lazarus on 26th January 2010, 6:44 pm

Since a few people here seem to be using Celestia for creating artworks and making some add-ons, I'll give you a couple of hints and tips for keeping your Celestia installation up-to-date with the latest extrasolar planet discoveries, and on creating add-ons.

Obtaining the latest extrasolar planets catalogue

There are two relevant files here, extrasolar.stc which defines the extrasolar planet host stars (where not present in one of Celestia's default catalogue files), and extrasolar.ssc which defines the planets themselves. Both of these files are located in the data directory of the Celestia installation.

To get the latest versions of these files, you can go to Celestia's Subversion repository. The data directory in the repository is located here. You can then click through to the individual pages for the files, where you will find links to download the latest versions.

Orbital parameters
Periods for planets in Celestia files are given in Julian years, 1 Julian year = 365.25 days. The ability to specify units is not available in the current released version of Celestia however this has been added for the 1.7 series - if you are compiling from source or using one of the binaries provided by users you will be able to take advantage of this functionality already.

Celestia by default takes its orbital parameters in the J2000 ecliptic plane. However the quoted parameters for extrasolar planets are given in sky-plane coordinates. This means you cannot simply copy the orbital orientation parameters into a .ssc file. There are two options: the first is to transform the parameters into Celestia's frame (there is a spreadsheet available here which can do this). Celestia's extrasolar planets files transform the orbit into J2000 ecliptic parameters such that the inclination and ascending node of the resultant orbit are 0.

Alternatively you can use the listed extrasolar planet parameters as-is, and specify the reference frame. The following reference frame definition will do the trick:
Code:
"b" "Star"
{
    OrbitFrame {
        TwoVector {
            Center "*Star*"
            Primary { Axis "z" RelativePosition { Observer "*Barycenter*" Target "SSB" } }
            Secondary { Axis "x" ConstantVector { Vector [ 0 0 1 ] Frame { EquatorJ2000 { Center "*Star*" } } } }
        }
    }
    ...more object parameters...
}
Replace *Star* with the name of the parent star, and *Barycenter* with the name of the system's barycentre (if it is a single star system, this will be the parent star). Admittedly this is somewhat awkward, currently it's being proposed to define a SkyPlane reference frame, this should hopefully make it into the 1.7 versions.

For fully-specified orbits (i.e. ones where inclination, ascending node and argument of pericentre are all known) this will give the same results as the transformation method. For orbits with unspecified inclination and ascending node, this will result in different orbits: convention in Celestia is not to specify unknown parameters, so the transformation method as used to generate the Celestia extrasolar planets files results in inclination and ascending node being zero in the J2000 ecliptic plane, while the reference frame would result in inclination and ascending node being zero in the sky-plane, i.e. the orbit will be drawn face-on unless inclination is specifed.

Rotation
If you want the axis of the planet to be aligned perpendicular to the orbit, you must set the Inclination and AscendingNode properties in the UniformRotation block to the same values as the Inclination and AscendingNode properties in the EllipticalOrbit block. E.g.

Code:
"b" "Star"
{
    EllipticalOrbit {
        Inclination 114
        AscendingNode 329
        ...more orbit parameters...
    }
    UniformRotation {
        Inclination 114
        AscendingNode 329
        ...more rotation parameters...
    }
    ...more object parameters...
}

If you've decided to specify a reference frame, that means you must AGAIN specify the reference frame as a BodyFrame instead of an orbit frame, so for a tidally-locked planet you might have something like the following:
Code:
"b" "Star"
{
    OrbitFrame {
        TwoVector {
            Center "*Star*"
            Primary { Axis "z" RelativePosition { Observer "*Barycenter*" Target "SSB" } }
            Secondary { Axis "x" ConstantVector { Vector [ 0 0 1 ] Frame { EquatorJ2000 { Center "*Star*" } } } }
        }
    }
    BodyFrame {
        TwoVector {
            Center "*Star*"
            Primary { Axis "z" RelativePosition { Observer "*Barycenter*" Target "SSB" } }
            Secondary { Axis "x" ConstantVector { Vector [ 0 0 1 ] Frame { EquatorJ2000 { Center "*Star*" } } } }
        }
    }
    EllipticalOrbit {
        Inclination 123
        AscendingNode 345
        ...more orbit parameters...
    }
    UniformRotation {
        Inclination 123
        AscendingNode 345
    }
    ...more object parameters...
}
This works because the default rotation period is the same as the orbital period, so there's no need to specify it independently or add more parameters to the UniformRotation block.

Hope this is useful.

Lazarus
dG star
dG star

Number of posts : 2750
Registration date : 2008-06-12

View user profile

Back to top Go down

Re: For Celestia Users

Post by Sirius_Alpha on 26th January 2010, 6:52 pm

Thanks for writing this!

_________________
Caps Lock: Cruise control for 'Cool'!

Sirius_Alpha
Admin
Admin

Number of posts : 3381
Location : Earth
Registration date : 2008-04-06

View user profile http://solar-flux.forumandco.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum