Project

General

Profile

Bug #1531

Matrix#determinant fails on some matrices

Added by marcandre (Marc-Andre Lafortune) about 10 years ago. Updated about 8 years ago.

Status:
Closed
Priority:
Normal
Target version:
ruby -v:
ruby 1.9.2dev (2009-05-24 trunk 23554) [i386-darwin9.7.0]
Backport:
[ruby-core:23597]

Description

=begin
ruby1.9 -r matrix -e 'Matrix0,1],[1,0.determinant'
/usr/local/ruby191/lib/ruby/1.9.1/matrix.rb:685:in block (2 levels) in determinant': undefined method+' for nil:NilClass (NoMethodError)
from /usr/local/ruby191/lib/ruby/1.9.1/matrix.rb:684:in loop'
from /usr/local/ruby191/lib/ruby/1.9.1/matrix.rb:684:in
block in determinant'
from /usr/local/ruby191/lib/ruby/1.9.1/matrix.rb:681:in loop'
from /usr/local/ruby191/lib/ruby/1.9.1/matrix.rb:681:in
determinant'
from -e:1:in `'

Same with determinant_e.

To fix: gsub('ii','i') in matrix.rb
=end

History

#1

Updated by yugui (Yuki Sonoda) almost 10 years ago

  • Assignee set to keiju (Keiju Ishitsuka)

=begin

=end

#2

Updated by marcandre (Marc-Andre Lafortune) almost 10 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

=begin
Applied in changeset r24949.
=end

Also available in: Atom PDF