finding out if expr has the form F(y/x^a)



It should be easy to fix, but:

  (%i4) solution(1/(y-1/x),x,y);
  expt: undefined: 0 to a negative exponent.

--Barton

________________________________________


solution(g,x,y):=block
(
[g2,g3,g6,a],
g2:g*x/y,
g3:at(g2,y=1/x),
if is(equal(g3,g2))=true then
(g6:1,a:%r)
else
(g6:at(diff(at(g,y=x),x)/diff(g3,x),x=1),a:-ratsimp((g6+1)/(g6-1))),
f:at(g*x/y,y=x^(a+1)),
if is(equal(radcan(rat(g-y/x*at(f,[x=y/x^a]))),0))=true then
['a=a,'f(x)=f]
)$