When you pull a crate across a GAA hall, how much of your pull moves it forward?
You're pulling a crate across a GAA hall. The rope points up and forwards, but the crate slides straight along the floor. Does the whole pull count when you calculate the work done by the rope?
Follow the crate's displacement to the right, then look at the sloping rope force. Resolve that force into components. The vertical component points up, at right angles to the displacement. The horizontal component points along the displacement. Theta marks the angle between the rope force and the displacement.
For a constant force, multiply the signed component along the displacement by the displacement magnitude. That's force times displacement magnitude times cosine theta. Work is in joules, force in newtons and displacement magnitude in metres. Theta is the angle between the force and displacement. Work can be positive, negative or zero.
A crate slides four metres to the right. A constant friction force of ten newtons points to the left. What is the signed work done by friction? Pick the value in joules.
Over five metres, the eighty newton rope force acts at sixty degrees to the displacement. Its forward component is forty newtons, giving positive two hundred joules. The twelve newton friction force acts at one hundred and eighty degrees. Its signed component is negative twelve newtons, giving negative sixty joules.
Now the crate moves four metres. The rope pulls with sixty newtons at sixty degrees to the displacement, and friction opposes the motion with fifteen newtons. Pick the signed work done by the rope and by friction, in that order.
The floor pushes up on the crate. It's tempting to say that a large upward force must do work. Look at the angle instead. The crate moves horizontally, so the normal reaction makes a right angle with the displacement. Its work is zero, whatever its magnitude.
Lift the crate near Earth's surface and it gains gravitational potential energy: mass times g times the rise in height. Gravity does that much negative work. A moving crate has kinetic energy: half its mass times its speed squared. Add the signed work of all forces to get the change in kinetic energy.
As you slowly stretch an ideal spring, the pull rises in proportion to the extension. The area under the force graph gives the work you do. This triangle's area is half the spring constant times the extension squared. The spring stores that work as elastic potential energy.