This looks like the best thread of several for this Q.
I am building a 10-35V to 5V 1A PSU using the MCP16366:
https://ww1.microchip.com/downloads/aemDocuments/documents/APID/ProductDocuments/DataSheets/MCP16364-5-6-Family-Data-Sheet-DS20006969.pdfIn front of the above circuit I am putting an LC filter, with 10uF on the input, and 6.8uH driving the above circuit. So we have 10uF on the actual input, then 6.8uH, then another 10uF which is the Cin you see above. Actually I plan to have 20uF there, for Cin.
IOW, a PI filter, of which above Cin is a part.
And I got stuck in to the Middlebrook stability stuff. In simple terms, watching the video which a number of people have posted already, the Zin of the PSU needs to be much higher than the Zout of the filter before it.
But how can this be calculated when Cin participates both in the Zout of the input filter, and Zin of the PSU?
The video gives a simple estimation formula for the Zin but that clearly ignores Cin (it takes in just Vin, efficiency, and power out). Yet every SMPS must have a Cin otherwise the conducted RF would be massive. In fact it would probably just not work at all. The formula it gives for Zout of 10uF and 6.8uH produces a value of Zout which is much much lower than the Zin, so it should be OK.
The circuit given by Microchip above will almost certainly not meet any CE standards, so I am putting in a bit of money into a decent input filter

I am actually using the spread spectrum version of the chip... and everything will go into a shielded case, on a 4 layer PCB, so shielded on all six sides.
Unfortunately, while I understand the basics of control loop stability (open loop gain to be below 1 before the phase shift goes past 180, etc) and have designed loads of products employing control loops (most of these were succesfully substantially over-damped and worked fine) I am bad at maths and can't get my head around those formulae.
Yes the Zin must be negative; it is thus for any SMPS because a higher Vin produces a lower Iin.
I've dug around everywhere for suggested values for input filters for this chip but can't find anything. Also not for the 3A version (which has the additional problem of discontinuous operation at low loads).
Another thing is what effect would a series diode have (reverse polarity protection). Many years ago I worked in a HV PSU company (photomultiplier PSUs) and they found a series diode made them unstable. So they used a parallel diode (which blew a fuse

).