# 3d Contour Plotting

I would like to plot three 3D-contour plots in the region $$x,y,z >=0$$ and $$x+y+z<1.$$ The functions which I would like to plot are as follows

 r = 0.4;
a1 = 2; a2 = 3; a3 = 4; \
v1 = 0.2; v2 = 0.3; v3 = 0.4;      (*a1,a2,a3, v1,v2,v3 are \
parameters such that ai\[GreaterEqual] 0 and vi>0 and v1+v2+v3<1*)

f1[x_, y_,
z_] = ((1 - r) a1*
x/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) + r*v1 - x;
f2[x_, y_,
z_] = ((1 - r) a2*
y/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) + r*v2 - y;
f3[x_, y_,
z_] = ((1 - r) a3*
x/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) + r*v3 - z;


I would like to see the above three functions on the same 3d plot in the region $$x,y,z >=0$$ and $$x+y+z<1.$$ I tried using ContourPlot3d but it did not work for me (most probably because am not using it correctly). Any help/suggestions will be greatly appreciated.

• ContourPlot3D[{f1[x, y, z], f2[x, y, z], f3[x, y, z]}, {x, 0, 1}, {y, 0, 1}, {z, 0, 1}, RegionFunction -> Function[{x, y, z}, x + y + z < 1], RegionBoundaryStyle -> None] Commented May 26, 2022 at 11:54

r = 0.4;
a1 = 2; a2 = 3; a3 = 4; v1 = 0.2; v2 = 0.3; v3 = 0.4;
f1[x_, y_,
z_] := ((1 - r) a1*x/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) +
r*v1 - x;
f2[x_, y_,
z_] := ((1 - r) a2*y/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) +
r*v2 - y;
f3[x_, y_,
z_] := ((1 - r) a3*x/(1 + (a1 - 1)*x + (a2 - 1)*y + (a3 - 1)*z)) +
r*v3 - z;

ContourPlot3D[{f1[x, y, z], f2[x, y, z],
f3[x, y, z]}, {x, y, z} \[Element]
ImplicitRegion[x > 0 && y > 0 && z > 0 && x + y + z < 1, {x, y, z}]
]


• I am getting this message. "ContourPlot3D::pllim: Range specification {x,y,z}[Element]ImplicitRegion[x>0&&y>0&&z>0&&x+y+z<1,{x,y,z}] is not of the form {x, xmin, xmax}." I have Mathematica 11.1.1 version Commented May 26, 2022 at 11:47
• Is it possible to remove the space and just have the entire plot in the $x+y+z <=1$ and $x,y,z>=0$ region ? Commented May 26, 2022 at 11:50
• To be sure, I copied my own code from this page and (once again) ran it with a fresh kernel on v12.2.0 on Win7-x64 and got the same image. I am not aware of the trick to remove the region box shown in gray. Add this info to main question if you cannot run this. It may be version related.
– Syed
Commented May 26, 2022 at 11:54