However, I wonder why the adjugate method is not implemented by standard in case of the determinant being a unit. :-/

Regards,
Michael

Von meinem Huawei-Mobiltelefon gesendet


-------- Originalnachricht --------
Betreff: Re: [sage-devel] Matrix Inverse for Arbitrary Rings
Von: Michael Jung
An: sage-devel@googlegroups.com
Cc:


Thanks for you answer.

Ah well, I already tried to compute the adjugate of a corresponding
scalar field matrix, but it threw an error due to the is_field method.
So I thought it is not possible since the ring is no field (what I found
really strange, but god knows what algorithms are used). But I just
added a "proof=True" argument to scalar fields and now it's fine. I get
the feeling, interpreting error messages correctly is some kind of art. :D

Best regards,

Michael

Am 12.07.19 um 17:20 schrieb Vincent Delecroix:
> Or directly through the adjugate method
>
> sage: R. = ZZ[]
> sage: RR = R.quotient(a*d-b*c-1)
> sage: a,b,c,d = RR.gens()
> sage: m = matrix(2, [a,b,c,d])
> sage: n = m.adjugate()    # we know that det=1 in this case
> sage: m * n
> [1 0]
> [0 1]
>
> Le 12/07/2019 à 16:53, Vincent Delecroix a écrit :
>> Dear Michael,
>>
>> At least, you need to know that the determinant is invertible...
>> See the related tickets
>>
>> https://trac.sagemath.org/ticket/15160
>> https://trac.sagemath.org/ticket/27869
>>
>> Note that the division free inversion of matrices is not a
>> completely trivial task. A simple way is to go via the matrix
>> of cofactors by computing determinant with division free
>> algorithms. This should be reasonable enough.
>>
>> Best
>> Vincent
>>
>> Le 12/07/2019 à 16:43, Michael Jung a écrit :
>>> Dear developers,
>>> I need to compute the inverses of matrices over commutative rings
>>> (namely
>>> scalar fields on manifolds). Unfortunately, the algorithms only
>>> process if
>>> the ring is a field or a corresponding fraction field is known. For
>>> now, I
>>> will pretend that the algebra of scalar fields is an algebraic field.
>>> However, for most cases, the algorithms work for arbitrary rings aswell
>>> when the matrix is invertible. I wonder why that hasn't been
>>> implemented
>>> yet. It would be nice if there was (for example) an additional
>>> attribute
>>> (something like "force=True") for the inverse function to pretend
>>> that the
>>> given ring is a field and at least try a computation.
>>>
>>> Best regards,
>>> Michael
>>>
>

--
You received this message because you are subscribed to a topic in the Google Groups "sage-devel" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/sage-devel/4WVPLOHyMbc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-devel/01b4c7c8-f4a6-a816-35b3-4614300a6178%40uni-potsdam.de.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
To view this discussion on the web visit https://groups.google.com/d/msgid/sage-devel/dl7pqn-savxcy-c3kyrr-ld2v7z-oouf47-unxr5iijgtgt6znkqiunpzgc-gim7j-wss1rww1px0bee6l75-y2bm7n-6lcrnt-seeslnrvzqjq-249vzu-5z0fob-t3ken-edzk4u-oze8q7-ji71vv7rgxx2.1562949872823%40email.android.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to