Hi professor.. thanks for this fantastic video.. why did you take pm wrt -180 but not with 0 degrees.. I see some people take it so.. Please explain. When to consider pm with 0 degrees and -180 degrees.
Hi, thanks for your nice comment and question. PM means "Phase Margin", so it is a margin, which is an "amount of difference" according to the dictionary. So the correct way to define PM is as the difference between the loop gain phase at 0 dB and -180, this is: PM = (loop gain phase at 0dB) - (-180). In our case: PM= -135 - (-180) = 45. It should always be given as a positive number. Thanks for watching!
@@MarcosAlonsoElectronics Hi professor. Thanks for reply.. . But, still can you make a video or a note, When to take wrt 0 deg and -180 with some illustrations or example as necessary. I generally take wrt 0 degrees when we have opaamp as error amplifier. I believe, negetive feedback connected to inverting pin of opamp offers that -180 component. Is my understanding correct .? Thanks in advance. ...,,👍👍
@@foodyshrii6795 The correct way to do it is to measure the PM wrt -180º. Sometimes you can see it measured wrt 0º because what they are really representing is not exactly the loop gain phase but (180º - loop gain phase). This happens when you measure the loop gain with an analyzer. What you get is not exactly the loop gain phase but (180 - loop gain phase). See explanation in the video at 17:10. You should do the following correction: Actual loop gain phase = 180º - Loop gain phase measured by the analyzer. This is what it is done in the video at 17:10. Sometimes people avoid doing this correction to save time and just measure the PM wrt to 0 on the uncorrected curve of the loop gain phase. So you have to pay attention to the curve that you have. If you have the actual loop gain phase then measure PM wrt -180º. If you have (180º - loop gain phase) then measure PM wrt 0º. I prefer the former rather than the latter. Hope this clarifies. Thanks!
Hi, it is explained at 4:33. We get two equations: 1/(2*pi*R2*C2)=7.1 kHz and R2/R1=1. We choose a suitable value for C2, for example, C2=10nF and get the other two from the equations.
Great video, watching here from Brazil, I've been looking for this theme for a while. By the way, I didn't even know that this simulation was possible in LTSpice, your video and tip will help me a lot in my projects. I have a doubt, in the Maximum Timestep window did you use 0.1uS, that is, 1% of the period of the maximum sweep frequency 100Khz? If yes, can I use this 1% of the period of the maximum sweep frequency as default in the Maximum Timestep to simulate any converter?
Thanks for your nice comment. Yes, 1% of the switching period is a value that usually works fine. This type of simulation is tricky to adjust because you have to achieve convergence for all the simulations at the different step frequencies (31 in this case). To achieve this I usually "play" with two parameters. One is the maximum timestep, and the other the "reltol" parameter that you can adjust by using ".options reltol=value." The default value is 1m. Increasing this value usually improves convergence if necessary and can also speed up the simulation. Sometimes I use 10m, 100m or even 1 and the accuracy of the results is usually good. With a similar process you can measure other parameters, like the input impedance of the converter. See an example here: ruclips.net/video/ZXCcwmKXz9I/видео.html
Hi, it is explained at 4:33. We get two equations: 1/(2*pi*R2*C2)=7.1 kHz and R2/R1=1. We choose a suitable value for C2, for example, C2=10nF and get the other two from the equations.
Hi, we would like an open loop gain for the opamp as high as possible. At the end this can affect the steady state error. Common opamps have very high gain, usually 100 dB, so this is not an issue for most applications. In the video there is Avol=1meg (120 dB). You can change it to Avol=1e5 and see that there is no much change.
Professor, this is my first time visit your channel. It's awsome! Please make the current mode control converter, thanks!
Thanks for your nice comment.
This topic is in my mind for a future video. Thanks!
Thank you so much for these amazing videos. Please make a video about EMC filter design procedure for DC/DC converters and simulate it it in LTspice.
Thanks for the suggestion. EMI topic is on my list.
@@MarcosAlonsoElectronics Thank you
Can you share slides and lectures pdf and simulation of this video
Hi, I do not share slides. Sorry.
You have the link to the simulation file in the answer to your previous comments. Thanks for watching!
Hi professor.. thanks for this fantastic video.. why did you take pm wrt -180 but not with 0 degrees..
I see some people take it so..
Please explain. When to consider pm with 0 degrees and -180 degrees.
Hi, thanks for your nice comment and question.
PM means "Phase Margin", so it is a margin, which is an "amount of difference" according to the dictionary.
So the correct way to define PM is as the difference between the loop gain phase at 0 dB and -180, this is:
PM = (loop gain phase at 0dB) - (-180).
In our case: PM= -135 - (-180) = 45.
It should always be given as a positive number.
Thanks for watching!
@@MarcosAlonsoElectronics Hi professor. Thanks for reply.. . But, still can you make a video or a note, When to take wrt 0 deg and -180 with some illustrations or example as necessary.
I generally take wrt 0 degrees when we have opaamp as error amplifier. I believe, negetive feedback connected to inverting pin of opamp offers that -180 component.
Is my understanding correct .?
Thanks in advance. ...,,👍👍
@@foodyshrii6795 The correct way to do it is to measure the PM wrt -180º. Sometimes you can see it measured wrt 0º because what they are really representing is not exactly the loop gain phase but (180º - loop gain phase). This happens when you measure the loop gain with an analyzer. What you get is not exactly the loop gain phase but (180 - loop gain phase). See explanation in the video at 17:10.
You should do the following correction:
Actual loop gain phase = 180º - Loop gain phase measured by the analyzer. This is what it is done in the video at 17:10.
Sometimes people avoid doing this correction to save time and just measure the PM wrt to 0 on the uncorrected curve of the loop gain phase.
So you have to pay attention to the curve that you have. If you have the actual loop gain phase then measure PM wrt -180º. If you have (180º - loop gain phase) then measure PM wrt 0º. I prefer the former rather than the latter.
Hope this clarifies. Thanks!
@@MarcosAlonsoElectronics Thank you.. professor.. for your clarification...
How did you calculate the values of capacitor and resistor in compensator??
Hi, it is explained at 4:33. We get two equations: 1/(2*pi*R2*C2)=7.1 kHz and R2/R1=1.
We choose a suitable value for C2, for example, C2=10nF and get the other two from the equations.
Great video, watching here from Brazil, I've been looking for this theme for a while. By the way, I didn't even know that this simulation was possible in LTSpice, your video and tip will help me a lot in my projects. I have a doubt, in the Maximum Timestep window did you use 0.1uS, that is, 1% of the period of the maximum sweep frequency 100Khz? If yes, can I use this 1% of the period of the maximum sweep frequency as default in the Maximum Timestep to simulate any converter?
Thanks for your nice comment.
Yes, 1% of the switching period is a value that usually works fine. This type of simulation is tricky to adjust because you have to achieve convergence for all the simulations at the different step frequencies (31 in this case). To achieve this I usually "play" with two parameters. One is the maximum timestep, and the other the "reltol" parameter that you can adjust by using ".options reltol=value." The default value is 1m. Increasing this value usually improves convergence if necessary and can also speed up the simulation. Sometimes I use 10m, 100m or even 1 and the accuracy of the results is usually good.
With a similar process you can measure other parameters, like the input impedance of the converter. See an example here: ruclips.net/video/ZXCcwmKXz9I/видео.html
@@MarcosAlonsoElectronics Thanks for the comment, I'll take a look at the video indicated. Hug!
Hi Sir .. please make the Current mode control Buck converter simulation
Yes, it's on my list. Thanks!
can you please upload a video on simulation of synchronous buck converter,ZVS converter in ltspice
Thanks for your suggestion
How did you choose the values of R2 and C2 and R1???
Hi, it is explained at 4:33. We get two equations: 1/(2*pi*R2*C2)=7.1 kHz and R2/R1=1.
We choose a suitable value for C2, for example, C2=10nF and get the other two from the equations.
How did you choose the open loop gain for op amp?
Hi, we would like an open loop gain for the opamp as high as possible. At the end this can affect the steady state error. Common opamps have very high gain, usually 100 dB, so this is not an issue for most applications. In the video there is Avol=1meg (120 dB). You can change it to Avol=1e5 and see that there is no much change.
Ca you share its simulation ????
Hi, this is the link to the file. Thanks for watching!
drive.google.com/file/d/1oUVPWHc9nZ9J9YujLSmsLEeuSScrRIvn/view?usp=sharing