Documentation

Complexity.Algorithms.WordRAM.ThreeSum.Host.Slow

A finite exhaustive native Exact Triangle callee #

This reference implementation enumerates the actual triples, loads all three encoded matrix weights, and compares the sums of their positive and negative magnitudes. No solver instruction, host execution premise or precomputed verdict occurs in its code. It is library code because its certification witnesses that Host.Callee can be satisfied by a concrete finite program.

Main definitions #

This exhaustive native implementation and its certification are original.

@[reducible, inline]

Raw number of vertices per part.

Instances For
    @[reducible, inline]

    AB matrix pointer.

    Instances For
      @[reducible, inline]

      BC matrix pointer.

      Instances For
        @[reducible, inline]

        AC matrix pointer.

        Instances For
          @[reducible, inline]

          The free-pointer argument is overwritten by zero after entry.

          Instances For
            @[reducible, inline]

            Raw Boolean return value.

            Instances For
              @[reducible, inline]

              Next flattened triple.

              Instances For
                @[reducible, inline]

                Number of cells per matrix.

                Instances For
                  @[reducible, inline]

                  Number of triples.

                  Instances For
                    @[reducible, inline]

                    Loop increment.

                    Instances For
                      @[reducible, inline]

                      Sign-and-magnitude radix.

                      Instances For
                        @[reducible, inline]

                        First vertex index.

                        Instances For
                          @[reducible, inline]

                          Second vertex index.

                          Instances For
                            @[reducible, inline]

                            Third vertex index.

                            Instances For
                              @[reducible, inline]

                              Actual matrix-load address.

                              Instances For

                                The three actual loaded edge words.

                                Instances For
                                  @[reducible, inline]

                                  Sum of positive magnitudes.

                                  Instances For
                                    @[reducible, inline]

                                    Sum of negative magnitudes.

                                    Instances For
                                      @[reducible, inline]

                                      Magnitude of the current encoded edge.

                                      Instances For
                                        @[reducible, inline]

                                        Sign bit of the current encoded edge.

                                        Instances For
                                          @[reducible, inline]

                                          Flattened second and third vertex indices.

                                          Instances For

                                            Add one encoded edge to its positive or negative magnitude sum.

                                            Instances For

                                              Compute three indices and load the three corresponding matrix cells.

                                              Instances For

                                                Retain a found zero-weight triangle and advance to the next triple.

                                                Instances For

                                                  Initialize every scratch value used before the first triple.

                                                  Instances For

                                                    Exhaust all t³ triples using native division/remainder and actual matrix loads.

                                                    Instances For

                                                      Actual finite cubic-time solver used to inhabit the complete host's callee contract. It preserves all memory, works on arbitrary signed matrices, and never reads physical width.

                                                      Instances For