LUSolve

module LUSolve

Solves a*x = b for x, using LU decomposition.

Public Instance Methods

ludecomp(a,n,zero=0,one=1) Show source

Performs LU decomposition of the n by n matrix a.

# File ext/bigdecimal/lib/bigdecimal/ludcmp.rb, line 11
  def ludecomp(a,n,zero=0,one=1)
    prec = BigDecimal.limit(nil)
    ps     = []
    scales = []
    for i in 0...n do  # pick up largest(abs. val.) element in each row.
      ps <