Answered

What algorithm to use for collision avoidance of a robot?

Hi @Farzad Torabi I'm unsure. Maybe you intend to tell the robot to "back down" or retract the arm? Conventionally, RRT is an ...

What algorithm to use for collision avoidance of a robot?

Hi @Farzad Torabi I'm unsure. Maybe you intend to tell the robot to "back down" or retract the arm? Conventionally, RRT is an ...

25 days ago | 2

| accepted

Answered

PID for fixed distance

Hi @Andrea Tonelli I think your control design part is okay. But the divergence issue is probably related to the way you setup ...

PID for fixed distance

Hi @Andrea Tonelli I think your control design part is okay. But the divergence issue is probably related to the way you setup ...

25 days ago | 0

Answered

Why does matlab plot the unit step like a straight line?

Hi @Mark S System 1: s = tf('s'); sys1 = 1/s; % integrator system step(sys1) System 2: sys2 = zpk([], [...

Why does matlab plot the unit step like a straight line?

Hi @Mark S System 1: s = tf('s'); sys1 = 1/s; % integrator system step(sys1) System 2: sys2 = zpk([], [...

26 days ago | 1

| accepted

Answered

Minimization of cost function on MPC

Hi @Chandrakanth Pavanaskar You have a system model sys and I presume that you have written your own code for the ODE_solver to...

Minimization of cost function on MPC

Hi @Chandrakanth Pavanaskar You have a system model sys and I presume that you have written your own code for the ODE_solver to...

27 days ago | 0

Answered

How can i get smooth sine wave in MATLAB R2020b with any frequency.

Hi @Rohit To get a smooth sine wave, you are suggested to use this Sine Wave Function block: https://www.mathworks.com/help/...

How can i get smooth sine wave in MATLAB R2020b with any frequency.

Hi @Rohit To get a smooth sine wave, you are suggested to use this Sine Wave Function block: https://www.mathworks.com/help/...

27 days ago | 0

Answered

Implement these expressions in OCTAVE and plot on the same figure, the two functions: f=3t2 +2t-0.5 , g=2t cos(t) where the variable t varies from 0 to 10 with step 0.5.

@Jignasa, I typed exactly the same equations as you knowingly put on the description. But it gives error. Please check if the...

Implement these expressions in OCTAVE and plot on the same figure, the two functions: f=3t2 +2t-0.5 , g=2t cos(t) where the variable t varies from 0 to 10 with step 0.5.

@Jignasa, I typed exactly the same equations as you knowingly put on the description. But it gives error. Please check if the...

28 days ago | 0

Answered

PID Tune: Plant cannot be linearized

Hi @Arash Most likely your PV system has components that contain discontinuities. Thus, the Plant cannot be linearized. Howeve...

PID Tune: Plant cannot be linearized

Hi @Arash Most likely your PV system has components that contain discontinuities. Thus, the Plant cannot be linearized. Howeve...

28 days ago | 0

| accepted

Answered

State-Space Matrices

Hi @Aysel Alimirzayeva I added a simple example to show you. If you like this example, consider voting 👍 the Answer. Thanks! S...

State-Space Matrices

Hi @Aysel Alimirzayeva I added a simple example to show you. If you like this example, consider voting 👍 the Answer. Thanks! S...

30 days ago | 1

Answered

Plot step response of transfer function

Hi @Ye Ken Kok It is a input-output difference equation. Thus, you cannot use the continuous-time Laplace transform. Since the...

Plot step response of transfer function

Hi @Ye Ken Kok It is a input-output difference equation. Thus, you cannot use the continuous-time Laplace transform. Since the...

1 month ago | 0

Answered

tuning PID controller in simulink with actual hardware equipments

Hi @aakash dewangan If the transfer function is unknown, and the system is relatively simple, perhap the model-free extremum-se...

tuning PID controller in simulink with actual hardware equipments

Hi @aakash dewangan If the transfer function is unknown, and the system is relatively simple, perhap the model-free extremum-se...

1 month ago | 0

Answered

Help with formulating conditional logic.

Hi @Jeffrey Lewis There are a few ways to do it. But since you have written the data into the code, I think probably the simple...

Help with formulating conditional logic.

Hi @Jeffrey Lewis There are a few ways to do it. But since you have written the data into the code, I think probably the simple...

1 month ago | 0

| accepted

Answered

State-Space Matrices

Hi @Aysel Alimirzayeva It's because of negative feedback. The LQR function only computes . Making a substitution

State-Space Matrices

Hi @Aysel Alimirzayeva It's because of negative feedback. The LQR function only computes . Making a substitution

1 month ago | 1

| accepted

Answered

runge kutta for 2 order ODE

Hi @Rio Bratasena Assuming that the symbol is the Dirac impulse. please check if the following responses are expected wh...

runge kutta for 2 order ODE

Hi @Rio Bratasena Assuming that the symbol is the Dirac impulse. please check if the following responses are expected wh...

1 month ago | 0

Answered

Calculating system bandwidth using Function "bandwidth"

Hi @Alireza Aghdaei The function can distinguish from the input type. One requires a Dynamic System Model, the other requires a...

Calculating system bandwidth using Function "bandwidth"

Hi @Alireza Aghdaei The function can distinguish from the input type. One requires a Dynamic System Model, the other requires a...

1 month ago | 0

| accepted

Answered

how does matlab simulate electric field

Hi @abdullah Typically, the quiver() function can be used. You can also find a very good example on the simulation of Electri...

how does matlab simulate electric field

Hi @abdullah Typically, the quiver() function can be used. You can also find a very good example on the simulation of Electri...

1 month ago | 1

Answered

Solve system of equations graphically

Alternatively, you can also do like this: Solve or plot this polynomial: x = -2:0.01:2; y = x.^4 - 6; plot(x, y), gr...

Solve system of equations graphically

Alternatively, you can also do like this: Solve or plot this polynomial: x = -2:0.01:2; y = x.^4 - 6; plot(x, y), gr...

1 month ago | 0

Answered

What block is hydraulic/liquid on/off valve in Simulink?

Hi @Busuyi 2nd Edit: Based on your sketch, it should be a Gate Valve. https://www.mathworks.com/help/hydro/ref/gatevalve.html...

What block is hydraulic/liquid on/off valve in Simulink?

Hi @Busuyi 2nd Edit: Based on your sketch, it should be a Gate Valve. https://www.mathworks.com/help/hydro/ref/gatevalve.html...

1 month ago | 0

Answered

i need help to find impulse response of system h(t) at time t

Hi @Rushit Bhavsar I used the impulse() method. but you can try using the expm() method. Look up the example and verify with th...

i need help to find impulse response of system h(t) at time t

Hi @Rushit Bhavsar I used the impulse() method. but you can try using the expm() method. Look up the example and verify with th...

1 month ago | 0

Answered

Does the fuzzy inference system (Mamdani) use Forward Chaining or Backward ?

Hi @Sarah IF you understand that the Fuzzy System provides means of reasoning by inference in order to decide the truthness of ...

Does the fuzzy inference system (Mamdani) use Forward Chaining or Backward ?

Hi @Sarah IF you understand that the Fuzzy System provides means of reasoning by inference in order to decide the truthness of ...

1 month ago | 0

Answered

Can anybody give me the idea for implementing PID control for dc motor using state space equations through ode45 solver?

@MOHAMED ASWER Not sure how your DI/dc motor system, but I think the following example should give you the basic idea. tspan ...

Can anybody give me the idea for implementing PID control for dc motor using state space equations through ode45 solver?

@MOHAMED ASWER Not sure how your DI/dc motor system, but I think the following example should give you the basic idea. tspan ...

1 month ago | 0

Answered

Find AIC, AICc, BIC for ODE system

Hi @TrevorR You can try using this command [aic, bic] = aicbic(). For more info, please check: https://www.mathworks.com/help/...

Find AIC, AICc, BIC for ODE system

Hi @TrevorR You can try using this command [aic, bic] = aicbic(). For more info, please check: https://www.mathworks.com/help/...

1 month ago | 0

Answered

How can I obtain the State space from the Mass,stiffness,damping matrices

Hi @aiman If the matrices are known, then you can apply these formulas: A = [zeros(n) eye(n); M\K M\C]; % to get the State...

How can I obtain the State space from the Mass,stiffness,damping matrices

Hi @aiman If the matrices are known, then you can apply these formulas: A = [zeros(n) eye(n); M\K M\C]; % to get the State...

1 month ago | 1

Answered

How to tune PID controller from time constant and static gain?

@Bruno Araujo, Not sure if you are looking for some manipulations like this: Kp = 72.402; Tp = 639.24; Gc = pid(Kp) Gf = tf(...

How to tune PID controller from time constant and static gain?

@Bruno Araujo, Not sure if you are looking for some manipulations like this: Kp = 72.402; Tp = 639.24; Gc = pid(Kp) Gf = tf(...

1 month ago | 0

Answered

Cost function to minimize variance of error

@Rishabh Pachchhao, Since you didn't provide info about your system. here is an example that you can study. However, I don't t...

Cost function to minimize variance of error

@Rishabh Pachchhao, Since you didn't provide info about your system. here is an example that you can study. However, I don't t...

1 month ago | 0

Answered

How to solve this equation

@Raef, you are a good son and took up a filial duty to help your father. n = 1; y0 = 1; % intial value F = @(t, y) - (1...

How to solve this equation

@Raef, you are a good son and took up a filial duty to help your father. n = 1; y0 = 1; % intial value F = @(t, y) - (1...

1 month ago | 1

| accepted

Answered

Can anyone help understand what the blocks in this figure are and where to find them in Simulink library?

Hi @Busuyi If you compare with the generic symbols in a Piping and Instrumentation Diagram (P&ID), they are manual-operated Gat...

Can anyone help understand what the blocks in this figure are and where to find them in Simulink library?

Hi @Busuyi If you compare with the generic symbols in a Piping and Instrumentation Diagram (P&ID), they are manual-operated Gat...

1 month ago | 0

Answered

Find the local and global maxima and minima for the function (x+1)^2/(1+x^2) x belongs to [-5,5].Showing local min value something different than zero and how get local values

@Aashay, your code works. So, what exactly is the question for the math problem? syms x f(x)=(x+1)^2/(1+x^2); I=[-5,5]; fl(x...

Find the local and global maxima and minima for the function (x+1)^2/(1+x^2) x belongs to [-5,5].Showing local min value something different than zero and how get local values

@Aashay, your code works. So, what exactly is the question for the math problem? syms x f(x)=(x+1)^2/(1+x^2); I=[-5,5]; fl(x...

1 month ago | 0

Answered

Fossen's dynamic AUV model implementation

Hi @John Terry You can follow a few examples on this link and apply the [V, S] = odeToVectorField(eqns) command. https://www.m...

Fossen's dynamic AUV model implementation

Hi @John Terry You can follow a few examples on this link and apply the [V, S] = odeToVectorField(eqns) command. https://www.m...

1 month ago | 0

Answered

Solving a State Space Model using Runge Kutta method, Mid Point or Heun Method to view system response

Hi @Anas Rehman If you still keep the old versions of MATLAB (R2012 and older), you can find the requested ODE solvers in the l...

Solving a State Space Model using Runge Kutta method, Mid Point or Heun Method to view system response

Hi @Anas Rehman If you still keep the old versions of MATLAB (R2012 and older), you can find the requested ODE solvers in the l...

1 month ago | 0

Answered

Using fminsearch and then using the output of fminsearch in cost and ode function.

Maybe like this: [lambdas, cost] = fminsearch(@Q1_cost, -100) [interval, sol] = ode45(@Q1_ode, [0 10], [0.5 lambdas]); plot(i...

Using fminsearch and then using the output of fminsearch in cost and ode function.

Maybe like this: [lambdas, cost] = fminsearch(@Q1_cost, -100) [interval, sol] = ode45(@Q1_ode, [0 10], [0.5 lambdas]); plot(i...

1 month ago | 0

| accepted