Creating Lines From/To Polar Coordinates

This example use the start point(x1,y2), angle, and length of a line to determine the end point of the line (x2,y2). Or conversely, uses the start/end points of a line to determine its polar coordinates.
SVG has angle values as: 0 degrees at top, and angle increases clockwise.

General Form:
x = rCOS θ
y = rSIN θ

Javascript θ=degrees:
x = length*Math.cos((θ-90)*Math.PI/180)
y = length*Math.sin((θ-90)*Math.PI/180)
90 degrees
GIVEN: 2 Points x1= y1= x2= y2= length = angle = degrees
GIVEN: Start point, length, and angle x1= y1= length= angle= x2= y2=

SVG Source:
OK in:IE11/CH32/FF23