Skip to main content
1-Visitor
Jul 16, 2012 5:09 PM UTC
Solved

Creating Countour Plots (i.e. plot contours of f(x,y)=C in xy-plane)

I have a worksheet right now that defines a function (concentration) as a function of x and y - call it "Cg(x,y)"

I am looking to plot contours of constant concentration in the xy-plane, that is to say, set Cg = 0.8, 0.6, etc. and plot the resulting contours on a x-y graph.


I am new to the community and a beginner, for the most part, to Mathcad, so I really don't know even where to start. It is not a function that could be solved symbolically, therefore I think it might have to be plotted as a series of sequential points. If anyone can help tell me how to create such contour plots, that would be very much appreciated. Thank you!

19-Tanzanite
Jul 16, 2012 6:59 PM UTC

There are several values for which your cg function doesn't converge, and the contour plot function doesn't like this. I've replaced these with zero in the attached (this might or might not be acceptable to you) - see attached.

Also you needed to change the range of the Quickplot data.

Alan

7 replies

19-Tanzanite
Jul 16, 2012 5:55 PM UTC

Something like this:

Contour.PNG

Alan

Translate
1-Visitor
Jul 16, 2012 6:07 PM UTC

Yes, that is precisely what I am looking for and figured out how to get that type of plot now, but how do I specify the countours I want? For instance in your plot you have contours of Cg(x,y)=0,5,10,15,20... plotted. I am looking to get contours of Cg(x,y)=0.9, 0.8, 0.7...

Translate
19-Tanzanite
Jul 16, 2012 6:13 PM UTC

Ethan Ambroziak wrote:

... I am looking to get contours of Cg(x,y)=0.9, 0.8, 0.7...

Try it with your function and see if Mathcad comes up with suitable values. I'm not sure you can specify exactly which values it must use!

Post your function (with the ranges of x and y of interest) and I (or someone else) might be able to produce something acceptable to you.

Alan

Translate