Geometry3D
Geometry3D copied to clipboard
Issue with intersection
I'm having problems with evaluating the intersection of a line and a cylinder. I use the following code:
from Geometry3D import *
def intersection_v2(xp,yp,zp,px,py,pz,xt,yt,zt,rt,ht):
part = Line(Point(xp,yp,zp),Vector(px,py,pz))
tank = Cylinder(Point(xt,yt,zt),191.6,302.4*x_unit_vector(),40)
inters = intersection(part,tank)
print(inters)
intersection_v2(100000000,100000000,100000000,-1,-1,-1,0,0,0,191.6,302.4)
I get that intersection is only a point (0,0,0) which is absurd. For smaller initial points (1000,1000,1000) the code behaves as intended. I tried to look for eventual limits on intersection but could not find them