Maximum curvature of a plot
6 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
hi I have plotted a polynomial Im interested to get the values of x and y at point of maximum curvature of curve.
Thanks
Réponses (1)
John D'Errico
le 15 Juin 2014
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 commentaires
Roger Stafford
le 16 Juin 2014
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.)
Voir également
Catégories
En savoir plus sur Interpolation dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!