I have a few beastly mathematical expressions that I need to use in C++, but I got it from Maple. Maple uses "^" as the exponentiation operator, incompatible with C (which uses pow().
So, I need a script to go from a^b to pow(a,b).
For instance, here's one of them:
1/12/d/k/tan(b)/a*((6*sqrt(3)*r*sqrt(-k^4*a^4-a^4*d^4*tan(b)^4*k^2-2*a^4*d^2*tan(b)^2*k^3+4*k^3*a^3*r*tan(b)^2-4*k^2*a^2*r^2*tan(b)^4-2*a^4*tan(b)^4*d^2*k^2+4*a^3*tan(b)^4*k^2*r-2*a^4*tan(b)^2*k^3-a^4*tan(b)^4*k^2+4*a^3*d^2*tan(b)^4*k^2*r-16*r*k^4*d*tan(b)^2*a^2+k^3*a^4+a^4*tan(b)^6+3*a^4 *tan(b)^6*d^2+a^4*d^6*tan(b)^6-8*a*r^3*tan(b)^6+3*a^4*tan(b)^2*k^2+12*a^2*tan(b)^ 6*r^2-6*a^3*tan(b)^6*r+3*a^4*tan(b)^6*d^4-12*a^3*d^2*tan(b)^4*k*r+3*a^4*d^2*tan(b)^2*k^2-12*a^3*tan(b)^6*d^2*r+6*a^4*tan(b)^4*d^2*k+12*a^2* d^2*tan(b)^6*r^2+27*r^2*tan(b)^4*d^2*k^2+3*a^4*d^4 *tan(b)^4*k-6*a^3*d^4*tan(b)^6*r+12*k*a^2*r^2*tan(b)^4-6*k^2*a^3*r*tan(b)^2-12*a^3*tan(b)^4*k*r+18*r*d*k^2*tan(b)^4*a^2+18*r*d ^3*k^2*tan(b)^4*a^2+18*r*d*k^3*tan(b)^2*a^2-36*r^2*d*k^2*tan(b)^4*a+3*a^4*tan(b)^4*k)*d*k*tan( b)^2+k^3*a^4+a^4*tan(b)^6+3*a^4*tan(b)^6*d^2+a^4*d ^6*tan(b)^6-8*a*r^3*tan(b)^6+3*a^4*tan(b)^2*k^2+12*a^2*tan(b)^ 6*r^2-6*a^3*tan(b)^6*r+3*a^4*tan(b)^6*d^4-12*a^3*d^2*tan(b)^4*k*r+3*a^4*d^2*tan(b)^2*k^2-12*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2*k^2-12*a^3*tan(b)^6*d^2*r+6*a^4*tan(b)^4*d^2*k+12*a^2* d^2*tan(b)^6*r^2+54*r^2*tan(b)^4*d^2*k^2+3*a^4*d^4 *tan(b)^4*k-6*a^3*d^4*tan(b)^6*r+12*k*a^2*r^2*tan(b)^4-6*k^2*a^3*r*tan(b)^2-12*a^3*tan(b)^4*k*r+18*r*d*k^2*tan(b)^4*a^2+18*r*d ^3*k^2*tan(b)^4*a^2+18*r*d*k^3*tan(b)^2*a^2-36*r^2*d*k^2*tan(b)^4*a+3*a^4*tan(b)^4*k)*a^2)^(1/3));
I tried doing a find and replace shtick over and over again, but I definitely missed some things.
Any ideas?
So, I need a script to go from a^b to pow(a,b).
For instance, here's one of them:
1/12/d/k/tan(b)/a*((6*sqrt(3)*r*sqrt(-k^4*a^4-a^4*d^4*tan(b)^4*k^2-2*a^4*d^2*tan(b)^2*k^3+4*k^3*a^3*r*tan(b)^2-4*k^2*a^2*r^2*tan(b)^4-2*a^4*tan(b)^4*d^2*k^2+4*a^3*tan(b)^4*k^2*r-2*a^4*tan(b)^2*k^3-a^4*tan(b)^4*k^2+4*a^3*d^2*tan(b)^4*k^2*r-16*r*k^4*d*tan(b)^2*a^2+k^3*a^4+a^4*tan(b)^6+3*a^4 *tan(b)^6*d^2+a^4*d^6*tan(b)^6-8*a*r^3*tan(b)^6+3*a^4*tan(b)^2*k^2+12*a^2*tan(b)^ 6*r^2-6*a^3*tan(b)^6*r+3*a^4*tan(b)^6*d^4-12*a^3*d^2*tan(b)^4*k*r+3*a^4*d^2*tan(b)^2*k^2-12*a^3*tan(b)^6*d^2*r+6*a^4*tan(b)^4*d^2*k+12*a^2* d^2*tan(b)^6*r^2+27*r^2*tan(b)^4*d^2*k^2+3*a^4*d^4 *tan(b)^4*k-6*a^3*d^4*tan(b)^6*r+12*k*a^2*r^2*tan(b)^4-6*k^2*a^3*r*tan(b)^2-12*a^3*tan(b)^4*k*r+18*r*d*k^2*tan(b)^4*a^2+18*r*d ^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+18*r*d ^3*k^2*tan(b)^4*a^2+18*r*d*k^3*tan(b)^2*a^2-36*r^2*d*k^2*tan(b)^4*a+3*a^4*tan(b)^4*k)*d*k*tan( b)^2+k^3*a^4+a^4*tan(b)^6+3*a^4*tan(b)^6*d^2+a^4*d ^6*tan(b)^6-8*a*r^3*tan(b)^6+3*a^4*tan(b)^2*k^2+12*a^2*tan(b)^ 6*r^2-6*a^3*tan(b)^6*r+3*a^4*tan(b)^6*d^4-12*a^3*d^2*tan(b)^4*k*r+3*a^4*d^2*tan(b)^2*k^2-12*a^3*tan(b)^6*d^2*r+6*a^4*tan(b)^4*d^2*k+12*a^2* d^2*tan(b)^6*r^2+54*r^2*tan(b)^4*d^2*k^2+3*a^4*d^4 *tan(b)^4*k-6*a^3*d^4*tan(b)^6*r+12*k*a^2*r^2*tan(b)^4-6*k^2*a^3*r*tan(b)^2-12*a^3*tan(b)^4*k*r+18*r*d*k^2*tan(b)^4*a^2+18*r*d ^3*k^2*tan(b)^4*a^2+18*r*d*k^3*tan(b)^2*a^2-36*r^2*d*k^2*tan(b)^4*a+3*a^4*tan(b)^4*k)*a^2)^(1/3));
I tried doing a find and replace shtick over and over again, but I definitely missed some things.
Any ideas?
Comment