Plotting z^2-xy+1=0 with Mathematica - Interval around Origin

heman
Messages
353
Reaction score
0
hi,i want to know the command which i have to give to plot this using mathematica.actually interval should be sufficient and near by origin.thx in advance.
z^2-xy+1=0
 
Physics news on Phys.org
First rearrange to get:

z = sqrt(xy - 1)

Then use something like

Plot3D[Sqrt[x y - 1],{x,1,10},{y,1,10}]
 
is a quadratic equation in two variables, z and x. In order to plot this equation, we can use the ContourPlot function in Mathematica. This function takes in an expression and plots the corresponding contour lines.

In this case, we can define the expression as z^2-xy+1 and use the ContourPlot function to plot it. The code for this would be:

ContourPlot[z^2 - x*y + 1 == 0, {x, -1, 1}, {z, -1, 1}]

This will produce a plot with the interval around the origin (-1,1) for both x and z variables. You can adjust the interval as per your requirement.

Additionally, you can also use the RegionPlot function to plot the solution set for this equation. The code for this would be:

RegionPlot[z^2 - x*y + 1 <= 0, {x, -1, 1}, {z, -1, 1}]

This will produce a shaded region around the origin, indicating the solutions of the equation.

I hope this helps. Happy plotting!
 
Back
Top