# dimViaBezout -- computes the dimension of the given ideal $I$ probabilistically

## Synopsis

• Usage:
dimViaBezout(I)
• Inputs:
• I, an ideal, in a polynomial ring over a field
• Optional inputs:
• DimensionIntersectionAttempts => an integer, default value null, the number of linear spaces to try before moving to the next dimension
• MinimumFieldSize => an integer, default value null, if the ambient field is smaller than this value it will automatically be replaced with an extension
• Homogeneous => ..., default value true
• Replacement => ..., default value Full, When changing coordinates, whether to replace variables by general degre 1 forms, binomials, etc.
• Verbose => ..., default value false
• Outputs:
• an integer, d = dimension of the ideal $I$

## Description

This intersects $V(I)$ with successively higher dimensional random linear spaces until there is an intersection. For example, if $V(I)$ intersect a random line has a point, then we expect that $V(I)$ contains a hypersurface. If there was no intersection, this function tries a 2-dimensional linear space, and so on. This greatly speeds up some computations, although in other examples, the built in dim function is much faster.

 i1 : kk=ZZ/101; i2 : S=kk[y_0..y_8]; i3 : I=ideal random(S^1,S^{-2,-2,-2,-2})+(ideal random(2,S))^2; o3 : Ideal of S i4 : elapsedTime dimViaBezout(I) -- 1.49651 seconds elapsed o4 = 4 i5 : elapsedTime dim I -- 4.69892 seconds elapsed o5 = 4

The user may set the MinimumFieldSize to ensure that the field being worked over is big enough. For instance, there are relatively few linear spaces over a field of characteristic 2, and this can cause incorrect results to be provided. If no size is provided, the function tries to guess a good size based on ambient ring.

If the option Homogeneous=>true then we use homogeneous linear spaces if the ideal itself is homogeneous. Otherwise our linear spaces are not homogeneous.

The user may also specify what sort of linear forms to intersect with via the Replacement option.