Maximum curvature of a plot
조회 수: 6 (최근 30일)
이전 댓글 표시
hi I have plotted a polynomial Im interested to get the values of x and y at point of maximum curvature of curve.
Thanks
답변 (1개)
John D'Errico
2014년 6월 15일
If you have the polynomial, you need to compute the curvature, and then find the maximum value of that function. You can just use fminbnd.
댓글 수: 7
Roger Stafford
2014년 6월 16일
In that case it is "On the other hand" of my last paragraph above. To have used 'cftool' you must have had the coordinates of a set of points that determined your curve. If you are very confident of the accuracy of these points, you can approximate the curvature at a point (x2,y2) by the curvature of the unique circle that goes through the three successive points (x1,y1), (x2,y2), and (x3,y3). I quote the answer I gave in the Answers Thread #58964 on Jan 16, 2013:
"Let (x1,y1), (x2,y2), and (x3,y3) be three successive points on your curve. The curvature of a circle drawn through them is simply four times the area of the triangle formed by the three points divided by the product of its three sides. Using the coordinates of the points this is given by:
K = 2*abs((x2-x1).*(y3-y1)-(x3-x1).*(y2-y1)) ./ ...
sqrt(((x2-x1).^2+(y2-y1).^2)*((x3-x1).^2+(y3-y1).^2)*((x3-x2).^2+(y3-y2).^2));
You can consider this as an approximation to the curve's curvature at the middle point. (x2,y2), of the three points."
I leave it to you to work out how to locate the maximum value of such 'K' values. (Note: If you leave out the 'abs' in this formula, you get the signed version, positive for turning left and negative for turning right.)
참고 항목
카테고리
Help Center 및 File Exchange에서 Interpolation에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!