- #1
kwsockman
- 1
- 0
For the following three-dimensional surface, z = -4.53 + 2.67x + 2.78y - 1.09xy, I would like to calculate the area for each of three subsections of this surface: (1) for which z is in between the corresponding x and y values (i.e., x < z < y OR y < z < x); (2) for which x is in between the corresponding z and y values (i.e., z < x < y OR y < x < z); (3) for which y is in between the corresponding z and x values (i.e., z < y < x OR x < y < z). Can anybody give me a formula for doing this so that I can do additional versions of this with different coefficient values?
If it helps to clarify and if you have Mathematica, I have plotted the surface in Mathematica and colored the regions indicated above.
f[x_, y_] = -4.53 + 2.67 x + 2.78 y - 1.09 x y // Rationalize // Simplify;
Plot3D[f[x, y], {x, 1.8, 2.6}, {y, 1.8, 2.6}, PlotRange -> {1.7, 2.6}, PlotPoints -> 101, AxesLabel -> (Style[#, Bold, 14] & /@ {"x", "y", "z"}), Ticks -> {{1.8, 2., 2.2, 2.4, 2.6}, {1.8, 2., 2.2, 2.4, 2.6}, {1.8, 2., 2.2, 2.4, 2.6}}, BoxRatios -> {1, 1, 1}, Mesh -> None, ColorFunction -> Function[{x, y, z}, Piecewise[{{Pink, (x < z < y) || (y < z < x)}, {Gray, (z < x < y) || (y < x < z)}}, Yellow]], ColorFunctionScaling -> False]
The three regions above are colored pink, gray, and yellow, respectively.
Thanks in advance,
Keith
If it helps to clarify and if you have Mathematica, I have plotted the surface in Mathematica and colored the regions indicated above.
f[x_, y_] = -4.53 + 2.67 x + 2.78 y - 1.09 x y // Rationalize // Simplify;
Plot3D[f[x, y], {x, 1.8, 2.6}, {y, 1.8, 2.6}, PlotRange -> {1.7, 2.6}, PlotPoints -> 101, AxesLabel -> (Style[#, Bold, 14] & /@ {"x", "y", "z"}), Ticks -> {{1.8, 2., 2.2, 2.4, 2.6}, {1.8, 2., 2.2, 2.4, 2.6}, {1.8, 2., 2.2, 2.4, 2.6}}, BoxRatios -> {1, 1, 1}, Mesh -> None, ColorFunction -> Function[{x, y, z}, Piecewise[{{Pink, (x < z < y) || (y < z < x)}, {Gray, (z < x < y) || (y < x < z)}}, Yellow]], ColorFunctionScaling -> False]
The three regions above are colored pink, gray, and yellow, respectively.
Thanks in advance,
Keith