Sha256: 064a818dbda89a3783bd5de3726a1bf59bdc08c3aa27e3b79b445868f02130ba

Contents?: true

Size: 297 Bytes

Versions: 3

Compression:

Stored size: 297 Bytes

Contents

require 'facets/math/cot'
require 'facets/numeric/range'  # used to test within a precision

test_case Math do

  class_method :cot do
    test do
      Math.cot(1.0).range(1.0e-6).assert === 1.0 / Math.tan(1.0)
      Math.cot(2.0).range(1.0e-6).assert === 1.0 / Math.tan(2.0) 
    end
  end

end

Version data entries

3 entries across 3 versions & 2 rubygems

Version Path
facets-glimmer-3.2.0 test/standard/math/test_cot.rb
facets-3.1.0 test/standard/math/test_cot.rb
facets-3.0.0 test/standard/math/test_cot.rb