Check-sheet of proper treatment of empty and zero-dimensional domains

Procedure: translation? object

Empty: Irrelevant.

Zero-dimensional: Allow empty vectors.

Implemented:

Tested:

Documented:

Procedure: permutation? object

Empty: Irrelevant.

Zero-dimensional: Allow empty vectors.

Implemented:

Tested:

Documented:

Procedure: index-rotate n k

Empty: Irrelevant.

Zero-dimensional: Still an error when $n=0$.

Implemented:

Tested:

Documented:

Procedure: index-first n k

Empty: Irrelevant.

Zero-dimensional: Still an error when $n=0$.

Implemented:

Tested:

Documented:

Procedure: index-last n k

Empty: Irrelevant.

Zero-dimensional: Still an error when $n=0$.

Implemented:

Tested:

Documented:

Procedure: make-interval arg1 #!optional arg2

Empty: Allow $\ell_k=u_k$.

Zero-dimensional: Allow empty vectors.

Implemented:

Tested:

Documented:

Procedure: interval? obj

Empty: No change

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-dimension interval

Empty: Irrelevant

Zero-dimensional: Allow zero result.

Implemented:

Tested:

Documented:

Procedure: interval-lower-bound interval i

Empty: No change.

Zero-dimensional: Error.

Implemented:

Tested:

Documented:

Procedure: interval-upper-bound interval i

Empty: No change.

Zero-dimensional: Error.

Implemented:

Tested:

Documented:

Procedure: interval-width interval i

Empty: Allow zero result.

Zero-dimensional: Error.

Implemented:

Tested:

Documented:

Procedure: interval-lower-bounds->list interval

Empty: No change.

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-upper-bounds->list interval

Empty: No change.

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-lower-bounds->vector interval

Empty: No change.

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-upper-bounds->vector interval

Empty: No change.

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-widths interval

Empty: Allow zero result.

Zero-dimensional: Allow empty vector.

Implemented:

Tested:

Documented:

Procedure: interval-volume interval

Empty: Allow zero result.

Zero-dimensional: result is 1.

Implemented:

Tested:

Documented:

Procedure: interval= interval1 interval2

Empty: No change.

Zero-dimensional: No change.

Implemented:

Tested:

Documented:

Procedure: interval-subset? interval1 interval2

Empty: No change.

Zero-dimensional: ????

Implemented:

Tested:

Documented:

Procedure: interval-contains-multi-index? interval index-0 index-1 ...

Empty: Always #f.

Zero-dimensional: I suppose if no indices, answer is #t, otherwise #f.

Implemented:

Tested:

Documented:

Procedure: interval-projections interval right-dimension

Empty: No change.

Zero-dimensional: Allow right-dimension to be zero or the dimension of the interval.

Implemented:

Tested:

Documented:

Procedure: interval-for-each f interval

Empty: No change.

Zero-dimensional: call $f$ on single element.

Implemented:

Tested:

Documented:

Procedure: interval-dilate interval lower-diffs upper-diffs

Empty: Allow empty intervals.

Zero-dimensional: Allow empty vectors for lower-diffs upper-diffs.

Implemented:

Tested:

Documented:

Procedure: interval-intersect interval-1 interval-2 ...

Empty: Allow empty intervals.

Zero-dimensional: I suppose that if all the intervals are zero-dimensional, then return zero-dimensional interval.

Implemented:

Tested:

Documented:

Procedure: interval-translate interval translation

Empty: No change.

Zero-dimensional: Allow empty translation.

Implemented:

Tested:

Documented:

Procedure: interval-permute interval permutation

Empty: No change.

Zero-dimensional: Allow empty permutations.

Implemented:

Tested:

Documented:

Procedure: interval-scale interval scales

Empty: No change.

Zero-dimensional: Allow empty scales.

Implemented:

Tested:

Documented:

Procedure: interval-cartesian-product interval . intervals

Empty: No change.

Zero-dimensional: Zero-dimensional arguments don't increase the dimension of the result.

Implemented:

Tested:

Documented:

Procedure: make-storage-class getter setter checker maker copier length default data? data->body

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class? m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-getter m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-setter m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-checker m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-maker m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-copier m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-length m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-default m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-data? m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: storage-class-data->body m

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: make-array interval getter [ setter ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array? obj

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-domain array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-getter array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-dimension array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: mutable-array? obj

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-setter array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: make-specialized-array interval [ storage-class generic-storage-class ] [ initial-value (storage-class-default storage-class ) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: make-specialized-array-from-data data [ storage-class generic-storage-class ] [ mutable? (specialized-array-default-mutable?) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: specialized-array? obj

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-storage-class array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-indexer array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-body array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-safe? array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-elements-in-order? A

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: specialized-array-share array new-domain new-domain->old-domain

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-copy array [ result-storage-class [ mutable? [ safe? ] ] ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-curry array inner-dimension

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-extract array new-domain

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-tile A S

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-translate array translation

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-permute array permutation

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-reverse array #!optional flip?

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-sample array scales

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-outer-product op array1 array2

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-inner-product A f g B

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-map f array . arrays

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-for-each f array . arrays

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-foldl op id array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-foldr op id array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-reduce op A

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-any pred array1 array2 ...

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-every pred array1 array2 ...

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array->list array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: list->array domain l [ result-storage-class generic-storage-class ] [ mutable? (specialized-array-default-mutable?) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: list*->array d nested-list [ result-storage-class generic-storage-class ] [ mutable? (specialized-array-default-mutable?) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array->list* A

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array->vector array

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: vector->array domain v [ result-storage-class generic-storage-class ] [ mutable? (specialized-array-default-mutable?) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: vector*->array d nested-vector [ result-storage-class generic-storage-class ] [ mutable? (specialized-array-default-mutable?) ] [ safe? (specialized-array-default-safe?) ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array->vector* A

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-assign! destination source

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-stack k arrays [ storage-class [ mutable? [ safe? ] ] ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-append k arrays [ storage-class [ mutable? [ safe? ] ] ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-block A [ storage-class [ mutable? [ safe? ] ] ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-ref A i0 . i-tail

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: array-set! A v i0 . i-tail

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented:

Procedure: specialized-array-reshape array new-domain [ copy-on-failure? #f ]

Empty:

Zero-dimensional:

Implemented:

Tested:

Documented: