Sha256: 394d6f666499b25cadda7f86fa76fbb06923e641e3842db2a79882ccc8bca65f

Contents?: true

Size: 460 Bytes

Versions: 6

Compression:

Stored size: 460 Bytes

Contents

require File.dirname(__FILE__) + '/spec_helper.rb'

describe MPFI::Matrix, "when subdividing interval" do
  before(:all) do
    @size = MPFR.new('1')
    @arg = MPFI::ColumnVector.new([MPFI.interval(-1.8, -1.729), MPFI.interval('-1e-2', '8.2e-2'), MPFI.interval('1.82', '2.27')])
  end
  
  it "should return unchanged object" do
    res = @arg.subdivision_by_size(@size)
    res.size.should eql 1
    res.each { |a| a.max_diam_abs.should <= @size }
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
ruby-mpfi-0.0.7 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb
ruby-mpfi-0.0.6 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb
ruby-mpfi-0.0.5 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb
ruby-mpfi-0.0.4 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb
ruby-mpfi-0.0.3 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb
ruby-mpfi-0.0.2 spec/mpfi_matrix/mpfi_matrix_subdivision_spec.rb