Macro Library interval
Interval functions, Version 1.1 March 2, 2010
forminterval(min,max,minmarkertype,maxmarkertype)
Forms an interval string, like "[2,3)"
min,max: min and max of interval
minmarkertype, maxmarkertype: 0 for open, 1 for closed
linegraph(intervals,[xmin,xmax,xscl,width,height])
Creates a line graph
intervals: string or array of strings in interval notation, ex: [2,5)
linegraphbrackets(intervals,[xmin,xmax,xscl,width,height])
Creates a line graph using brackets/parens instead of open/closed dots
intervals: string or array of strings in interval notation, ex: [2,5)
intervalstodraw(interval,xmin,xmax)
converts an interval like (-oo,4]U(3,5] into an array of strings
suitable for use as $answers for a drawing question with
$answerformat = 'numberline'
also provide xmin and xmax, the min and max of the drawing grid
if different than the default -5 to 5