Documentation

DescriptiveComplexity.Problems.JobSequencing.Kernel

The certificate of job sequencing #

The syntax of the Σ₁ definition of DescriptiveComplexity.JobSequencing: the existential block and the first-order kernel. What is guessed is

Both walks run on the wide positions of DescriptiveComplexity.Numbers.Wide, since a completion time is a sum of every execution time and a penalty total a sum of every penalty; neither need fit where the instance writes. They are the same five clauses read twice, so the clause family is a function of s, as in DescriptiveComplexity.Problems.Partition.Membership.

What is new here, and what job sequencing needs that no earlier problem did, is comparing two numbers rather than adding them: a job is late when its deadline is smaller than its completion time, and the schedule is good when the bound is not smaller than the penalty total. Both are written by the highest differing position (DescriptiveComplexity.binNum_lt_iff), the deadline and the bound being read on the wide positions through their lowest block (DescriptiveComplexity.binNum_wide_bot).

The existential block #

The relation variables of the certificate: the schedule, the late jobs, and the running totals and carries of the two walks.

  • sched : JIdx

    The schedule.

  • late : JIdx

    The jobs that miss their deadline.

  • ps (s : Bool) : JIdx

    The running total of the walk s.

  • cy (s : Bool) : JIdx

    The carries of the walk s.

Instances For
    Dependency graph
    Dependency graph
    Equations
    Instances For
      Dependency graph
      @[instance_reducible]
      Equations
      • One or more equations did not get rendered due to their size.
      Dependency graph

      The single existential block of the Σ₁ definition of job sequencing: the schedule (binary), the late jobs (unary), and, for each walk, the running totals and the carries (ternary: a job and a wide position, itself a pair).

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

        The symbol of the running total of the walk s.

        Equations
        Instances For
          Dependency graph

          The symbol of the carries of the walk s.

          Equations
          Instances For
            Dependency graph
            Dependency graph
            @[reducible, inline]

            The job symbol in the kernel's vocabulary.

            Equations
            Instances For
              Dependency graph
              @[reducible, inline]

              The position symbol in the kernel's vocabulary.

              Equations
              Instances For
                Dependency graph
                @[reducible, inline]

                The execution-time symbol in the kernel's vocabulary.

                Equations
                Instances For
                  Dependency graph
                  @[reducible, inline]

                  The deadline symbol in the kernel's vocabulary.

                  Equations
                  Instances For
                    Dependency graph
                    @[reducible, inline]

                    The penalty symbol in the kernel's vocabulary.

                    Equations
                    Instances For
                      Dependency graph
                      @[reducible, inline]

                      The bound symbol in the kernel's vocabulary.

                      Equations
                      Instances For
                        Dependency graph
                        @[reducible, inline]

                        The order symbol in the kernel's vocabulary.

                        Equations
                        Instances For
                          Dependency graph
                          @[reducible, inline]

                          The schedule symbol in the kernel's vocabulary.

                          Equations
                          Instances For
                            Dependency graph
                            @[reducible, inline]

                            The late-jobs symbol in the kernel's vocabulary.

                            Equations
                            Instances For
                              Dependency graph
                              @[reducible, inline]

                              The running-total symbol of the walk s in the kernel's vocabulary.

                              Equations
                              Instances For
                                Dependency graph
                                @[reducible, inline]

                                The carry symbol of the walk s in the kernel's vocabulary.

                                Equations
                                Instances For
                                  Dependency graph

                                  Formula builders #

                                  Dependency graph
                                  Dependency graph

                                  The execution time of j has bit 1 at p, as a formula.

                                  Equations
                                  Instances For
                                    Dependency graph
                                    Dependency graph

                                    The penalty of j has bit 1 at p, as a formula.

                                    Equations
                                    Instances For
                                      Dependency graph

                                      The bound has bit 1 at p, as a formula.

                                      Equations
                                      Instances For
                                        Dependency graph
                                        Dependency graph
                                        Dependency graph
                                        Dependency graph
                                        Dependency graph
                                        def DescriptiveComplexity.jqPSF {α : Type} (s : Bool) (i x p : α) :

                                        Bit (x, p) of the running total of the walk s at i, as a formula.

                                        Equations
                                        Instances For
                                          Dependency graph
                                          def DescriptiveComplexity.jqCyF {α : Type} (s : Bool) (i x p : α) :

                                          The carry at (x, p) of the step appending i to the walk s, as a formula.

                                          Equations
                                          Instances For
                                            Dependency graph
                                            def DescriptiveComplexity.jqOrdF {α : Type} (s : Bool) (x y : α) :

                                            The order the walk s follows: the schedule for the completion times, the instance's own order for the penalties.

                                            Equations
                                            Instances For
                                              Dependency graph
                                              def DescriptiveComplexity.jqSelF {α : Type} (s : Bool) (i : α) :

                                              The jobs the walk s adds up: all of them for the completion times, the late ones for the penalties.

                                              Equations
                                              Instances For
                                                Dependency graph
                                                def DescriptiveComplexity.jqWtF {α : Type} (s : Bool) (i p : α) :

                                                The number the walk s adds: the execution time, or the penalty.

                                                Equations
                                                Instances For
                                                  Dependency graph
                                                  noncomputable def DescriptiveComplexity.jqBotF {α : Type} (x : α) :

                                                  x is a minimum of the order, as a formula.

                                                  Equations
                                                  Instances For
                                                    Dependency graph
                                                    noncomputable def DescriptiveComplexity.jqTopF {α : Type} (x : α) :

                                                    x is a maximum of the order, as a formula.

                                                    Equations
                                                    Instances For
                                                      Dependency graph
                                                      noncomputable def DescriptiveComplexity.jqAddF {α : Type} (s : Bool) (i x p : α) :

                                                      The bit the job i contributes to the walk s at the wide position (x, p): its number's bit, in the lowest block, if the walk adds it up.

                                                      Equations
                                                      Instances For
                                                        Dependency graph
                                                        noncomputable def DescriptiveComplexity.jqDlineWF {α : Type} (j x p : α) :

                                                        Bit (x, p) of the deadline of j, read on the wide positions.

                                                        Equations
                                                        Instances For
                                                          Dependency graph
                                                          noncomputable def DescriptiveComplexity.jqBndWF {α : Type} (x p : α) :

                                                          Bit (x, p) of the bound, read on the wide positions.

                                                          Equations
                                                          Instances For
                                                            Dependency graph

                                                            The exclusive or of three formulas, as x ↔ (y ↔ z).

                                                            Equations
                                                            Instances For
                                                              Dependency graph

                                                              The majority of three formulas.

                                                              Equations
                                                              Instances For
                                                                Dependency graph
                                                                noncomputable def DescriptiveComplexity.jqMinItemF {α : Type} (s : Bool) (i : α) :

                                                                i is the first job of the walk s, as a formula.

                                                                Equations
                                                                • One or more equations did not get rendered due to their size.
                                                                Instances For
                                                                  Dependency graph
                                                                  noncomputable def DescriptiveComplexity.jqMaxItemF {α : Type} (s : Bool) (i : α) :

                                                                  i is the last job of the walk s, as a formula.

                                                                  Equations
                                                                  • One or more equations did not get rendered due to their size.
                                                                  Instances For
                                                                    Dependency graph
                                                                    noncomputable def DescriptiveComplexity.jqSuccItemF {α : Type} (s : Bool) (i j : α) :

                                                                    j is the job right after i in the walk s, as a formula.

                                                                    Equations
                                                                    • One or more equations did not get rendered due to their size.
                                                                    Instances For
                                                                      Dependency graph
                                                                      noncomputable def DescriptiveComplexity.jqMinPosnF {α : Type} (p : α) :

                                                                      p is the lowest position, as a formula.

                                                                      Equations
                                                                      • One or more equations did not get rendered due to their size.
                                                                      Instances For
                                                                        Dependency graph
                                                                        noncomputable def DescriptiveComplexity.jqMaxPosnF {α : Type} (p : α) :

                                                                        p is the highest position, as a formula.

                                                                        Equations
                                                                        • One or more equations did not get rendered due to their size.
                                                                        Instances For
                                                                          Dependency graph
                                                                          noncomputable def DescriptiveComplexity.jqSuccPosnF {α : Type} (p q : α) :

                                                                          q is the position right above p, as a formula.

                                                                          Equations
                                                                          • One or more equations did not get rendered due to their size.
                                                                          Instances For
                                                                            Dependency graph
                                                                            noncomputable def DescriptiveComplexity.jqSuccAllF {α : Type} (x y : α) :

                                                                            y is the element right after x in the whole universe, as a formula.

                                                                            Equations
                                                                            • One or more equations did not get rendered due to their size.
                                                                            Instances For
                                                                              Dependency graph
                                                                              noncomputable def DescriptiveComplexity.jqMinWideF {α : Type} (x p : α) :

                                                                              (x, p) is the lowest wide position, as a formula.

                                                                              Equations
                                                                              Instances For
                                                                                Dependency graph
                                                                                noncomputable def DescriptiveComplexity.jqMaxWideF {α : Type} (x p : α) :

                                                                                (x, p) is the highest wide position, as a formula.

                                                                                Equations
                                                                                Instances For
                                                                                  Dependency graph
                                                                                  noncomputable def DescriptiveComplexity.jqSuccWideF {α : Type} (x p y q : α) :

                                                                                  (y, q) is the wide position right above (x, p), as a formula.

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

                                                                                    (x, p) ≤ (y, q) on the wide positions, as a formula.

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

                                                                                      The clauses #

                                                                                      Dependency graph

                                                                                      Kernel clause: the order is transitive.

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

                                                                                        Kernel clause: the order is antisymmetric.

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

                                                                                          Kernel clause: the schedule is transitive.

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

                                                                                            Kernel clause: the schedule is antisymmetric.

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

                                                                                              Kernel clause: the schedule is total.

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

                                                                                                Kernel clause: at the first job of the walk s the running total is that job's contribution.

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

                                                                                                  Kernel clause: each step of the walk s adds a bit.

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

                                                                                                    Kernel clause: each step of the walk s propagates its carry.

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

                                                                                                      Kernel clause: nothing is carried into the lowest wide position.

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

                                                                                                        Kernel clause: nothing is carried out of the highest wide position.

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

                                                                                                          The clauses of one walk.

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

                                                                                                            Kernel clause: a job is late exactly when its deadline is smaller than its completion time, compared at the highest wide position where the two differ.

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

                                                                                                              Kernel clause: the penalty total the second walk ends on does not exceed the bound – there is no wide position carrying the total's bit above which the two agree.

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

                                                                                                                The first-order kernel of the Σ₁ definition of job sequencing.

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

                                                                                                                  Reading an assignment #

                                                                                                                  What the guessed relations mean, and what the numbers the kernel talks about decode to. Everything the walks carry lives on the wide positions, so each number of the instance appears there through its lowest block – named by minimality, since that is all a formula can say, which is why the predicates below quantify over Unit → A the way the kernel's produces.

                                                                                                                  A number of the instance, read on the wide positions: its own bits, in the lowest block.

                                                                                                                  Equations
                                                                                                                  Instances For
                                                                                                                    Dependency graph
                                                                                                                    theorem DescriptiveComplexity.jWide_iff {A : Type} [FirstOrder.Language.jobSeq.Structure A] {b : AProp} {u : A × A} :
                                                                                                                    JWide b u (∀ (y : A), JSLe u.1 y) b u.2
                                                                                                                    Dependency graph
                                                                                                                    theorem DescriptiveComplexity.binNum_jWide {A : Type} [FirstOrder.Language.jobSeq.Structure A] [Finite A] (hlin : IsLinOrd JSLe) {a₀ : A} (h₀ : ∀ (y : A), JSLe a₀ y) (b : AProp) :

                                                                                                                    Read on the wide positions, a number still has its value.

                                                                                                                    Dependency graph

                                                                                                                    The bits the walk s adds up: the execution times, or the penalties.

                                                                                                                    Equations
                                                                                                                    Instances For
                                                                                                                      Dependency graph
                                                                                                                      noncomputable def DescriptiveComplexity.JVal {A : Type} [FirstOrder.Language.jobSeq.Structure A] (s : Bool) (i : A) :

                                                                                                                      The number the walk s adds up: the execution time, or the penalty.

                                                                                                                      Equations
                                                                                                                      Instances For
                                                                                                                        Dependency graph

                                                                                                                        The bit the walk s reads at a wide position.

                                                                                                                        Equations
                                                                                                                        Instances For
                                                                                                                          Dependency graph

                                                                                                                          The deadline of a job, read on the wide positions.

                                                                                                                          Equations
                                                                                                                          Instances For
                                                                                                                            Dependency graph
                                                                                                                            Dependency graph
                                                                                                                            theorem DescriptiveComplexity.binNum_jWt {A : Type} [FirstOrder.Language.jobSeq.Structure A] [Finite A] (hlin : IsLinOrd JSLe) {a₀ : A} (h₀ : ∀ (y : A), JSLe a₀ y) (s : Bool) (i : A) :
                                                                                                                            Dependency graph
                                                                                                                            theorem DescriptiveComplexity.binNum_jDlineW {A : Type} [FirstOrder.Language.jobSeq.Structure A] [Finite A] (hlin : IsLinOrd JSLe) {a₀ : A} (h₀ : ∀ (y : A), JSLe a₀ y) (j : A) :
                                                                                                                            Dependency graph
                                                                                                                            Dependency graph

                                                                                                                            The schedule, read off an assignment of the block.

                                                                                                                            Equations
                                                                                                                            Instances For
                                                                                                                              Dependency graph

                                                                                                                              The late jobs, read off an assignment of the block.

                                                                                                                              Equations
                                                                                                                              Instances For
                                                                                                                                Dependency graph
                                                                                                                                def DescriptiveComplexity.JPS {A : Type} (ρ : jobSeqGuessBlock.Assignment A) (s : Bool) (i : A) (u : A × A) :

                                                                                                                                The running total of the walk s, read off an assignment of the block.

                                                                                                                                Equations
                                                                                                                                Instances For
                                                                                                                                  Dependency graph
                                                                                                                                  def DescriptiveComplexity.JCy {A : Type} (ρ : jobSeqGuessBlock.Assignment A) (s : Bool) (i : A) (u : A × A) :

                                                                                                                                  The carries of the walk s, read off an assignment of the block.

                                                                                                                                  Equations
                                                                                                                                  Instances For
                                                                                                                                    Dependency graph

                                                                                                                                    The order the walk s follows: the guessed schedule for the completion times, the instance's own order for the penalties.

                                                                                                                                    Equations
                                                                                                                                    Instances For
                                                                                                                                      Dependency graph

                                                                                                                                      The jobs the walk s adds up: all of them for the completion times, the late ones for the penalties.

                                                                                                                                      Equations
                                                                                                                                      Instances For
                                                                                                                                        Dependency graph