请问分段函数,该如何编写。
Mostra commenti meno recenti
比如这里面的Cw=350, Ww=40,I是已知矩阵
那么Cw-Ww/2=330 Cw+Ww=350
其中Im是要得出的矩阵 I作为一个矩阵变量 也就是说让I中矩阵所有的数 每个都做一次运算 然后根据分段函数 得出 矩阵Im 请问如何编程 不剩感激
直接我写的是
I(I<=40)=0
I (I>=350) =255
但是中间那个以矩阵作为变量的矩阵就不会写了 虚心请教大神!!

Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Creating and Concatenating Matrices in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!