Next: 7.5 Conversions
Up: 7 Internal programs
Prev: 7.3 Particular displays
Contents
SUBROUTINE GENPLY(R, A, N, T) INTEGER N REAL R, A, T(2, N+1)
generates N+1 (X, Y) couples in T, defining a polygon with N sides centered at the origin, with radius R and angle A.
SUBROUTINE ARC3P(P1, P2, P3, RES) REAL P1(2), P2(2), P3(2), RES(5)
calculates the arc of a circle going through the 3 points, P1, P2 and P3, by joining them in this order, where on exit RES(1:5) defines the arc in the following manner:
RES(1), RES(2): first point on the arc;
RES(3), RES(4): arc's center;
RES(5): angle of arc.
REAL FUNCTION DIST2P(P1, P2) REAL P1(3), P2(3)
returns the distance of 2 points: DIST2P=distance(P1, P2)
SUBROUTINE DP1DR(D, P1, DR) REAL D(3), P1(2), DR(2)
returns D, the line going through a point (P1) and perpendicular to a direction (DR). The line's equation is given by: D(1)*x + D(2)*y + D(3) =0
SUBROUTINE DPP(D, P1, P2, IRES) SUBROUTINE DP1P2(D,P1,P2,IRES) REAL D(3), P1(2), P2(2) INTEGER IRES
returns D, the line going through two points P1 and P2. IRES=0 if OK.
The line's equation is given by: D(1)*x + D(2)*y + D(3) =0
REAL FUNCTION DTP1D1(P, D) REAL P(2), D(3), X
returns DTP1D1, the distance of point P from line D. The line's equation is given by: D(1)*x + D(2)*y + D(3) =0
REAL FUNCTION DTP1P2(P1, P2) REAL P1(2), P2(2), DX, DY
returns DTP1P2, the distance between point P1 and point P2.
REAL FUNCTION DTP1SG(P, P1, P2) REAL P1(2), P2(2), P(2)
returns DTP1SG, the distance of point P from the segment defined by the 2 points, P1 and P2.
SUBROUTINE ITDD(P, D1, D2, IRES) SUBROUTINE ITD1D2(P, D1, D2, IRES) REAL P(2), D1(3), D2(3)
returns P, the intersection point of two lines D1 and D2 defined by D1(1:3) and D2(1:3). IRES = 0 if OK.
SUBROUTINE MDP1P2(D, P1, P2, IRES) REAL D(3), P1(2), P2(2)
returns D, the bisecting line of the segment going through points P1 and P2. The line's equation is given by: D(1)*x + D(2)*y + D(3) =0
SUBROUTINE PJPD(P, P1, D1) SUBROUTINE PJP1D1(P, P1, D1) REAL P(2), D1(3), P1(2)
returns P, the projection point of P1 on line D1. The line's equation is given by: D1(1)*x + D1(2)*y + D1(3) =0
SUBROUTINE SLOPE(PE, PT, C, R, IRES) REAL PT(2), C(2), R, PE(3)
returns PE, the slope of the line going through PT, tangent to circle (C, R).