How to calculate the position of stars

In summary, the software creates a star map by taking into account a user's location and time, and calculating the altitude and azimuth of a star. The program stellarium is a free app that may help with this process.
  • #1
zackola
3
0
Hi all, hope everyone is doing well this rainy cold night. Hopefully it's not like that wherever you are. Anyhow - I hope someone can help me out.

I'm writing some software for a mobile device to create star maps. I've gotten pretty far into it. I'm using data from the Yale bright star catalog that has the right ascension and declination of stars, then taking into account a users local time/date and geographic location (using the gps on the device), and from that info, calculating MST (mean sidereal time) and using that calculating what the Altitude and Azimuth of a star should be from your observation point on Earth. I've verified my calculations of alt + az are correct using some static star charts, but what I'm wrestling with now is how to map the star onto a plane in order to display it in on a screen, with minimal distortion.

Right now, I'm using a simple map to put stars onto the 2d drawing surface. So, if for example my intended vertical and horizontal FOVs are 90 degrees, I want to only display stars with an Altitude 0-90 (0 being the local horizon) and I can easily figure out that:

Altitude / verticalFOV = y / heightOfScreen
Azimuth / 360 / horizontalFOV = x / widthOfScreen

The problem arises as Altitude approaches the zenith (90) and because of this very linear mapping, the distances between the stars on screen is stretched and warped (makes drawing of constellations look pretty dumb).

Anyhow, anyone know any way to project a star's location to 2d space given it's altitude and azimuth that minimizes the distortion at the zenith? Welcome to hear about any other ways of calculating or doing this type of thing. Many thanks in advance!
 
Astronomy news on Phys.org
  • #2
Have you had a look at the program stellarium? Its free to download and might give you some ideas. Sorry I can't be of more help.

P.S. I have been waiting for an application to arrive like this for my iphone, makes perfect sense with the GPS facility. Will this app be available for iphone?
 
  • #3
Hi! I did find Stellarium, thanks. They are doing things in a much more 3d way than I had anticipated, but the good news is that plain old polar coordinates are working out pretty well for me.

The good news for you is that there are already several iPhone apps like this:

http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=295430577&mt=8

and

http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=284408099&mt=8

Haven't used either, but they look cool. Later
 
  • #4
It is a general problem of mapping a large sphere onto a small rectangle.
Obvious solutions are to show the pole in the centre, but this wastes screen space, show north/east/south/west views but this goes wrong at the pole

Could you use the tilt sensor to show a smaller window that changes as you raise the device (so the tilt becomes the azimuth) - the unit would then be simple window onto the stars in front of you?
The GPS might not be good enough to give you the compass heading.
 
  • #5
Thanks mgb_phys,

That's a pretty good idea too. The tilt sensor and compass are sensitive enough to do what you suggest. I'm already getting the compass heading and using that. (There's a digital compass in the device, don't need the gps for that) I think maybe a 30 degree swath of altitude might look pretty good on the device...Food for thought...
 
  • #6
Translating star charts into what you see in the sky is difficult with paper charts.
People have tried printing them reversed so looking down is the same as looking up.
Holding them up at arms length is tricky.

A phone screen that you could hold up in front of you and became effectively a Head Up Display with star names could be interesting. You would set the scale for the screen size held a comfortable distance (8-12") in front of you.
 

1) How do I calculate the position of stars?

To calculate the position of stars, you will need to know their right ascension and declination coordinates. These are similar to longitude and latitude coordinates on Earth. Right ascension is measured in hours, minutes, and seconds, while declination is measured in degrees, minutes, and seconds. These coordinates can be found in star catalogs or through online databases.

2) What is the difference between apparent and absolute position of stars?

The apparent position of a star is its location as seen from Earth, taking into account the effects of our planet's rotation and orbit. The absolute position of a star is its location in the universe, independent of Earth's perspective. This is determined by taking into account the star's distance and its motion through space.

3) How do I correct for Earth's rotation when calculating star positions?

To correct for Earth's rotation, you will need to know your location on Earth, the date and time you are observing, and the star's right ascension and declination coordinates. Using this information, you can calculate the star's position at the center of the Earth, and then adjust for your specific location on the planet.

4) What is parallax and how does it affect star positions?

Parallax is the apparent shift in position of a nearby object when viewed from different perspectives. In the case of stars, parallax is caused by Earth's orbit around the Sun. This effect is used to measure the distance to nearby stars, and must be taken into account when calculating their positions.

5) Can I use a telescope to calculate the position of stars?

Yes, a telescope can be used to calculate the position of stars. By using a star chart, you can identify the right ascension and declination coordinates of the star you are observing. You can also use a computerized telescope or star tracker to automatically calculate and display the coordinates of the stars you are viewing.

Similar threads

Replies
1
Views
2K
Replies
4
Views
6K
  • Astronomy and Astrophysics
Replies
1
Views
2K
  • Astronomy and Astrophysics
Replies
6
Views
2K
  • Astronomy and Astrophysics
Replies
2
Views
3K
  • Astronomy and Astrophysics
Replies
4
Views
11K
  • Astronomy and Astrophysics
Replies
2
Views
1K
Replies
1
Views
4K
Replies
1
Views
2K
  • Introductory Physics Homework Help
Replies
11
Views
3K
Back
Top