Skip to content

Incorrect matrix inverse over SR #38336

Open
@galashin

Description

Steps To Reproduce

M = Matrix(SR,[[-0.193469699433335, -0.183934430242923, -9.23026395957241, -234.680519425251, -4.56220425542616, -1.00000000000000, 0],
[-4.41006516415701, -4.04624755225825, -34.3402432065932, -712.818780249295, -9.03026688522083, 0, 1.00000000000000],
[-2.65271365792984, -2.42946892291712, -15.3627946531470, -289.367653048543, -2.62301553224534, 0, 0],
[-2.42930274338041, -2.22351202430932, -12.6512341012439, -230.654739849570, -1.95615689827990, 0, 0],
[-5.02850517118872, -0.940972164125432, -19.9103986565546, -236.148509713831, -8.90077623301954, 7.46410161513775, -6.46410161513775],
[-0.0799721747292845, -8.59828369225104, 3.94544109797720, -103.092869883371, 13.5928135282255, -12.9282032302755, 10.1961524227066],
[-5.35162679183391, 2.77378312755603, -12.0987003087950, -73.6532885076776, -7.76222579473772, 6.46410161513775, -4.73205080756887]])
print(M.inverse() * M)

Expected Behavior

Identity matrix expected

Actual Behavior

Does not output anything close to the identity matrix. Removing SR, from the matrix definition produces the identity matrix.

Additional Information

No response

Environment

- **OS**: Mac OS Ventura 13.5.1
- **Sage Version**: 10.0

Checklist

  • I have searched the existing issues for a bug report that matches the one I want to file, without success.
  • I have read the documentation and troubleshoot guide

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions