Plot two functions in one diagramm with different y-axis limits

2 次查看(过去 30 天)
Does someone know how i could solve the following Problem:
%x_1,...,x_7 are real valued Variables (which are generated before)
g = 0.5*x_1*(x_2*f_1-x_3*f_2)^2+x_4*f_1+x_5*f_2+x_6-x_7;
funct = solve(g,f_2,'Real',true,'ReturnConditions',true);
y_lim = [10,15];
syms f_1
assume(funct.conditions);
funct.f_2(isAlways(funct.f_2 < y_lim(1),Unknown="falseWithWarning")) = NaN;
funct.f_2(isAlways(funct.f_2 > y_lim(2),Unknown="falseWithWarning")) = NaN;
fplot(funct.f_2, [7,50] ,'Color', 'b');
So i want to plot the quadratic function "funct" in the y-Intervall [10,15] and x-Intervall [7,50] but i get the (4) Warnings:
Warning: Unable to prove '(423*f_1)/77 - (576460752303423488000000*(7353528183219767092002251709184784741/324518553658426726783156020576256000000 -
(907661965900503303521461870041895139*f_1)/16615349947311448411297588253504307200000)^(1/2))/18611613717480648557 -
86464670358732992000000/18611613717480648557 < 10'.
> In symengine
In sym/isAlways (line 41)
So the function gets plottet and the x-Interval is respected, but not the y-Interval. If i set Unknown="true" my function is not plotted at all. Do you know how i could plot the function "funct" correctly (in both intervals)? Thanks

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 MATLAB 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by