distributed.speye
分散スパース単位行列を作成する
構文
DS = distributed.speye(n)
DS = distributed.speye(m,n)
DS = distributed.speye([m,n])
DS = distributed.speye(___,typename)
説明
DS = distributed.speye(n) は、基になるクラスが double である n 行 n 列のスパース分散単位行列を作成します。
DS = distributed.speye(m,n) または DS = distributed.speye([m,n]) は、基になるクラスが double である m 行 n 列のスパース分散単位行列を作成します。
DS = distributed.speye(___,typename) は、前述の構文のいずれかのデータ型 (クラス) も指定します。typename の入力値は "single" または "double" です。 (R2025a 以降)
例
1000 行 1000 列の分散スパース単位行列を作成します。
N = 1000; DS = distributed.speye(N);
400 行 800 列で単精度のスパース単位行列を作成します。
DS = distributed.speye(400,800,"single");