-- -*- M2-comint -*- hash: 9397571824118617119

i1 : PP2 = toricProjectiveSpace 2

o1 = PP2

o1 : NormalToricVariety

i2 : D1 = toricDivisor ({2,-7,3}, PP2)

o2 = 2*PP2  - 7*PP2  + 3*PP2
          0        1        2

o2 : ToricDivisor on PP2

i3 : assert isWellDefined D1

i4 : debugLevel = 1;

i5 : D2 = new ToricDivisor from hashTable { 0 => 2, symbol variety => PP2, symbol cache => new CacheTable};

o5 : ToricDivisor on PP2

i6 : assert not isWellDefined D2
-- missing key(s): {1, 2}

i7 : D3 = new ToricDivisor from hashTable { 0 => 2, 1 => x, 2 => 3, symbol variety => PP2, symbol cache => new CacheTable};

o7 : ToricDivisor on PP2

i8 : assert not isWellDefined D3
expected 1-th coefficient to be an integer

i9 : D4 = new ToricDivisor from hashTable { 0 => 2, 1 => -7, 2 => 3, symbol variety => 7, symbol cache => new CacheTable};

o9 : ToricDivisor on 7

i10 : assert not isWellDefined D4
expected a divisor over a normal toric variety

i11 : 
