Given two parametric 2D curves:
$c_1=[x_1(a),y_1(a)], \text{ for } a\in[0,1]$
$c_2=[x_2(b),y_2(b)], \text{ for } b\in[0,1]$
I want to find the "sum" of these curves, which I define as the points $[x,y]$ for which there exists $a,b$ such that
- $x=x_1(a)+x_2(b)$
- $y = y_1(a) = y_2(b)$.
I suspect the result should also be a curve, since there is only one degree of freedom given the constraint $2$). I approached this by brute-forcing it, checking all points $[a,b]$ in a grid and keeping those that satisfy constraint $2$) (with a given margin), and indeed the result $[x,y]$ looks like a curve (see example below, where the right curve shows the "sum" of the two curves on the left).
However, extending this to more input curves becomes computationally expensive, since each new curve would add a new dimension to the grid. Notice that it is impossible to add curves sequentially in this way, since the result is a list of sparse points, instead of a parametric curve.
This question has a physical origin: if two physical systems with a non-linear relationship between parameters (e.g., pressure and temperature) are connected in such a way that one of the parameters must be the same in both, what would be the resulting curve for the total system?
Would you know of any more efficient way to get the resulting curve? Or any other way this could be extended to more input curves in an efficient way?