View Single Post
  #4  
Old 16-12-2018, 01:31 PM
angelof (Angelo)
Registered User

angelof is offline
 
Join Date: Nov 2012
Location: newcastle australia
Posts: 14
Thanks. I worked it out with a little help
To get dec in degrees and ra in hours I did this


double dec = Math.asin(z) / Math.PI * 180;

double ra = (((Math.atan2(x, y) * 180 / Math.PI -90) * -1 / 360 * 24) + 24) % 24;

Thanks
Reply With Quote