title: How to draw a curve without knowing 4 points?
body: <p>According to <a href="http://cairographics.org/samples/curve_to/" rel="nofollow noreferrer">cairo example code</a>, following code</p>
  
  <pre><code>double x=25.6,  y=128.0;
  double x1=102.4, y1=230.4,
         x2=153.6, y2=25.6,
         x3=230.4, y3=128.0;
  
  cairo_move_to (cr, x, y);
  cairo_curve_to (cr, x1, y1, x2, y2, x3, y3);
  
  cairo_set_line_width (cr, 10.0);
  cairo_stroke (cr);
  
  cairo_set_source_rgba (cr, 1, 0.2, 0.2, 0.6);
  cairo_set_line_width (cr, 6.0);
  cairo_move_to (cr,x,y);   cairo_line_to (cr,x1,y1);
  cairo_move_to (cr,x2,y2); cairo_line_to (cr,x3,y3);
  cairo_stroke (cr);
  </code></pre>
  
  <p>can generate the curve and two pink lines.</p>
  
  <p><img src="https://i.stack.imgur.com/b0Bch.png" alt="enter image description here"></p>
  
  <p>But that need 4 points, (x,y), (x1,y1), (x2,y2), (x3,y3)</p>
  
  <p>If I only have x,y and x3, y3 (start and end points of the curve), 
  is there any math formula to generate those pink lines without knowing x1,y1 and x2,y2?</p>
  
  <p><strong>Edit</strong>:</p>
  
  <p>Its for the case that I generate the curve through following way.</p>
  
  <pre><code>cairo_move_to (cr, x, y);
  cairo_curve_to (cr, x, y3, x3, y, x3, y3);
  </code></pre>