353件ヒット
[1-100件を表示]
(0.089秒)
ライブラリ
- ビルトイン (353)
キーワード
- abs (12)
- abs2 (12)
- angle (12)
- arg (12)
- coerce (12)
- conjugate (12)
- denominator (12)
- fdiv (12)
- finite? (9)
- floor (1)
- imag (12)
- imaginary (12)
- magnitude (12)
- negative? (10)
- nonzero? (12)
- numerator (12)
- phase (12)
- polar (12)
- quo (12)
- real (12)
- real? (12)
- rectangular (12)
- remainder (12)
- step (81)
- truncate (12)
検索結果
先頭5件
-
Numeric
# abs -> Numeric (6101.0) -
自身の絶対値を返します。
...自身の絶対値を返します。
//emlist[例][ruby]{
12.abs #=> 12
(-34.56).abs #=> 34.56
-34.56.abs #=> 34.56
//}... -
Numeric
# abs2 -> Numeric (6101.0) -
自身の絶対値の 2 乗を返します。
...自身の絶対値の 2 乗を返します。
//emlist[例][ruby]{
2.abs2 # => 4
-2.abs2 # => 4
2.0.abs2 # => 4
-2.0.abs2 # => 4
//}
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。... -
Numeric
# angle -> 0 | Math :: PI (6101.0) -
自身の偏角(正の数なら 0、負の数なら Math::PI)を返します。
...自身の偏角(正の数なら 0、負の数なら Math::PI)を返します。
//emlist[例][ruby]{
1.arg # => 0
-1.arg # => 3.141592653589793
//}
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
@see Complex#arg... -
Numeric
# arg -> 0 | Math :: PI (6101.0) -
自身の偏角(正の数なら 0、負の数なら Math::PI)を返します。
...自身の偏角(正の数なら 0、負の数なら Math::PI)を返します。
//emlist[例][ruby]{
1.arg # => 0
-1.arg # => 3.141592653589793
//}
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
@see Complex#arg... -
Numeric
# denominator -> Integer (6101.0) -
自身を Rational に変換した時の分母を返します。
...自身を Rational に変換した時の分母を返します。
@return 分母を返します。
@see Numeric#numerator、Integer#denominator、Float#denominator、Rational#denominator、Complex#denominator... -
Numeric
# imag -> 0 (6101.0) -
常に 0 を返します。
...常に 0 を返します。
//emlist[例][ruby]{
12.imag # => 0
-12.imag # => 0
1.2.imag # => 0
-1.2.imag # => 0
//}
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
@see Numeric#real、Complex#imag... -
Numeric
# imaginary -> 0 (6101.0) -
常に 0 を返します。
...常に 0 を返します。
//emlist[例][ruby]{
12.imag # => 0
-12.imag # => 0
1.2.imag # => 0
-1.2.imag # => 0
//}
Numeric のサブクラスは、このメソッドを適切に再定義しなければなりません。
@see Numeric#real、Complex#imag... -
Numeric
# magnitude -> Numeric (6101.0) -
自身の絶対値を返します。
...自身の絶対値を返します。
//emlist[例][ruby]{
12.abs #=> 12
(-34.56).abs #=> 34.56
-34.56.abs #=> 34.56
//}... -
Numeric
# negative? -> bool (6101.0) -
self が 0 未満の場合に true を返します。そうでない場合に false を返します。
...self が 0 未満の場合に true を返します。そうでない場合に false を返します。
//emlist[例][ruby]{
-1.negative? # => true
0.negative? # => false
1.negative? # => false
//}
@see Numeric#positive?...