Manipulate Matrix Element using subscripts (ex: isprime(i-j)) or (i+j)>10)
1 回表示 (過去 30 日間)
古いコメントを表示
I need to create a oneline command to set a 'n x n' matrix to {1 if i-j isprime, 0 if not). I don't remember how to select an element in this manor. Thank you.
0 件のコメント
採用された回答
その他の回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Discrete Math についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!