Magnesium Calcium and Alkalinity are all inter related. I have never had a problem with nitrates but I did have a breakout of byropsis and treated my tank with Kent Tech M, which worked great by the way. After the treatment I started adjusting the Alk and Calcium levels using BRS Two Part and thought that the Magnesium levels would drop back to the 1300 range they were at before the treatment at 1500. It took a couple weeks for my levels of alk and calcium to stabilize and now my magnesium stays around 1450 both in my Nano and the 55 Gallon Frag tank, and I didn't treat the frag tank for byropsis.
Generally I have found that higher PH and Magnesium levels do greatly reduce the algae in the tank.