In mathematica-output how can one removes the leading spaces from each line of the output.
Here is a sample code
SetDirectory[Directory[]]
result=(4*(5*y^7*(-1 + 4*z) + y^6*(15 - 83*z + 80*z^2) - 5*z^4*(-2+4*z
- 3*z^2 + z^3) + y^5*(-20 + 147*z - 273*z^2 + 140*z^3) + y*z^3*(40
- 154*z + 147*z^2 - 83*z^3 + 20*z^4) + y^2*z^2*(60 - 254*z + 363*z^2
- 273*z^3 + 80*z^4) + y^3*z*(40 - 254*z + 462*z^2 - 439*z^3 + 140*z^4)
+ y^4*(10 - 154*z + 363*z^2 - 439*z^3 + 160*z^4)) - 9*(y + z)^4*(2
+ y^2*(3 - 9*z) - 4*z + 3*z^2 - z^3 + y^3*(-1 + 4*z) + y*(-4 + 12*z
- 9*z^2 + 4*z^3))*H[0, y] );
result >> output.m;
Quit[]
where the output is
cat output.m
(4*(5*y^7*(-1 + 4*z) + y^6*(15 - 83*z + 80*z^2) -
5*z^4*(-2 + 4*z - 3*z^2 + z^3) + y^5*(-20 + 147*z - 273*z^2 + 140*z^3) +
y*z^3*(40 - 154*z + 147*z^2 - 83*z^3 + 20*z^4) +
y^2*z^2*(60 - 254*z + 363*z^2 - 273*z^3 + 80*z^4) +
y^3*z*(40 - 254*z + 462*z^2 - 439*z^3 + 140*z^4) +
y^4*(10 - 154*z + 363*z^2 - 439*z^3 + 160*z^4)) -
9*(y + z)^4*(2 + y^2*(3 - 9*z) - 4*z + 3*z^2 - z^3 + y^3*(-1 + 4*z) +
y*(-4 + 12*z - 9*z^2 + 4*z^3))*H[0, y] )
from the 2nd line of the output there are 4 or 2 spaces in front of each line.
For some larger expression this looks worse.
Is there any way to remove those leading spaces in the output in mathematica?
Note: This is a question of beautification of the output, nothing wrong with the output, its still right. I just want to remove the leading spaces?
Is there any smart way to output so that this problem does not appear?
result
? Where did it come from? $\endgroup$