ライブラリ
- matrix (22)
キーワード
- == (1)
- antisymmetric? (1)
-
cofactor
_ expansion (1) - combine (1)
- diagonal? (1)
- empty? (1)
- eql? (1)
- hermitian? (1)
-
laplace
_ expansion (1) -
lower
_ triangular? (1) - normal? (1)
- orthogonal? (1)
- permutation? (1)
- real? (1)
- regular? (1)
- singular? (1)
-
skew
_ symmetric? (1) - square? (1)
- symmetric? (1)
- unitary? (1)
-
upper
_ triangular? (1) - zero? (1)
検索結果
先頭5件
-
Matrix
# combine(*matrices) {|*elements| . . . } -> Matrix (28207.0) -
要素ごとにブロックを呼び出した結果を組み合わせた Matrix を返します。
...要素ごとにブロックを呼び出した結果を組み合わせた Matrix を返します。
Matrix.combine(self, *matrices) { ... } と同じです。
@see Matrix.combine... -
Matrix
# antisymmetric? -> bool (27997.0) -
行列が反対称行列 (交代行列、歪〔わい〕対称行列とも) ならば true を返します。
...@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します
//emlist[][ruby]{
require 'matrix'
Matrix[[0, -2, Complex(1, 3)], [2, 0, 5], [-Complex(1, 3), -5, 0]].antisymmetric? # => true
Matrix.empty.antisymmetric? # => true
Matrix[[1, 2, 3], [4, 5, 6]......, [7, 8, 9]].antisymmetric? # => false
# 対角要素が違う
Matrix[[1, -2, 3], [2, 0, 6], [-3, -6, 0]].antisymmetric? # => false
# 符号が違う
Matrix[[0, 2, -3], [2, 0, 6], [-3, 6, 0]].antisymmetric? # => false
//}... -
Matrix
# skew _ symmetric? -> bool (27997.0) -
行列が反対称行列 (交代行列、歪〔わい〕対称行列とも) ならば true を返します。
...@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します
//emlist[][ruby]{
require 'matrix'
Matrix[[0, -2, Complex(1, 3)], [2, 0, 5], [-Complex(1, 3), -5, 0]].antisymmetric? # => true
Matrix.empty.antisymmetric? # => true
Matrix[[1, 2, 3], [4, 5, 6]......, [7, 8, 9]].antisymmetric? # => false
# 対角要素が違う
Matrix[[1, -2, 3], [2, 0, 6], [-3, -6, 0]].antisymmetric? # => false
# 符号が違う
Matrix[[0, 2, -3], [2, 0, 6], [-3, 6, 0]].antisymmetric? # => false
//}... -
Matrix
# lower _ triangular? -> bool (27907.0) -
行列が下三角行列ならば true を返します。
行列が下三角行列ならば true を返します。 -
Matrix
# symmetric? -> bool (27907.0) -
行列が対称ならば true を返します。
...行列が対称ならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# upper _ triangular? -> bool (27907.0) -
行列が上三角行列ならば true を返します。
行列が上三角行列ならば true を返します。 -
Matrix
# cofactor _ expansion(row: nil , column: nil) -> object | Integer | Rational | Float (18925.0) -
row 行、もしくは column 列に関するラプラス展開をする。
...けです。かわりにMatrix#determinant を
利用すべきです。
変則的な形状の行列に対してはそれ以上の意味を持ちます。例えば
row行/column列が行列やベクトルである場合には
//emlist[例][ruby]{
require 'matrix'
# Matrix[[7,6], [3,9]].laplace_expa......=> 45
Matrix[[Vector[1, 0], Vector[0, 1]], [2, 3]].laplace_expansion(row: 0) # => Vector[3, -2]
//}
@param row 行
@param column 列
@raise ArgumentError row と column を両方指定した、もしくは両方とも指定していない、場合に発生します
@raise ExceptionForMatrix::ErrD......imensionMismatch 行列が正方でない場合に発生します
@see Matrix#cofactor... -
Matrix
# empty? -> bool (18907.0) -
行列が要素を持たないならば true を返します。
...行列が要素を持たないならば true を返します。
要素を持たないとは、行数か列数のいずれかが0であることを意味します。
@see Matrix.empty... -
Matrix
# hermitian? -> bool (18907.0) -
行列がエルミートならば true を返します。
...行列がエルミートならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# orthogonal? -> bool (18907.0) -
行列が直交行列ならば true を返します。
...行列が直交行列ならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# permutation? -> bool (18907.0) -
行列が置換行列ならば true を返します。
...行列が置換行列ならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# unitary? -> bool (18907.0) -
行列がユニタリならば true を返します。
...行列がユニタリならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# laplace _ expansion(row: nil , column: nil) -> object | Integer | Rational | Float (10225.0) -
row 行、もしくは column 列に関するラプラス展開をする。
...けです。かわりにMatrix#determinant を
利用すべきです。
変則的な形状の行列に対してはそれ以上の意味を持ちます。例えば
row行/column列が行列やベクトルである場合には
//emlist[例][ruby]{
require 'matrix'
# Matrix[[7,6], [3,9]].laplace_expa......=> 45
Matrix[[Vector[1, 0], Vector[0, 1]], [2, 3]].laplace_expansion(row: 0) # => Vector[3, -2]
//}
@param row 行
@param column 列
@raise ArgumentError row と column を両方指定した、もしくは両方とも指定していない、場合に発生します
@raise ExceptionForMatrix::ErrD......imensionMismatch 行列が正方でない場合に発生します
@see Matrix#cofactor... -
Matrix
# ==(other) -> bool (9907.0) -
自分自身と other を比較し、同値であれば真(true)を返します。
自分自身と other を比較し、同値であれば真(true)を返します。
@param other 比較対象のオブジェクト -
Matrix
# eql?(other) -> bool (9907.0) -
自分自身と other を比較し、同値であれば真(true)を返します。
自分自身と other を比較し、同値であれば真(true)を返します。
@param other 比較対象のオブジェクト -
Matrix
# regular? -> bool (9679.0) -
行列が正方で正則なら true を、特異なら false を返します。
...例外 ExceptionForMatrix::ErrDimensionMismatch を
発生させます。
//emlist[例][ruby]{
require 'matrix'
a1 = [ 1, 2, 3]
a2 = [10, 15, 20]
a3 = [-1, -2, 1.5]
m = Matrix[a1, a2, a3]
p m.regular? # => true
a1 = [ 1, 2, 3]
a2 = [10, 15, 20]
a3 = [-1, -2, -3]
m = Matrix[a1, a2, a3]
p m.re......gular? # => false
a1 = [ 1, 2, 3]
a2 = [10, 15, 20]
a3 = [-1, -2, 1.5]
a4 = [1, 1, 1]
m = Matrix[a1, a2, a3, a4]
p m.regular? # => raise ExceptionForMatrix::ErrDimensionMismatch
//}
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# diagonal? -> bool (9607.0) -
行列が対角行列ならば true を返します。
...行列が対角行列ならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# normal? -> bool (9607.0) -
行列が正規行列ならば true を返します。
...行列が正規行列ならば true を返します。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# real? -> bool (9607.0) -
行列の全要素が実(Numeric#real?)であれば true を返します。
...が0でも偽を返します。
//emlist[例][ruby]{
require 'matrix'
Matrix[[1, 0], [0, 1]].real? # => true
Matrix[[Complex(0, 1), 0], [0, 1]].real? # => false
# 要素が実数であっても Complex オブジェクトなら偽を返す。
Matrix[[Complex(1, 0), 0], [0, 1]].real? # => false
//}... -
Matrix
# singular? -> bool (9607.0) -
行列が正方で特異なら true を、正則なら false を返します。
...るとは、正則でないことです。
行列式が0であること同値です。
正方行列でない場合には例外 ExceptionForMatrix::ErrDimensionMismatch を
発生させます。
@raise ExceptionForMatrix::ErrDimensionMismatch 行列が正方行列でない場合に発生します... -
Matrix
# square? -> bool (9607.0) -
正方行列であるなら、 true を返します。
正方行列であるなら、 true を返します。 -
Matrix
# zero? -> bool (9607.0) -
行列が零行列ならば true を返します。
行列が零行列ならば true を返します。