# \donttest{
c1<-.4; c2<-.6
A<-c(0,0); B<-c(1,0); C<-c(c1,c2);
Tb<-rbind(A,B,C);
M<-as.numeric(runif.basic.tri(1,c1,c2)$g) #try also M<-c(.6,.2)
r<-2
P1<-as.numeric(runif.basic.tri(1,c1,c2)$g) #try also P1<-c(.4,.2)
NPEbasic.tri(P1,r,c1,c2,M)
#or try
Rv<-rel.vert.basic.tri(P1,c1,c2,M)$rv
NPEbasic.tri(P1,r,c1,c2,M,Rv)
P1<-c(1.4,1.2)
P2<-c(1.5,1.26)
NPEbasic.tri(P1,r,c1,c2,M) #gives an error if M=c(1.3,1.3)
#since center is not the circumcenter or not in the interior of the triangle
# }
Run the code above in your browser using DataLab