How introduce column vector in M-file?
古いコメントを表示
how I improved my file to get { temp1<<1}, I am stuck here.
i gto sugestion to introduce column vector for temp0 but i am fail in this stage
7 件のコメント
Walter Roberson
2023 年 2 月 19 日
ket = sum(tmpI(:,2:D),2);
The sum over the second dimension of a 2d array is going to be a column vector.
temp0 = symsum(exp(-abs(alpha(k))^2 * alpha(k)^n / sqrt(factorial(n)) ), n, 0, 14)*ket;
symsum of a scalar expression is going to give a scalar result. You then multiply by the column vector, and that will give you a column vector result.
It therefore appears that your temp0 is already a column vector.
Abu Zar
2023 年 2 月 19 日
Abu Zar
2023 年 2 月 19 日
Image Analyst
2023 年 2 月 19 日
whos temp1
What does that show? Does it show many rows and 1 column?
Abu Zar
2023 年 2 月 19 日
Walter Roberson
2023 年 2 月 19 日
double() or vpa()
The exp() terms I tested were exp(-1e-9) to exp(-1e-15). Precision is low in that range but the values should be distinguishable from 1.
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Quantum Mechanics についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!



