Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Some thoughts about this problem. I suggest there was initial Bezier curve <code>P0</code>-<code>P3</code> with control points <code>P1</code> and <code>P2</code></p> <p><img src="https://i.stack.imgur.com/ncF9A.gif" alt="enter image description here"></p> <p>Let's make two subdivisions at parameters ta and tb. We have now two subcurves (in yellow) - <code>P0</code>-<code>PA3</code> and <code>PB0</code>-<code>P3</code>. Blue interval is lost. <code>PA1</code> and <code>PB2</code> - known control points. We have to find unknown <code>P1</code> and <code>P2</code>.</p> <p>Some equations</p> <p>Initial curve:</p> <pre><code>C = P0*(1-t)^3+3*P1(1-t)^2*t+3*P2*(1-t)*t^2+P3*t^3 </code></pre> <p>Endpoints:</p> <pre><code>PA3 = P0*(1-ta)^3+3*P1*(1-ta)^2*ta+3*P2*(1-ta)*ta^2+P3*ta^3 PB0 = P0*(1-tb)^3+3*P1*(1-tb)^2*tb+3*P2*(1-tb)*tb^2+P3*tb^3 </code></pre> <p>Control points of small curves</p> <pre><code>PA1 = P0*(1-ta)+P1*ta =&gt; P1*ta = PA1 – P0*(1-ta) PB2 = P2*(1-tb)+P3*tb =&gt; P2(1-tb) = PB2 – P3*tb </code></pre> <p>Now substitute unknown points in PA3 equation:</p> <pre><code>**PA3***(1-tb) = **P0***(1-ta)^3*(1-tb)+3*(1-ta)^2*(1-tb)*(**PA1** – **P0***(1-ta))+3*(1-ta)*ta^2*( **PB2** – **P3***tb)+**P3***ta^3*(1-tb) </code></pre> <p>(some multiplication signs have been lost due to SO formatting)</p> <p>This is vector equation, it contains two scalar equations for two unknowns <code>ta</code> and <code>tb</code></p> <pre><code>PA3X*(1-tb) = P0X*(1-ta)^3*(1-tb)+3*(1-ta)^2*(1-tb)*(PA1X – P0X*(1-ta))+3*(1-ta)*ta^2*( PB2X – P3X*tb)+P3X*ta^3*(1-tb) PA3Y*(1-tb) = P0Y*(1-ta)^3*(1-tb)+3*(1-ta)^2*(1-tb)*(PA1Y – P0Y*(1-ta))+3*(1-ta)*ta^2*( PB2Y – P3Y*tb)+P3Y*ta^3*(1-tb) </code></pre> <p>This system might be solved both numerically and analytically (indeed Maple solves it with very-very big cubic formula :( ) </p> <p>If we have points with some error, that makes sense to build overdetermined equation system for some points (<code>PA3</code>, <code>PB0</code>, <code>PA2</code>, <code>PB1</code>) and solve it numerically to minimize deviations.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload