Numerical simulation with symbolic expressions

4 ビュー (過去 30 日間)
Nordine Bouchelia
Nordine Bouchelia 2022 年 6 月 8 日
回答済み: Torsten 2022 年 6 月 8 日
Hello, I’m a beginner with octave, never used, and I would like to compute some things.
I have long symbolic expressions and I would like to compute the output of the functions for a set of parameters included in the function which may vary between an interval.
for example I’d like to compute this function for the parameters which may range between an interval or else
thanks for your help,

回答 (1 件)

Torsten
Torsten 2022 年 6 月 8 日
syms gamma alpha b
expr = gamma^2*alpha + log(b);
expr = matlabFunction(expr,'Vars',[gamma alpha b]);
gamma = 0:0.1:1;
alpha = 2.0;
b = 5.0;
plot(gamma,expr(gamma,alpha,b))

カテゴリ

Help Center および File ExchangeSymbolic Math Toolbox についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by