When a player creates a potion, the effects of the potion are determined by a particular complex formula. If you don’t want to rely on a glitch, then vendors typically take 48 hours to restock normally.
If you buy from a merchant, save the game, then kill that merchant and reload the save their inventory and gold will be restocked. Unfortunately, the easiest way to acquire ingredients in Skyrim is actually based on a glitch.