Included Modules

Class Index [+]

Quicksearch

When::Coordinates::Spatial

空間位置

Constants

DEGREE

Degree / Internal Location Unit(16”)

  (3600 を 2 の因数で割りつくした値を単位とする)
ECLIPTIC

黄道座標 (ecliptic coordinate system)

EQUATORIAL

赤道座標 (equatorial coordinate system)

HORIZONTAL

地平座標 (horizontal coordinate system)

CENTER

惑星中心の高度

Attributes

lat[R]

北緯を正とする緯度 / 16秒

  type : Numeric
long[R]

東経を正とする経度 / 16秒

  type : Numeric
alt[R]

高度 / m

  type : Numeric or 天体の中心(:Center)
datum[R]

座標系

  type : When::Ephemeris::Datum
ref[R]

参照

  type : URI

Public Instance Methods

_coords(t) click to toggle source

観測地の日心三次元座標(黄道座標)

   t : ユリウス日(Terrestrial Time)または(Temporal)Positionオブジェクト
      # File when/coordinates.rb, line 1493
1493:     def _coords(t)
1494:       t   = +t
1495:       @datum._coords(t) + _coords_diff(t)
1496:     end
horizon() click to toggle source

観測地の地平線の天頂角

      # File when/coordinates.rb, line 1471
1471:     def horizon
1472:       return 0.25 if (@alt <= 0)
1473:       r = obserber_distance
1474:       asin((1.0+@datum.air[1]*@alt/(@datum.air[2]*@alt+r))*r/(r+@alt))/CIRCLE
1475:     end
local_sidereal_time(t) click to toggle source

観測地の地方恒星時 / 時を返します。

  t : ユリウス日(Terrestrial Time)または(Temporal)Positionオブジェクト
      # File when/coordinates.rb, line 1481
1481:     def local_sidereal_time(t)
1482:       t = +t
1483:       c = julian_century_from_2000(t)
1484:       (@datum.sid[0] + c * (@datum.sid[1] + c * @datum.sid[2]) +
1485:        (cosd(obl(c)) * delta_p(c) + @long/DEGREE) / 15         +
1486:        (t % 1) * 24)
1487:     end
obserber_distance() click to toggle source

観測地の地心距離 / kmを返します。

      # File when/coordinates.rb, line 1465
1465:     def obserber_distance
1466:       l = PI / (90 * DEGREE) * @long
1467:       @datum.r * (@datum.shape[0]+@datum.shape[1]*cos(l)+@datum.shape[2]*cos(2*l))
1468:     end

Private Instance Methods

_coords_diff(t, system=ECLIPTIC) click to toggle source

観測地の惑星中心を原点とする三次元座標

   t      : ユリウス日(Terrestrial Time)または(Temporal)Positionオブジェクト
   system : 座標系
     ECLIPTIC   = 黄道座標
     EQUATORIAL = 赤道座標
     HORIZONTAL = 地平座標
      # File when/coordinates.rb, line 1547
1547:     def _coords_diff(t, system=ECLIPTIC)
1548:       return Coordinates.polar(0,0,0) if alt == Center
1549:       t   = +t
1550:       lat = @lat / DEGREE
1551:       coords = Coordinates.polar(
1552:                         local_sidereal_time(t) /  24.0,
1553:          (lat + @datum.shape[3] * sind(2*lat)) / 360.0,
1554:                     (obserber_distance + @alt) /   AU)
1555:       case system
1556:       when ECLIPTIC   ; coords.r_to_y(t, @datum)
1557:       when EQUATORIAL ; coords
1558:       when HORIZONTAL ; coords.r_to_h(t, self)
1559:       end
1560:     end
method_missing(name, *args, &block) click to toggle source

その他のメソッド

  When::Coordinates::Spatial で定義されていないメソッドは
  処理を @datum (type: When::Ephemeris::Datum) に委譲する
      # File when/coordinates.rb, line 1566
1566:     def method_missing(name, *args, &block)
1567:       @datum.send(name.to_sym, self, *args, &block)
1568:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.