For a project, I need to design a power circuit like this one :

With the input pusle, I can say that I want this value of current in my LED. But this current won't be stable, it will have some ripple.

By the way, that's a simple schematic, the pulse isn't the real input source, it's only to show you how it works. I know that at the start it will not be a ripple but I'm speaking here when the current is in his stable phase.

I want to calculate this ripple to after, calculate a good frequency for my switch (nmos). But I don't know how can I calculate this.

I have calculated the 2 formula for the inductor which are:

This is an exemple of what it does like:

Does someone know how can I calculate this ?