line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Astro::Montenbruck::Time::Sidereal; |
2
|
4
|
|
|
4
|
|
168905
|
use strict; |
|
4
|
|
|
|
|
14
|
|
|
4
|
|
|
|
|
114
|
|
3
|
4
|
|
|
4
|
|
20
|
use warnings; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
92
|
|
4
|
|
|
|
|
|
|
|
5
|
4
|
|
|
4
|
|
607
|
use Readonly; |
|
4
|
|
|
|
|
3988
|
|
|
4
|
|
|
|
|
187
|
|
6
|
4
|
|
|
4
|
|
24
|
use Exporter qw/import/; |
|
4
|
|
|
|
|
8
|
|
|
4
|
|
|
|
|
119
|
|
7
|
4
|
|
|
4
|
|
466
|
use Astro::Montenbruck::MathUtils qw/reduce_deg/; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
216
|
|
8
|
4
|
|
|
4
|
|
526
|
use Astro::Montenbruck::Time qw/jd_cent/; |
|
4
|
|
|
|
|
11
|
|
|
4
|
|
|
|
|
217
|
|
9
|
4
|
|
|
4
|
|
562
|
use Astro::Montenbruck::NutEqu qw/deltas obliquity/; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
850
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
our @EXPORT = qw/ramc/; |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
our $VERSION = 0.01; |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
Readonly::Scalar our $SOLAR_TO_SIDEREAL => 1.002737909350795; |
17
|
|
|
|
|
|
|
# Difference in between Sidereal and Solar hour (the former is shorter) |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub ramc { |
20
|
624
|
|
|
624
|
1
|
1369
|
my ( $jd, $lambda ) = @_; |
21
|
624
|
|
|
|
|
1659
|
my $t = jd_cent($jd); |
22
|
|
|
|
|
|
|
|
23
|
624
|
|
|
|
|
1782
|
my ($dpsi) = deltas($t); |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
# Correction for apparent S.T. |
26
|
624
|
|
|
|
|
1568
|
my $corr = $dpsi * cos( obliquity($t) ) / 3600; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
# Mean Local S.T. |
29
|
624
|
|
|
|
|
2376
|
my $result = |
30
|
|
|
|
|
|
|
280.46061837 + 360.98564736629 * ( $jd - 2451545 ) + 0.000387933 * $t * $t |
31
|
|
|
|
|
|
|
- $t**3 / 38710000 + $corr; |
32
|
|
|
|
|
|
|
|
33
|
624
|
|
|
|
|
1017
|
$result -= $lambda; |
34
|
624
|
|
|
|
|
1469
|
reduce_deg($result); |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
1; |
38
|
|
|
|
|
|
|
__END__ |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=pod |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=encoding UTF-8 |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
=head1 NAME |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
Astro::Montenbruck::Time::Sidereal - Sidereal time related calculations. |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=head1 VERSION |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
Version 0.01 |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head1 DESCRIPTION |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
Sidereal time related calculations. |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head1 EXPORT |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
=over |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=item * L</ramc($jd, $lambda)> |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
=back |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head1 SUBROUTINES/METHODS |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=head2 ramc($jd, $lambda) |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
Right Ascension of the Meridian |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=head3 Arguments |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=over |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=item * B<$jd> â Standard Julian Date. |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
=item * B<$lambda> â geographic longitude in degrees, negative for East |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=back |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=head3 Returns |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
Right Ascension of Meridian, arc-degrees |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=cut |