When I throw a ball (system) up in the air, gravity (of the earth [external]) does negative work on the system. The system's total energy remains constant as it moves in the conservative field, potential and kinetic energies interplay. Here, work done by gravity is negative and we say that work is done by the system. What is the physical meaning of the system doing work (or in some cases work being done on the system)? Is there any such physical meaning?
[Physics] Work done on/by the system
forcesnewtonian-mechanicswork
Related Solutions
Energy is conserved so it can't be created or destroyed. All we can do is change energy from one form to another.
In your example we are changing the potential energy of the mass $m$ into kinetic energy. The increase in kinetic energy must be equal to the decrease otherwise energy wouldn't have been conserved.
By an external force I assume you mean some third party outside the system. To give a slightly ridiculous example this could be me standing well away from the Earth and the mass and poking the mass with a long pole to accelerate it. In this case the energy of the Earth + mass wouldn't be conserved, but also my energy wouldn't be conserved. However the energy of the Earth, the mass and me would be conserved. The distinction between internal and external forces is a bit artificial because all systems are closed and all forces are internal if you look on a big enough scale.
Two things might be helpful here.
First - collisions are always easier to look at in the center of mass frame (that is, from the point of view of an observer who is traveling at the velocity of the center of mass). If you have two objects with mass $m_1, m_2$ and velocities $v_1, v_2$ then the center of mass moves at velocity
$$v_{com}=\frac{m_1v_1+m_2v_2}{m_1+m_2}$$
Second - during an elastic collision, you can consider there being a small spring between the masses: in the center of mass frame all kinetic energy will convert to potential energy of the spring (since the two masses will be stationary at one instant) after which it is "given back" to the masses (and each gets the same amount of energy as before, in this frame of reference).
Now if we have net motion (we look in a different frame of reference) then the mass that is moving in the same direction as the center of mass is doing more work during compression (it is pushing on a spring that is moving away from it). This means that that object will end up losing energy (doing work on the other one), and vice versa. The magnitude of the work done by A on B can be found by looking at the kinetic energy before and after the collision.
When you include losses during the collision the same kind of analysis can be used - but now part of the work done "during compression of the spring " is lost. This means you first need to figure out what fraction of the "after" energy is due to the mass itself (by looking at its velocity in the center of mass frame after the collision and the energy it lost during the collision). The difference is due to work done by the other mass.
Best Answer
When you lift the ball up from the earth, you are doing work on the system by increasing the potential energy. This corresponds to negative work done by gravity (energy is added rather than used / removed).
By the way, the earth must be included in the system you are talking about. The potential energy is a property of both object and earth, not only of the object.