lib/polynomials.rb in polynomials-0.3.0 vs lib/polynomials.rb in polynomials-0.4.0
- old
+ new
@@ -5,15 +5,23 @@
ActiveSupport::Inflector.inflections do |inflect|
inflect.plural /mum$/, '\1ma'
inflect.singular /ma$/, '\1mum'
end
-require 'polynomial'
+require 'exceptions'
+require 'formulas'
require 'set'
-require 'term'
require 'point'
-require 'formulas'
-require 'exceptions'
+require 'term'
+require 'analyzable'
+require 'polynomial'
module Polynomials
+ Infinity = 1.0/0
+end
+
+class Numeric
+ def sign
+ self/self.abs
+ end
end