I am struggling to visualize the following function by using Plot3D
A = (2.29 - 2.6 s - 2 s^2 + 2.2 s^3 +
c (-1 + s) (-1.3 + 1.1 s^2))/(4.58 - 5.2 s - 4 s^2 + 4.4 s^3)
with the following restrictions:
-0.665954 < s < 0.826905 &&
((-1.1 + s^2) (-0.01 + 2 (-1 + s)^2 (1 + s) +
0.1 (3 - 6 s + 2 s^3)))/(0.01 (7 + s - s^2 (3 + s)) + (-1 +
s^2)^2 (-7 + s (-1 + 4 s)) +
0.1 (1 + s) (-8 + s (16 + s (9 + s (2 + s) (-9 + 4 s)))))
< c <=
-(((-1 + s) (-0.01 + 2 (-1 + s)^2 (1 + s) +
0.1 (3 - 6 s + 2 s^3)))/(-0.02 + (-1 + s)^2 (1 + s) (3 + s) +
0.1 (3 + s (-6 + s (-2 + s (2 + s))))))
I am aware that the restrictions are quite complicated, so I am not sure whether it is possible to plot it at all.
I've tried to plot it using RegionFunction, similar to this thread Plotting above desired region, which does not work give me any result.
It was possible to create a plot using the second answer in this thread Alternative 2, but with the given restrictions c cannot become negative and the plot also shows negative values for c, which is why I think it is incorrect.
I've searched the forum for hours and didn't find a different solution, which could help me.
Does anyone know how to plot the function, if it is possible at all?
Let me know if more information is required!
Best, Phil
Answer
One possibility:
reg = BoundaryDiscretizeRegion[ImplicitRegion[-0.665954 < s < 0.826905 &&
((-1.1 + s^2) (-0.01 + 2 (-1 + s)^2 (1 + s) +
0.1 (3 - 6 s + 2 s^3)))/(0.01 (7 + s - s^2 (3 + s)) +
(-1 + s^2)^2 (-7 + s (-1 + 4 s)) + 0.1 (1 + s)
(-8 + s (16 + s (9 + s (2 + s) (-9 + 4 s))))) < c <=
-(((-1 + s) (-0.01 + 2 (-1 + s)^2 (1 + s) +
0.1 (3 - 6 s + 2 s^3)))/(-0.02 + (-1 + s)^2 (1 + s)
(3 + s) + 0.1 (3 + s (-6 + s (-2 + s (2 + s)))))),
{s, c}], MaxCellMeasure -> {"Length" -> 0.1},
Method -> "RegionPlot"];
Plot3D[(2.29 - 2.6 s - 2 s^2 + 2.2 s^3 + c (-1 + s) (-1.3 + 1.1 s^2))/
(4.58 - 5.2 s - 4 s^2 + 4.4 s^3), {s, c} ∈ reg]
Comments
Post a Comment