Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

linecirc

Intersections of circles and lines in Cartesian plane

Syntax

[xout,yout] = linecirc(slope,intercpt,centerx,centery,radius)

Description

[xout,yout] = linecirc(slope,intercpt,centerx,centery,radius) finds the points of intersection given a circle defined by a center and radius in x-y coordinates, and a line defined by slope and y-intercept, or a slope of "inf" and an x-intercept. Two points are returned. When the objects do not intersect, NaNs are returned.

When the line is tangent to the circle, two identical points are returned. All inputs must be scalars.

See Also

Introduced before R2006a

Was this topic helpful?