The Force on a Dam not accounting for atmospheric pressure? I have seen this problem in one textbook (Physics for Scientists and Engineers, Raymond A. Serway, 2018) and in several places on The Internet, where we have a dam and we need to calculate the total force that the water exerts on the dam.
The problem starts setting  $ y = 0 $ at the bottom of the dam and proceeds to define the pressure at depth $ h $ as $ P = \rho g(H-y) $
Then goes on with, $ dF = P dA $, etc, etc. Integrates and gets $ \frac{1}{2} \rho g w H^2 $.

What it's puzzling me is that the premise is that $ P = \rho g(H-y) $. From my point of view, if we set $ y = H $, the top of the dam, they are implying that the pressure at the top is 0 when it should be the atmospheric pressure, 1 atm.
Are they wrong assuming 0 pressure at the top of the dam or am I wrong assuming 1 atm?
 A: Short answer:

*

*Whatever the atmospheric pressure is at the top of the dam, it acts on both sides and thus does not produce a net force.

*Then, you have a pressure form the water on one side and from the air below the top of the dam on the other. Since the density of air is about 1000 times lower than that of water, you can completely neglect this.

*In general, atmospheric pressure (about 1 bar) corresponds to a water column of 10 m. So for a larger dam, that pressure (that results form the entire atmosphere above you) is again negligible.

Update following Jon's comment:
If you're interested in the "total force that the water exerts on the dam", then you would presumably include atmospheric pressure, sicne the air pushes on the water and the water transfers this pressure to the dam. The fact that the air also pushes on the outside of the dam is then irrelevant, as is the variation of atmospheric pressure with height, i.e. what counts is the atmospheric pressure at the surface of the lake. (Then again, it's not clear whether the "total force that the water exerts on the dam" is very useful, or whether the question was just worded sloppily.)
