\[\Im(\left(\left(\left(\left(\left(\left(\left(\left(\left(\left(\left(\left(-1 + 1 i\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) + \left(\left(\left(\left(\left(\left(6 + 0.0 i\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right)\right) + \left(\left(\left(\left(\left(15 + 0.0 i\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right)\right) + \left(\left(\left(\left(20 + 0.0 i\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right)\right) + \left(\left(\left(15 + 0.0 i\right) \cdot \left(-1 + 1 i\right)\right) \cdot \left(-1 + 1 i\right)\right)\right) + \left(\left(6 + 0.0 i\right) \cdot \left(-1 + 1 i\right)\right)\right) + \left(1 + 0.0 i\right)\right))\]

Reproduce

Please include this information when filing a bug report:

herbie shell --seed 2020079 +o rules:numerics
(FPCore ()
  :name "3.9.1 imaginary part (p56)"
  :precision binary64
  (im (+ (+ (+ (+ (+ (+ (* (* (* (* (* (complex -1 1) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (* (* (* (* (* (complex 6 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (* (* (complex 15 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (* (complex 20 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (complex 15 0.0) (complex -1 1)) (complex -1 1))) (* (complex 6 0.0) (complex -1 1))) (complex 1 0.0))))

Backtrace

cdr: contract violation expected: pair? given: '()LC
loopunknown
prog-cost/data/pavpan/nightlies/herbie/simpler-alts/src/core/alt-table.rkt1330
for-loop/data/pavpan/nightlies/herbie/simpler-alts/src/core/alt-table.rkt3415
make-alt-table/data/pavpan/nightlies/herbie/simpler-alts/src/core/alt-table.rkt320
(unnamed)/opt/racket-7.5/collects/racket/contract/private/arrow-val-first.rkt48618
run-improve47/data/pavpan/nightlies/herbie/simpler-alts/src/mainloop.rkt3650
.../more-scheme.rkt:261:28unknown
run/opt/racket-7.5/share/pkgs/profile-lib/main.rkt392
profile-thunk16/opt/racket-7.5/share/pkgs/profile-lib/main.rkt90
(unnamed)/opt/racket-7.5/collects/racket/private/more-scheme.rkt26128

Reproduce

herbie shell --seed 2020079 +o rules:numerics
(FPCore ()
  :name "3.9.1 imaginary part (p56)"
  :precision binary64
  (im (+ (+ (+ (+ (+ (+ (* (* (* (* (* (complex -1 1) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (* (* (* (* (* (complex 6 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (* (* (complex 15 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (* (complex 20 0.0) (complex -1 1)) (complex -1 1)) (complex -1 1))) (* (* (complex 15 0.0) (complex -1 1)) (complex -1 1))) (* (complex 6 0.0) (complex -1 1))) (complex 1 0.0))))