let width = function i -> if is_open(i) then add_rat (upper_bound (i), opp_rat (lower_bound (i))) else cons_rat ("0", "1")