0
$\begingroup$

I have an question about solving equation.

x and y are variable, and a, b, and c are complex constant.

The equations is formed like: $x^2/a - y^2/b = c$.

I want to contour plot a graph range from $x1 < Re(x) < x2$ to $y1 < Re(y) < y2$. $x1$, $x2$, $y1$, and $y2$ is real number even though $x$ and $y$ satisfied this equation are complex number.

I have used

ContourPlot[x^2/a - y^2/b == c, {x, x1, x2}, {y, y1, y2}]

However, because this considers only real case, I can't find a solution.

If anyone has a idea, please help me.

Thank you.

$\endgroup$

1 Answer 1

3
$\begingroup$

Something like this using ReIm?

SeedRandom[1]

{a, b, c} = RandomComplex[1 + I, 3];

ContourPlot[ReIm[x^2/a - y^2/b] == ReIm[c], {x, -1, 1}, {y, -1, 1}]

enter image description here

If you are using an older version of Mathematica without ReIm define:

ReIm = Function[x, {Re@x, Im@x}, Listable];
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.