lib/mk_coord/trigonometric.rb
def compute_lambda(alpha, delta, eps)
      a = Math.sin(delta) * Math.sin(eps) \
        + Math.cos(delta) * Math.sin(alpha) * Math.cos(eps)
      b = Math.cos(delta) * Math.cos(alpha)
      lambda = Math.atan2(a, b)
      lambda %= PI2 if lambda < 0
      return lambda
    rescue => e
      raise
    end
def compute_lambda(alpha, delta, eps)
      a = Math.sin(delta) * Math.sin(eps) \
        + Math.cos(delta) * Math.sin(alpha) * Math.cos(eps)
      b = Math.cos(delta) * Math.cos(alpha)
      lambda = Math.atan2(a, b)
      lambda %= PI2 if lambda < 0
      return lambda
    rescue => e
      raise
    end
def compute_lambda ( alpha , delta , eps ) a = Math . sin ( delta ) * Math . sin ( eps ) + Math . cos ( delta ) * Math . sin ( alpha ) * Math . cos ( eps ) b = Math . cos ( delta ) * Math . cos ( alpha ) lambda = Math . atan2 ( a , b ) lambda %= PI2 if lambda < 0 return lambda rescue => e raise end
=========================================================================
 λ の計算

 * λ = arctan((sinδ sinε + cosδ sinα cosε ) / cosδ cosα)

 @param:  alpha   (unit: rad)
 @param:  delta   (unit: rad)
 @param:  eps     (unit: rad)
 @return: lambda  (unit: rad)
=========================================================================
========================================================================= λ の計算