Getting terms and only evaluate specific parts

I want to expand the expression but I do not want it to evaluate.

Sum[(HoldForm[1/(2 # - 1) - 1/(2 # + 1)] &)[i], {i, 1, 6}]


However if you evaluate this you get: (Fraction-Fraction)+...+(Fraction-Fraction). What i want is to have this fraction evaluated without having to evaluate the subtraction inside the parenthesis or the addition outside the parenthesis. Could someone show me a simple way to do this?

• It is a good habit to hold on with an accept a day or two, let's don't discourage others. – Kuba Jan 17 '15 at 16:24
• @Kuba Okey, ill do that next time:) – ALEXANDER Jan 17 '15 at 16:29

3 Answers

HoldForm[# - #2] & @@@ Table[{1/(2 i - 1), 1/(2 i + 1)}, {i, 1, 6}] // Total


• I am still (till now) don't know how to format any of my answers that way you did it here. can you tell me how? Thanks. – Algohi Jan 18 '15 at 1:30
• @Algohi The result is a picture :) – Kuba Jan 18 '15 at 8:03
• Oh, I see. I should have known this. I can't copy it:-) – Algohi Jan 18 '15 at 16:01

Another way of doing it (something similar to Kuba's great answer) is:

Sum[HoldForm[#1 - #2] &[1/(2 i - 1), 1/(2 i + 1)], {i, 1, 6}]


May be also something different:

Sum[(1/(2 i - 1) - 1/(2 i + 1) // Trace)[[-2]], {i, 1, 6}]

• Nice! (8 to go) – Kuba Jan 17 '15 at 22:08

One more subtle variation:

Sum[Defer[# - #2] & @@ (1/(2 i + {-1, 1})), {i, 6}]

(1/11 - 1/13) + (1/9 - 1/11) + (1/7 - 1/9) + (1/5 - 1/7) + (1/3 - 1/5) + (1 - 1/3)

• Always new thing to the scene. When the master speech, everyone has to listen. :) – Algohi Jan 17 '15 at 20:49