← dcf954423fbb · dd038eb3d459 →
dcfb4c64c914
A centered full-height gray divider separates two independently placed monochrome connected objects. Count object cells per row in each object's own bounding box, zero-pad the shorter row profile, take elementwise absolute differences, and draw that list as a left-justified cyan histogram.
constructive outputnumeric profile reasoningpanel comparison
Generated by the released generator before publication; every output was computed by its Racket reference rule. White outlines mark the cells the rule changed. Lesson check:
refuted: a demonstration contradicts the rival. survived_all: it fits every demonstration and also gives the intended answer, so it cannot mislead here. ambiguous: it fits every demonstration but answers the query differently. Names are as declared by the generator; a declared shortcut is not guaranteed to fit the original pairs (see the paper’s Limitations).
Original task pairs
From the source task; the reference rule must reproduce them.
Reference rule (Racket)
(rule! (let ((dummy 0)) (define (top-left< a b) (if (= (obj-r1 a) (obj-r1 b)) (< (obj-c1 a) (obj-c1 b)) (< (obj-r1 a) (obj-r1 b)))) (define (row-profile obj) (for/list ((r (in-range (obj-r1 obj) (+ (obj-r2 obj) 1)))) (count-where (lambda (p) (= (first p) r)) (obj-cells obj)))) (define (col-profile obj) (for/list ((c (in-range (obj-c1 obj) (+ (obj-c2 obj) 1)))) (count-where (lambda (p) (= (second p) c)) (obj-cells obj)))) (define (max-row-peak obj) (apply max (row-profile obj))) (define (max-col-peak obj) (apply max (col-profile obj))) (define (row-histogram profile (color 8)) (let ((w (if (empty? profile) 1 (max 1 (apply max profile))))) (grid-from-fn (length profile) w (lambda (r c) (if (< c (list-ref profile r)) color 0))))) (define (split-vertical-panels grid sep-color) (define sep-cols (filter (lambda (c) (all? (lambda (r) (= (at grid r c) sep-color)) (range 0 (rows grid)))) (range 0 (cols grid)))) (define bounds (append (list -1) sep-cols (list (cols grid)))) (let loop ((xs bounds)) (if (empty? (rest xs)) (list) (let* ((left (+ (first xs) 1)) (right (- (second xs) 1)) (tail (loop (rest xs)))) (if (<= left right) (cons (subgrid grid 0 left (- (rows grid) 1) right) tail) tail))))) (define (single-largest grid (banned (list))) (first (sort (filter (lambda (obj) (not (member (obj-color obj) banned))) (objects grid 0)) (lambda (a b) (cond ((not (= (obj-size a) (obj-size b))) (> (obj-size a) (obj-size b))) ((not (= (max-row-peak a) (max-row-peak b))) (> (max-row-peak a) (max-row-peak b))) ((not (= (max-col-peak a) (max-col-peak b))) (> (max-col-peak a) (max-col-peak b))) (else (top-left< a b))))))) (define (pad-to xs len) (append xs (make-list (max 0 (- len (length xs))) 0))) (define panels (split-vertical-panels g 5)) (define a (single-largest (first panels))) (define b (single-largest (second panels))) (define ra (row-profile a)) (define rb (row-profile b)) (define len (max (length ra) (length rb))) (define pa (pad-to ra len)) (define pb (pad-to rb len)) (row-histogram (for/list ((i (in-range len))) (abs (- (list-ref pa i) (list-ref pb i)))) 8)))
Provenance
- Generator
- generators/dcfb4c64c914/generator.py
- Notes and decisions
- generators/dcfb4c64c914/notes.md
- Review label
- reviewed_safe
- Generator SHA-256
- 9c665258ec35ed487f525a5ad8a66434b19146776ac6d877e13d72102ec10e47
- Rule hash
- 53fe6f709bdc
- Sources
- bank:fe9bb13a9b18
- Lesson seeds
- 20261108, 20261109, 20261110, 20261111, 20261112
- Reproduce lesson 1
arcpuzzles generate dcfb4c64c914 --count 1 --seed 20261108 --test 1