TSTP Solution File: DAT087_1 by Z3---4.8.9.0

View Problem - Process Solution

%------------------------------------------------------------------------------
% File     : Z3---4.8.9.0
% Problem  : DAT087_1 : TPTP v8.1.0. Released v6.1.0.
% Transfm  : none
% Format   : tptp
% Command  : z3_tptp -proof -model -t:%d -file:%s

% Computer : n022.cluster.edu
% Model    : x86_64 x86_64
% CPU      : Intel(R) Xeon(R) CPU E5-2620 v4 2.10GHz
% Memory   : 8042.1875MB
% OS       : Linux 3.10.0-693.el7.x86_64
% CPULimit : 300s
% WCLimit  : 300s
% DateTime : Fri Sep 16 14:36:40 EDT 2022

% Result   : Theorem 0.18s 0.50s
% Output   : Proof 0.44s
% Verified : 
% SZS Type : Refutation
%            Derivation depth      :   16
%            Number of leaves      :   29
% Syntax   : Number of formulae    :   67 (  22 unt;   3 typ;   0 def)
%            Number of atoms       :  174 ( 150 equ)
%            Maximal formula atoms :    7 (   2 avg)
%            Number of connectives :  168 (  70   ~;  53   |;   0   &)
%                                         (  38 <=>;   7  =>;   0  <=;   0 <~>)
%            Maximal formula depth :    9 (   4 avg)
%            Maximal term depth    :    5 (   2 avg)
%            Number of FOOLs       :   12 (  12 fml;   0 var)
%            Number arithmetic     :  693 (   6 atm; 220 fun; 372 num;  95 var)
%            Number of types       :    1 (   0 usr;   1 ari)
%            Number of type conns  :    4 (   2   >;   2   *;   0   +;   0  <<)
%            Number of predicates  :   10 (   5 usr;   3 prp; 0-3 aty)
%            Number of functors    :    8 (   3 usr;   4 con; 0-2 aty)
%            Number of variables   :  151 ( 134   !;   0   ?; 151   :)

% Comments : 
%------------------------------------------------------------------------------
tff(count_type,type,
    count: ( $int * list ) > $int ).

tff(cons_type,type,
    cons: ( $int * list ) > list ).

tff(nil_type,type,
    nil: list ).

tff(1,plain,
    ^ [K: $int,H: $int,T: list] :
      refl(
        ( ( ( $sum(H,$product(-1,K)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      <=> ( ( $sum(H,$product(-1,K)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) )),
    inference(bind,[status(th)],]) ).

tff(2,plain,
    ( ! [K: $int,H: $int,T: list] :
        ( ( $sum(H,$product(-1,K)) != 0 )
        | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( $sum(H,$product(-1,K)) != 0 )
        | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) ),
    inference(quant_intro,[status(thm)],[1]) ).

tff(3,plain,
    ^ [K: $int,H: $int,T: list] :
      rewrite(
        ( ( ( $sum(K,$product(-1,H)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      <=> ( ( $sum(H,$product(-1,K)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) )),
    inference(bind,[status(th)],]) ).

tff(4,plain,
    ( ! [K: $int,H: $int,T: list] :
        ( ( $sum(K,$product(-1,H)) != 0 )
        | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( $sum(H,$product(-1,K)) != 0 )
        | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) ),
    inference(quant_intro,[status(thm)],[3]) ).

tff(5,plain,
    ^ [K: $int,H: $int,T: list] :
      rewrite(
        ( ( ( K != H )
          | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )
      <=> ( ( $sum(K,$product(-1,H)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) )),
    inference(bind,[status(th)],]) ).

tff(6,plain,
    ( ! [K: $int,H: $int,T: list] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( $sum(K,$product(-1,H)) != 0 )
        | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ) ),
    inference(quant_intro,[status(thm)],[5]) ).

tff(7,plain,
    ( ! [K: $int,H: $int,T: list] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) ),
    inference(rewrite,[status(thm)],]) ).

tff(8,plain,
    ( ! [K: $int,H: $int,T: list,N: $int] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) ),
    inference(elim_unused_vars,[status(thm)],]) ).

tff(9,plain,
    ^ [K: $int,H: $int,T: list,N: $int] :
      trans(
        monotonicity(
          rewrite(
            ( ( count(K,cons(H,T)) = $sum(count(K,T),1) )
          <=> ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )),
          ( ( ( K = H )
           => ( count(K,cons(H,T)) = $sum(count(K,T),1) ) )
        <=> ( ( K = H )
           => ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) )),
        rewrite(
          ( ( ( K = H )
           => ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) )
        <=> ( ( K != H )
            | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) )),
        ( ( ( K = H )
         => ( count(K,cons(H,T)) = $sum(count(K,T),1) ) )
      <=> ( ( K != H )
          | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) )),
    inference(bind,[status(th)],]) ).

tff(10,plain,
    ( ! [K: $int,H: $int,T: list,N: $int] :
        ( ( K = H )
       => ( count(K,cons(H,T)) = $sum(count(K,T),1) ) )
  <=> ! [K: $int,H: $int,T: list,N: $int] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) ),
    inference(quant_intro,[status(thm)],[9]) ).

tff(11,plain,
    ( ! [K: $int,H: $int,T: list,N: $int] :
        ( ( K = H )
       => ( count(K,cons(H,T)) = $sum(count(K,T),1) ) )
  <=> ! [K: $int,H: $int,T: list] :
        ( ( K != H )
        | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ) ),
    inference(transitivity,[status(thm)],[10,8]) ).

tff(12,axiom,
    ! [K: $int,H: $int,T: list,N: $int] :
      ( ( K = H )
     => ( count(K,cons(H,T)) = $sum(count(K,T),1) ) ),
    file('/export/starexec/sandbox2/benchmark/theBenchmark.p',a_4) ).

tff(13,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( K != H )
      | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ),
    inference(modus_ponens,[status(thm)],[12,11]) ).

tff(14,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( K != H )
      | ( count(K,cons(H,T)) = $sum(1,count(K,T)) ) ),
    inference(modus_ponens,[status(thm)],[13,7]) ).

tff(15,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( $sum(K,$product(-1,H)) != 0 )
      | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ),
    inference(modus_ponens,[status(thm)],[14,6]) ).

tff(16,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( $sum(H,$product(-1,K)) != 0 )
      | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ),
    inference(modus_ponens,[status(thm)],[15,4]) ).

tff(17,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( $sum(H,$product(-1,K)) != 0 )
      | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ),
    inference(skolemize,[status(sab)],[16]) ).

tff(18,plain,
    ! [K: $int,H: $int,T: list] :
      ( ( $sum(H,$product(-1,K)) != 0 )
      | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) ),
    inference(modus_ponens,[status(thm)],[17,2]) ).

tff(19,plain,
    ( ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) )
  <=> ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ) ),
    inference(rewrite,[status(thm)],]) ).

tff(20,plain,
    ( ( $false
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) )
  <=> ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ),
    inference(rewrite,[status(thm)],]) ).

tff(21,plain,
    ( ( $sum($product(-1,count(1,nil)),count(1,cons(1,nil))) = 1 )
  <=> ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ),
    inference(rewrite,[status(thm)],]) ).

tff(22,plain,
    $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = $sum($product(-1,count(1,nil)),count(1,cons(1,nil))),
    inference(rewrite,[status(thm)],]) ).

tff(23,plain,
    ( ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 )
  <=> ( $sum($product(-1,count(1,nil)),count(1,cons(1,nil))) = 1 ) ),
    inference(monotonicity,[status(thm)],[22]) ).

tff(24,plain,
    ( ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 )
  <=> ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ),
    inference(transitivity,[status(thm)],[23,21]) ).

tff(25,plain,
    ( ~ $true
  <=> $false ),
    inference(rewrite,[status(thm)],]) ).

tff(26,plain,
    ( ( 0 = 0 )
  <=> $true ),
    inference(rewrite,[status(thm)],]) ).

tff(27,plain,
    $sum(1,-1) = 0,
    inference(rewrite,[status(thm)],]) ).

tff(28,plain,
    $product(-1,1) = -1,
    inference(rewrite,[status(thm)],]) ).

tff(29,plain,
    $sum(1,$product(-1,1)) = $sum(1,-1),
    inference(monotonicity,[status(thm)],[28]) ).

tff(30,plain,
    $sum(1,$product(-1,1)) = 0,
    inference(transitivity,[status(thm)],[29,27]) ).

tff(31,plain,
    ( ( $sum(1,$product(-1,1)) = 0 )
  <=> ( 0 = 0 ) ),
    inference(monotonicity,[status(thm)],[30]) ).

tff(32,plain,
    ( ( $sum(1,$product(-1,1)) = 0 )
  <=> $true ),
    inference(transitivity,[status(thm)],[31,26]) ).

tff(33,plain,
    ( ( $sum(1,$product(-1,1)) != 0 )
  <=> ~ $true ),
    inference(monotonicity,[status(thm)],[32]) ).

tff(34,plain,
    ( ( $sum(1,$product(-1,1)) != 0 )
  <=> $false ),
    inference(transitivity,[status(thm)],[33,25]) ).

tff(35,plain,
    ( ( ( $sum(1,$product(-1,1)) != 0 )
      | ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 ) )
  <=> ( $false
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ) ),
    inference(monotonicity,[status(thm)],[34,24]) ).

tff(36,plain,
    ( ( ( $sum(1,$product(-1,1)) != 0 )
      | ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 ) )
  <=> ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ),
    inference(transitivity,[status(thm)],[35,20]) ).

tff(37,plain,
    ( ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(1,$product(-1,1)) != 0 )
      | ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 ) )
  <=> ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ) ),
    inference(monotonicity,[status(thm)],[36]) ).

tff(38,plain,
    ( ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(1,$product(-1,1)) != 0 )
      | ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 ) )
  <=> ( ~ ! [K: $int,H: $int,T: list] :
            ( ( $sum(H,$product(-1,K)) != 0 )
            | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
      | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ) ),
    inference(transitivity,[status(thm)],[37,19]) ).

tff(39,plain,
    ( ~ ! [K: $int,H: $int,T: list] :
          ( ( $sum(H,$product(-1,K)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
    | ( $sum(1,$product(-1,1)) != 0 )
    | ( $sum(count(1,cons(1,nil)),$product(-1,count(1,nil))) = 1 ) ),
    inference(quant_inst,[status(thm)],]) ).

tff(40,plain,
    ( ~ ! [K: $int,H: $int,T: list] :
          ( ( $sum(H,$product(-1,K)) != 0 )
          | ( $sum(count(K,cons(H,T)),$product(-1,count(K,T))) = 1 ) )
    | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1 ) ),
    inference(modus_ponens,[status(thm)],[39,38]) ).

tff(41,plain,
    $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = -1,
    inference(unit_resolution,[status(thm)],[40,18]) ).

tff(42,plain,
    ( ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) != -1 )
    | $lesseq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),-1) ),
    inference(theory_lemma,[status(thm)],]) ).

tff(43,plain,
    $lesseq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),-1),
    inference(unit_resolution,[status(thm)],[42,41]) ).

tff(44,plain,
    ( ~ $greatereq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),0)
    | ~ $lesseq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),-1) ),
    inference(theory_lemma,[status(thm)],]) ).

tff(45,plain,
    ~ $greatereq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),0),
    inference(unit_resolution,[status(thm)],[44,43]) ).

tff(46,plain,
    ( ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) != 0 )
    | $greatereq($sum(count(1,nil),$product(-1,count(1,cons(1,nil)))),0) ),
    inference(theory_lemma,[status(thm)],]) ).

tff(47,plain,
    $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) != 0,
    inference(unit_resolution,[status(thm)],[46,45]) ).

tff(48,plain,
    ^ [N: $int,L: list] :
      refl(
        ( ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 )
      <=> ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ) )),
    inference(bind,[status(th)],]) ).

tff(49,plain,
    ( ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 )
  <=> ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ) ),
    inference(quant_intro,[status(thm)],[48]) ).

tff(50,plain,
    ^ [N: $int,L: list] :
      rewrite(
        ( ( count(N,L) = count(N,cons(1,L)) )
      <=> ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ) )),
    inference(bind,[status(th)],]) ).

tff(51,plain,
    ( ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ) ),
    inference(quant_intro,[status(thm)],[50]) ).

tff(52,plain,
    ( ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ) ),
    inference(rewrite,[status(thm)],]) ).

tff(53,plain,
    ( ~ ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ) ),
    inference(rewrite,[status(thm)],]) ).

tff(54,plain,
    ( ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ) ),
    inference(rewrite,[status(thm)],]) ).

tff(55,plain,
    ( ~ ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ~ ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ) ),
    inference(monotonicity,[status(thm)],[54]) ).

tff(56,plain,
    ( ~ ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) )
  <=> ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ) ),
    inference(transitivity,[status(thm)],[55,53]) ).

tff(57,axiom,
    ~ ~ ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ),
    file('/export/starexec/sandbox2/benchmark/theBenchmark.p',c) ).

tff(58,plain,
    ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ),
    inference(modus_ponens,[status(thm)],[57,56]) ).

tff(59,plain,
    ! [N: $int,L: list] : ( count(N,L) = count(N,cons(1,L)) ),
    inference(modus_ponens,[status(thm)],[58,52]) ).

tff(60,plain,
    ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ),
    inference(modus_ponens,[status(thm)],[59,51]) ).

tff(61,plain,
    ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ),
    inference(skolemize,[status(sab)],[60]) ).

tff(62,plain,
    ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 ),
    inference(modus_ponens,[status(thm)],[61,49]) ).

tff(63,plain,
    ( ~ ! [N: $int,L: list] : ( $sum(count(N,L),$product(-1,count(N,cons(1,L)))) = 0 )
    | ( $sum(count(1,nil),$product(-1,count(1,cons(1,nil)))) = 0 ) ),
    inference(quant_inst,[status(thm)],]) ).

tff(64,plain,
    $false,
    inference(unit_resolution,[status(thm)],[63,62,47]) ).

%------------------------------------------------------------------------------
%----ORIGINAL SYSTEM OUTPUT
% 0.06/0.11  % Problem  : DAT087_1 : TPTP v8.1.0. Released v6.1.0.
% 0.06/0.12  % Command  : z3_tptp -proof -model -t:%d -file:%s
% 0.12/0.32  % Computer : n022.cluster.edu
% 0.12/0.32  % Model    : x86_64 x86_64
% 0.12/0.32  % CPU      : Intel(R) Xeon(R) CPU E5-2620 v4 @ 2.10GHz
% 0.12/0.32  % Memory   : 8042.1875MB
% 0.12/0.32  % OS       : Linux 3.10.0-693.el7.x86_64
% 0.12/0.32  % CPULimit : 300
% 0.12/0.32  % WCLimit  : 300
% 0.12/0.32  % DateTime : Wed Aug 31 01:51:26 EDT 2022
% 0.12/0.32  % CPUTime  : 
% 0.12/0.32  Z3tptp [4.8.9.0] (c) 2006-20**. Microsoft Corp.
% 0.12/0.32  Usage: tptp [options] [-file:]file
% 0.12/0.32    -h, -?       prints this message.
% 0.12/0.32    -smt2        print SMT-LIB2 benchmark.
% 0.12/0.32    -m, -model   generate model.
% 0.12/0.32    -p, -proof   generate proof.
% 0.12/0.32    -c, -core    generate unsat core of named formulas.
% 0.12/0.32    -st, -statistics display statistics.
% 0.12/0.32    -t:timeout   set timeout (in second).
% 0.12/0.32    -smt2status  display status in smt2 format instead of SZS.
% 0.12/0.32    -check_status check the status produced by Z3 against annotation in benchmark.
% 0.12/0.32    -<param>:<value> configuration parameter and value.
% 0.12/0.32    -o:<output-file> file to place output in.
% 0.18/0.50  % SZS status Theorem
% 0.18/0.50  % SZS output start Proof
% See solution above
%------------------------------------------------------------------------------