2.47 Exercise 2.47
If frames are defined using a list:
(define (origin-frame frame) (car frame)) (define (edge1-frame frame) (cadr frame)) (define (edge2-frame frame) (caddr frame))
If frames are defined by consing an origin vector onto a pair of edge vectors:
(define (origin-frame frame) (car frame)) (define (edge1-frame frame) (cadr frame)) (define (edge2-frame frame) (cddr frame))
Since the only difference is the position of the edge2 vector, the procedures are all identical except for edge2-frame. And these are almost the same, too, since the data structures are so similar.