NavList:
A Community Devoted to the Preservation and Practice of Celestial Navigation and Other Methods of Traditional Wayfinding
Re: Angular Distance Between Stars By Camera and Sextant
From: Paul Hirose
Date: 2012 Sep 17, 16:14 -0700
From: Paul Hirose
Date: 2012 Sep 17, 16:14 -0700
Greg Rudzinski wrote: > The Vega Deneb distance was made at UT 2:25:00 9/16/2012 from Lat. 34* 10.4' N Lon. 119* 13.8' W > The Alioth Alkaid distance was made at UT 3:05:00 > Temp. 72* F > Pressure 29.99 in. My computations say: 48°03.90' +82°47.50' Vega unrefracted az el 48°03.90' +82°47.62' Vega refracted 57°21.56' +59°03.90' Deneb unrefracted az el 57°21.56' +59°04.46' Deneb refracted 23°50.82' Vega to Deneb (unrefracted) 23°50.37' Vega to Deneb (refracted) 310°14.96' +34°06.86' Alkaid unrefracted az el 310°14.96' +34°08.24' Alkaid refracted 320°26.60' +28°18.99' Alioth unrefracted az el 320°26.60' +28°20.73' Alioth refracted 10°27.66' Alkaid to Alioth (unrefracted) 10°27.34' Alkaid to Alioth (refracted) C# source code to compute those values is included (one file, 20 k). For simplicity, the program does not interact with the user, except to display the output. All input data are embedded in the source code. The desired data are selected with preprocessor directives. The calculation is precise, with corrections for proper motion, parallax, radial velocity, aberration (including the diurnal component), light deflection due to the Sun's gravity, and refraction (including nonstandard pressure and temperature). In the source code are provisions to input polar motion and deflection of the vertical, but I've set those parameters to zero. Microsoft Visual Studio will compile and run the program. It should also run under the "Express" (free) version of Visual Studio, but I haven't tested that. http://www.microsoft.com/visualstudio/eng/downloads#d-2012-express The .NET Framework must be installed on your computer. Recent Windows versions already have it. Otherwise, you can download it for free. Finally, the .NET Framework version of my free SofaJpl astronomy DLL must be installed. http://home.earthlink.net/~s543t-24dst/sofajplNet/index.html -- ��/ / S e p A n g l e . c s / / W i n d o w s . N E T F r a m e w o r k c o n s o l e a p p t o c a l c u l a t e s e p a r a t i o n a n g l e / / b e t w e e n s t a r s . / / 2 0 1 2 S e p t 1 4 b y P a u l S . H i r o s e . / / T h i s s o u r c e c o d e i s i n t h e p u b l i c d o m a i n . / / T o c o m p i l e t h e p r o g r a m , t h e S o f a J p l f u n d a m e n t a l a s t r o n o m y D L L m u s t b e / / i n s t a l l e d o n y o u r s y s t e m , a n d a r e f e r e n c e t o S o f a J p l a d d e d t o t h e V i s u a l / / S t u d i o p r o j e c t . T o r u n t h e p r o g r a m , t h e S o f a J p l l e a p s e c o n d f i l e i s n e e d e d . / / I t m a y b e s t o r e d a n y c o n v e n i e n t p l a c e . T h e D L L a n d l e a p s e c o n d f i l e a r e / / f r e e a t h t t p : / / h o m e . e a r t h l i n k . n e t / ~ s 5 4 3 t - 2 4 d s t / s o f a j p l N e t / i n d e x . h t m l . u s i n g S y s t e m ; / / T h e S o f a J p l n a m e s p a c e i s a b b r e v i a t e d t o " S J " f o r c o n v e n i e n c e . u s i n g S J = H i r o s e P S . S o f a J p l ; n a m e s p a c e S e p A n g l e { c l a s s S e p A n g l e { s t a t i c v o i d M a i n ( s t r i n g [ ] a r g s ) { / / L o a d t h e l e a p s e c o n d t a b l e . s t r i n g l e a p S e c F i l e = @ " G : \ D o c u m e n t s a n d S e t t i n g s \ H i r o s e l i m i t e d \ " + @ " M y D o c u m e n t s \ a s t r o \ i e r s \ l e a p S e c T a b l e . t x t " ; S J . U t c . L o a d T a b l e F r o m F i l e ( l e a p S e c F i l e ) ; / / d a t e a n d t i m e ( U T C ) # i f t r u e S J . U t c u t c = n e w S J . U t c ( 2 0 1 2 , 9 , 1 6 , 2 , 2 5 , 0 . 0 ) ; # e l s e S J . U t c u t c = n e w S J . U t c ( 2 0 1 2 , 9 , 1 6 , 3 , 5 , 0 . 0 ) ; # e n d i f / / D e l t a T , c o m p u t e d f r o m T T - T A I ( a l w a y s 3 2 . 1 8 4 s ) , T A I - U T C ( 3 5 s , / / u n t i l n e x t l e a p s e c o n d ) , a n d U T 1 - U T C . / / A l l q u a n t i t i e s f r o m I E R S B u l l e t i n A . S J . D u r a t i o n d e l t a T = n e w S J . D u r a t i o n ( ( 3 2 . 1 8 4 + 3 5 . 0 - 0 . 3 8 9 8 8 ) / 8 6 4 0 0 . 0 ) ; / / T T a n d U T 1 S J . J u l i a n D a t e t t = u t c . T e r r e s t r i a l T i m e ; S J . J u l i a n D a t e u t 1 = t t - d e l t a T ; / / p o l a r m o t i o n ( r a d i a n s ) d o u b l e x P o l e = S J . A n g l e . D m s T o R a d ( 0 , 0 , 0 ) ; d o u b l e y P o l e = S J . A n g l e . D m s T o R a d ( 0 , 0 , 0 ) ; / / O b s e r v e r l a t / l o n ( r a d i a n s ) a n d h e i g h t ( m e t e r s ) d o u b l e l a t = S J . A n g l e . D m s T o R a d ( 3 4 , 1 0 . 4 , 0 ) ; d o u b l e l o n = S J . A n g l e . D m s T o R a d ( - 1 1 9 , 1 3 . 8 , 0 ) ; d o u b l e h e i g h t = 0 . 0 ; S J . G e o g r a p h i c P o s i t i o n o b s e r v e r = n e w S J . G e o g r a p h i c P o s i t i o n ( l a t , l o n , h e i g h t ) ; / / d e f l e c t i o n o f t h e v e r t i c a l ( r a d i a n s ) d o u b l e x i = S J . A n g l e . D m s T o R a d ( 0 , 0 , 0 ) ; d o u b l e e t a = S J . A n g l e . D m s T o R a d ( 0 , 0 , 0 ) ; / / a l t i m e t e r s e t t i n g ( m i l l i b a r s ) a n d t e m p e r a t u r e ( C ) d o u b l e m b = 2 9 . 9 9 * S J . A t m o s p h e r e . M i l l i b a r s P e r I n c h H g ; d o u b l e d e g C = ( 7 2 . 0 - 3 2 . 0 ) / 1 . 8 ; / / d e s i r e d a n g l e a c c u r a c y d o u b l e a c c u r a c y = S J . A n g l e . D m s T o R a d ( 0 , . 0 1 , 0 ) ; / / S e x a g e s i m a l d i s p l a y r e s o l u t i o n . 1 = 1 d e g r e e , 6 0 = 1 m i n u t e , / / 6 0 0 = . 1 m i n u t e , e t c . d o u b l e r e s o l u t i o n = 6 0 0 0 . 0 ; / / c o n s t a n t s c o n s t d o u b l e s e c s P e r D a y = 8 6 4 0 0 . 0 ; c o n s t d o u b l e d a y s P e r J Y = 3 6 5 . 2 5 ; c o n s t d o u b l e k m P e r A U = 1 . 4 9 5 9 7 8 7 0 7 e 8 ; / / E p o c h o f t h e s t a r c a t a l o g . S J . J u l i a n D a t e c a t a l o g E p o c h = S J . J u l i a n D a t e . J 2 0 0 0 B a s e ; / / C a t a l o g d a t a , f i r s t s t a r . # i f t r u e s t r i n g s t a r 1 N a m e = " V e g a " ; d o u b l e s t a r 1 R a = S J . A n g l e . H m s T o R a d ( 1 8 , 3 6 , 5 6 . 3 3 6 3 5 ) ; d o u b l e s t a r 1 D e c = S J . A n g l e . D m s T o R a d ( + 3 8 , 4 7 , 0 1 . 2 8 0 2 ) ; d o u b l e s t a r 1 P a r a l l a x = S J . A n g l e . D m s T o R a d ( 0 , 0 , 1 3 0 . 2 3 / 1 0 0 0 . 0 ) ; d o u b l e s t a r 1 R a P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , 2 0 0 . 9 4 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 1 D e c P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , 2 8 6 . 2 3 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 1 R a d V e l = - 1 3 . 9 * s e c s P e r D a y / k m P e r A U ; # e n d i f # i f f a l s e s t r i n g s t a r 1 N a m e = " A l k a i d " ; d o u b l e s t a r 1 R a = S J . A n g l e . H m s T o R a d ( 1 3 , 4 7 , 3 2 . 4 3 7 7 6 ) ; d o u b l e s t a r 1 D e c = S J . A n g l e . D m s T o R a d ( + 4 9 , 1 8 , 4 7 . 7 6 0 2 ) ; d o u b l e s t a r 1 P a r a l l a x = S J . A n g l e . D m s T o R a d ( 0 , 0 , 3 1 . 3 8 / 1 0 0 0 . 0 ) ; d o u b l e s t a r 1 R a P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , - 1 2 1 . 1 7 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 1 D e c P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , - 1 4 . 9 1 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 1 R a d V e l = - 1 0 . 9 * s e c s P e r D a y / k m P e r A U ; # e n d i f / / S e c o n d s t a r . # i f t r u e s t r i n g s t a r 2 N a m e = " D e n e b " ; d o u b l e s t a r 2 R a = S J . A n g l e . H m s T o R a d ( 2 0 , 4 1 , 2 5 . 9 1 5 1 4 ) ; d o u b l e s t a r 2 D e c = S J . A n g l e . D m s T o R a d ( + 4 5 , 1 6 , 4 9 . 2 1 9 7 ) ; d o u b l e s t a r 2 P a r a l l a x = S J . A n g l e . D m s T o R a d ( 0 , 0 , 2 . 3 1 / 1 0 0 0 . 0 ) ; d o u b l e s t a r 2 R a P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , 2 . 0 1 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 2 D e c P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , 1 . 8 5 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 2 R a d V e l = - 4 . 5 * s e c s P e r D a y / k m P e r A U ; # e n d i f # i f f a l s e s t r i n g s t a r 2 N a m e = " A l i o t h " ; d o u b l e s t a r 2 R a = S J . A n g l e . H m s T o R a d ( 1 2 , 5 4 , 0 1 . 7 4 9 5 9 ) ; d o u b l e s t a r 2 D e c = S J . A n g l e . D m s T o R a d ( + 5 5 , 5 7 , 3 5 . 3 6 2 7 ) ; d o u b l e s t a r 2 P a r a l l a x = S J . A n g l e . D m s T o R a d ( 0 , 0 , 3 9 . 5 1 / 1 0 0 0 . 0 ) ; d o u b l e s t a r 2 R a P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , 1 1 1 . 9 1 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 2 D e c P M = S J . A n g l e . D m s T o R a d ( 0 , 0 , - 8 . 2 4 / 1 0 0 0 . 0 ) / d a y s P e r J Y ; d o u b l e s t a r 2 R a d V e l = - 9 . 3 * s e c s P e r D a y / k m P e r A U ; # e n d i f / / S o u r c e s o f S u n a n d E a r t h p o s i t i o n a n d v e l o c i t y t o c o r r e c t f o r / / r e l a t i v i s t i c l i g h t d e f l e c t i o n , p a r a l l a x , a b e r r a t i o n . T h e / / a c c u r a c y o f t h e J P L e p h e m e r i d e s i s n o t n e e d e d , s o u s e t h e S O F A / / l o w a c c u r a c y r o u t i n e s . S J . S o f a E p h B o d y s u n = n e w S J . S o f a E p h B o d y ( S J . S o f a . B o d y . S u n , a c c u r a c y ) ; S J . S o f a E p h B o d y e a r t h = n e w S J . S o f a E p h B o d y ( S J . S o f a . B o d y . E a r t h , a c c u r a c y ) ; / / C r e a t e t w o S t a r o b j e c t s . S J . S t a r s t a r 1 = n e w S J . S t a r ( c a t a l o g E p o c h , s t a r 1 R a , s t a r 1 D e c , s t a r 1 P a r a l l a x , s t a r 1 R a P M , s t a r 1 D e c P M , s t a r 1 R a d V e l , s u n , e a r t h ) ; S J . S t a r s t a r 2 = n e w S J . S t a r ( c a t a l o g E p o c h , s t a r 2 R a , s t a r 2 D e c , s t a r 2 P a r a l l a x , s t a r 2 R a P M , s t a r 2 D e c P M , s t a r 2 R a d V e l , s u n , e a r t h ) ; / / R o t a t i o n m a t r i x , G C R S t o t h e I T R S . S J . R M a t r i x c r s T o T r s = S J . R M a t r i x . C r s T o T r s 0 6 a ( t t , u t 1 , x P o l e , y P o l e ) ; / / G C R S p o s i t i o n a n d v e l o c i t y o f o b s e r v e r . S J . P V V e c t o r o b s P V = o b s e r v e r . T o P V V e c t o r ( c r s T o T r s ) ; / / G C R S v e c t o r s t o t h e t o p o c e n t r i c a p p a r e n t p l a c e s o f t h e s t a r s . S J . V e c t o r b o d y 1 V e c = s t a r 1 . T o p o c e n t r i c A p p a r e n t ( t t , o b s P V ) ; S J . V e c t o r b o d y 2 V e c = s t a r 2 . T o p o c e n t r i c A p p a r e n t ( t t , o b s P V ) ; / / R o t a t e t h e c o o r d i n a t e s y s t e m f r o m t h e G C R S t o t h e I T R S . . . b o d y 1 V e c = c r s T o T r s * b o d y 1 V e c ; b o d y 2 V e c = c r s T o T r s * b o d y 2 V e c ; / / . . . t h e n f r o m t h e I T R S t o t h e l o c a l h o r i z o n t a l . S J . R M a t r i x t r s T o H o r = S J . R M a t r i x . T r s T o H o r ( l a t , l o n , x i , e t a ) ; b o d y 1 V e c = t r s T o H o r * b o d y 1 V e c ; b o d y 2 V e c = t r s T o H o r * b o d y 2 V e c ; / / C o n v e r t c o o r d s f r o m v e c t o r t o s p h e r i c a l . S J . S p h e r i c a l s p h 1 U n r e f = n e w S J . S p h e r i c a l ( b o d y 1 V e c ) ; S J . S p h e r i c a l s p h 2 U n r e f = n e w S J . S p h e r i c a l ( b o d y 2 V e c ) ; / / C r e a t e a n A t m o s p h e r e o b j e c t , u s e i t t o r e f r a c t t h e a l t i t u d e s t o / / t h e s p e c i f i e d a c c u r a c y . S J . A t m o s p h e r e a t m o s = n e w S J . A t m o s p h e r e ( h e i g h t , m b , d e g C ) ; d o u b l e a l t 1 R e f = a t m o s . R e f r a c t ( s p h 1 U n r e f . A l t , a c c u r a c y ) ; d o u b l e a l t 2 R e f = a t m o s . R e f r a c t ( s p h 2 U n r e f . A l t , a c c u r a c y ) ; / / R e - a s s e m b l e t h e r e f r a c t e d c o o r d i n a t e s i n t o n e w S p h e r i c a l o b j e c t s . / / T h e " T h e t a " p r o p e r t y m u s t b e u s e d b e c a u s e a z i m u t h d o e s n ' t o b e y / / t h e u s u a l c o n v e n t i o n s f o r s p h e r i c a l c o o r d i n a t e s . S J . S p h e r i c a l s p h 1 R e f = n e w S J . S p h e r i c a l ( s p h 1 U n r e f . T h e t a , a l t 1 R e f ) ; S J . S p h e r i c a l s p h 2 R e f = n e w S J . S p h e r i c a l ( s p h 2 U n r e f . T h e t a , a l t 2 R e f ) ; / / D i s p l a y u n r e f r a c t e d a n d r e f r a c t e d a z / a l t . C o n s o l e . W r i t e L i n e ( " { 0 } { 1 } u n r e f r a c t e d a z a l t " , a z A l t S t r i n g ( s p h 1 U n r e f , r e s o l u t i o n ) , s t a r 1 N a m e ) ; C o n s o l e . W r i t e L i n e ( " { 0 } { 1 } r e f r a c t e d a z a l t " , a z A l t S t r i n g ( s p h 1 R e f , r e s o l u t i o n ) , s t a r 1 N a m e ) ; C o n s o l e . W r i t e L i n e ( " \ n { 0 } { 1 } u n r e f r a c t e d a z a l t " , a z A l t S t r i n g ( s p h 2 U n r e f , r e s o l u t i o n ) , s t a r 2 N a m e ) ; C o n s o l e . W r i t e L i n e ( " { 0 } { 1 } r e f r a c t e d a z a l t " , a z A l t S t r i n g ( s p h 2 R e f , r e s o l u t i o n ) , s t a r 2 N a m e ) ; / / D i s p l a y u n r e f r a c t e d a n d r e f r a c t e d s e p a r a t i o n a n g l e s . C o n s o l e . W r i t e L i n e ( " \ n { 0 } { 1 } t o { 2 } ( u n r e f r a c t e d ) " , s e p A n g l e S t r i n g ( s p h 1 U n r e f , s p h 2 U n r e f , r e s o l u t i o n ) , s t a r 1 N a m e , s t a r 2 N a m e ) ; C o n s o l e . W r i t e L i n e ( " { 0 } { 1 } t o { 2 } ( r e f r a c t e d ) \ n " , s e p A n g l e S t r i n g ( s p h 1 R e f , s p h 2 R e f , r e s o l u t i o n ) , s t a r 1 N a m e , s t a r 2 N a m e ) ; } / / C o n v e r t a S p h e r i c a l o b j e c t t o s e x a g e s i m a l a z a n d a l t i n a / / s t r i n g w i t h s p e c i f i e d r e s o l u t i o n . s t a t i c s t r i n g a z A l t S t r i n g ( S J . S p h e r i c a l s p h , d o u b l e r e s o l u t i o n ) { d o u b l e a z = S J . A n g l e . R a d i a n s T o D e g r e e s ( s p h . A z ) ; d o u b l e a l t = S J . A n g l e . R a d i a n s T o D e g r e e s ( s p h . E l ) ; S J . S e x a g e s i m a l a z S e x = n e w S J . S e x a g e s i m a l ( a z , r e s o l u t i o n ) ; S J . S e x a g e s i m a l a l t S e x = n e w S J . S e x a g e s i m a l ( a l t , r e s o l u t i o n ) ; r e t u r n S t r i n g . F o r m a t ( " { 0 : 3 b � 2 3 } { 1 : + 2 b � 2 3 } " , a z S e x , a l t S e x ) ; } / / C o m p u t e s e p a r a t i o n a n g l e b e t w e e n t w o S p h e r i c a l o b j e c t s , c o n v e r t t o / / s t r i n g i n s e x a g e s i m a l f o r m a t w i t h s p e c i f i e d r e s o l u t i o n . s t a t i c s t r i n g s e p A n g l e S t r i n g ( S J . S p h e r i c a l s p h 1 , S J . S p h e r i c a l s p h 2 , d o u b l e r e s o l u t i o n ) { / / s e p a r a t i o n a n g l e d o u b l e s e p a r a t i o n = s p h 1 . S e p a r a t i o n A n g l e ( s p h 2 ) ; s e p a r a t i o n = S J . A n g l e . R a d i a n s T o D e g r e e s ( s e p a r a t i o n ) ; / / C o n v e r t d e g r e e s t o s e x a g e s i m a l a n d d i s p l a y . S J . S e x a g e s i m a l s e p a r a t i o n S e x = n e w S J . S e x a g e s i m a l ( s e p a r a t i o n , r e s o l u t i o n ) ; r e t u r n s t r i n g . F o r m a t ( " { 0 : b � 2 3 } " , s e p a r a t i o n S e x ) ; } } }
File: 120641.sepangle.cs