Economic profit is equal to total revenue - total cost, or q(P - ATC) where q = quantity, P = price, and ATC = average total cost. This is not the same thing as producer surplus.
When you draw supply and demand, the area between the supply and demand curves all the way up to the equilibrium point represents total surplus. The area above the equilibrium price and below demand is consumer surplus because it is where consumers pay less than what they value a good as. The area under the equilibrium price and above supply is producer surplus. It is the area where the producer can get a good for more than they value it.