- dsolve===>> to solve linear differential equation, just write the equation in inverted comma and initial condition also in inverted comma. to assign value of answer you can use variable name in big bracket in left hand side.
- solve==>>to solve any number of equation
- vdp1==> is vanderpol oscillator with mu=1. you can directly use this to solve
- to solve nonlinear differential equation you can use ode45, see the syntax
feval==>it will evaluate a function and gives output depending upon the input. input may be in n numbers and output may also be in n numbers.
write a function then use this your function or function from library in inverted comma or with the @ symbol and follow the syntax.
to know the size of a matrix you dont have to use ‘r ‘and ‘c’ to store the row and column instead enter some any other variable.
‘find’ function will give the linear index of the matrix so use accordingly.
problem is that there are F matrix which has 12 elements and one S matrix which has 10 rows. and according to the maximum element of F, elements of S should be adjusted. means this number should be same for the both.
thats why there is index exceed matrix dimension is occuring.
F has more number of elements because initially it stored some numbers of elemnets then there should be elimination of elements in S. so dimension of S will decrease but F has same dimension. so solution for this problem is that every time reset the F variable. but when resetting, then we cant eneter the interval in to it bcz it again shows the error that conversion from interval to double is not possible. so any how i have to reset the F. then problem will be solved.
finally problem solved 🙂
according to the location found in I_elim i was removing the elements in S, but after removal of the elements, location of desired elements also changes. as if it was in 5th location then after removal of 1 element it will move to 4th location. this problem should be considered. after adjusting the elimination location also , i solved the problem
every day only one problem is enough. select one problem and try to solve it using the c++. this will be of great use in future.
make a flow chart first for any problem then start coding for that problem. it will make your work very easy.
recall all the knowledge you have gained till that and repeat them only, till you become master on that.
every practical system is a nonlinear system . so we have to understand the control of this systems . this systems can be approximated to a linear system and controlling of linear system we know very well, we can do pole placement according to our desired response criteria.
so nonlinear system can be approximated to linear system at the equilibrium point. equilibrium points are the points where all states are constant or not changing, find that point and linearize the system for that point and do the rest of the analysis same as the linear system.
stability can be BIBO stability or stability in terms of the equilibrium point, in BIBO stability for a bounded input there should be a bounded output but for stability in sense of equilibrium point there should be convergence of system should be present when we disturb the system means system should come back to the equilibrium point if we disturb the system. this is useful when we don’t know the input for the system then we can use this stability condition.
solution of the any LTI system we know that is the addition of the zero input response and zero state response. for the stability of the system this both response sound be bounded. if we solve this one then we can see the exponential term in that so if it decays then it will decay exponentially. that is called asymptotically stable, hence the exponential stability and asymptotically stability are same. either it will decay asymptotically or it will be unstable.