Thank you all in advance.
I want to change the format of this expression
(n + r)^3/n^3 into this
(1+r/n)^3using rules an patterns.
I manage to work this with symbolic exponents. In this example
(n + r)^q/n^q /. (n + r)^q_/n^q_ -> HoldForm[(1 + r/n)^q](*This works with symbolic exp*)
But if I change exponent
q for any number, it won't work any longer.
(n + r)^3/n^3 /. (n + r)^q_/n^q_ -> HoldForm[(1 + r/n)^q] (*This does not work with numeric exp*)