Answered
how can I set the decimal digits of all coefficients at one time when outputting a polynomial f?
a = 5.327416; b = 3.660092; c = 1.5799301; fprintf('f(x) = %.3f*x^2 + %.3f*x + %.3f', a, b, c)

2 years ago | 0

Answered
Unable to use Control System Designer
Hi @Oz Etkin Please post the full code because the error message appears to have something to do with logical operations involv...

2 years ago | 0

Answered
Where is the tle file that contain data satellite (eccentricOrbitSatellite.tle) ?
Hello @Eman Adel The file "eccentricOrbitSatellite.tle" can be found in the folder named "orbitdata" if you have the Example fi...

2 years ago | 0

Answered
how do I set membership function to this ANFIS?
Hi @Ahmad In ANFIS training, only the Grid Partitioning method provides the flexibility to assign a fixed number of membership ...

2 years ago | 1

| accepted

Answered
using mean function to return a singular value of a row vector
Hi Jack, It could be the get_SoilMoisture(Object) function is nested in a for-loop that performs 3 iterations in the Main Scr...

2 years ago | 0

| accepted

Answered
Calculated 100% rise time value different than matlab value
Hi @Caleb Since and , then % Parameters theta = 1.23; % rad wd = 1.97; % rad % Rise t...

2 years ago | 0

| accepted

Answered
Sinc Interpolation without using predefined function
Hi @Radu-Andrei Not an interpolation expert, but I believe your code didn't work correctly because the sampling frequency (at 1...

2 years ago | 0

| accepted

Answered
Piecewise function in Simulink
Hi @Yamana Uno Since the piecewise signal is generated through an If-Else conditional statement in the coding mode, @Ishaan's a...

2 years ago | 0

Answered
Show matrix is not invertible.
Hi @L I believe this is an exercise in the Linear Algebra course. You have likely learned how to find the determinant of a matr...

2 years ago | 0

Answered
how can i plot bifurcation diagram of fractional logistic map?
The logistic map is given by and the code for the graphical representation of the bifurcation may be converted from the Pytho...

2 years ago | 0

Answered
F values come out as Infinity using the anovan function
Hi @ki o kim In this example, you'll notice that the F-statistic is calculated as the ratio of the mean squared errors: (7.875/...

2 years ago | 0

Answered
matlab gives my answer inverted
Hi @Maria Cinthia It sounds like you're looking for a state-space realization in the Controllable Canonical Form. If that's the...

2 years ago | 0

Answered
Find the integral of ;
Hello Sir @Newton I feel honored to have the opportunity to solve this integral problem for you in the modern computational era...

2 years ago | 1

Answered
How to simulate the state-space model
Hi @Hein zaw In MATLAB, you can use the ODE solver approach. If the system is LTI and you have the Control System Toolbox insta...

2 years ago | 0

| accepted

Answered
How to find mean of sin(t)/t with t [0, pi]?
Hi @Han Your function does not have the variable . But I guess that your teacher probably wants you to cleverly apply the Lagr...

2 years ago | 0

Answered
Control Algorithm for a Plant with Hysteresis-Shifted S-Curve
Hi @Achraf Without knowledge about the physical nature of the dynamics, your questions can only be adequately answered through ...

2 years ago | 0

Answered
how to define mpc object's plant as state space ?
Hi @AMAN There was an incorrect syntax issue with mpc(), but it is now fixed below: % Define system matrices (Ad, Bd, Cd, Dd) ...

2 years ago | 0

| accepted

Answered
plot 2 signals for sin(t)
After thinking about your learning experience, to learn exactly how sine wave is sampled at a fixed time step, you can try the p...

2 years ago | 0

Answered
Ploting streamline with vector's module on line.
Hi @泽江 Can you check if the following are what you want? spacing = 0.2; x = -2:spacing:2; y = -2:spacing:2; [X,...

2 years ago | 0

| accepted

Answered
what is the issue with my Fuzzy inference system (FIS) code?
Hi @Ahmad The error is due to the incorrect usage of the option set. The option set for the genfis() function should be genfisO...

2 years ago | 1

| accepted

Answered
How to apply step disturbance on one output at specific time in MPC?
Hi @HN I believe your algorithmic-based MPC can automatically handle the step change at 200 minutes, thanks to its built-in sel...

2 years ago | 1

| accepted

Answered
for PI feedback controller with un-unity feedback, final values is off
Hi @Abdulaziz Abutunis You can fix the issue by scaling the step input to match the gain in the feedback path (H) in order to e...

2 years ago | 0

| accepted

Answered
2nd Order Non-Linear Equation Numerical Solution and Plot
Hi @Conlen O'Brien You can assign a display name to each state and toggle the legends. Also, if A and B are fixed constants, th...

2 years ago | 0

Answered
EVALFIS : FIS must have rules.
Hi @Ceferino Please note that the input argument order for evalfis() has changed since the R2018b release. Additionally, there ...

2 years ago | 0

Answered
Not enough input arguments Been over the code so much need fresh eyes
Hi @Taylor Millett The code for the fmincon part is now fixed and it returns a local minimum solution. % Constants rho ...

2 years ago | 0

Answered
Error while creating DDPG RL agent
Hi @Muhammad Nadeem Error using deep.internal.network.dlnetwork/setLearnables Layer 'fc': Invalid Learnables. Expected...

2 years ago | 1

| accepted

Answered
Deep reinforcement learning and TD3 algorithm in the PID control
Hi @Francisco Rodriguez Sanchez As a matter of common sense, for the cartpole system, any angle that deviates from precisely ±1...

2 years ago | 0

Answered
Unrecognized function or variable 'i1'.
Hi @Dan Giffin I think you can do something like this: t = 0:0.01:10; f1 = 1/10; f2 = 1/5; % Call the function ThreeFun...

2 years ago | 1

Answered
Creating a Smith Chart with load impedance only
Hi @Adham Elkhouly I'm not well-versed with plotting Smith Chart. But starting R2023b, the smithplot() function replaces the sm...

2 years ago | 0

| accepted

Answered
Can't solve the equations
Hi @Della I assume you want to plot something similar to this. However, please note that the solution set depends on the initia...

2 years ago | 0

Load more