Module: MathViz::Measurable

Includes:
Units
Included in:
Numeric
Defined in:
lib/mathviz.rb

Overview

Something (i.e. Numeric) which does not have MathViz::Units, but can be turned into something which does (i.e., MathViz::Constant)

Instance Method Summary collapse

Methods included from Units::Class

#included, #new_units

Instance Method Details

#perObject

return constant wrapping self with new units assigned to the denominator



173
174
175
# File 'lib/mathviz.rb', line 173

def per
  MathViz::Constant.new(self).per
end

#unit(x) ⇒ Object

return constant wrapping self with the specified units; see also MathViz::Units::Class#new_units



168
169
170
# File 'lib/mathviz.rb', line 168

def unit(x)
  MathViz::Constant.new(self).unit(x)
end