A script to mark ALL Fridger's galaxies

All about writing scripts for Celestia in Lua and the .cel system
Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

A script to mark ALL Fridger's galaxies

Post #1by Cham » 10.03.2007, 23:03

Here's a script I made (not the ideal code but it works very well), to mark all galaxies in Fridger's galactic database.

There are exactly 10608 objects marked. The global view is pretty interesting, but a bit slow in Celestia.

Download link :

http://nho.ohn.free.fr/celestia/Cham/markgalaxy.cel.zip (32 KB zip file)

Here's a picture of the beast (maybe I should have used dots instead of circles, but then you can easily edit that script) :

Image

The red arrow is marking my town, in that pile (from another script) ! :mrgreen:

It would be most interesting to mark the various types of galaxies with a color code. Say, all elliptical galaxies in red, all irr in gray, spirals in blue, etc...
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #2by Cham » 10.03.2007, 23:30

Hmmm, I just found that a smaller "disk" marker is much better, and the frame rate is a bit higher. Using copy-paste in the previous script, use the following line of code instead :

Code: Select all

size 2 color [ 1 0.5 0] symbol "disk"
Last edited by Cham on 10.03.2007, 23:46, edited 1 time in total.
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

ElChristou
Developer
Posts: 3776
Joined: 04.02.2005
With us: 19 years 9 months

Post #3by ElChristou » 10.03.2007, 23:41

Cool! it would be nice to mark each class with a different color... possible?
Image

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #4by Cham » 10.03.2007, 23:44

Of course, it's possible. However, I'm not an expert in scripting, and I don't know how to do it in a proper way, except in a lenghty and tedious way.

We need a short trick for that, if there is one.
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Johaen
Posts: 341
Joined: 14.01.2006
With us: 18 years 9 months
Location: IL, USA

Post #5by Johaen » 10.03.2007, 23:50

Am I missing something? I started up Celestia and ran the script. The message in Celestia said "Running script", but I'm not seeing anything. No circles/disks.
AMD Athlon X2 4400+; 2GB OCZ Platinum RAM; 320GB SATA HDD; NVidia EVGA GeForce 7900GT KO, PCI-e, 512MB, ForceWare ver. 163.71; Razer Barracuda AC-1 7.1 Gaming Soundcard; Abit AN8 32X motherboard; 600 watt Kingwin Mach1 PSU; Windows XP Media Center SP2;

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #6by Cham » 10.03.2007, 23:56

To use that script, you need Celestia 1.5 (CVS version, which hasn't been published yet). That's because I'm using "circle" (or "disk", which is better), and that option isn't available in Celestia 1.4.1.

Try replacing all the "circle" by "square", and it should work.

Of course, you also need to show all the markers in Celestia, by pressing ctrl-K.
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Johaen
Posts: 341
Joined: 14.01.2006
With us: 18 years 9 months
Location: IL, USA

Post #7by Johaen » 11.03.2007, 00:08

Cham wrote:Of course, you also need to show all the markers in Celestia, by pressing ctrl-K.


That's the part I was missing, lol. It works just fine with 1.5.0pre2, using disks. I get between 20 and 25 fps, which is tolerable to me.
AMD Athlon X2 4400+; 2GB OCZ Platinum RAM; 320GB SATA HDD; NVidia EVGA GeForce 7900GT KO, PCI-e, 512MB, ForceWare ver. 163.71; Razer Barracuda AC-1 7.1 Gaming Soundcard; Abit AN8 32X motherboard; 600 watt Kingwin Mach1 PSU; Windows XP Media Center SP2;

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

Post #8by t00fri » 11.03.2007, 00:14

NICE!

Of course the central void wedge is nothing but our galactic plane with the MilkkyWay being right in the center.

Image

Bye Fridger
Image

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #9by Cham » 11.03.2007, 00:18

Fridger,

try the script with 2 points disks. It's much better looking. :)

Seeing the galactic distribution always impresses me. This "phenomenon" is trully amazing. My own father can't even look at it : he says this gives him vertigo !
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

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

Post #10by t00fri » 11.03.2007, 00:44

Yeah, looks way more "filiamentary" ;-)

It's just time for

COSMO-Celestia....

Image

Bye Fridger
Image

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #11by Cham » 11.03.2007, 00:59

Fridger,

what are the parameters for that color ? I love it. I may use it for another galactic class, if I can find the time to make another script.
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

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

Post #12by t00fri » 11.03.2007, 01:13

Cham wrote:Fridger,

what are the parameters for that color ? I love it. I may use it for another galactic class, if I can find the time to make another script.



Didn't note it down. I just moved the Hue slider until I liked the color ;-)

It is NICE.

Bye Fridger
Image

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

Post #13by t00fri » 11.03.2007, 01:19

Here is the corresponding cone plot with 221283 galaxies from 2dF versus redshift as usual.

Image
The filiamentary structure is already nicely seen.

Bye Fridger
Image

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

Post #14by t00fri » 11.03.2007, 01:45

Cham wrote:Fridger,

what are the parameters for that color ? I love it. I may use it for another galactic class, if I can find the time to make another script.


I just measured the red color:

[228/256, 0, 113/256]

Bye Fridger
Image

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #15by Cham » 11.03.2007, 02:47

Here's a complement of scripts, and a small mystery (to me) :

Two separate scripts to mark in blue ALL spirals (S and SB alike), and another one to mark all Irr and Elliptical in orange :

http://nho.ohn.free.fr/celestia/Cham/mark_galaxies2.zip

In all the 10609 galaxies marked in both scripts, there is a total of 2135 elliptical and Irr galaxies, and a total of 8474 spirals (S and SB). This gives exactly 20.1% Irr and elliptical, and 79.9% spirals. Then, for a long time, I believed that most galaxies out there were elliptical giant galaxies. Was I wrong ? Heee, what's up doc !?
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

ElChristou
Developer
Posts: 3776
Joined: 04.02.2005
With us: 19 years 9 months

Post #16by ElChristou » 11.03.2007, 03:05

Many Tx! I go for a try right now... :D
Image

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #17by Cham » 11.03.2007, 04:20

LOL,

I just found an extremelly easy way to make a full script to mark all object types with a different colors. I should have thought about it at first, sheesh ! :oops:

I'll do it later and be back with it.
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #18by Cham » 11.03.2007, 04:37

Done ! 8)

http://nho.ohn.free.fr/celestia/Cham/deepsky.cel.zip (40 KB zip file)

This script will mark with a different color ALL object classes from the deepsky.dsc database (10609 objects, excluding the Milky Way).

In orange : all the E galaxies (1706 objects)
In yellow : all the Irr galaxies (429 objects)
In blue : all the S galaxies (6093 objects)
In green : all the SB galaxies (2381 objects).

It's pretty nice to look at, and it looks like some modern experiments in particle physics labs ! :wink:

Enjoy !
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"

Johaen
Posts: 341
Joined: 14.01.2006
With us: 18 years 9 months
Location: IL, USA

Post #19by Johaen » 11.03.2007, 04:56

Cham wrote:It's pretty nice to look at, and it looks like some modern experiments in particle physics labs ! :wink:


It's also just plain pretty, imo. :)
AMD Athlon X2 4400+; 2GB OCZ Platinum RAM; 320GB SATA HDD; NVidia EVGA GeForce 7900GT KO, PCI-e, 512MB, ForceWare ver. 163.71; Razer Barracuda AC-1 7.1 Gaming Soundcard; Abit AN8 32X motherboard; 600 watt Kingwin Mach1 PSU; Windows XP Media Center SP2;

Avatar
Topic author
Cham M
Posts: 4324
Joined: 14.01.2004
Age: 60
With us: 20 years 9 months
Location: Montreal

Post #20by Cham » 11.03.2007, 07:46

Here's a nice view, in the world of markers :

Image

Pulsars shown in our galaxy, galaxies shown on the background, Messiers objects in squares, etc. All this in full 3D ! :mrgreen:
"Well! I've often seen a cat without a grin", thought Alice; "but a grin without a cat! It's the most curious thing I ever saw in all my life!"


Return to “Scripting”