165件ヒット
[101-165件を表示]
(0.230秒)
検索結果
先頭5件
-
Complex
# / (other) -> Complex (8010.0) -
商を計算します。
...商を計算します。
@param other 自身を割る数
//emlist[例][ruby]{
Complex(10.0) / 3 # => (3.3333333333333335+(0/1)*i)
Complex(10) / 3 # => ((10/3)+(0/1)*i)
//}
@see Numeric#quo... -
Complex
# angle -> Float (8010.0) -
自身の偏角を[-π,π]の範囲で返します。
...ruby]{
Complex.polar(3, Math::PI/2).arg # => 1.5707963267948966
//}
非正の実軸付近での挙動に注意してください。以下の例のように虚部が 0.0 と
-0.0 では値が変わります。
//emlist[例][ruby]{
Complex(-1, 0).arg #=> 3.141592653589793
Complex(-1, -......#=> 3.141592653589793
Complex(-1, -0.0).arg #=> -3.141592653589793
Complex(0, 0.0).arg #=> 0.0
Complex(0, -0.0).arg #=> -0.0
Complex(-0.0, 0).arg #=> 3.141592653589793
Complex(-0.0, -0.0).arg #=> -3.141592653589793
//}
@see Numeric#arg... -
Complex
# arg -> Float (8010.0) -
自身の偏角を[-π,π]の範囲で返します。
...ruby]{
Complex.polar(3, Math::PI/2).arg # => 1.5707963267948966
//}
非正の実軸付近での挙動に注意してください。以下の例のように虚部が 0.0 と
-0.0 では値が変わります。
//emlist[例][ruby]{
Complex(-1, 0).arg #=> 3.141592653589793
Complex(-1, -......#=> 3.141592653589793
Complex(-1, -0.0).arg #=> -3.141592653589793
Complex(0, 0.0).arg #=> 0.0
Complex(0, -0.0).arg #=> -0.0
Complex(-0.0, 0).arg #=> 3.141592653589793
Complex(-0.0, -0.0).arg #=> -3.141592653589793
//}
@see Numeric#arg... -
Complex
# phase -> Float (8010.0) -
自身の偏角を[-π,π]の範囲で返します。
...ruby]{
Complex.polar(3, Math::PI/2).arg # => 1.5707963267948966
//}
非正の実軸付近での挙動に注意してください。以下の例のように虚部が 0.0 と
-0.0 では値が変わります。
//emlist[例][ruby]{
Complex(-1, 0).arg #=> 3.141592653589793
Complex(-1, -......#=> 3.141592653589793
Complex(-1, -0.0).arg #=> -3.141592653589793
Complex(0, 0.0).arg #=> 0.0
Complex(0, -0.0).arg #=> -0.0
Complex(-0.0, 0).arg #=> 3.141592653589793
Complex(-0.0, -0.0).arg #=> -3.141592653589793
//}
@see Numeric#arg... -
Complex
# quo(other) -> Complex (8010.0) -
商を計算します。
...商を計算します。
@param other 自身を割る数
//emlist[例][ruby]{
Complex(10.0) / 3 # => (3.3333333333333335+(0/1)*i)
Complex(10) / 3 # => ((10/3)+(0/1)*i)
//}
@see Numeric#quo... -
Complex
# real? -> false (8010.0) -
常に false を返します。
...常に false を返します。
//emlist[例][ruby]{
(2+3i).real? # => false
(2+0i).real? # => false
//}
@see Numeric#real?...