500件ヒット
[201-300件を表示]
(0.017秒)
種類
- インスタンスメソッド (420)
- 文書 (39)
- クラス (22)
- ライブラリ (11)
- モジュール関数 (8)
モジュール
- Math (8)
キーワード
- -@ (11)
-
/ (21) -
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) -
NEWS for Ruby 2
. 1 . 0 (11) -
NEWS for Ruby 2
. 6 . 0 (6) - Ruby用語集 (11)
- abs (11)
- abs2 (11)
- angle (22)
- arg (22)
- conj (11)
- conjugate (11)
- denominator (11)
- fdiv (28)
- i (11)
- imag (22)
- imaginary (22)
- infinite? (8)
- magnitude (11)
- matrix (11)
- numerator (11)
- phase (22)
- polar (22)
- quo (22)
- real (22)
- real? (33)
- rect (22)
- rectangular (22)
- rsqrt (4)
- sqrt (4)
-
to
_ c (11)
検索結果
先頭5件
-
Numeric
# conjugate -> Numeric (21120.0) -
常に self を返します。
...常に self を返します。
自身が Complex かそのサブクラスのインスタンスの場合は、自身の共役複素数(実数の場合は常に自身)を返します。
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
//emli......st[例][ruby]{
10.conj # => 10
0.1.conj # => 0.1
(2/3r).conj # => (2/3)
//}
@see Complex#conj... -
Numeric
# real -> Numeric (21119.0) -
自身を返します。
...す。
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
//emlist[例][ruby]{
10.real # => 10
-10.real # => -10
0.1.real # => 0.1
Rational(2, 3).real # => (2/3)
//}
@see Numeric#imag、Complex#real... -
Complex
# imag -> Numeric (21114.0) -
自身の虚部を返します。
...自身の虚部を返します。
//emlist[例][ruby]{
Complex(3, 2).imag # => 2
//}
@see Numeric#imag... -
Complex
# imaginary -> Numeric (21114.0) -
自身の虚部を返します。
...自身の虚部を返します。
//emlist[例][ruby]{
Complex(3, 2).imag # => 2
//}
@see Numeric#imag... -
Complex
# real -> Numeric (21107.0) -
自身の実部を返します。
...自身の実部を返します。
//emlist[例][ruby]{
Complex(3, 2).real # => 3
//}... -
Numeric
# -@ -> Numeric (21107.0) -
単項演算子の - です。 self の符号を反転させたものを返します。
...単項演算子の - です。
self の符号を反転させたものを返します。
このメソッドは、二項演算子 - で 0 - self によって定義されています。
@see Integer#-@、Float#-@、Rational#-@、Complex#-@... -
Complex
# angle -> Float (21054.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 (21054.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 (21054.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... -
Numeric
# real? -> bool (21034.0) -
常に true を返します。(Complex またはそのサブクラスではないことを意味します。)
...常に true を返します。(Complex またはそのサブクラスではないことを意味します。)
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
//emlist[例][ruby]{
10.real? # => true
-10.real? # =>......true
0.1.real? # => true
Rational(2, 3).real? # => true
//}
@see Numeric#integer?、Complex#real?...