Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You can easily plot a segment between two suitable points on the line passing by P and R. For example, you can replace plotE += line([P.xy(),R.xy()],color='red') by:

vP, vR = vector(P.xy()), vector(R.xy())
PR = (vR - vP).normalized()
plotE += line([vP-5*PR, vP+4*PR], color="red")