134     plo = is_undef(o) ? p
 
  160     dtp = is_undef(tr) ? [-1, 0]
 
  163           (al2>  45 && al2< 135) ? [ 0, 1]
 
  164         : (al2>=135 && al2<=225) ? [ 1, 0]
 
  165         : (al2> 225 && al2< 315) ? [ 0,-1]
 
  169     rotate( [0, 0, tra] )
 
  286     mr1 = is_undef(v1) ? p1
 
  289     mr2 = is_undef(v2) ? p2
 
  332            du = is_undef(u) ? md
 
  343          is_undef(u) ? str(rd) : str(rd, 
" ", u);
 
  354       draft_line(l=[pd1, pd2], w=w, s=s, a1=da1, a2=da2);
 
  356       translate( (pd1+pd2)/2 )
 
  357       rotate( [0, 0, ape-90] )
 
  374       draft_line(l=[pd1, pd2], w=w, s=s, a1=da1, a2=da2);
 
  378     translate( (pd1+pd2)/2 )
 
  379     rotate( [0, 0, ape-90] )
 
  501     pd1 = (do1 == 0) ? mr1
 
  503     pd2 = (do2 == 0) ? mr2
 
  518            du = is_undef(u) ? md
 
  531          is_undef(u) ? str(rt, 
" ", rd) : str(rt, 
" ", rd, 
" ", u);
 
  542       draft_line(l=[pd1, pd2], w=w, s=s, a1=da1, a2=da2);
 
  544       translate( (pd1+pd2)/2 )
 
  545       rotate( [0, 0, ape] )
 
  562       draft_line(l=[pd1, pd2], w=w, s=s, a1=da1, a2=da2);
 
  566     translate( (pd1+pd2)/2 )
 
  567     rotate( [0, 0, ape] )
 
  718               : 
angle_ll([c, mr1], [c, mr2], 
false),
 
  721            au = is_undef(u) ? ma
 
  732          is_undef(u) ? str(rd) : str(rd, 
" ", u);
 
  743       draft_arc(r=r-o, c=c, v1=[c, pe1], v2=[c, pe2], fn=fn, cw=cw, w=w, s=s, a1=da1, a2=da2);
 
  763       draft_arc(r=r-o, c=c, v1=[c, pe1], v2=[c, pe2], fn=fn, cw=cw, w=w, s=s, a1=da1, a2=da2);
 
  843       p1 = c - l * [cos(la), sin(la)];
 
  853       p1 = c + (r-l) * [cos(la), sin(la)];      
 
  854       p2 = c + (r-l/2)/2 * [cos(la), sin(la)];  
 
  868       p1 = c + rs * [cos(la), sin(la)];         
 
origin2d
<point-2d> The origin point coordinate in 2d Euclidean space.
 
x_axis2d_uv
<vector-2d> The unit vector of the positive x-axis in 2d Euclidean space.
 
function line_tp(l)
Return the terminal point of a line or vector.
 
function angle_ll(l1, l2, s=true)
Compute the angle between two lines or vectors in a 3d or 2d-space.
 
function is_point(v)
Test if a value defines a point.
 
function line2d_new(m=1, a=0, p1=origin2d, p2, v)
Construct a 2 dimensional directed line.
 
function point_closest_pl(p, l)
Compute the coordinates of the closest point on a line to a given point.
 
function distance_pp(p1, p2)
Compute the distance between two points.
 
function defined_e_or(v, i, d)
Return an element of an iterable when it exists or a default value otherwise.
 
function third(v)
Return the third element of an iterable value.
 
function second(v)
Return the second element of an iterable value.
 
function is_empty(v)
Test if an iterable value is empty.
 
function round_d(v, d=6)
Round a list of numbers to a fixed number of decimal point digits.
 
function round_s(v, d=6)
Round a list of numbers to a fixed number of significant figures.
 
function defined_or(v, d)
Return given value, if defined, or a secondary value, if primary is not defined.
 
function is_defined(v)
Test if a value is defined.
 
function is_number(v)
Test if a value is a number.
 
function angle(a, from=angle_unit_default, to=angle_unit_base)
Convert an angle from some units to another.
 
angle_unit_base
<string> The base units for value storage.
 
function length(v, from=length_unit_default, to=length_unit_base, d=1)
Convert a value from from one units to another with dimensions.
 
length_unit_base
<string> The base units for value storage.