フィルターのクリア

implementing fmincon() when the variables are matrix

2 ビュー (過去 30 日間)
Susan
Susan 2019 年 4 月 29 日
編集済み: Susan 2019 年 4 月 29 日
Hey guys,
I want to implement fmincon() for this problem: I am minimizing an objective function with respect to some variables. the variable has the following format
X = cell(max(I(:)), numel(I), numel(I), numel(M), max(M(:)))) and inside each cell I have a Nt*Nr matrix. The goal is to find the optimal values of each matrix.
I defined the symbolic array of X (I am not sure if I am doing it correctly, though) and pass it to my objective function to calculate the objective function as follows:
X = cell2sym(cell(max(I(:)), numel(I), numel(I), numel(M), max(M(:))));
objfun = f(X)
but, I get the following error: Brace indexing is not supported for variables of this type.
while I am able to get the value of f(X0) without any issue. Could anyone please kindly explain what the problem is?
Thanks in advance

回答 (0 件)

カテゴリ

Help Center および File ExchangeSolver Outputs and Iterative Display についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by