# dualize -- finds an ideal or module isomorphic to Hom(M, R)

## Synopsis

• Usage:
dualize( I1 )
dualize( M1 )
• Inputs:
• Optional inputs:
• KnownDomain => , default value true, assume the ambient ring is a domain
• Strategy => , default value NoStrategy, specify the strategy of dualize
• Outputs:

## Description

This computes $Hom_R(M, R)$.

 i1 : R = QQ[x,y,z]/ideal(x^2-y*z); i2 : m = ideal(x,y,z); o2 : Ideal of R i3 : dualize(m) o3 = ideal x o3 : Ideal of R i4 : I = ideal(x,y); o4 : Ideal of R i5 : dualize(I) o5 = ideal (z, x) o5 : Ideal of R i6 : dualize(I^2) o6 = ideal z o6 : Ideal of R i7 : dualize(I^3) 2 o7 = ideal (z , x*z) o7 : Ideal of R

If Strategy => IdealStrategy, then dualize assume the module is isomorphic to an ideal, embeds it as an ideal, and computes the dual by forming a colon. ModuleStrategy simply computes the Hom. The default Strategy for modules is ModuleStrategy, and the default Strategy for ideals is IdealStrategy. This is because there is overhead using the opposite strategy (involving embedding modules as ideals). Frequently IdealStrategy is faster, but not always. Consider first a D4 singularity in characteristic 2.

 i8 : R = ZZ/2[x,y,z]/ideal(z^2-x*y*z-x^2*y-x*y^2); i9 : m = ideal(x,y,z); o9 : Ideal of R i10 : J = m^9; o10 : Ideal of R i11 : M = J*R^1; i12 : time dualize(J, Strategy=>IdealStrategy); -- used 0.049881 seconds o12 : Ideal of R i13 : time dualize(J, Strategy=>ModuleStrategy); -- used 0.850981 seconds o13 : Ideal of R i14 : time dualize(M, Strategy=>IdealStrategy); -- used 1.0612 seconds i15 : time dualize(M, Strategy=>ModuleStrategy); -- used 0.0027893 seconds i16 : time embedAsIdeal dualize(M, Strategy=>ModuleStrategy); -- used 0.00273186 seconds o16 : Ideal of R

For monomial ideals in toric rings, frequently ModuleStrategy appears faster.

 i17 : R = ZZ/7[x,y,u,v]/ideal(x*y-u*v); i18 : I = ideal(x,u); o18 : Ideal of R i19 : J = I^15; o19 : Ideal of R i20 : time dualize(J, Strategy=>IdealStrategy); -- used 0.103817 seconds o20 : Ideal of R i21 : time dualize(J, Strategy=>ModuleStrategy); -- used 0.0060857 seconds o21 : Ideal of R

KnownDomain is an option for dualize. If it is false (default is true), then the computer will first check whether the ring is a domain, if it is not then it will revert to ModuleStrategy. If KnownDomain is set to true for a non-domain, then the function can return an incorrect answer.

 i22 : R = QQ[x,y]/ideal(x*y); i23 : J = ideal(x,y); o23 : Ideal of R i24 : dualize(J, KnownDomain=>true) o24 = ideal x o24 : Ideal of R i25 : dualize(J, KnownDomain=>false) o25 = ideal (y, x) o25 : Ideal of R