View source: R/conicThrough5Points.R
conicThrough5Points | R Documentation |
Return the matrix representation of the conic that passes through exactly 5 points.
conicThrough5Points(p1, p2, p3, p4, p5)
p1 |
(3 \times 1) vectors of the homogeneous coordinates of one of the five points. |
p2 |
(3 \times 1) vectors of the homogeneous coordinates of one of the five points. |
p3 |
(3 \times 1) vectors of the homogeneous coordinates of one of the five points. |
p4 |
(3 \times 1) vectors of the homogeneous coordinates of one of the five points. |
p5 |
(3 \times 1) vectors of the homogeneous coordinates of one of the five points. |
A (3 \times 3) matrix representation of the conic passing through the 5 points.
Richter-Gebert, Jürgen (2011). Perspectives on Projective Geometry - A Guided Tour Through Real and Complex Geometry, Springer, Berlin, ISBN: 978-3-642-17285-4
# five points p1 <- c(-4.13, 6.24, 1) p2 <- c(-8.36, 1.17, 1) p3 <- c(-2.03, -4.61, 1) p4 <- c(9.70, -3.49, 1) p5 <- c(8.02, 3.34, 1) # matrix representation of the conic passing # through the five points C5 <- conicThrough5Points(p1,p2,p3,p4,p5) # plot plot(rbind(p1,p2,p3,p4,p5),xlim=c(-10,10), ylim=c(-10,10), asp=1) # from matrix to ellipse parameters E5 <- conicMatrixToEllipse(C5) lines(ellipse(E5$saxes, E5$loc, E5$theta, n=500))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.