Firstly, I am sorry for my poor english since it is only my second language.
During my spare time, I tried to form a hearshaping function.
Here's what I did.
If I drew a ellipse that looks like this,
by making the $x$ values absolute, I can make the positive side to be symmetrical and form a heart-shape.
So, I first drew $x^2 + y^2 = 1$ (a circle)
In order to make it into a ellipse, I time $0.5$ to the $x^2$ and I got an ellipse
To make it into an ellipse shown previously, here's what I did:
I put $(x-y)$ into $y$ and $(x+y)$ into $x$ because if you think carefully, if the below part of $x=y$ is symmetrical, the ellipse would form the first image.
So I did get a ellipse as shown at the top, with the equation,
$$x^2 + y^2- \frac{2}{3}\cdot x\cdot y = \frac{2}{3}$$
Now, if I make the $x$ value to be absolute,
$$x^2 + y^2 - \frac{2}{3}\cdot\left|x\right|\cdot y = \frac{2}{3}$$
Theoretically, it should work, but GEOGEBRA , an app I use for drawing graphs, won't get me a heart shaped graph, instead it is keep saying that there is an error.
Can anyone check and show what's wrong??
$\endgroup$ 11 Answer
$\begingroup$There is nothing wrong, you're absolutely right.
GeoGebra seems to have limitations with composite functions and multivariable expressions.
$$x^2 + y^2 - \frac{2}{3}\left|x\right|y = \frac{2}{3}$$
Your equation is not a polynomial which the algebra module of GeoGebra is designed for and hence, having both $x^2 + y^2$ and $\left|x\right|y$ is apparently too much for the application to handle. Newer versions may rectify this issue. You may make sure by asking with the Geogebra User Forum and telling them about your problem.
Thankfully, Mathematica and Wolfram Alpha do not share this problem and can plot your graph perfectly. Also, Desmos currently seems to plot it as well.
Mathematica plots it as:
WolframAlpha can plot it:
Desmos:
In my opinion, a much better heart shape will form if you replace all the $\frac{2}{3}$ in your equation with $1$.
That is, $$x^2 + y^2 - |x|y = 1$$
It produces a more pronounced heart
You can play with the constants on the graph I've created at Desmos
The following are other equations which also give heart shapes:
$(y^2 + x^2 - 1)^3 - x^2\cdot y^3 = 0$
Using 2 equations: " $y = \sqrt{1-(\left|x\right|-1)^2}$ " and " $y = -3\sqrt{1-\sqrt{\frac{\left|x\right|}{2}}}$ from $-2$ to $2$ "
- Try using the polar coordinate system for $y = \frac{\sin x \sqrt{\left|\cos x\right|}}{ \sin x + 1.4} - 2\sin x + 2 $
If you're bored with 2D hearts, then check out Taubin's heart surface
Also check out this question about drawing a heart in mathematica