Documentation

GaudisCrypt.Examples.SHA3.IRO

The infinite random oracle (EasyCrypt proof/IRO.eca) — EC-fidelity port #

It maps values of type from to infinite sequences of values of type to, each sampled uniformly and independently; it is lazy. Inputs not satisfying the validity predicate are mapped to the empty list.

Translation (as the pilot SecureRO's):

Declarations of the first port #

Definitions and plain lemmas of the first port of this file (2026-10/11) that the proofs below use; its program-logic proofs are gone.

@[simp]
theorem GaudisCrypt.SHA3.IRO.IRO_T.init.mk_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure «to» «from») :
init «to» «from» (mk «to» «from» theRecord✝) = theRecord✝.init

@[simp]: reading the field init back off a module built from a record — IRO_T.init (IRO_T.mk r) = r.init.

It is what carries the right-hand side of an X.apply_simp (which is an IRO_T.mk) on to the field the caller actually asked for, so that simp chains X.apply_simp into X.init.apply_simp.

@[implicit_reducible]
instance GaudisCrypt.SHA3.IRO.instIsModuleIRO_T («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
IsModule (IRO_T «to» «from»)

The IsModule IRO_T instance: IRO_T is a module type, with representation IRO_T.typeRep.

It is what lets the name IRO_T stand where a module type is expected — in Module.Arr/Module.Prod (→ₘ/×ₘ), say — which the underlying Module IRO_T.typeRep would do on its own but IRO_T, a plain (non-reducible) def, would not.

Equations
noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.f («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
IRO_T «to» «from» → procmod («from» × ℤ) → List «to»

The field f of a module of type IRO_T: the projection onto component 1 of the right-nested tuple IRO_T.typeRep, as a chain of Module.fst'/Module.snd'. Tagged @[module_accessor].

IRO_T.f.mk_simp reads this field back off a module built by IRO_T.mk; IRO_T.f.utilities has the accessor as a module, and the lemmas about it.

Its parameters are named xn, in that order (recorded in @[gaudiProcParamNames], a ProcedureSignature holding only their types).

Equations
Instances For
    @[reducible]
    noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.mk («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
    Structure «to» «from» → IRO_T «to» «from»

    Builds a module of type IRO_T from the record IRO_T.Structure of its fields, as a right-nested Module.pair'. @[reducible].

    Inverse of IRO_T.structure (IRO_T.mk_destruct, IRO_T.destruct_mk); a single field of a module built this way is read back by the @[simp] lemmas IRO_T.init.mk_simp, IRO_T.f.mk_simp.

    Equations
    Instances For
      def GaudisCrypt.SHA3.IRO.IRO_T.typeRep («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

      The ModuleTypeRep underlying IRO_T, the module type declared by moduletype IRO_T: the right-nested product of its 2 field types, in declaration order.

      IRO_T is by definition Module IRO_T.typeRep.

      Equations
      Instances For
        noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.structure («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
        IRO_T «to» «from» → Structure «to» «from»

        The record of a module's fields: IRO_T.structure m is IRO_T.Structure.mk applied to IRO_T.init, IRO_T.f of m.

        Inverse of IRO_T.mk (IRO_T.mk_destruct, IRO_T.destruct_mk).

        Equations
        Instances For
          @[simp]
          theorem GaudisCrypt.SHA3.IRO.IRO_T.destruct_mk («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theModule✝ : IRO_T «to» «from») :
          mk «to» «from» («structure» «to» «from» theModule✝) = theModule✝

          @[simp]: IRO_T.mk (IRO_T.structure m) = m — rebuilding a module from its own fields gives that module back.

          def GaudisCrypt.SHA3.IRO.IRO_T («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

          The module type declared by moduletype IRO_T, with fields init, f: the type Module IRO_T.typeRep of modules that are a right-nested tuple of the field types.

          Build one from a record of its fields with IRO_T.mk, read a single field off one with the accessors IRO_T.init, IRO_T.f, and get the whole record back with IRO_T.structure.

          Equations
          Instances For
            @[simp]
            theorem GaudisCrypt.SHA3.IRO.IRO_T.f.mk_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure «to» «from») :
            f «to» «from» (mk «to» «from» theRecord✝) = theRecord✝.f

            @[simp]: reading the field f back off a module built from a record — IRO_T.f (IRO_T.mk r) = r.f.

            It is what carries the right-hand side of an X.apply_simp (which is an IRO_T.mk) on to the field the caller actually asked for, so that simp chains X.apply_simp into X.f.apply_simp.

            noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.init («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
            IRO_T «to» «from» → procmod () → Unit

            The field init of a module of type IRO_T: the projection onto component 0 of the right-nested tuple IRO_T.typeRep, as a chain of Module.fst'/Module.snd'. Tagged @[module_accessor].

            IRO_T.init.mk_simp reads this field back off a module built by IRO_T.mk; IRO_T.init.utilities has the accessor as a module, and the lemmas about it.

            It takes no parameters (recorded in @[gaudiProcParamNames]).

            Equations
            Instances For
              noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.f.utilities («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
              ModuleTypeUtilities (IRO_T «to» «from») (procmod («from» × ℤ) → List «to») (f «to» «from»)

              What is derivable about the accessor IRO_T.f, bundled into one ModuleTypeUtilities (one name per field in the namespace, rather than one per fact):

              • IRO_T.f.utilities.accessorModule : IRO_T →ₘ … — the accessor as a module, a projection being a module morphism;
              • IRO_T.f.utilities.apply_simp — Module.app IRO_T.f.utilities.accessorModule m = IRO_T.f m: applying that module is the accessor;
              • IRO_T.f.utilities.expression_eq — the same at the level of expressions: (IRO_T.f m).expression = (IRO_T.f.utilities.proj m.expression).reduce.
              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                structure GaudisCrypt.SHA3.IRO.IRO_T.Structure («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                The record of the fields of a module of type IRO_T: the fields init, f, one per moduletype field, each of that field's own module type.

                IRO_T.mk turns such a record into a IRO_T, IRO_T.structure turns a IRO_T back into one.

                Instances For
                  noncomputable def GaudisCrypt.SHA3.IRO.IRO_T.init.utilities («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
                  ModuleTypeUtilities (IRO_T «to» «from») (procmod () → Unit) (init «to» «from»)

                  What is derivable about the accessor IRO_T.init, bundled into one ModuleTypeUtilities (one name per field in the namespace, rather than one per fact):

                  • IRO_T.init.utilities.accessorModule : IRO_T →ₘ … — the accessor as a module, a projection being a module morphism;
                  • IRO_T.init.utilities.apply_simp — Module.app IRO_T.init.utilities.accessorModule m = IRO_T.init m: applying that module is the accessor;
                  • IRO_T.init.utilities.expression_eq — the same at the level of expressions: (IRO_T.init m).expression = (IRO_T.init.utilities.proj m.expression).reduce.
                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For
                    @[simp]
                    theorem GaudisCrypt.SHA3.IRO.IRO_T.mk_destruct («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure «to» «from») :
                    «structure» «to» «from» (mk «to» «from» theRecord✝) = theRecord✝

                    @[simp]: IRO_T.structure (IRO_T.mk r) = r — destructing a module built from a record gives that record back.

                    IRO's module variable mp is a parameter: a clone declares its own (BIRO.IRO.mp) and passes it.

                    theorem GaudisCrypt.SHA3.IRO.IRO.init.procedure.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) (holeArgs✝ : HoleSigs.empty.Instantiation) :
                    (procedure «to» «from» valid dto mp).instantiate holeArgs✝ = proc () : Unit { mp <- EC.FMap.empty; return () }

                    Instantiating the holes of IRO.init.procedure with a tuple holeArgs of procedures: the body of proc init as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                    Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.init.procedure.apply_simp]).

                    @[simp]
                    theorem GaudisCrypt.SHA3.IRO.IRO.init.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :
                    init «to» «from» valid dto mp = Module.proc (procedure «to» «from» valid dto mp)

                    @[simp]: IRO.init = Module.proc IRO.init.procedure — true by definition, proc init using no module parameter and so having no holes to fill.

                    noncomputable def GaudisCrypt.SHA3.IRO.IRO.f.procedure («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :
                    proctype («from» × ℤ) -> List «to»

                    The body of proc f of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                    A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.f.procedure.apply_simp) rather than run. Use IRO.f for this procedure as a module.

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For
                      noncomputable def GaudisCrypt.SHA3.IRO.IRO.fill_in.procedure («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :

                      The body of proc fill_in of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                      A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.fill_in.procedure.apply_simp) rather than run. Use IRO.fill_in for this procedure as a module.

                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For
                        noncomputable def GaudisCrypt.SHA3.IRO.IRO.f («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :
                        procmod («from» × ℤ) → List «to»

                        proc f of module IRO as a module: Module.proc IRO.f.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.f.apply_simp says exactly that.

                        Equations
                        Instances For
                          theorem GaudisCrypt.SHA3.IRO.IRO.f.procedure.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) (holeArgs✝ : HoleSigs.empty.Instantiation) :
                          (procedure «to» «from» valid dto mp).instantiate holeArgs✝ = proc (xn : «from» × ℤ) : (List «to») { var x : «from», n : ℤ, i : ℤ, bs : List «to», b : «to»; x, n <- §xn; i <- 0; bs <- []; if (valid §x) { while (decide (§i < §n)) { b <- call (fill_in «to» «from» valid dto mp).procedure (§x, §i); bs <- EC.rcons §bs §b; i <- §i + 1; } } return §bs }

                          Instantiating the holes of IRO.f.procedure with a tuple holeArgs of procedures: the body of proc f as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                          Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.f.procedure.apply_simp]).

                          noncomputable def GaudisCrypt.SHA3.IRO.IRO.init («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :

                          proc init of module IRO as a module: Module.proc IRO.init.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.init.apply_simp says exactly that.

                          Equations
                          Instances For
                            @[simp]
                            theorem GaudisCrypt.SHA3.IRO.IRO.fill_in.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :
                            fill_in «to» «from» valid dto mp = Module.proc (procedure «to» «from» valid dto mp)

                            @[simp]: IRO.fill_in = Module.proc IRO.fill_in.procedure — true by definition, proc fill_in using no module parameter and so having no holes to fill.

                            noncomputable def GaudisCrypt.SHA3.IRO.IRO.init.procedure («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :

                            The body of proc init of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                            A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.init.procedure.apply_simp) rather than run. Use IRO.init for this procedure as a module.

                            Equations
                            Instances For
                              theorem GaudisCrypt.SHA3.IRO.IRO.fill_in.procedure.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) (holeArgs✝ : HoleSigs.empty.Instantiation) :
                              (procedure «to» «from» valid dto mp).instantiate holeArgs✝ = proc (x : «from», n : ℤ) : «to» { var r : «to»; if (!decide ((§mp).dom (§x, §n))) { r <$ dto; mp <- (§mp).set (§x, §n) §r; } return EC.oget ((§mp).get (§x, §n)) }

                              Instantiating the holes of IRO.fill_in.procedure with a tuple holeArgs of procedures: the body of proc fill_in as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                              Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.fill_in.procedure.apply_simp]).

                              @[simp]
                              theorem GaudisCrypt.SHA3.IRO.IRO.f.apply_simp («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :
                              f «to» «from» valid dto mp = Module.proc (procedure «to» «from» valid dto mp)

                              @[simp]: IRO.f = Module.proc IRO.f.procedure — true by definition, proc f using no module parameter and so having no holes to fill.

                              noncomputable def GaudisCrypt.SHA3.IRO.IRO («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :

                              The module declared by module IRO: the record of its procedures IRO.init, IRO.fill_in, IRO.f.

                              The declaration has no parameter list, so no procedure of it can call one either and the module is not a function — it is the plain record itself, and there is no IRO.apply_simp to apply it with.

                              Equations
                              • One or more equations did not get rendered due to their size.
                              Instances For
                                noncomputable def GaudisCrypt.SHA3.IRO.IRO.fill_in («to» «from» : Type) [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (valid : «from» → Bool) (dto : SubProbability «to») (mp : Lens (EC.FMap («from» × ℤ) «to») VariableAssignment) :

                                proc fill_in of module IRO as a module: Module.proc IRO.fill_in.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.fill_in.apply_simp says exactly that.

                                Equations
                                Instances For

                                  EC's type to, from., op valid, op dto. The types are outParams: a clone of the theory is an instance.

                                  Instances
                                    @[implicit_reducible]
                                    instance GaudisCrypt.SHA3.Pilot.IRO.instIsModuleIRO_T {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                    The IsModule IRO_T instance: IRO_T is a module type, with representation IRO_T.typeRep.

                                    It is what lets the name IRO_T stand where a module type is expected — in Module.Arr/Module.Prod (→ₘ/×ₘ), say — which the underlying Module IRO_T.typeRep would do on its own but IRO_T, a plain (non-reducible) def, would not.

                                    Equations
                                    @[simp]
                                    theorem GaudisCrypt.SHA3.Pilot.IRO.IRO_T.f.mk_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure) :
                                    (mk theRecord✝).f = theRecord✝.f

                                    @[simp]: reading the field f back off a module built from a record — IRO_T.f (IRO_T.mk r) = r.f.

                                    It is what carries the right-hand side of an X.apply_simp (which is an IRO_T.mk) on to the field the caller actually asked for, so that simp chains X.apply_simp into X.f.apply_simp.

                                    @[simp]
                                    theorem GaudisCrypt.SHA3.Pilot.IRO.IRO_T.destruct_mk {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theModule✝ : IRO_T) :
                                    mk theModule✝.structure = theModule✝

                                    @[simp]: IRO_T.mk (IRO_T.structure m) = m — rebuilding a module from its own fields gives that module back.

                                    noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.init {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                    The field init of a module of type IRO_T: the projection onto component 0 of the right-nested tuple IRO_T.typeRep, as a chain of Module.fst'/Module.snd'. Tagged @[module_accessor].

                                    IRO_T.init.mk_simp reads this field back off a module built by IRO_T.mk; IRO_T.init.utilities has the accessor as a module, and the lemmas about it.

                                    It takes no parameters (recorded in @[gaudiProcParamNames]).

                                    Equations
                                    Instances For
                                      noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.f {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :
                                      IRO_T → procmod («from» × ℤ) → List «to»

                                      The field f of a module of type IRO_T: the projection onto component 1 of the right-nested tuple IRO_T.typeRep, as a chain of Module.fst'/Module.snd'. Tagged @[module_accessor].

                                      IRO_T.f.mk_simp reads this field back off a module built by IRO_T.mk; IRO_T.f.utilities has the accessor as a module, and the lemmas about it.

                                      Its parameters are named xn, in that order (recorded in @[gaudiProcParamNames], a ProcedureSignature holding only their types).

                                      Equations
                                      Instances For
                                        @[reducible]
                                        noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.mk {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                        Builds a module of type IRO_T from the record IRO_T.Structure of its fields, as a right-nested Module.pair'. @[reducible].

                                        Inverse of IRO_T.structure (IRO_T.mk_destruct, IRO_T.destruct_mk); a single field of a module built this way is read back by the @[simp] lemmas IRO_T.init.mk_simp, IRO_T.f.mk_simp.

                                        Equations
                                        Instances For
                                          noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.structure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                          The record of a module's fields: IRO_T.structure m is IRO_T.Structure.mk applied to IRO_T.init, IRO_T.f of m.

                                          Inverse of IRO_T.mk (IRO_T.mk_destruct, IRO_T.destruct_mk).

                                          Equations
                                          Instances For
                                            def GaudisCrypt.SHA3.Pilot.IRO.IRO_T {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                            The module type declared by moduletype IRO_T, with fields init, f: the type Module IRO_T.typeRep of modules that are a right-nested tuple of the field types.

                                            Build one from a record of its fields with IRO_T.mk, read a single field off one with the accessors IRO_T.init, IRO_T.f, and get the whole record back with IRO_T.structure.

                                            Equations
                                            Instances For
                                              @[simp]
                                              theorem GaudisCrypt.SHA3.Pilot.IRO.IRO_T.mk_destruct {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure) :
                                              (mk theRecord✝).structure = theRecord✝

                                              @[simp]: IRO_T.structure (IRO_T.mk r) = r — destructing a module built from a record gives that record back.

                                              def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.typeRep {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                              The ModuleTypeRep underlying IRO_T, the module type declared by moduletype IRO_T: the right-nested product of its 2 field types, in declaration order.

                                              IRO_T is by definition Module IRO_T.typeRep.

                                              Equations
                                              Instances For
                                                noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.f.utilities {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                                What is derivable about the accessor IRO_T.f, bundled into one ModuleTypeUtilities (one name per field in the namespace, rather than one per fact):

                                                • IRO_T.f.utilities.accessorModule : IRO_T →ₘ … — the accessor as a module, a projection being a module morphism;
                                                • IRO_T.f.utilities.apply_simp — Module.app IRO_T.f.utilities.accessorModule m = IRO_T.f m: applying that module is the accessor;
                                                • IRO_T.f.utilities.expression_eq — the same at the level of expressions: (IRO_T.f m).expression = (IRO_T.f.utilities.proj m.expression).reduce.
                                                Equations
                                                • One or more equations did not get rendered due to their size.
                                                Instances For
                                                  structure GaudisCrypt.SHA3.Pilot.IRO.IRO_T.Structure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                                  The record of the fields of a module of type IRO_T: the fields init, f, one per moduletype field, each of that field's own module type.

                                                  IRO_T.mk turns such a record into a IRO_T, IRO_T.structure turns a IRO_T back into one.

                                                  Instances For
                                                    noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO_T.init.utilities {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] :

                                                    What is derivable about the accessor IRO_T.init, bundled into one ModuleTypeUtilities (one name per field in the namespace, rather than one per fact):

                                                    • IRO_T.init.utilities.accessorModule : IRO_T →ₘ … — the accessor as a module, a projection being a module morphism;
                                                    • IRO_T.init.utilities.apply_simp — Module.app IRO_T.init.utilities.accessorModule m = IRO_T.init m: applying that module is the accessor;
                                                    • IRO_T.init.utilities.expression_eq — the same at the level of expressions: (IRO_T.init m).expression = (IRO_T.init.utilities.proj m.expression).reduce.
                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For
                                                      @[simp]
                                                      theorem GaudisCrypt.SHA3.Pilot.IRO.IRO_T.init.mk_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] (theRecord✝ : Structure) :
                                                      (mk theRecord✝).init = theRecord✝.init

                                                      @[simp]: reading the field init back off a module built from a record — IRO_T.init (IRO_T.mk r) = r.init.

                                                      It is what carries the right-hand side of an X.apply_simp (which is an IRO_T.mk) on to the field the caller actually asked for, so that simp chains X.apply_simp into X.init.apply_simp.

                                                      def GaudisCrypt.SHA3.Pilot.IRO.prefix_closed {«to» «from» : Type} (m : EC.FMap («from» × ℤ) «to») :
                                                      Equations
                                                      Instances For
                                                        def GaudisCrypt.SHA3.Pilot.IRO.prefix_closed' {«to» «from» : Type} (m : EC.FMap («from» × ℤ) «to») :
                                                        Equations
                                                        Instances For
                                                          theorem GaudisCrypt.SHA3.Pilot.IRO.prefix_closed_equiv {«to» «from» : Type} (m : EC.FMap («from» × ℤ) «to») :

                                                          EC's prefix_closed_equiv m (smt()).

                                                          The official version #

                                                          instance GaudisCrypt.SHA3.Pilot.IRO.instIsGlobalVarFMapProdIntMpMk {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                          IRO.mp.IsGlobalVar (VariableName.mk "GaudisCrypt.SHA3.Pilot.IRO.IRO.mp" (EC.FMap («from» × ℤ) «to»))
                                                          noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.mp {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                          Lens (EC.FMap («from» × ℤ) «to») VariableAssignment
                                                          Equations
                                                          Instances For
                                                            noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.init.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                            The body of proc init of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                                                            A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.init.procedure.apply_simp) rather than run. Use IRO.init for this procedure as a module.

                                                            Equations
                                                            Instances For
                                                              @[simp]
                                                              theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.init.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                              @[simp]: IRO.init = Module.proc IRO.init.procedure — true by definition, proc init using no module parameter and so having no holes to fill.

                                                              noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                              The module declared by module IRO: the record of its procedures IRO.init, IRO.fill_in, IRO.f.

                                                              The declaration has no parameter list, so no procedure of it can call one either and the module is not a function — it is the plain record itself, and there is no IRO.apply_simp to apply it with.

                                                              Equations
                                                              Instances For
                                                                noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.fill_in {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                proc fill_in of module IRO as a module: Module.proc IRO.fill_in.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.fill_in.apply_simp says exactly that.

                                                                Equations
                                                                Instances For
                                                                  @[simp]
                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.fill_in.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                  @[simp]: IRO.fill_in = Module.proc IRO.fill_in.procedure — true by definition, proc fill_in using no module parameter and so having no holes to fill.

                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.init.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                  procedure.instantiate holeArgs✝ = proc () : Unit { mp <- EC.FMap.empty; return () }

                                                                  Instantiating the holes of IRO.init.procedure with a tuple holeArgs of procedures: the body of proc init as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                  Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.init.procedure.apply_simp]).

                                                                  @[simp]
                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.f.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                  @[simp]: IRO.f = Module.proc IRO.f.procedure — true by definition, proc f using no module parameter and so having no holes to fill.

                                                                  noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.f {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :
                                                                  procmod («from» × ℤ) → List «to»

                                                                  proc f of module IRO as a module: Module.proc IRO.f.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.f.apply_simp says exactly that.

                                                                  Equations
                                                                  Instances For
                                                                    noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.f.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :
                                                                    proctype («from» × ℤ) -> List «to»

                                                                    The body of proc f of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                    A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.f.procedure.apply_simp) rather than run. Use IRO.f for this procedure as a module.

                                                                    Equations
                                                                    • One or more equations did not get rendered due to their size.
                                                                    Instances For
                                                                      theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.f.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                      procedure.instantiate holeArgs✝ = proc (xn : «from» × ℤ) : (List «to») { var x : «from», n : ℤ, i : ℤ, bs : List «to», b : «to»; x, n <- §xn; i <- 0; bs <- []; if (valid §x) { while (decide (§i < §n)) { b <- call fill_in.procedure (§x, §i); bs <- EC.rcons §bs §b; i <- §i + 1; } } return §bs }

                                                                      Instantiating the holes of IRO.f.procedure with a tuple holeArgs of procedures: the body of proc f as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                      Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.f.procedure.apply_simp]).

                                                                      theorem GaudisCrypt.SHA3.Pilot.IRO.IRO.fill_in.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                      procedure.instantiate holeArgs✝ = proc (x : «from», n : ℤ) : «to» { var r : «to»; if (!decide ((§mp).dom (§x, §n))) { r <$ dto; mp <- (§mp).set (§x, §n) §r; } return EC.oget ((§mp).get (§x, §n)) }

                                                                      Instantiating the holes of IRO.fill_in.procedure with a tuple holeArgs of procedures: the body of proc fill_in as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                      Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO.fill_in.procedure.apply_simp]).

                                                                      noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.init {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                      proc init of module IRO as a module: Module.proc IRO.init.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO.init.apply_simp says exactly that.

                                                                      Equations
                                                                      Instances For
                                                                        noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO.fill_in.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                        The body of proc fill_in of module IRO, as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                        A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO.fill_in.procedure.apply_simp) rather than run. Use IRO.fill_in for this procedure as a module.

                                                                        Equations
                                                                        • One or more equations did not get rendered due to their size.
                                                                        Instances For

                                                                          The version for the AbsorbToBlocks.ec attempt #

                                                                          instance GaudisCrypt.SHA3.Pilot.IRO.instIsGlobalVarFMapProdIntMpMk_1 {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                                          IRO'.mp.IsGlobalVar (VariableName.mk "GaudisCrypt.SHA3.Pilot.IRO.IRO'.mp" (EC.FMap («from» × ℤ) «to»))
                                                                          noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.mp {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                                          Lens (EC.FMap («from» × ℤ) «to») VariableAssignment
                                                                          Equations
                                                                          Instances For
                                                                            instance GaudisCrypt.SHA3.Pilot.IRO.instIsGlobalVarFSetProdIntVisibleMk {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                                            IRO'.visible.IsGlobalVar (VariableName.mk "GaudisCrypt.SHA3.Pilot.IRO.IRO'.visible" (EC.FSet («from» × ℤ)))
                                                                            noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.visible {«to» «from» : Type} [DecidableEq «from»] [Inhabited «to»] [Inhabited «from»] [Params «to» «from»] :
                                                                            Equations
                                                                            Instances For
                                                                              noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.f_lazy {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                              proc f_lazy of module IRO' as a module: Module.proc IRO'.f_lazy.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO'.f_lazy.apply_simp says exactly that.

                                                                              Equations
                                                                              Instances For
                                                                                theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.resample_invisible.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                                procedure.instantiate holeArgs✝ = proc () : Unit { var work : EC.FSet («from» × ℤ), x : «from» × ℤ, r : «to»; work <- (§mp).fdom \ §visible; while (§work != EC.FSet.fset0) { x <- (§work).pick; r <$ dto; mp <- (§mp).set §x §r; work <- §work \ EC.FSet.fset1 §x; } return () }

                                                                                Instantiating the holes of IRO'.resample_invisible.procedure with a tuple holeArgs of procedures: the body of proc resample_invisible as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                                Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO'.resample_invisible.procedure.apply_simp]).

                                                                                theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.init.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                                procedure.instantiate holeArgs✝ = proc () : Unit { mp <- EC.FMap.empty; visible <- EC.FSet.fset0; return () }

                                                                                Instantiating the holes of IRO'.init.procedure with a tuple holeArgs of procedures: the body of proc init as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                                Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO'.init.procedure.apply_simp]).

                                                                                @[simp]
                                                                                theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.resample_invisible.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                @[simp]: IRO'.resample_invisible = Module.proc IRO'.resample_invisible.procedure — true by definition, proc resample_invisible using no module parameter and so having no holes to fill.

                                                                                noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.f.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :
                                                                                proctype («from» × ℤ) -> List «to»

                                                                                The body of proc f of module IRO', as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                                A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO'.f.procedure.apply_simp) rather than run. Use IRO'.f for this procedure as a module.

                                                                                Equations
                                                                                • One or more equations did not get rendered due to their size.
                                                                                Instances For
                                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.f_lazy.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                                  procedure.instantiate holeArgs✝ = proc (x : «from», i : ℤ) : «to» { (localVarLens "b" «to») <- default; if (valid §x && decide (0 ≤ §i)) { visible <- §visible ∪ EC.FSet.fset1 (§x, §i); (localVarLens "b" «to») <- call fill_in.procedure (§x, §i); } return §(localVarLens "b" «to») }

                                                                                  Instantiating the holes of IRO'.f_lazy.procedure with a tuple holeArgs of procedures: the body of proc f_lazy as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                                  Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO'.f_lazy.procedure.apply_simp]).

                                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.fill_in.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                                  procedure.instantiate holeArgs✝ = proc (x : «from», n : ℤ) : «to» { var r : «to»; if (!decide ((§mp).dom (§x, §n))) { r <$ dto; mp <- (§mp).set (§x, §n) §r; } return EC.oget ((§mp).get (§x, §n)) }

                                                                                  Instantiating the holes of IRO'.fill_in.procedure with a tuple holeArgs of procedures: the body of proc fill_in as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                                  Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO'.fill_in.procedure.apply_simp]).

                                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.f.procedure.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] (holeArgs✝ : HoleSigs.empty.Instantiation) :
                                                                                  procedure.instantiate holeArgs✝ = proc (xn : «from» × ℤ) : (List «to») { var x : «from», n : ℤ, i : ℤ, bs : List «to»; x, n <- §xn; i <- 0; bs <- []; if (valid §x) { visible <- §visible ∪ EC.FSet.fset1 (§x, §n); while (decide (§i < §n)) { (localVarLens "b" «to») <- call fill_in.procedure (§x, §i); bs <- EC.rcons §bs §(localVarLens "b" «to»); i <- §i + 1; } } return §bs }

                                                                                  Instantiating the holes of IRO'.f.procedure with a tuple holeArgs of procedures: the body of proc f as written, with each hole call replaced by the matching holeArgs.lookup (HoleIndex.zero being the first hole the body declared). True by rfl.

                                                                                  Deliberately not @[simp], unlike the other apply_simp lemmas: its right-hand side is the whole body written out, so letting it fire on its own would turn any goal mentioning an instantiated procedure into that body. Inlining a procedure is a step to ask for by name (simp [IRO'.f.procedure.apply_simp]).

                                                                                  noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.f {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :
                                                                                  procmod («from» × ℤ) → List «to»

                                                                                  proc f of module IRO' as a module: Module.proc IRO'.f.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO'.f.apply_simp says exactly that.

                                                                                  Equations
                                                                                  Instances For
                                                                                    noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.resample_invisible {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                    proc resample_invisible of module IRO' as a module: Module.proc IRO'.resample_invisible.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO'.resample_invisible.apply_simp says exactly that.

                                                                                    Equations
                                                                                    Instances For
                                                                                      noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.f_lazy.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                      The body of proc f_lazy of module IRO', as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                                      A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO'.f_lazy.procedure.apply_simp) rather than run. Use IRO'.f_lazy for this procedure as a module.

                                                                                      Equations
                                                                                      • One or more equations did not get rendered due to their size.
                                                                                      Instances For
                                                                                        noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.init {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                        proc init of module IRO' as a module: Module.proc IRO'.init.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO'.init.apply_simp says exactly that.

                                                                                        Equations
                                                                                        Instances For
                                                                                          noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.resample_invisible.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                          The body of proc resample_invisible of module IRO', as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                                          A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO'.resample_invisible.procedure.apply_simp) rather than run. Use IRO'.resample_invisible for this procedure as a module.

                                                                                          Equations
                                                                                          • One or more equations did not get rendered due to their size.
                                                                                          Instances For
                                                                                            @[simp]
                                                                                            theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.init.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                            @[simp]: IRO'.init = Module.proc IRO'.init.procedure — true by definition, proc init using no module parameter and so having no holes to fill.

                                                                                            @[simp]
                                                                                            theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.f.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                            @[simp]: IRO'.f = Module.proc IRO'.f.procedure — true by definition, proc f using no module parameter and so having no holes to fill.

                                                                                            noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO' {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                            The module declared by module IRO': the record of its procedures IRO'.resample_invisible, IRO'.init, IRO'.fill_in, IRO'.f, IRO'.f_lazy.

                                                                                            The declaration has no parameter list, so no procedure of it can call one either and the module is not a function — it is the plain record itself, and there is no IRO'.apply_simp to apply it with.

                                                                                            Equations
                                                                                            • One or more equations did not get rendered due to their size.
                                                                                            Instances For
                                                                                              noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.fill_in.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                              The body of proc fill_in of module IRO', as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                                              A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO'.fill_in.procedure.apply_simp) rather than run. Use IRO'.fill_in for this procedure as a module.

                                                                                              Equations
                                                                                              • One or more equations did not get rendered due to their size.
                                                                                              Instances For
                                                                                                noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.init.procedure {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                                The body of proc init of module IRO', as a procedure of its own: it calls no module parameter, so it has no holes.

                                                                                                A hole stands for a call whose callee is not known here — a module parameter is supplied only when the module is applied — so the body is a ProcedureWithHoles, to be instantiated (see IRO'.init.procedure.apply_simp) rather than run. Use IRO'.init for this procedure as a module.

                                                                                                Equations
                                                                                                • One or more equations did not get rendered due to their size.
                                                                                                Instances For
                                                                                                  @[simp]
                                                                                                  theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.fill_in.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                                  @[simp]: IRO'.fill_in = Module.proc IRO'.fill_in.procedure — true by definition, proc fill_in using no module parameter and so having no holes to fill.

                                                                                                  noncomputable def GaudisCrypt.SHA3.Pilot.IRO.IRO'.fill_in {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                                  proc fill_in of module IRO' as a module: Module.proc IRO'.fill_in.procedure, of type Module.Proc (procsig …). It uses no module parameter, so it is not a function — IRO'.fill_in.apply_simp says exactly that.

                                                                                                  Equations
                                                                                                  Instances For
                                                                                                    @[simp]
                                                                                                    theorem GaudisCrypt.SHA3.Pilot.IRO.IRO'.f_lazy.apply_simp {«to» «from» : Type} [_gaudiParam0 : DecidableEq «from»] [_gaudiParam1 : Inhabited «to»] [_gaudiParam2 : Inhabited «from»] [_gaudiParam3 : Params «to» «from»] :

                                                                                                    @[simp]: IRO'.f_lazy = Module.proc IRO'.f_lazy.procedure — true by definition, proc f_lazy using no module parameter and so having no holes to fill.