is.std.eq.tri {pcds} | R Documentation |
Check whether a triangle is a standard equilateral triangle
Description
Checks whether the triangle, tri
,
is the standard equilateral triangle
T_e=T((0,0),(1,0),(1/2,\sqrt{3}/2))
or not.
Usage
is.std.eq.tri(tri)
Arguments
tri |
A |
Value
TRUE
if tri
is a standard equilateral triangle,
else FALSE
.
Author(s)
Elvan Ceyhan
Examples
A<-c(0,0); B<-c(1,0); C<-c(1/2,sqrt(3)/2);
Te<-rbind(A,B,C) #try adding +10^(-16) to each vertex
is.std.eq.tri(Te)
is.std.eq.tri(rbind(B,C,A))
Tr<-rbind(A,B,-C)
is.std.eq.tri(Tr)
A<-c(1,1); B<-c(2,0); C<-c(1.5,2);
Tr<-rbind(A,B,C);
is.std.eq.tri(Tr)
[Package pcds version 0.1.8 Index]