Hi Michael! On 4 Nov., 20:55, Michael Orlitzky <mich...@orlitzky.com> wrote: [...] > > it starts using floating point numbers internally. > > I didn't tell it to do that.
You did. 0.5 is a floating point number. > Ok, but (assuming it can be done) how do you propose I convert my > problem to an exact field? By hand? If only there were some sort of > program... There is a simple program (namely the method change_ring()). Starting with your example: sage: n = matrix([ [-0.3, 0.2, 0.1],[0.2, -0.4, 0.4],[0.1, 0.2, -0.5] ]) sage: m = n.change_ring(QQ) sage: m [-3/10 1/5 1/10] [ 1/5 -2/5 2/5] [ 1/10 1/5 -1/2] So, n.change_ring(QQ) tries to interprete the approximate data as exact fractions. It might not always be as easy, but here it works: sage: m.echelon_form() [ 1 0 -3/2] [ 0 1 -7/4] [ 0 0 0] Cheers, Simon --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---