필터 지우기
필터 지우기

how to calculate tangent between circle and polynomial (from curve fit)

조회 수: 13 (최근 30일)
Yu Li
Yu Li 2024년 1월 21일
댓글: Yu Li 2024년 1월 22일
Hi:
I have a known circle with x0,y0, and r, I also have a polynomial function from curve fitting result, is there any way to find the tangent line between those two? as well as the tangent point on each profile?
the curve fitting polynomia is attached, and the parameter of circle is:
x: 0.9439
y: 0.1063
r: 0.0537
Thank!
Yu

채택된 답변

Matt J
Matt J 2024년 1월 21일
편집: Matt J 2024년 1월 21일
The equation for the tangent to the polynomial is y=m(x1,y1)*x+b(x1,y1) where m(x1,y1) and b(x1,y1) are a function of the tangent point (x1,y1) and can easily be determined from calculus. Therefore, the tangent point on the circle must satisfy the two equations,
y2=m(x1,y1)*x2+b(x1,y1)
(x2-0.9439)^2+(y2-0.1063)^2=0.0537^2
Also, (x1,y1) must satisfy the polynomial equations
P(x1,y1)=0
And you have a 4th equation to express the fact that the normal vector to the tangent line is perpendicular to the tangent line,
(x2-0.9439)-m(x1,y1)*(y2-0.1063)=0
Four nonlinear equations in four unknowns. I expect there will be two solutions.
  댓글 수: 1
Yu Li
Yu Li 2024년 1월 22일
thank you so much, I successfully find the solution based on your suggestions.
there are 6 tangent lines found as this is 3rd order polynomia.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Polynomials에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by