Using fzero to keep tolerance within limits
古いコメントを表示
I would like to get the value of f to zero with Th value changing. Th is my initial guess. Something similar to goalseek in excel. My objective function is x-y which is to be made to zero by changing the value of Th. The error is "FUN must be a function, a valid string expression, or an inline function object." I think using fzero would be easier rather than to write a code for bisection method. Right?
Th=10;
x=100*((0.15*70/Th)-(0.5*0.75));
y=6.205;
f = x-y;
z = fzero(f,Th);
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Get Started with Optimization Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!