@Pkrd @LittleRiver The beer is not overcarbed. The foam is really good, not too much.... but there is less foam day after day. I tried the set and forget for 1 week at 13psi, same result.
By overcarbed, I believe they meant carbed beyond the equilibrium carbonation level for your serving temp and pressure. Since you said you were a beginner, let's back up and cover the basics quick:
Carbonation levels in beer are listed as "volumes of CO2" or more commonly just "volumes", where 1 volume is 1 liter of gas at atmospheric pressure dissolved in 1 liter of beer, 2 volumes is 2 liters of gas dissolved in 1 liter of beer, and so forth. A lot of beer is served around 2.4 volumes, but the ideal carbonation level depends on the type of beer and individual preferences.
Now, the volumes of CO2 depend on two things, pressure
and temperature.
At 38 °F, 10 psi gives 2.4 volumes, but at 50 °F you need 16 psi for the same 2.4 volumes. This is why at least one person asked what temperature your beer is at, since that affects carbonation levels just as much as pressure does.
The next thing to understand is equilibrium. Equilibrium is when the pressure and temp are held constant for long enough that the amount of dissolved CO2 in the beer stops changing. While pressure and temperature change the amount of CO2 in the beer, it's not immediate. It takes time for CO2 to dissolve into the beer, and more importantly,
CO2 will come out of the beer if the pressure is reduced or the temperature increased, though this also takes time. In other words, this is a two way street. This is why your serving pressure has to be appropriate for the desired volume level of CO2 at your serving temp. If your serving pressure does not match the volume level of CO2 you desire, then the carbonation will either increase or decrease over time.
Okay, so let's put some pieces together here. It takes time to carbonate to equilibrium. The most basic method of carbonation is the "set and forget" where you choose your pressure based desired carbonation volumes and temp, then let it sit. This normally takes 2-3 weeks to become fully carbonated, or in other words reach equilibrium. If you tap off beer before this, it will be "undercarbed" as it has not yet reached equilibrium carbonation level. As time goes on it will become more and more carbonated until it reaches equilibrium carbonation at which point the carbonation will be the same until the keg is kicked, assuming the keg is left on gas at the same pressure and temp. Make sense?
So then the thing is people don't want to wait 2-3 weeks for beer to reach full carbonation. A common way to speed this up is "burst carbing". Burst carbing involves putting the keg at a much higher pressure than what would reach desired carbonation level if you did the "set and forget", but the idea is you don't let it go long enough to get that carbonated. For example, at 38 °F, if you set the beer to 30 psi and left it for 3 weeks, the beer would end up at 4.3 volumes of CO2, which is way too much for almost any style of beer. But if you leave it for a couple days, you may get it to say 2.4 volumes, then if you set your regulator to 10 psi and vent the excess pressure from the keg, the keg will maintain this 2.4 volumes until it kicks.
The problem with this method is that it's really difficult to reach the exact level of carbonation desired. Don't wait long enough before reducing the pressure, and the beer will be undercarbed, and will slowly increase in carbonation while on tap. Wait too long, and the beer will be over carbed, and will decrease in carbonation while on tap.
So, what does it appear happened in
your case? Well, again I don't know your temp, so if I assume 38 °F, then 9 psi you served at will give 2.3 volumes of CO2. But you had the keg at 40 psi for 4 days. Likely you overshot this 2.3 volume mark, maybe your were at 2.6 or 3 volumes of CO2. And for
you, that was a perfect carb level. But the problem is, 9 psi at 38 °F is 2.3 volumes of CO2, not 2.6 or 3 volumes. So as you let the keg sit at 9 psi, the carbonation started reducing. It won't reduce forever, just until the equilibrium of 2.3 volumes is reached.
I suspect to get the carbonation you desire, you need to increase your serving pressure. Try setting it at 12 psi for a week or two, then if not enough keep turning up until you find your sweet spot.
This was rather long, but hopefully it's useful for you to help understand what's going on here. Just remember that carbonation depends on both temp and pressure, and it takes time to reach equilibrium before things stop changing.