Questions tagged [astronomy]

Astronomy is the study of celestial objects, such as planets, stars, and galaxies. Any astronomy question on this site should be programming related; other astronomy questions should be asked on our sister site Astronomy Stack Exchange.

Astronomy is the study of celestial objects, such as planets, stars, and galaxies. Any astronomy question on this site should be programming related; other astronomy questions should be asked on our sister site Astronomy Stack Exchange.

619 questions
4
votes
1 answer

Stacking star PSFs from an Image; aligning sub-pixel centers

I have an (1727,1853) size array (image), in which I have identified stars to model a point-spread function. Each index of the array corresponds to an image coordinate, however, the centroid of each star is given by a sub-pixel coordinate. I must…
4
votes
1 answer

Fitting an ellipse through orbital data

I've generated a bunch of data for the (x,y,z) coordinates of a planet as it orbits around the Sun. Now I want to fit an ellipse through this data. What I tried to do: I created a dummy ellipse based on five parameters: The semi-major axis &…
SubTachyon
  • 43
  • 5
4
votes
2 answers

Is it possible to make a correlation between an image and a constellation?

What I'm trying to do is to create a relation between an image which has been taken by a mobile phone and a constellation. Let's suppose I've been given the whole coordinates of each constellations from NASA and I can recognize some specified…
Mustafa Güven
  • 15,526
  • 11
  • 63
  • 83
4
votes
1 answer

Getting latitude and longitude of the Sun on a world map with PyEphem

I'm trying to determine the latitude and longitude of say the Sun, the Moon and Mars. I need the result relative to the Earth's equator and the Prime Meridian in order to produce a result similar to this map. I believe that's also what the author of…
trehn
  • 381
  • 2
  • 7
4
votes
1 answer

Visualisation of star catalogues and celestial coordinates

Does anyone have a suggested methodology for visualising the data in a star catalogue such as the Bright Star Catalogue. I'm thinking that there would be a notional sphere and a viewpoint i.e. at the center of that sphere with two vectors…
acheo
  • 3,106
  • 2
  • 32
  • 57
4
votes
1 answer

Position of the sun given time of day, latitude and longitude in php

This is a php implementation of Josh r code to calculate the position of the sun for a given date and time : This is the corrected code after MvG help : function getSunPosition($lat, $long, $year, $month, $day, $hour, $min) { // From…
iero
  • 401
  • 3
  • 14
4
votes
3 answers

pyEphem - Calculating Positions of non-Earthy Moons

I'm trying to get the Earth distance and the right ascension (relative to my observer point in Earth) of a satellite not orbiting the Earth, but pyEphem isn't returning the same properties as other solar bodies. With Ganymede (the largest moon of…
Alix Axel
  • 151,645
  • 95
  • 393
  • 500
4
votes
1 answer

Python satellite tracking with spg4, pyephem - positions not matching

I'm trying to write a basic python scrip that will track a given satellite, defined with tle's, from a given location. I'm not a asto/orbital person but am trying to become smarter on it. I am running into a problem where the different models I'm…
user2084330
4
votes
1 answer

matplotlib heatmap reversing data?

This is a weird one, hope someone can help me. I'm trying to do a density plot of my data with matplotlib heatmap, but somehow my data is getting reversed/rotated in a strange way. I have a scatterplot and then I'm binning those points for…
Teachey
  • 549
  • 7
  • 18
4
votes
2 answers

How to slice up a numpy array with inequalities?

I've done my best to find a solution on my own but I'm just not turning up anything relevant. I've got some numpy arrays that are extracted from .tbl files (it's an astronomical table format that I'm extracting with atpy). There are about 25,000…
Teachey
  • 549
  • 7
  • 18
4
votes
6 answers

What is wrong with my gravity simulation?

As per advice given to me in this answer, I have implemented a Runge-Kutta integrator in my gravity simulator. However, after I simulate one year of the solar system, the positions are still off by cca 110 000 kilometers, which isn't acceptable. My…
corazza
  • 31,222
  • 37
  • 115
  • 186
4
votes
3 answers

Calculate longitude based on latitude and sunrise time?

I'm calculating the longitude of positions where the current sun altitude currently is ~0.0. This is done by iterating over a range of latitudes, calculating the time of sunrise at (0.0, latitude) and then calculate the longitude by multiplying the…
Izz ad-Din Ruhulessin
  • 5,955
  • 7
  • 28
  • 28
4
votes
2 answers

pyephem conversion of (Alt, Az) to (Ra, Dec) and back not internally consistent

I am finding that when I convert an (Alt, Az) to an (Ra, Dec) and then back with PyEphem, I don't get what I started with. Below is a simple example. import ephem print ephem.__version__ # '3.7.3.4' gbt = ephem.Observer() gbt.long =…
kiyo
  • 1,929
  • 1
  • 18
  • 22
4
votes
1 answer

How to compute (alt, az) for given Galactic coordinate (GLON, GLAT) with PyEphem?

For a given observer (lon, lat, time) on Earth and a given Galactic coordinate (GLON, GLAT), how can I compute the corresponding (alt, az) point in the sky with PyEphem?
Christoph
  • 2,790
  • 2
  • 18
  • 23
4
votes
2 answers

PyEphem Angle Clarification

I'd just like to make sure I understand what PyEphem is doing with angles. Let's say I have an observer at 30° S, 60° W looking at the sky today at noon. So I do: obs = ephem.Observer() obs.lat, obs.lon = '-30', '-60' obs.date = '2012/6/22…
user1475412
  • 1,659
  • 2
  • 22
  • 30