常定です。 > 以前から気になっていたのですが、次のように通常のComplexとの > 相性が悪いような気がします。これはこういうものでしょうか? > それとも回避可能でしょうか? > $ irb > irb(main):001:0> require 'gsl' > => true > irb(main):002:0> require 'complex' > => true > irb(main):003:0> Complex(1, 1) > => Complex(nil, nil) モジュール指定して下さい。 irb(main):001:0> require("gsl") => true irb(main):002:0> require("complex") => false irb(main):003:0> a = Complex(2, 3) => Complex(2, 3) irb(main):004:0> b = GSL::Complex.new(2, 3) => GSL::Complex [ 2.000000 3.000000 ] irb(main):005:0> a + 1 => Complex(3, 3) irb(main):006:0> b + 1 => GSL::Complex [ 3.000000 3.000000 ]