Question: How do I substitute the base of an ifactor result?

I wish to substitute only the base of the ifactor expression like the following

lst := [24300, 18907875, 151200, 147000]

[24300, 18907875, 151200, 147000]

(1)

map(ifactor, lst)

[``(2)^2*``(3)^5*``(5)^2, ``(3)^2*``(5)^3*``(7)^5, ``(2)^5*``(3)^3*``(5)^2*``(7), ``(2)^3*``(3)*``(5)^3*``(7)^2]

(2)

subs(2 = x, %)

[``(x)^x*``(3)^5*``(5)^x, ``(3)^x*``(5)^3*``(7)^5, ``(x)^5*``(3)^3*``(5)^x*``(7), ``(x)^3*``(3)*``(5)^3*``(7)^x]

(3)

I wish my results to be

[x^2*3^5*5^2, 3^2*5^3*7^5, 7*x^5*3^3*5^2, 3*x^3*5^3*7^2]

[6075*x^2, 18907875, 4725*x^5, 18375*x^3]

(4)

such that

subs(x = 2, %)

[24300, 18907875, 151200, 147000]

(5)

evalb(% = lst)

true

(6)

NULL

Download SubsExample.mw

If there a way to do that? I understand that there is a command ifactors which gives me more control, but the form of the result is rather inconvenient. I hope there is a more direct way to do the aforementioned operation.

Please Wait...