A morphism of varieties is dominant if the image is dense. For a toric map, it suffices to check that the dimension of the image is the dimension of the target.
We demonstrate that the natural inclusion from the affine plane into the projective plane is a dominant, but not surjective
i1 : A = affineSpace 2; |
i2 : P = toricProjectiveSpace 2; |
i3 : f = map(P, A, 1) o3 = | 1 0 | | 0 1 | o3 : ToricMap P <--- A |
i4 : isDominant f o4 = true |
i5 : isSurjective f o5 = false |
i6 : assert (isWellDefined f and isDominant f and not isSurjective f) |
A toric map from the projective line to the projective plane is not dominant.
i7 : X = toricProjectiveSpace 1; |
i8 : g = map(P, X, matrix{{2}, {1}}) o8 = | 2 | | 1 | o8 : ToricMap P <--- X |
i9 : isDominant g o9 = false |
i10 : I = ideal g 2 o10 = ideal(x x - x ) 0 1 2 o10 : Ideal of QQ[x ..x ] 0 2 |
i11 : assert (isWellDefined g and not isDominant g and codim I === 1) |
To avoid repeating a computation, the package caches the result in the CacheTable of the toric map.