Esempio n. 1
0
 def test_should_compute_chesapeake( self ):
     """About 11d 0m W, (almost exactly -11) for 4/18/2012"""
     p1= LatLon( lat=Angle2.fromdegrees(37.8311, "N"), lon=Angle2.fromdegrees(76.2819, "W") )
     #print( "p1 = {0}".format( p1.dms ) )
     d= declination( p1, date=datetime.date(2012,4,18) )
     #print( "declination= {0}".format(d.dm) )
     self.assertAlmostEqual( -11, d.dm[0] )
Esempio n. 2
0
 def test_should_compute_equator( self ):
     """somewhere near -5d 50m for 4/18/2012"""
     p1= LatLon( lat=Angle2.fromstring("0.0N"), lon=Angle2.fromstring( "0.0E" ) )
     #print( "p1 = {0}".format( p1.dms ) )
     d= declination( p1, date=datetime.date(2012,4,18)  )
     #print( "declination= {0}".format(d.dm) )
     self.assertAlmostEqual( -5, d.dm[0] )
     self.assertTrue( 45 <= d.dm[1] <= 55 )