@prefix skolem: <https://eyereasoner.github.io/.well-known/genid/8b98b360-9a70-4845-b52c-c675af60ad01#>.
@prefix r: <http://www.w3.org/2000/10/swap/reason#>.
@prefix my: <https://eyereasoner.github.io/eye/reasoning/ppt-bank/acct3#>.
@prefix ck: <https://eyereasoner.github.io/eye/reasoning/ppt-bank/checking#>.
@prefix n3: <http://www.w3.org/2004/06/rei#>.
@prefix log: <http://www.w3.org/2000/10/swap/log#>.
@prefix e: <http://eulersharp.sourceforge.net/2003/03swap/log-rules#>.
@prefix list: <http://www.w3.org/2000/10/swap/list#>.
@prefix math: <http://www.w3.org/2000/10/swap/math#>.
@prefix var: <http://www.w3.org/2000/10/swap/var#>.
@prefix bk: <https://eyereasoner.github.io/eye/reasoning/ppt-bank/banking#>.

skolem:proof a r:Proof, r:Conjunction;
    r:component skolem:lemma1;
    r:gives {
        my:account ck:balance 2.0 .
    }.

skolem:lemma1 a r:Inference;
    r:gives {
        my:account ck:balance 2.0 .
    };
    r:evidence (
        skolem:lemma2
    );
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_0"]; r:boundTo [ n3:uri "https://eyereasoner.github.io/eye/reasoning/ppt-bank/acct3#account"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_1"]; r:boundTo 2.0];
    r:rule skolem:lemma3.

skolem:lemma2 a r:Inference;
    r:gives {
        my:account ck:balance 2.0 .
    };
    r:evidence (
        skolem:lemma4
        [ a r:Fact; r:gives {<https://eyereasoner.github.io/eye/reasoning/pptbank/acct3start.n3> log:semantics {
            my:account a ck:Account.
            my:account ck:balance 10.0.
        }}]
        [ a r:Fact; r:gives {{
            my:account a ck:Account.
            my:account ck:balance 10.0.
        } log:includes {
            my:account ck:balance 10.0.
        }}]
        skolem:lemma5
        [ a r:Fact; r:gives {((<https://eyereasoner.github.io/eye/reasoning/pptbank/bankSW.n3> <https://eyereasoner.github.io/eye/reasoning/pptbank/checking.n3>) 1) e:findall (_:sk_0 {
            (<https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check1.n3> <https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check2.n3>) list:member _:sk_1.
            _:sk_1 log:semantics _:sk_2.
            _:sk_2 log:includes {
                _:sk_1 a ck:Check.
                _:sk_1 ck:amount _:sk_0.
                _:sk_1 ck:account my:account.
            }.
        } (5.0 3.0))}]
        [ a r:Fact; r:gives {(5.0 3.0) math:sum 8.0}]
        [ a r:Fact; r:gives {(10.0 8.0) math:difference 2.0}]
    );
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_0"]; r:boundTo [ n3:uri "https://eyereasoner.github.io/eye/reasoning/ppt-bank/acct3#account"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_1"]; r:boundTo [ n3:uri "https://eyereasoner.github.io/eye/reasoning/pptbank/acct3start.n3"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_2"]; r:boundTo {
        my:account a ck:Account.
        my:account ck:balance 10.0.
    }];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_3"]; r:boundTo 10.0];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_4"]; r:boundTo (<https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check1.n3> <https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check2.n3>)];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_5"]; r:boundTo ((<https://eyereasoner.github.io/eye/reasoning/pptbank/bankSW.n3> <https://eyereasoner.github.io/eye/reasoning/pptbank/checking.n3>) 1)];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_6"]; r:boundTo [ a r:Existential; n3:nodeId "_:sk_0"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_7"]; r:boundTo [ a r:Existential; n3:nodeId "_:sk_1"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_8"]; r:boundTo [ a r:Existential; n3:nodeId "_:sk_2"]];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_9"]; r:boundTo (5.0 3.0)];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_10"]; r:boundTo 8.0];
    r:binding [ r:variable [ n3:uri "http://www.w3.org/2000/10/swap/var#x_11"]; r:boundTo 2.0];
    r:rule skolem:lemma6.

skolem:lemma3 a r:Extraction;
    r:gives {
        @forAll var:x_0, var:x_1. {
            var:x_0 ck:balance var:x_1.
        } => {
            var:x_0 ck:balance var:x_1.
        }.
    };
    r:because [ a r:Parsing; r:source <https://eyereasoner.github.io/eye/reasoning/pptbank/query.n3>].

skolem:lemma4 a r:Extraction;
    r:gives {
        my:account bk:statements (<https://eyereasoner.github.io/eye/reasoning/pptbank/acct3start.n3>).
    };
    r:because [ a r:Parsing; r:source <https://eyereasoner.github.io/eye/reasoning/pptbank/bankSW.n3>].

skolem:lemma5 a r:Extraction;
    r:gives {
        my:account bk:transactions (<https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check1.n3> <https://eyereasoner.github.io/eye/reasoning/pptbank/acct3check2.n3>).
    };
    r:because [ a r:Parsing; r:source <https://eyereasoner.github.io/eye/reasoning/pptbank/bankSW.n3>].

skolem:lemma6 a r:Extraction;
    r:gives {
        @forAll var:x_0, var:x_1, var:x_2, var:x_3, var:x_4, var:x_5, var:x_6, var:x_7, var:x_8, var:x_9, var:x_10, var:x_11. {
            var:x_0 bk:statements (var:x_1).
            var:x_1 log:semantics var:x_2.
            var:x_2 log:includes {
                var:x_0 ck:balance var:x_3.
            }.
            var:x_0 bk:transactions var:x_4.
            var:x_5 e:findall (var:x_6 {
                var:x_4 list:member var:x_7.
                var:x_7 log:semantics var:x_8.
                var:x_8 log:includes {
                    var:x_7 a ck:Check.
                    var:x_7 ck:amount var:x_6.
                    var:x_7 ck:account var:x_0.
                }.
            } var:x_9).
            var:x_9 math:sum var:x_10.
            (var:x_3 var:x_10) math:difference var:x_11.
        } => {
            var:x_0 ck:balance var:x_11.
        }.
    };
    r:because [ a r:Parsing; r:source <https://eyereasoner.github.io/eye/reasoning/pptbank/checking.n3>].

