ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Sat, 23 Aug 2014 21:43:17 +0200How to find Smith normal form of a matrix over regular rings?https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/Let $A$ be a matrix over ring $^{\mathbb{Z}}/_{6\mathbb{Z}}$. How to find an invertible matrix $P$ and $Q$ such that the matrix $PAQ$ isa Smith Normal Form of $A$?Fri, 08 Aug 2014 08:38:16 +0200https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/Answer by FrédéricC for <p>Let $A$ be a matrix over ring $^{\mathbb{Z}}/_{6\mathbb{Z}}$. How to find an invertible matrix $P$ and $Q$ such that the matrix $PAQ$ isa Smith Normal Form of $A$?</p>
https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/?answer=23716#post-id-23716This does not make sense. See [Wikipedia](https://en.wikipedia.org/wiki/Smith_normal_form)
sage: R = Zmod(6)
sage: R in Domains()
False
sage: M=matrix(R,[[4,3],[2,1]])
sage: M.smith_form()
---------------------------------------------------------------------------
Traceback (most recent call last)
TypeError: Smith form only defined over Noetherian integral domains
Fri, 08 Aug 2014 10:26:59 +0200https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/?answer=23716#post-id-23716Comment by KnS for <p>This does not make sense. See <a href="https://en.wikipedia.org/wiki/Smith_normal_form">Wikipedia</a></p>
<pre><code>sage: R = Zmod(6)
sage: R in Domains()
False
sage: M=matrix(R,[[4,3],[2,1]])
sage: M.smith_form()
---------------------------------------------------------------------------
Traceback (most recent call last)
TypeError: Smith form only defined over Noetherian integral domains
</code></pre>
https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/?comment=23913#post-id-23913In fact, the error is misleading: it should say that the Smith form makes sense only over Principal ideal rings which are domains (I wrote it like that for emphasis: of course, I mean the Principal Ideal Domains). There is a similar structure theorem for modules over Dedekind domains, but now the torsion-free = projective which is free + fractional ideal. This probably is not implemented. At any rate, this is not Smith normal form (probably, this must be called the Steinitz normal form...).Sat, 23 Aug 2014 21:43:17 +0200https://ask.sagemath.org/question/23711/how-to-find-smith-normal-form-of-a-matrix-over-regular-rings/?comment=23913#post-id-23913