I just quickly wanted to tell you, that what you're doing is amazing! All this free material to topics with unfortunately little good material out there. You're one of the few sources I found with quality explanations to the control library. Can't wait to follow more of your videos and read your free (THANK YOU!) books! Best of luck for you and thank you for supporting the online community with these great learning resources.
@IndustrialITandAutomation3 жыл бұрын
Cool, thanks!
@AshishKumar-qe4hq3 жыл бұрын
@@IndustrialITandAutomation so you reply too 😂
@stepsvideos4 жыл бұрын
Thank you sir for your tutorial! I came across this warning when looking up the function 'odeint': "For new code, use scipy.integrate.solve_ivp to solve a differential equation." After a few hours of guess-and-search, this finally worked: import numpy as np import matplotlib.pyplot as plt from scipy.integrate import solve_ivp K = 3 T = 4 u = 1 tstart = 0 tstop = 30 t_increment = 0.1 # Note: y0 Is now an array y0 = [0] # Function that returns dx/dt # Note: t and y are in reverse order. Right side of ODE is now an array. def system1order(t, y, K, T, u): dydt = [(1/T) * (-y + K*u)] return dydt # Create time sequence t_samples = np.arange(tstart, tstop, t_increment) # Solve ODE # Note array indexing notation: -1 refers to last element, -2 second to last, etc x = solve_ivp(system1order, [t_samples[0], t_samples[-1]], y0, t_eval=t_samples, args=(K, T, u)) # solve_ivp() Returns a Bunch() object, which is a dot-accessible dictionary # In case you would like to see what it looks like: # print("x : ", x) # print("") # print("x.t: ", x.t) # print("") # print("x.y[0]: ", x.y[0]) # Plot results plt.plot(x.t, x.y[0]) plt.title('1.Order system dy/dt = (1/T)(-y + Ku)') plt.xlabel('t [s]') plt.ylabel('y(t)') plt.grid() plt.show()
@stepsvideos4 жыл бұрын
@46:52 Solving for u[k] (at the bottom of the slide), everything on the right hand side gets multiplied by Ts. Should the last term also be multiplied by Ts? If so, @50:38 Inside the for loop, should the equation for u[k] be: u[k] = u[k-1] + Kp*(e[k] - e[k-1]) + Ts*(Kp/Ti)*e[k] , with the last term multiplied by Ts?
@IndustrialITandAutomation4 жыл бұрын
Yes! Ts should be included in the last term. The simulation results also gets much better :-)
@makut4154 Жыл бұрын
This is gold. This guy is a genius.
@yimingzhang46363 жыл бұрын
The code for example 9: #The Loop Transfer function L=control.series(Hc, Hp, Hf, Hm) print('L(s)=',L) #Tracking transfer function T=control.feedback(L,1) print('T(s)=',T) Maybe should be: #The Loop Transfer function L=control.series(Hc, Hp) print('L(s)=',L) L2=control.series(Hf,Hm) #Tracking transfer function T=control.feedback(L,L2) print('T(s)=',T) ?
@JamesTJoseph4 жыл бұрын
How to simulate model with dead time?
@electronicsacademy2D2E29 Жыл бұрын
Dear Sir, Thank you for the wonderful tutorials. I had a question. In your YT video titled Python for control engineering, when you demonstrate the control example starting around 48:00. I can see there is a difference in the discrete PI term between the pdf presentation and the video. I see in the pdf there is an extra Ts term whereas in the video it is missing. Which one is the right expression? Pardon my ignorance, I am asking you instead of trying out the derivation myself.
@19293949596970 Жыл бұрын
Dear sir, Are u getting the same graph after executing the PI controller ? I am getting a different one.
@electronicsacademy2D2E29 Жыл бұрын
@@19293949596970 Hi, you are right. The code and the derivations in the pdf are the correct ones. So yes, the graphs look different. I tried out the derivations later and the ones in the pdf are derived correctly 👍🏻. The derivations in the video look to be flawed.
@19293949596970 Жыл бұрын
@@electronicsacademy2D2E29 Thanks
@dewdotninja4 жыл бұрын
Thanks for this tutorial. I'm in control system area though a beginner in Python. I 've learnt quite a lot with this video. Anyway, I have a question on the stability analysis example slide (around minute 56). According to the slide, T = y/r = L/(1+L) with L = HcHpHmHs, but y is not indicated in the block diagram. I guess that y is the process output (labeled x on the slide). In that case, T = HpHc/(1+HpHcHfHm). Could you clarify this?
@stepsvideos4 жыл бұрын
I think he means the tracking function is the transfer function between r and Yf. If you work that out, L(s) comes out as shown in the slide.
@blessy69953 жыл бұрын
Sir ... Is really python useful for Mangement engineerings from Mechanical engineering background?
@moreno34612 жыл бұрын
Very good class
@superflanker073 жыл бұрын
Super useful
@doobaas3 жыл бұрын
I have made a jupyter notebook of this tutorial if you are interested
@julioivanmaciascarrera93103 жыл бұрын
Could you share it please
@caleb77992 жыл бұрын
good stuff, but if at all possible, please keep some distance between you and the microphone. thanks.
@JamesTJoseph4 жыл бұрын
You can include SIPPY too. github.com/CPCLAB-UNIPI/SIPPY
@hopelopez833 жыл бұрын
What is K?
@a-mhamdi2 жыл бұрын
This is the most common and standardized way to describe a first order model. K is called the static gain, when the input is constant. It measures the ratio output by input when the plant reaches its steady state, i.e., K=y/u when t--> infty. For instance, if k>1, the system is amplifying the input. Otherwise, it is reducing its contribution on the output.