How can I solve a problem with subs?
1 次查看(过去 30 天)
显示 更早的评论
I have to substitute values in a matrix with 20 variables. I substitute variable after variable using a for loop, but in some cases the matrix does not contain the variable the loop is substituting, and in these cases the problem is Matlab replaces the zeros in the matrix wiht the variable. For instance if I am trying to replace the symbolic variable u3 subs(mat,{u3},{0}) and the matrix does not contain u3,the result is that u3 will appear in the matrix positions which were originally 0.(If originally mat(10,10)=0, after substitution mat(10,10)=u3).
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Symbolic Math Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!