ndims
動的システム モデルまたはモデル配列の次元数のクエリ
構文
n = ndims(sys)
説明
n = ndims(sys)
は動的システム モデルまたはモデル配列 sys
の次元数です。単一のモデルは、2 つの次元 (出力に 1 つ、入力に 1 つ) をもちます。配列は 2 + p 次元をもちます。ここで、p ≥ 2 は配列の次元数です。たとえば、2*3*4 配列のモデルは、2 + 3 = 5 の次元をもちます。
ndims(sys) = length(size(sys))
例
モデル配列の次元の特定
4 つの状態、1 つの入力、および 1 つの出力をもつ、ランダムな状態空間モデルの 3 行 1 列の配列を作成します。
sys = rss(4,1,1,3);
モデル配列の次元数を計算します。
ndims(sys)
ans = 4
次元数は 2+p です。ここで p は配列の次元数です。この例では、sys
が 3 行 1 列なので p は 2 になります。
バージョン履歴
R2006a より前に導入
参考
MATLAB コマンド
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)