Page 1 of 1

relative sky grid

Posted: 03.04.2007, 01:12
by chrisr
this has probably been asked already, but any chance for a relative sky grid. that is a grid to tell you the angular heights of objects relative to your position on a planet. i think using this in conjunction with the polar grid would make it far easier to find objects in the actual night sky. or it would make it easier to find an object in the sky that you couldn't identlify and then be able to identify it within celestia.

i notice that when the semicolon button is pressed you get the polar grid and these curious blue lines the point out from the planet. when you land on the planet you can still see the blue lines. is there any way you can implement direction over these blue lines (eg: east, west, north, south)

Posted: 03.04.2007, 04:15
by LordFerret
Perhaps Selden's Graticules are what you're looking for? I think you'll find help there.
http://www.lepp.cornell.edu/~seb/celestia/graticules.html

Posted: 18.04.2007, 08:23
by Imy
It would be great and useful to integrate these grids in celestia basic package, wouldn't be?

Posted: 18.04.2007, 11:26
by t00fri
Imy wrote:It would be great and useful to integrate these grids in celestia basic package, wouldn't be?



I think this might be a good idea.

But I must say, Selden's untransparent numerology as to the given numerical axis-angle parameters for the galactic graticule must be improved! By just quoting 4-digit numbers without published reference, it is impossible to separate input-uncertainties, possible calculational errors etc...I never believe other people's "anonymous" numerical values, unless I have verified them myself ;-)

Notably since this task is really easy. One just does some familiar rotations by means of quaternions. Voil? ...

Perhaps tonight, I can demonstrate in more detail, how I e.g. generate the Milkyway's axis-angle values by means of quaternions in my galaxy PERL script.

All one needs as starting values are the official J2000 IAU coordinates (RA, DEC) of the Milkyway's center (<=> vanishing galactic latitude and longitude):

RA: 17h45m37.224s (IAU, J2000)
DEC: ??’28?°56?€?10.23?€? (IAU, J2000)

and the position angle:

PA: 122.932?° (IAU, J2000)

The inclination angle is i ~ 0 degrees for an earthbound observer of our galaxy. (face-on view <=> 90 degrees)

According to the IAU definition (1959), the north galactic pole is at
(J2000):

RA: 12h51m26.282s
DEC: +27?°07?€?42.01?€?

the zero of longitude is the great semicircle that originates from this point along the line in position angle 122.932?° with respect to the equatorial pole. Standard PA conventions are understood.


Bye Fridger

Posted: 18.04.2007, 11:45
by selden
As I explained to Fridger in a PM, there are no references because I oriented the grid manually. Grids drawn algorithmically by Celestia would be far preferable.

Posted: 18.04.2007, 12:08
by t00fri
selden wrote:As I explained to Fridger in a PM, there are no references because I oriented the grid manually. Grids drawn algorithmically by Celestia would be far preferable.


But Celestia does not have to do it. Use e.g. PERL along with it's math::quaternion module. It's just a few lines PERL code to arrive at a fully documented analytical and easily understandable generation of the needed axis angles. They arise from an intuitive sequence of quaternionic operations. Analogously one can do the job as a celx script, for example.

That's what I was referring at.

What do you call a "manual orientation" of the galactic coordinate grid, say? Fiddling?

Bye Fridger

Posted: 18.04.2007, 13:44
by selden
manual alignment means just that:
place targets at defined locations and align grid to the target visually.

Unfortunately, the internal coordinate systems of 3ds and cmod models are not the same as Celestia's internal xyz coordinate system.

[edit]
Also, the orientation of an object within a model's coordinate system is arbitrary, so an external orientation which is correct for one model may not be correct for another model.

Drawing lines using Celestia's internal coordinate system is necessary in order to remove any such ambiguity. Supposedly this will be possible in the not too different future, perhaps using Lua OpenGL code.
[/edit]

Posted: 18.04.2007, 14:14
by t00fri
selden wrote:manual alignment means just that:
place targets at defined locations and align grid to the target visually.

Unfortunately, the internal coordinate systems of 3ds and cmod models are not the same as Celestia's internal xyz coordinate system.

So what. I don't understand. Then one simply has to find out how the model frame in question is defined and does the respective transformation relative to Celestia's internal frame. There is NO coordinate system that one cannot reach this way ;-)

Do you want to say that your 4-digit axis-angle numbers could not be derived by means of the simple quaternionic algorithm I was sketching above??

[edit]
Also, the orientation of an object within a model's coordinate system is arbitrary, so an external orientation which is correct for one model may not be correct for another model.

But we are talking here specifically about correctly placing a /plane/, one axis of which connects Earth and the MilkyWay center. This MUST be an elementary math problem, don't you think so? ;-)

Drawing lines using Celestia's internal coordinate system is necessary in order to remove any such ambiguity. Supposedly this will be possible in the not too different future, perhaps using Lua OpenGL code.
[/edit]



Of course everyone got to use Celestia's internal coordinate system. I do to, when orienting my 10000 galaxies by means of the same PERL routine. I really don't understand your reasoning.

Bye Fridger

Posted: 18.04.2007, 17:17
by selden
Fridger,

I simply do not like using multiple transforms between different arbitrarily chosen coordinate systems when that should be unnecessary.

Posted: 18.04.2007, 18:06
by t00fri
selden wrote:Fridger,

I simply do not like using multiple transforms between different arbitrarily chosen coordinate systems when that should be unnecessary.


???

Different coordinate systems are always connected by (a set of) transformations ;-) . In addition they take a most simple form in our case.

Once you define the orientations of your galactic graticule in your modelling program, everything is fixed and can be reproduced and understood by anyone interested to know what you did!

++++++++++++++++
Producing just a set of numbers without reference and asserted accuracies is certainly a far worse alternative!
++++++++++++++++

Indeed your graticule turns out to have a small misalignment relative to the Milkyway orientation that I transparently derived from the official IAU coordinates via quaternionic transforms.

In view of this fact, what is your graticule worth as a reference?? This is a pity, indeed. But if you dont like to invoke some trivial transformations, I cannot force you, of course ;-)


Bye Fridger

Posted: 18.04.2007, 18:17
by selden
As I pointed out, the orientation of the grid object within the model file is *arbitrary*.

Determining the transform for one such model does not tell you the correct transform for another model.

You are welcome to provide your own grid.

Posted: 18.04.2007, 18:55
by t00fri
selden wrote:As I pointed out, the orientation of the grid object within the model file is *arbitrary*.

Determining the transform for one such model does not tell you the correct transform for another model.

You are welcome to provide your own grid.


Of course the graticule orientation is arbitrary within a given modelling program. But one may easily agree on a coordinate convention that may be documented! Then a simple --well-defined-- transformation to the internal Celestia frame produces a reproducable result.

Here is the present status as I see it:

With the following official definitions of the MilkyWay location:

Code: Select all

#
# add Milky Way (J2000)
# --------------
#
$name = "Milky Way";
$altname = " ";
             
$ra  = "17 45 37.224";   #IAU 1959
$dec = "-28 56 10.23";   #IAU 1959
$PA = 122.932;  #IAU 1959

$epsilon =23.4392911; # ecliptic angle
$inclination = 0; #observer located in the Milkyway plane.

# convert to hours, degrees, respectively
$alpha = &ra2h ($ra);
$delta = &dec2deg ($dec);


and the simple quaternionic transform routine that I also use for my 10000+ other galaxy orientations (see below):

Code: Select all

&orientation($alpha,$delta,"MilkyWay",$inclination,$PA);


I produce this perfect face-on alignment of the MilkyWay with your graticule:

Image
Note the red diamond representing Sol in the Orion arm!

However, viewed sideways, there is this very small misalignment

Image
My resulting angle-axis values for the MilkyWay are:

Code: Select all

Axis    [  0.8708   0.4893   0.0476]
Angle    176.7157


+++++++++++++++++++++++
Since your angle-axis numbers are undocumented and unreproducable, your graticule looses much of it's high potential usefulness at this point!

Certainly I will not do a graticule myself ;-) .
++++++++++++++++++++++++

Even without knowing PERL, you will easily be able to read and understand the simple quaternionic transforms in my orientation routine, which aligned 10000's of galaxies already...

Code: Select all

sub orientation {
     my($ra, $dec, $Type, $i, $PA) = @_;
     my $decrot = Math::Quaternion::rotation(deg2rad(90 - $dec),1,0,0);
     my $rarot  = Math::Quaternion::rotation(deg2rad(90 - $ra * 15),0,1,0);
     my $radecrot = $decrot * $rarot;
     my $incrot = Math::Quaternion::rotation(deg2rad($i),0,0,1);
   my $pa =  Math::Quaternion::rotation(deg2rad($PA),0,1,0);
   my $px =  Math::Quaternion::rotation(deg2rad(-90),1,0,0);
     my $eclipticsrot = Math::Quaternion::rotation(deg2rad($epsilon),1,0,0);
     #
     if ($Type =~ /E/) {
       $rot = $pa * $radecrot * $eclipticsrot;
   } elsif ($Type =~ /^MilkyWay/){
      $rot = $px * $pa * $radecrot * $eclipticsrot;
   } else {
       $rot = $incrot * $pa * $radecrot * $eclipticsrot;
     }
   if ($rot->rotation_angle > pi){
      $rot = $rot->negate;
   }
     $angle=$rot->rotation_angle * 180/pi;
   @v=$rot->rotation_axis;   
}


The last several lines just use the familiar fact that if the quaternion (a + b i + c j + d k) represents a rotation then (- a - b i - c j - d k) represents the same rotation, however with angle -> 360 deg - angle and axis [xyz] -> [-x,-y,-z]. I use this trick to constrain the angle to < 180 degrees.

Bye Fridger

Posted: 23.04.2007, 11:28
by selden
I've spent some time determining just how much my galactic graticule is misaligned.
As best I can tell, it's off by less than 1/10 of a degree in both l2 and b2.

l2 = galactic longitude (east/west, 0-360 degrees)
b2 = galactic latitude (north/south, +/- 90 degrees)

In the direction of l2,b2 = [0,0]
the graticule is off by about -0.01 degree in both l2 and b2.
At right angles to that,
in the direction of l2,b2 = [90,0]
the graticule is off by about -0.01 degree in l2, +0.04 degree in b2

Here's the method I used. Anyone can do this.
No math skills are required, except to divide the calculator's decimal degrees by 15
to get decimal hours as needed by Celestia's DSC files.

Use the Chandra Proposal Planning Toolkit Precess calculator at
http://cxc.harvard.edu/toolkit/precess.jsp
I'm assuming that their algorithms are reasonably accurate.

Determine the RA and Dec of l2,b2 = [0,0]
Determine the RA and Dec of l2,b2 = [359.9, -0.1]

Determine the RA and Dec of l2,b2 = [90,0]
Determine the RA and Dec of l2,b2 = [89.9, +0.1]

Place objects at those 4 RA, Dec positions.
Draw plus Marks at those locations.
When you rotate Celestia's POV so Galactic North is toward the top,
the plus marks will outline boxes 0.1 degree on a side.


Here's the Objects.dsc file
that I used to place objects at those locations.
Please verify my numbers.

Code: Select all

# galactic l2,b2 converted to Equatorial(J2000) RA, Dec using
# Chandra proposal calculator at
# http://cxc.harvard.edu/toolkit/precess.jsp

OpenCluster "00,00" {
#l2=0,b2=0
RA   17.7603331 # 266.404996/15
Dec -28.936172
 Distance  1e9}

OpenCluster "90,00" {
# l2=90,b2=0
RA  21.2002927 # 318.004391/15.
Dec 48.329643
 Distance 1e9}
##############################################
#  0.1 degree marks:
# l2= -0.1, b2=-0.1
# l2=359.9
OpenCluster "00-0.1" {
RA   17.7628694 # 266.443041/15.
Dec -29.073623
Distance 1e9
}

# l2=89.9 , b2=0.1
OpenCluster "90+0.1" {
RA   21.1861927 # 317.791789/15.
Dec  48.325258
Distance 1e9
}

# l2 = 90, b2 = -5
OpenCluster "90-5" {
RA   21.5420718# 323.131077/15.
Dec  44.780942
Distance 1e9
}



The objects are placed far away to minimize parallax.

Here's the Mark.cel script that I used to draw the plus marks:

Code: Select all

 {
 mark { object "00,00" color [ 1 1 0.5 ] size 600 symbol "plus"}
 mark { object "90,00" color [ 0.5 1 1 ] size 600 symbol "plus"}

 mark { object "00-0.1" color [ 1 1 0.5 ] size 600 symbol "plus"}
 mark { object "90+0.1" color [ 0.5 1 1 ] size 600 symbol "plus"}

 mark { object "90-5" color [ 1 0 1 ] size 600 symbol "plus"}
 }



Here's a high magnification view from the Sun toward [0,0]
(Galactic North is up)
Image

Here's a high magnification view from the Sun toward [90,0]
(Galactic North is up)
Image

Here's the default 40 degree view of [90,0]
including the Milky Way and a marker at l2,b2 [90,-5]
Image