Amplitude of sine curve touching a line.

82 Views Asked by At

Please see the schematic. I know the points (x1, y1) and (x2,y2) located on a line y1=c. There is another line (y2=mx+c2) which intersect y1 at a point which does not lie on or between(x1, y1) and (x2,y2). I would like to know the function y3 which takes a form of sine function (y3 = Bsin(xpi/d - x1 ) +y1 , where d is the distance between points (x1, y1) and (x2,y2)) and touches the line (y2=mx+c2) at some point but not intersect it. Let me know if this make sense or what part doesn't make sense. Any help/lead would do.

Older version: Please see the schematic. I know points (x1, y1) and (x2,y2) and equations y1 and y2 (m and c). I want to figure out the curve y3, which is a sine curve with amplitude B and touches y2 only at one point. How can I approach this problem. Any lead?

1

There are 1 best solutions below

0
On BEST ANSWER

We can always move the origin to the intersection of the two lines so $c$ is irrelevant.

Call the points $A(a,0)$ and $B(b,0)$ with $b>a$. The green line is given by $f(x) = m x$ and the black line by $g(x) = C \sin \left( \frac{\pi}{b-a} (x-a) \right)$. We now want $f(x) = g(x)$ to have only one solution on the interval $(a,b)$. Unfortunately there is no closed-form solution for equations like $mx = \sin x$ so we use the Taylor series at $x = \frac{a+b}{2}$ as an approximation (the blue line):

$$C \sin \left( \frac{\pi}{b-a} (x-a) \right) \approx C \left(1 - \frac{\pi^2}{8} \left( \frac{a+b-2x}{a-b} \right)^2 \right)$$

Now $f(x) = g(x)$ is a quadratic equation which has only one solution if the discriminant is equal to $0$. We then rearrange and obtain

$$C \approx \frac{m}{4} \left( a+b + \sqrt{(a+b)^2 - \frac{8}{\pi^2} (a-b)^2} \right)$$

This approximation works best if $b \ll 2a$