How can I solve for six variable using six equations using the Optimization toolbox such that the variables are between 1 and 0?

15 ビュー (過去 30 日間)
ConstStr
N7 = 3.135E+00*N1*N2,
N8 = 4.100E-01*N2*N6,
N9 = 1.381E+01*N1*N4,
N10 = 7.610E+01*N2^2*N3,
N11 = 1.720E+05*N2*N3^2*N5^3,
N12 = 4.034E+04*N3*N5^2,
N13 = 2.615E+04*N2*N3^2*N5^2,
N14 = 3.826E+44*N1*N3*N5^2,
N15 = 1.458E+03*N2*N3*N5,
N16 = 2.435E+04*N1*N3^2*N5,
N17 = 1.186E+08*N3^2*N5^3,
N18 = 7.511E+02*N3*N5,
N19 = 6.874E+02*N3*N5;
Function
N1+N2+N3+N4+N5+N6+N7+N8+N9+N10+N11+N12+N13+N14+N15+N16+N17+N18+N19 = 1;
0.1962*(N2+N7+N8+2*N10+N11+N13+N15)-0.6575*(N1+N7+N9+N14+N16) = 0;
0.0557*(N3+N10+2*N11+N12+2*N13+N14+N15+2*N16+2*N17+N18+N19)-0.4698*(N4+N9) = 0;
0.0099*(N5+3*N11+2*N12+2*N13+2*N14+N15+N16+3*N17+N18+N19)-0.3525*(N6+N8) = 0;
0.0557*(N1+N7+N9+N14+N16)-0.1962*(N4+N9) = 0;
0.0099*(N2+N7+N8+2*N10+N11+N13+N15)-0.6575*(N6+N8) = 0;
  2 件のコメント
TAHMEED TASNIM
TAHMEED TASNIM 2020 年 10 月 1 日
I wish to find the values of N1, N2, N3, N4, N5 and N6 within 0 and 1
Alex Sha
Alex Sha 2024 年 10 月 11 日
Looks like the code of 1stOpt, easy to get the results below:
n1: 0.0102966514928505
n2: 0.239882301416368
n3: 0.0756391320164553
n4: 0.067590437058481
n5: 9.05432951887928E-22
n6: 0.0124929422699874

サインインしてコメントする。

回答 (1 件)

Abhisek Pradhan
Abhisek Pradhan 2020 年 10 月 5 日
編集済み: Abhisek Pradhan 2020 年 10 月 5 日
The following link has a detailed documentation and solved example of non-linear system of equations using Optimization Toolbox.

カテゴリ

Help Center および File ExchangeDirect Search についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by