I'm not a math guy, sorry. I read posts on the subject but couldn't find the answer to my problem (or didn't understood the answers). I'd like to get a simple answer.

I know a generic parabola formula


it focus, $(Fx,Fy)$

and the cartesian equation of it's directrix


What would be the easiest way to draw a portion of it using a quadratic bezier curve (say maybe from it summit up to $2p$ or like) ?

  • $\begingroup$ Welcome the MathematicsStackExchange! You can improve your experience by using MathJax for equations. A quick review is at math.meta.stackexchange.com/questions/5020/…. $\endgroup$
    – dantopa
    Commented Dec 6, 2018 at 20:39
  • $\begingroup$ How are you “drawing” the curve? What do you consider easy? $\endgroup$
    – amd
    Commented Dec 6, 2018 at 21:06
  • $\begingroup$ I want to draw the curve using SVG path Q/q command. Want I mean by "easy" is with the less computation possible. $\endgroup$
    – fdesar
    Commented Dec 7, 2018 at 22:18
  • $\begingroup$ See here: en.wikipedia.org/wiki/… $\endgroup$ Commented Dec 8, 2018 at 21:50
  • $\begingroup$ Do you know how to compute the position and first derivative at any point on the parabola from your "generic parabola formula"? $\endgroup$
    – fang
    Commented Dec 8, 2018 at 22:55

1 Answer 1

  • Choose at will start point $P_0$ and end point $P_2$ on your parabola.

  • Find the equations of tangent lines at $P_0$ and $P_2$.

  • Find the intersection point $P_1$ of the two tangents.

  • The quadratic Bézier $B(t)=(1-t)^2P_0+2t(1-t)P_1+t^2P_2$ is what you want.

  • $\begingroup$ Souds logical. My problem is to choose p0 and p2. $\endgroup$
    – fdesar
    Commented Dec 9, 2018 at 23:41
  • $\begingroup$ I interpret "from its summit" as meaning that $P_0$ is the vertex of the parabola. And that's easy because the vertex is the midpoint between the focus and the projection of the focus on the directrix.The meaning of "up to $2p$ or like" is otherwise rather obscure, to me at least. $\endgroup$ Commented Dec 10, 2018 at 11:58
  • $\begingroup$ Yep F is the focus and p is the parabola parameter, which is the length of the orthogonal projection of F on the directrix. $\endgroup$
    – fdesar
    Commented Dec 11, 2018 at 22:05
  • $\begingroup$ Do you then want to choose $P_2$ such that its distance from the directrix is $2p$? If so, $P_2$ is the intersection between the parabola and one of the two lines with equation $D_a x+D_b y+D_c\pm 2p\sqrt{D_a^2+D_b^2}=0$. $\endgroup$ Commented Dec 12, 2018 at 18:30
  • $\begingroup$ Thank you. Sounds logical. $\endgroup$
    – fdesar
    Commented Dec 14, 2018 at 8:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .