What about Variable Forces?

What about Variable Forces?
There is a force function.
Divide up the interval into tiny subintervals over which force can be thought of as constant.
Example: A force, in lb, moves an object along a straight line, where x is the distance in feet from the origin. Calculate the work done in moving the object from 30 to 50 feet from the origin.
Springs
Hooke's Law states the force required maintain a spring stretched x units beyond its natural length is proportional to x: f(x) = kx
So...to calculate the work done when a spring is stretched, we find...
Example: A spring has a natural length of 20 cm. A 40 N force is required to stretch (and hold the spring) to a length of 30 cm. How much work is done in stretching the spring from 35 cm to 38 cm?
Example: A force of 25 lbs is required to hold a spring stretched 8 inches beyond its natural length. How much work is done in stretching it from its natural length to 15 inches beyond its natural length?
Remember to pay attention to units!
Units on all given information let you know what you are working with.
Given ft­pounds, you have __________________.
Given Joules, you have _____________________.
Given kilograms, you have __________________.
Given Newtons, you have ___________________.
Given pounds, you have ____________________.
Including units in the integral set­up process helps you know if you left out anything.
Example: 6 J of work is needed to stretch a spring from its natural length of 10 cm to 50 cm. Find the spring constant.
Liquids
Suppose we have a tank full of a liquid.
Example: A rectangular aquarium measures 4 meters long, 2 meters wide, and 3 meters tall. It is full of water and an occasional fish, which we will ignore. (a) Find the work done to pump all the water out.
(b) Find the work done to pump half the water out.
Example: How much work is needed to pump all the motor oil out of an oil drum through the top of the drum? The drum has a height of 3 ft and a radius of 1 ft.
motor oil density
54.9 lb/ft2
Example: What if the drum is full but there is a 1 ft spigot through which the oil must pass?
motor oil density
54.9 lb/ft2