15Ambiguity Resolution

Ambiguity Resolution

This chapter gives examples of how ambiguity resolution might be used in promotion upgrades, splits, or merges. You might use ambiguity resolution differently, depending on your business model. This chapter includes the following topics:

Sum of Assets Greater Than MAX Cardinality

The promotion has a product component with multiple instances among the assets. If the sum of the assets is greater than the MAX cardinality defined in the promotion, then there is an ambiguity.

    Sequence 1

    Promotion Def
    Prom1
    |
    |-> Prod1(1,1,1)
    Installed Assets
    Asset Qty
    -------- ----
    Prod1 1
    Prod1 1
    Results in an Ambiguity

      Sequence 2

      Promotion Def
      Prom1
      |
      |-> Prod1(,,)
      Installed Assets
      Asset Qty
      -------- ----
      Prod1 1
      Prod1 1
      No Ambiguity

        Sequence 3

        Promotion Def
        Prom1
        |
        |-> Prod1(2,,)
        Installed Assets Installed Assets
        Asset Qty Asset Qty
        -------- ---- -------- ----
        Prod1 1 Prod1 1
        Prod1 1 Prod1 2
        No Ambiguity No Ambiguity

          Sequence 4

          Promotion Def
          Prom1
          |
          |-> Prod1(,2,)
          Installed Assets Installed Assets
          Asset Qty Asset Qty
          -------- ---- -------- ----
          Prod1 1 Prod1 2
          Prod1 1 Prod1 2
          No Ambiguity Results in an Ambiguity

            Conclusion

            • If no MAX cardinality is defined, then there is no ambiguity.

            • If MAX cardinality is defined, then sum up the Qty (in assets). If the sum is:

              • Less than MAX, then there is no ambiguity

              • Greater than MAX, then it is ambiguous

              Same Product Component Twice

              The promotion has the same product component twice, which results in an ambiguity. The asset has one instance of the promotion component.

                Sequence 1

                Promotion Def
                Prom1
                |-> Prod1(1,1,1)
                |-> Prod1(1,1,1)
                Installed Assets
                Asset Qty
                -------- ----
                Prod1 1
                Results in an Ambiguity

                  Sequence 2

                  Promotion Def
                  Prom1
                  |-> Prod1(1,1,1)
                  |-> Prod1(1,2,2)
                  Installed Assets Installed Assets
                  Asset Qty Asset Qty
                  -------- ---- -------- ----
                  Prod1 1 Prod1 2
                  Results in an Ambiguity No Ambiguity

                    Sequence 3

                    Promotion Def
                    Prom1
                    |-> Prod1(,,)
                    |-> Prod1(,,)
                    Installed Assets
                    Asset Qty
                    -------- ----
                    Prod1 1
                    Results in an Ambiguity

                      Sequence 4

                      Promotion Def
                      Prom1
                      |-> Prod1(,,)
                      |-> Prod1(1,1,1)
                      Installed Assets Installed Assets
                      Asset Qty Asset Qty
                      -------- ---- -------- ----
                      Prod1 1 Prod1 2
                      Results in an Ambiguity No Ambiguity

                        Conclusion

                        If the Product quantity in the installed assets matches more than one Product cardinality (in the Promotion Def, that is, Asset QTY falls between MIN and MAX cardinalities of more than one Promotion Def), then treat it as ambiguous.

                          Multiple Assets of the Same Product

                          There is more than one asset of the same product and that product is in the promotion more than once. If there is a n::m relationship between installed assets and Promotion Def, then treat it as ambiguous. (This is the simplest solution.)