Draw an egg

It's very easy to draw an egg with the curve y^2=(x^2-1)*(x-π)
  1. PrivateSubForm_Click()
  2. Me.Caption="Drawanegg"
  3. DimXAsDouble
  4. Me.Scale(-1.5,-3)-(1.5,3)
  5. ForX=-1To1Step0.0005
  6. Me.Circle(X,-Sqr((X^2-1)*(X-4*Atn(1)))),0.01,vbRed
  7. Me.Circle(X,Sqr((X^2-1)*(X-4*Atn(1)))),0.01,vbRed
  8. Next
  9. EndSub

It returns:

Draw an egg

你可能感兴趣的:(raw)