how to run optimisation problem
古いコメントを表示
Hello!
How can I run such kind of optimization :
max Q subject to x = x1,..., xn, where = Rp / σp
and constraints :
Rp = R' * x
σp^2 =x' * Σ * x
sum(x) = 1
Can someone help me about how to write down my objective function ...and the rest of the constraints. What type of sover I need to use ?
Best regards,
2 件のコメント
Walter Roberson
2019 年 3 月 21 日
I think part of the equations got lost?
What is Q?
You say "where = " but what needs to equal that?
Why do you say "subject to" and list variable names?
In Rp / op is that matrix division (least squared fitting) or is it element-by-element division ?
DAN TURMACU
2019 年 3 月 21 日
編集済み: DAN TURMACU
2019 年 3 月 21 日
採用された回答
その他の回答 (1 件)
Use fmincon with objective function
f = @(x)(R'*x)/sqrt(x'*sigma*x)
and linear constraint
Aeq = ones(size(x))
beq = 1
Best wishes
Torsten.
6 件のコメント
DAN TURMACU
2019 年 3 月 21 日
DAN TURMACU
2019 年 3 月 21 日
Walter Roberson
2019 年 3 月 21 日
Use the negative of your problem to search for the maximum.
DAN TURMACU
2019 年 3 月 21 日
Torsten
2019 年 3 月 21 日
f = @(x)-(R'*x)/sqrt(x'*sigma*x)
DAN TURMACU
2019 年 3 月 21 日
カテゴリ
ヘルプ センター および File Exchange で Surrogate Optimization についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!