Sha256: 001c6454c84c24609289898039815a36a563a0cb9d942c179e2ed13498d53133

Contents?: true

Size: 830 Bytes

Versions: 2

Compression:

Stored size: 830 Bytes

Contents

require 'set'

module Dither

  class Error < StandardError; end

  DEFUALT_OPTS = {
    :t => 2
  }

  # deprecated
  def self.all_pairs(params, t = 2, opts = {})
    opts[:t] = t
    IPOG.new(params, opts).run
  end

  def self.ipog(params, opts = {})
    opts = DEFUALT_OPTS.dup.merge(opts)
    IPOG.new(params, opts).run
  end

  def self.mipog(params, t = 2, opts = {})
    raise Error, 'mipog does not support constraints' if opts.key?(:constraints)
    opts[:t] = t
    MIPOG.new(params, opts).run
  end
end # Dither

require 'dither/param'
require 'dither/unbound_param'
require 'dither/test_case'
require 'dither/ipog_helper'
require 'dither/ipog'
require 'dither/mipog'
require 'dither/chinese_postman_problem'

if RUBY_PLATFORM =~ /java/
  require 'java'
  require 'dither.jar'

  require 'dither/java_ext/dither'
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
dither-0.0.11-java lib/dither.rb
dither-0.0.11 lib/dither.rb