(angular-coords center-x center-y theta magnitude)
Returns an [x y] vector representing a point that is offset from a center ([center-x center-y]) by a given angle and magnitude
Returns an [x y] vector representing a point that is offset from a center ([center-x center-y]) by a given angle and magnitude
(avg & values)
Returns the average of the arguments
Returns the average of the arguments
(interpolate start finish t)
Interpolates a point between [start, finish] at point t, where t is between 0.0 and 1.0
Interpolates a point between [start, finish] at point t, where t is between 0.0 and 1.0
(interpolate-multi start-point finish-point t)
Interpolates between two multi-dimensional points at t, where t is between 0.0 and 1.0
Interpolates between two multi-dimensional points at t, where t is between 0.0 and 1.0
(line-intersection line1 line2)
Finds the intersection of two lines. Each line argument is a vector of the form [slope y-intersect start-x end-x]
Finds the intersection of two lines. Each line argument is a vector of the form [slope y-intersect start-x end-x]
(lines-intersection-point [start-x-1 start-y-1]
[end-x-1 end-y-1]
[start-x-2 start-y-2]
[end-x-2 end-y-2])
(point-angle [x1 y1] [x2 y2])
Returns the angle between two points in radians
Returns the angle between two points in radians
(point-dist [x1 y1] [x2 y2])
Returns the euclidean distance between two points
Returns the euclidean distance between two points
(point-slope [x1 y1] [x2 y2])
Returns the slope of a line between two points: (x1, y1), (x2, y2)
Returns the slope of a line between two points: (x1, y1), (x2, y2)
(rescale value old-min old-max new-min new-max)
Rescales value from range [old-min, old-max] to [new-min, new-max]
Rescales value from range [old-min, old-max] to [new-min, new-max]
(slope x1 y1 x2 y2)
Returns the slope of a line between two points: (x1, y1), (x2, y2)
Returns the slope of a line between two points: (x1, y1), (x2, y2)
(y-intercept slope x1 y1)
Returns the y-intercept of a line with a given slope and one point on the line (x1, y1)
Returns the y-intercept of a line with a given slope and one point on the line (x1, y1)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close