Sha256: 251fedbf594b16783468435a888f41afe450328a41273b56413f60ed62454a36

Contents?: true

Size: 302 Bytes

Versions: 1

Compression:

Stored size: 302 Bytes

Contents

module Dydx
  module Algebra
    module Set
      class Cos < Base
        attr_accessor :x

        def initialize(x)
          @x = x
        end

        def to_s
          "cos( #{x.to_s} )"
        end

        def d(sym=:x)
          -1 * sin(x) * x.d(sym)
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
dydx-0.0.1 lib/dydx/algebra/set/cos.rb