Sha256: 01f42cce9703441f166d70fb45927a3c8cfa71f761b973169ee797a1b4a90922
Contents?: true
Size: 354 Bytes
Versions: 16
Compression:
Stored size: 354 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 differentiate(sym=:x) -1 * sin(x) * x.d(sym) end alias_method :d, :differentiate end end end end
Version data entries
16 entries across 16 versions & 1 rubygems