TITLE: A question on the work done by the electric field?
QUESTION [0 upvotes]: It's a well-known fact that the work done by the electric field is given by

$\int -k\frac{{Q(1)Q(2)}}{r^2} dr = \frac{kQ(1)Q(2)}r$

The work being negative as the force and direction of displacement are opposite
however the fact that the work becomes positive after integration is confusing me, could someone help, please?

REPLY [1 votes]: however the fact that the work becomes positive after integration is
confusing me, could someone help, please?

Mathematically, it's due to the integration power rule (neglecting constant of integration):
$$\int x^{n}dx=\frac {(x^{n+1})}{(n+1)}$$
Applied to your equation
$$-kQ_{1}Q_{2}\int r^{-2}dr=-kQ_{1}Q_{2}\frac{(r^{-1})}{-1}=kQ_{1}Q_{2}r^{-1}=\frac{kQ_{1}Q_{2}}{r}$$
Conceptually, it means (1) an external force is required to do positive work on like (same sign) charges to move them closer together against a repulsive force, increasing their potential energy while (2) negative work is done by opposite (different sign) charges on each other moving the charges closer together decreasing their potential energy.
Hope this helps.
{"set_name": "stack_exchange", "score": 0, "question_id": 728002}