Skip to content

Commit

Permalink
ComplexPair should be just Complex in rationa.j.
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanKarpinski committed Aug 6, 2011
1 parent 955079b commit 8ac33c1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions j/rational.j
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ Rational(n::Int) = Rational(n, one(n))
//(n::Int, d::Int) = Rational(n,d)
//(x::Rational, y::Int) = x.num // (x.den*y)
//(x::Int, y::Rational) = (x*y.den) // y.num
//(x::ComplexPair, y::Real) = complex(real(x)//y, imag(x)//y)
//(x::Real, y::ComplexPair) = x*y'//real(y*y')
//(x::Complex, y::Real) = complex(real(x)//y, imag(x)//y)
//(x::Real, y::Complex) = x*y'//real(y*y')

function //(x::ComplexPair, y::ComplexPair)
function //(x::Complex, y::Complex)
xy = x*y'
yy = real(y*y')
complex(real(xy)//yy, imag(xy)//yy)
Expand Down

0 comments on commit 8ac33c1

Please sign in to comment.