Answered
Unable to solve stiff differential equation
Hi @AJMIT KUMAR, It appears that the system is inherently unstable for . If you simulate the system for a longer time, then the...

3 years ago | 0

Answered
plotting transfer function / time domain version
Hi @Miller If you want to use the step(sys) function, then the sys must be a SISO or MIMO Linear System Model. In your case, i...

3 years ago | 0

Answered
Matlab Spring Damper models of Human Body Model
Hi @Phanindra Reddy Ravi There are some commercial realistic humans’ skeletal and muscle models developed by BoB Biomechanics. ...

3 years ago | 1

| accepted

Answered
Train a Siamese Network to Compare Images with image size [227 227 3]
You should be able to find this line in the tutorial: imageInputLayer([105 105 1],Normalization="none")

3 years ago | 0

Answered
Thermodynamic engine cycle and gas exchange simulation in ICE Engine
You can create the simulation model in MATLAB and Simulink, if you understand the mathematical model, or knowing how to make use...

3 years ago | 1

| accepted

Answered
Fuzzy Logic Toolbox - addRule throws "Do not use a rule keyword as a membership function name" error
Hi @Kartik Sahajpal Change the name of the fuzzy variable to "flowrate" (to eliminate the space). fis_size = mamfis; % Inpu...

3 years ago | 1

| accepted

Answered
Different Bode Plots from Same Function
Hi @Prithvi Nathan It seems that they are not exactly the same from the mathematical perspective. format long g estimated_n...

3 years ago | 0

Answered
How to generate a golden ratio graph in simulink
Hi @Ragavendra Joshi 18 Apr 2023 (Update): Here are the basic blocks in Simulink that you can use to create the Golden Ratio Sp...

3 years ago | 1

| accepted

Answered
build an augmented PID control model for a DC servo motor in Simulink
Hi @Tony Cheng I'm unfamiliar with your system, but the Augmented PID Control Scheme should look like the following diagram in ...

3 years ago | 1

| accepted

Answered
Error in using ode45 for solution of nonlinear system of three equations which are interlinked to each other
Hi @FAIZ UL HASSAN Try this: % Define the time-varying Disturbance D = @(t) sin(pi/10*t); % Define the scalar parameters ...

3 years ago | 0

Answered
how to add a state space representation with identifiable parameters into a Matlab function or a any block?
Hi @kawsar I'm unfamiliar with your system (probably something to do with the state of charge of an energy storage system). Ho...

3 years ago | 0

Answered
What is the difference between the RMSE calculations?
Hi @alvaro fernandes If you have the data, then you can compute the root-mean-square error between the data arrays. I don't ha...

3 years ago | 0

Answered
Why I am getting negative values in my low pass filter results?
Hi @Zahra Since you asked, I'm guessing the input values are negative. t = linspace(0, 10, 1001); lpf = tf(1, [1 1]) % L...

3 years ago | 0

Answered
How to estimate data plots as an exponential with a horizontal Asymptote? y=Ax^B+C where B<1
Hi @Dominic Bruce Are you looking for something like this? x = [0.5 1 2 3]; y = [292.4 264.8 324 305; 182.2 175.6 202.4 199...

3 years ago | 2

| accepted

Answered
Torque controlled BLDC motor
Hi @Vrinda V Nair Sinusoidal back-EMF motors can experience reduced torque ripple by utilizing sinusoidal currents, such as tho...

3 years ago | 0

Answered
Build a MATLAB model to predict the compressive strength of concrete based on its composition and age.
Hi @David Coombs Usually, if you're unsure of how to begin writing MATLAB code, people tend to suggest you to start with the fr...

3 years ago | 0

Answered
Determining optimal coefficients for Horwitz matrix or characteristic equation
Hi @mohammadreza Edit: It appears that and can make the matrix Hurwitz. However, the optimal coefficients are subjective, bec...

3 years ago | 0

Answered
How to add disturbances into the model predictive control as an input?
Hi @jana nassereddine The matrix expression is equivalent to where is the input vector. If you want to anticipate the meas...

3 years ago | 0

| accepted

Answered
making sqrt file without using sqrt function
Hi @zot Edit: Since you didn't provide more info, then I'd suggest Newton–Raphson method. From the definition it can be rea...

3 years ago | 0

Answered
Integrator error: Integrator in Simulink 2021a, I input a negative nymber but the output is a positive integral value
The integrator could be integrating from an initial positive value.

3 years ago | 1

Answered
Why does my ode45 function not run?
Hi @Sneh That's because the response of one of the states, exploded. This it cannot run to the end sec. % t = 0:0.01:(2*pi*4...

3 years ago | 0

Answered
Nonlinear iteration error in Simulink model
Hi @Andrew BArney The message does not imply an algebraic loop error, but it suggests that one or more system states are approa...

3 years ago | 0

Answered
Creating fuzzy rules with rule editor in matlab online
Hi @Hazal Eylül If you are designing the fuzzy inference system (FIS) manually, and there are 6 inputs with 2 MFs for each inpu...

3 years ago | 2

| accepted

Answered
polynomial curve fitting error
Hi @Sumera Yamin If, for some reasons, you like to name your script "polyfit.m", try adding a prefix to make the filename uniqu...

3 years ago | 2

Answered
I am not able to solve equilibria for coupled non linear ode system
@Ruma Dutta, can you fit your ODE in this example (double integrator)? If there are more states, then duplicate the lines as nec...

3 years ago | 0

Answered
Solving ODE with piecewise driving force
Hi @Moosejr In this case, you can use the deval() function. I also fixed the conditional statement in the ODE. tspan = [0 5]...

3 years ago | 2

| accepted

Answered
Plot transfer function with input
Hi @Kaizi Here are two simplest ways to do it: Method 1: Vi = 3; % input G = tf([1.8 2.4 0], [0.72 1.8 1]) step(Vi*G) ...

3 years ago | 0

Answered
Help on solving nonlinear coupled equations with Runge-Kutta approach
Hi @Jake I am unfamiliar with your equations of motion. But you can check and compare if you get similar plots below as solved ...

3 years ago | 2

| accepted

Answered
Using ode4 solver in a sliding mode controller
Hi @Mikel In MATLAB, I think these are the expexted results ,where the nonlinear state estimators and are able to rapidly tra...

3 years ago | 1

| accepted

Answered
state feedback control and observer
Hi @영탁 한 Since no requirement is provided, we follow the design criteria given in the example: Settling time less than 2 secon...

3 years ago | 5

| accepted

Load more