(add-var-name "x" "y" (py "alpha"))
(add-predconst-name "Q" (make-arity (py "alpha")))

(set-goal (pf "(all y.((Q y -> F) -> F) -> Q y) ->
               exca x.Q x -> all y Q y"))

; Automated proof search for minimal quantifier logic (Miller)
(search)

(dp)

(dpe)

(lambda (u2)
  (lambda (u3)
    ((u3 x) (lambda (u4)
	      (lambda (y)
		((u2 y) (lambda (u5)
			  ((u3 y) (lambda (u8)
				    (lambda (y17)
				      ((u2 y17) (lambda (u9)
						  (u5 u8)))))))))))))> 



































(dp)

; ....all x.(Q x -> all y Q y) -> F by assumption Hyp3
; ....x
; ...(Q x -> all y Q y) -> F by all elim
; .......all y.((Q y -> F) -> F) -> Q y by assumption Hyp2
; .......y
; ......((Q y -> F) -> F) -> Q y by all elim
; .........all x.(Q x -> all y Q y) -> F by assumption Hyp3
; .........y
; ........(Q y -> all y Q y) -> F by all elim
; ............all y.((Q y -> F) -> F) -> Q y by assumption Hyp2
; ............y17
; ...........((Q y17 -> F) -> F) -> Q y17 by all elim
; .............Q y -> F by assumption Hyp5
; .............Q y by assumption Hyp8
; ............F by imp elim
; ...........(Q y17 -> F) -> F by imp intro Hyp9
; ..........Q y17 by imp elim
; .........all y17 Q y17 by all intro
; ........Q y -> all y17 Q y17 by imp intro Hyp8
; .......F by imp elim
; ......(Q y -> F) -> F by imp intro Hyp5
; .....Q y by imp elim
; ....all y Q y by all intro
; ...Q x -> all y Q y by imp intro Hyp4
; ..F by imp elim
; .exca x.Q x -> all y Q y by imp intro Hyp3
; (all y.((Q y -> F) -> F) -> Q y) -> exca x.Q x -> all y Q y by imp intro Hyp2

(dpe)

; (lambda (u2)
;   (lambda (u3)
;     ((u3 x) (lambda (u4)
; 	      (lambda (y)
; 		((u2 y) (lambda (u5)
; 			  ((u3 y) (lambda (u8)
; 				    (lambda (y17)
; 				      ((u2 y17) (lambda (u9)
; 						  (u5 u8)))))))))))))

(set-goal (pf "exca x.Q x -> all y Q y"))
(assume 1)
(use 1 (pt "x"))
(assume 2 "y")
(use "Stab")
(assume 3)
(use 1 (pt "y"))
(assume 4)
(use "Efq")
(use-with 3 4)

(dp)

; ...all x.(Q x -> all y Q y) -> F by assumption Hyp0
; ...x
; ..(Q x -> all y Q y) -> F by all elim
; ......all y.((Q y -> F) -> F) -> Q y by global assumption Stab-Log
; ......y
; .....((Q y -> F) -> F) -> Q y by all elim
; ........all x.(Q x -> all y Q y) -> F by assumption Hyp0
; ........y
; .......(Q y -> all y Q y) -> F by all elim
; .........F -> all y Q y by global assumption Efq-Log
; ..........Q y -> F by assumption Hyp2
; ..........Q y by assumption Hyp3
; .........F by imp elim
; ........all y Q y by imp elim
; .......Q y -> all y Q y by imp intro Hyp3
; ......F by imp elim
; .....(Q y -> F) -> F by imp intro Hyp2
; ....Q y by imp elim
; ...all y Q y by all intro
; ..Q x -> all y Q y by imp intro Hyp1
; .F by imp elim
; excl x.Q x -> all y Q y by imp intro Hyp0

