# Revision history [back]

### Evaluate expression with unknowns

I'm trying to evaluate an integral that comes out with a crazy long result. I'm not going to paste it here because it really is quite long, which is essentially the problem. The result actually only has a few instances of unknowns in it, 90% of it's length comes from un-evaluated constants (like 2^(1/7), log(11.5), stuff like that). So it sort of looks like:

f(x) = (x* 2* pi* log(5)* 6^1.5) / (3^4*pi^2+x)

except it spans 10 lines.

If I could get sage to just express all of that stuff as a solid number, then the resulting expression wouldn't be so prohibitively long (I think it would actually evaluate out to something similar to the example I gave, number*x/(number+x) ). But numerical_approx() won't take anything with unknowns in it, so I can't just plug that expression into n().

How does one evaluate the knowns in an expression that contains unknowns?

 2 retagged FrédéricC 4968 ●3 ●41 ●107

### Evaluate expression with unknowns

I'm trying to evaluate an integral that comes out with a crazy long result. I'm not going to paste it here because it really is quite long, which is essentially the problem. The result actually only has a few instances of unknowns in it, 90% of it's length comes from un-evaluated constants (like 2^(1/7), log(11.5), stuff like that). So it sort of looks like:

f(x) = (x* 2* pi* log(5)* 6^1.5) / (3^4*pi^2+x)

except it spans 10 lines.

If I could get sage to just express all of that stuff as a solid number, then the resulting expression wouldn't be so prohibitively long (I think it would actually evaluate out to something similar to the example I gave, number*x/(number+x) ). But numerical_approx() won't take anything with unknowns in it, so I can't just plug that expression into n().

How does one evaluate the knowns in an expression that contains unknowns?