Page 1 of 1
Celestia Vector data type questions
Posted: 18.07.2003, 16:35
by don
Howdy Everyone,
I'm not an Astronomer, Pilot, or Space Flight expert, let alone a 3-D graphics designer or programmer, so please go easy on me (smile) ...
My current task is an attempt to provide an end-user guide to the existing commands and parameters in Celestia's .CEL Scripting. It will include an introduction to the Data Types used by .CEL, and the one I am not clear on is Vectors. Your assistance, in layman's terms that I can use in the guide, would be very much appreciated.
I *think* a Vector is a position in a 3-D space, but I'm not sure exactly what the X, Y and Z coordinates represent in outer space.
In Celestia, the Vector data type is used in the following commands:
* goto and gotolonglat: Vector is up (not sure what "up" means)
* gotoloc: Vector is position
* orbit, rotate, and setorientation: Vector is axis
* setposition: Vectors are base and offset (not sure what these mean)
My questions, so I can provide this information in the guide, are ...
Q1. What is the proper definition of a "vector", in layman's terms, as used in Celestia?
Q2. What do the X, Y and Z coordinates represent in Celestia's outer space?
Q3a. What are the "valid values" (low and high) for each of the X-Y-Z values?
Q3b. Are the valid values *different* depending on the .CEL command they are used in? If so, please list what the valid values would be for each of the X-Y-Z coordinates for each of the commands listed above.
Thank you all very much for your help.
-Don
Posted: 22.07.2003, 18:57
by don
Awwww, come on group . . . someone here must be able to describe a vector so I can put it in the Scripting Guide, no?
Thank you!
-Don
Posted: 22.07.2003, 19:11
by JackHiggins
Ok as someone who's pretty familiar with xyz files & celestia in general, heres my take on the vectors question...
Q1. What is the proper definition of a "vector", in layman's terms, as used in Celestia?
Distance from the sun, in km, along the 3 dimensional cartesian plane (can a plane be 3 dimensional?)
Q2. What do the X, Y and Z coordinates represent in Celestia's outer space?
Distance from the sun, in km. ie x & y are as if you were looking down on the sun, and z is "up & down" through the poles of the sun. (this may not be entirely the correct orientation)
Q3a. What are the "valid values" (low and high) for each of the X-Y-Z values?
Anything! just look at the massive distances in the pioneer & voyager scripts!
Q3b. Are the valid values *different* depending on the .CEL command they are used in? If so, please list what the valid values would be for each of the X-Y-Z coordinates for each of the commands listed above.
Dunno about that sorry...
Ok so this is the trajectory version of what xyz's mean, but...
Isn't the vector data type in the "move" command as well? (There is a "move" command- right?)
That was the one I was familiar with, & in that I thought the z axis was forward, x was left & right & y was up & down.
Dunno if this is actually going to be much help to you but it's better than nothing I guess!
Posted: 22.07.2003, 19:54
by don
Howdy Jack,
Thanks a bunch for taking a stab at this one
.
I'm printing it out to "play" with, now that I have a basic idea of what the x, y, and z parameters might do, depending on the command.
The only thing my mind could come up with for a "vector" was trying to imagine creating a 3-D space in a 2-D display screen ... x = left/right position, y = up/down position, and z = depth/distance from the front of the display, or from some reference object. But, some Celestia vector parameters are named xrot, yrot, and zrot, which obviously means something totally different. Thus, my question.
> (can a plane be 3 dimensional?)
I think a plane is only 2-D.
> Isn't the vector data type in the "move" command as well?
move has only two parameters: duration and velocity. So, I *think* (not tested yet), the
setposition,
setorientation and possibly
setframe,
center and/or
track commands would need to be used before a move command. It looks quite tricky to "script" movement with any precision, without using
goto.
Every little bit helps Jack, so I thank you for your reply and hope some others will help out too.
-Don
Posted: 22.07.2003, 21:22
by selden
Don and Jack,
3d vectors and matrix algebra are fundamental to 3d graphics.
They, as well as spherical trigonometry and calculus, are fundamental to celestial mechanics. Celestia uses these concepts to determine locations and orientations of objects and of the observer.
If you're having trouble understanding how Celestia is using them, you should seriously consider taking a course in mathematics that covers one or more of these topics. It doesn't have to be in a classroom: "remote learning", correspondance and self-paced study guides are readily available.
I hope this suggestion helps a little.
Posted: 23.07.2003, 00:28
by don
Howdy Selden,
Hey, I was pretty good in math and trig at high-school (31 years ago), but never got into spherical trigonometry, calculus or celestial navigation, even in college <smile>. Don't have time for a class right now ... I'm just trying to write a scripting guide that every-day folk can understand, which is what prompted my initial post. (In the future, I may very well do some on-line studying of these subjects, but that takes a lot of time.)
Soooo, if someone can use laymen's terms to describe what a vector is and what the 3 parameters represent, in the noted Celestia scripting commands, future scripters will get a short education in vectors <smile>.
Thanks!
-Don
Posted: 23.07.2003, 01:16
by HankR
don,
In computer jargon, the term vector often refers to any ordered set of values. Essentially, it's just a list of values. The vector length (number of values), the range of values which are allowable, and their meaning, will depend on the context.
- Hank
Posted: 23.07.2003, 01:42
by HankR
In a geometric context, vectors are commonly used to represent directions, displacements (direction plus distance) and locations (displacement from an origin). They can also be used to represent orientations (e.g. as a sequence of rotations).
I'm not sure whether these concepts can be easily "translated" into a "layman's language" which "every-day folk" could understand. You have to learn a certain amount of mathematics to make sense of it.
-Hank
Posted: 23.07.2003, 12:50
by selden
Don,
"Describe them in layman's terms" is just another way of saying "teach a class in 3D math"
Seriously, you should at least consider getting a book or two on the subject and reading the first few chapters. Two I have are
Fundamentals of Astrodynamics by Bate, Mueller and White, published by Dover (1971), and
Spherical Astronomy by Smart, published by Cambridge University Press (1965). The first is a "classic" and is still readily available. It quickly gets into more complex topics, though, since it treats most of what you're insterested in as a "review". Modern equivalents of the second title must be available, but I haven't looked.
I hope these suggestions help a little.
Posted: 24.07.2003, 03:02
by don
Thank you ... Jack, Selden and Hank.
Guess I'll do some research <smile>.
-Don