General

Profile

LitoNico (Lito Nicolai)

Issues

open closed Total
Assigned issues 0 0 0
Reported issues 0 2 2

Activity

07/23/2015

07:38 AM Ruby Feature #10903: [PATCH] Matrix#zip returns a matrix
Marc-Andre Lafortune wrote:
> Hi, sorry I missed your proposal until now, and thanks for the patch.
> ...
No worries! Thanks for taking a look.
Matrix#zip is useful for simply implementing any binary (or n-ary) operation on matrices...
LitoNico (Lito Nicolai)

02/25/2015

04:44 AM Ruby Feature #10903 (Closed): [PATCH] Matrix#zip returns a matrix
Currently:
> x = Matrix.I 2
> x.zip x
=> [[1, 1], [0, 0], [0, 0], [1, 1]] # It's an array!
With the patch:
> x.zip x
=> Matrix[[1, 1], [0, 0], [0, 0], [1, 1]]
And also:
> x.zip x, x # and so on
=...
LitoNico (Lito Nicolai)

02/23/2015

12:03 AM Ruby Bug #10855: [PATCH] Matrix#inverse returns matrix of integers whenever possible
Hello! Are there any further thoughts or consensus on which path to take with this?
Here are the options:
1. When dividing matrices, if the resulting matrix has any rational numbers in it, it is entirely rational numbers--
even if ...
LitoNico (Lito Nicolai)

02/15/2015

10:23 PM Ruby Bug #10855: [PATCH] Matrix#inverse returns matrix of integers whenever possible
Marc-Andre Lafortune wrote:
> Interesting.
> ...
In the Matrix class, scalar divison is implemented by using the usual `/`
operation, which loses precision on `Integer`s but not on `Rational`s. If
the Matrix is a mix of the two, some...
LitoNico (Lito Nicolai)
07:08 PM Ruby Bug #10855 (Third Party's Issue): [PATCH] Matrix#inverse returns matrix of integers whenever possible
Currently, Matrix#inverse returns a matrix of Rationals, even when each
element has a denominator of 1. This leads to
> x = Matrix.identity 3
=> Matrix[[1, 0, 0],
[0, 1, 0],
[0, 0, 1]]
> ...
LitoNico (Lito Nicolai)

Also available in: Atom