LM2576 is for buck converter applications (output voltage lower than input)
LM2586 is for boost converters (output voltage higher than input) and flyback converters (any output voltage at all)
They're not interchangeable. The main difference is that the LM2576 has its power switch in series with the positive rail, whereas the 2586 switches to ground.
I find the 2586 very handy. You can make almost any kind of DC-DC converter with it, except of course a buck converter