Questions tagged [matlab]

Use of Matlab to solve engineering problems.

Filter by
Sorted by
Tagged with
0
votes
0answers
17 views

Inverse Kinematics with MATLAB problem [closed]

Work can be checked using the MATLAB code below: ...
0
votes
1answer
47 views

Pole placement with damping ratio and natural frequency

how can I find out the poles of a system if I have the damping ratio $ ζ = 0.707$ and the natural frequency $ω_n = 2.3\text{ rad/sec}$? $A = \begin{bmatrix} -0.02 & 0.1 & 0 & -9.81 \\ -0....
0
votes
0answers
19 views

Process disturbance in PI controller help

This is the project i'm working on and i'm struggling to understand one sentence which is stopping me from progressing the project. I'm struggling to understand what it means when it says to add +/- ...
0
votes
0answers
26 views

Heat Transfer FEA with matlab

I have to write a matlab code using finite element method to solve this problem. I have solved it as follows but I dont know how to apply it in matlab. I have to write a matlab code using finite ...
0
votes
0answers
20 views

Mixed Sensitivity Problem

I have plant, $$P(s) = \frac{1-s/5}{(s^2 + s/4 +1/4)}$$ I am taking a mixed sensitivity approach for that I have chosen $V$,$W_1$ and $W_2$ as follows: For bandwidth, $\omega$ =1 so I chose M as, $M = ...
1
vote
2answers
65 views

Fault Recovery of a UAV using MATLAB

I'm currently investigating fault recovery in a UAV using MATLAB. I've been given several variables: phi = the roll angle psi = the yaw/heading angle beta = the side slip p = roll rate r = yaw/...
0
votes
1answer
26 views

How I can separate a matrix into two matrices in Matlab?

I want to separate into two matrices in Matlab like this: $$ Q=Sq^{T}Sq $$ for example this matrix: $$ Q=\Biggm[\matrix{92.316 &31.78&240.417\cr 31.78 &194.66 &275.47\cr 240.417 &...
0
votes
1answer
39 views

Optimization with GA (genetic algorithm)

I want to optimize the below function with GA(genetic algorithm): $$ \min_{l_{x_1},l_{x_2},l_d}||S_QS(z)||_2 $$ $S_Q$ and S(z) are defined as: $$ S_Q=\Biggm[\matrix{6.6549 &-0.806&6.883\cr -0....
0
votes
0answers
23 views

Plotting S parameters on Matlab

I have equations for S11 and S21 parameters for a bandpass filter which are obviously frequency dependent. I know there are commands like sparameters() and rfplot() used specifically for plotting S ...
0
votes
0answers
35 views

Craig Bampton Model Order Reduction on Ansys

I am in the process of modeling a component as a flexible body in Simscape Multibody environment (Simulink). I need to superimpose rigid body model with the deformation model. The deformation model is ...
0
votes
0answers
26 views

Simscape Flexible body - modeling a busbar as a flexible component on Simscape

I am trying to model a copper busbar as a flexible body for simulating it in the Simscape Multibody environment. I have built the model, but I am failing to generate the flexibility. I will describe ...
0
votes
1answer
26 views

Why use python over MATLAB? [closed]

So in my bachelors and throughout my engineering degree, we did everything in MATLAB. But I've heard that many companies use python over matlab. Trying Python out for myself, it seems harder to use in ...
0
votes
1answer
46 views

What meaning does the following sine wave have when it comes to amplitude?

So I am getting into engineering and was curious what it means when a sine wave isn't even in a sense, at 0, from my understanding, the waveform has peak to peak amplitude of 4, while having a ...
0
votes
1answer
36 views

Is more requested MATLAB or Python in companies (for engineers)? [closed]

My question is not exactly on MATLAB vs Python in terms of features (about which there are plenty of topics yet). It's a specific question for engineers who have a certain experience with some ...
0
votes
0answers
38 views

How to model a double transfer function in Simulink?

I'm trying to model an actuator in Simulink based transfer functions previously derived. One of functions is $$\omega_p=G_2(K_cG_1V_c-c)$$ where $$G_1=\frac{K_e}{\tau_es+1}$$ $$G_2=\frac{1}{c+...
0
votes
0answers
28 views

How to take the engineering FFT of Signal in Matlab?

All, The FFT function in matlab gives a theoretical mathematical FFT of the signal, and is not scaled to units and is real imaginary and not amplitude-frequency is there an alternative way of FFT to ...
1
vote
2answers
69 views

How do I interpret states in the MATLAB System Identification Toolbox?

I am using the MATLAB System Identification Toolbox to estimate a 3rd order state space plant model. More precisely, the plant is a car with an Arduino mounted on it. The car takes in a PWM duty cycle ...
0
votes
2answers
75 views

How can I find deflection in a member that doesn't have a constant area moment of inertia?

I'm trying to calculate the maximum deflection in a simply supported member with a uniformly distributed load. The trouble is this member does not have a constant area moment of inertia. I've drawn a ...
-1
votes
1answer
20 views

Regressor-passivity robot control. Help with simulation (Simulink/Matlab)

I'm trying to simulate a 2DOF planar pendulum with a regresor-passivity control, the thing is I've been having some issues with my simulation, I'm using Simulink, but in theory I know my control law ...
-1
votes
1answer
58 views

sinking speed of particle in water

For a Newtonian fluid the sinking final speed of a metal particle is given by this equation : while g is Gravitational acceleration , $\rho_P$ = is particle density , $\rho_F $ = is fluid density ,...
1
vote
1answer
187 views

Root Locus and Routh–Hurwitz stability criterion

A satellite launcher has a unit feedback system, whose TF global open loop is given by: $$G_c(s)G(s) = \frac{K(s^2-4s+18)(s+2)}{(s^2-2)(s+12)} $$ a) Draw the root locus for this function b) ...
3
votes
0answers
42 views

Mathematical transformation of a heading angle to a roll angle

I'm trying to understand a function in a SIMULINK example of a path following UAV simulation. The gist is that, the UAV Waypoint Follower block provides a required heading from a list of waypoints and ...
0
votes
1answer
189 views

How to find closed loop transfer function and use it to identify τ and k?

I have to answer a few questions on transfer functions using Matlab. The first question, which I solved without Matlab, gives a time response graph for an LR circuit, and asks me to find the first ...
1
vote
0answers
24 views

Slow integration of system ODE under specific conditions in adsorption problem

I am trying to solve the system of ODEs below. I am applying the finite differences to z, so I get a system of ODE that I can solve with a solver like ode45. The problem is that under the conditions ...
3
votes
0answers
56 views

LQR Implementation in MATLAB

I am trying to implement a simple LQR controller in MATLAB for a purely deterministic system. The code is shown below: ...
3
votes
1answer
101 views

Finding coefficients for a PID controller that minimize the integral of the squared error (ISE)

The problem The problem is to find the coefficients for the P, I and D terms of a PID controller used to regulate the object that minimize the the integral of the squared error (ISE): $$Q = \int_0^\...
-2
votes
1answer
60 views

Limiting PID controller's output making the plant unstable and untunable

I am using the PID block in Simulink and limiting the output to (+/-)5. The plant becomes unstable and untunable after putting these limits. The plant is stable and tuneable otherwise if no limits are ...
1
vote
1answer
147 views

How to calculate initial concentration of first-order reaction in CSTR?

(This question comes from a Chemical Engineering background, but basic Math and Programming knowledge is also required. I hope it still falls in the scope of engineering.stackexchange.com If not, ...
1
vote
0answers
9 views

how to implement an encoder in matlab

How can I encode a quantized vector in matlab ? This is a part of a problem where I am asked to implement a communication block using matlab.
1
vote
0answers
16 views

Unexpected Closed-Loop System Response of Longitudinal Aircraft Dynamics

I have a closed-loop system that represents the longitudinal dynamics of an aircraft with states x velocity, z velocity, pitch rate, pitch, and x and z inertial positions. The outputs of the system (...
3
votes
1answer
61 views

Problem with performances of a control scheme

I am trying to prove with Matlab that if I have an improper system and I place poles at higher and higher frequencies the performances of the system improves. In particular I am considering the ...
0
votes
0answers
28 views

Matlab Code Debug: Trapezoidal and Simpson's Integration Rule

Hey so I am having issues some issue with this code: ~ ...
0
votes
0answers
326 views

How to obtain transfer function of servo?

I am using a servo motor and controlling it via arduino. Servo motor is part of a control system and I have to use System Identification techniques in order to obtain the servo's transfer function. ...
0
votes
0answers
49 views

effect of coupling in MIMO systems

I have a MIMO system with a 2x2 transfer matrix, for example consider: $\begin{pmatrix} \frac{2}{s+1} & \frac{1}{(s+1)(s+2)}\\ \frac{1}{(s+1)(s+2)}&\frac{2}{s+2} \end{pmatrix}$ I would ...
0
votes
1answer
107 views

Solving a linear mass balance equation in the form of Ax = 0 with variables in vector x

I have been tasked with solving a series of linear equations in the form of Ax = b, where b is the zero vector. Specifically, I have a matrix E which is 4x7 and a column vector r which is 7x1, as ...
0
votes
0answers
29 views

Tool to simulate sensor data

Say I have a light source at a distance of 1Km from a light detector (photo detector). Right in front of the sensor, I keep a rotating reticle with some sort of pattern. To better appreciate the ...
0
votes
1answer
35 views

Is it possible to have open loop with same input term as the output?

For example, i have this differential equation: $$\dot{y} = 1.8 + 0.58u \sqrt{y}$$ Is it possible to model this system in open loop?? My understanding is that since the term $y$ is in the output ...
1
vote
0answers
28 views

How can I measure the impact of noise on a FFT?

Please, I have to solve a problem and I really need some help. I have to give an efficient method to consider a maximum amplitude as a starting point to consider as noise the whole spectrum below ...
0
votes
2answers
615 views

How to find Performance assessment (IAE and ISE) of a PID Controlled system?

The Integral Absolute value Error (IAE) and the Integral Squared Error (ISE) is to be analysed. A PID Controller is given as follows: \begin{gather} C(s)=K_p+K_i\frac{1}{s}+K_ds \end{gather} where $...
0
votes
1answer
59 views

How to input amplitude on a second order transfer function?

I have some samples of readings from an accelerometer (unit: g) and I did a FFT (on MATLAB) on the vector generated from these samples to see its frequency spectrum. Then I have isolated the peaks and ...
1
vote
1answer
101 views

Stabilization of telescope on gimbal using data from encoders and gyroscope

I'm designing a control system for a balloon-borne telescope experiment. As the balloon is constantly moving and the gondola is rotating, I want to stabilize the telescope which can be controlled in 3 ...
1
vote
0answers
126 views

Designing a PID Controller for Satellite Control

As an Aerospace Engineering Student, I have been trying to make a project of a PID Controller to control the attitude response of a satellite using the parameters from a project called Kufasat. The ...
2
votes
1answer
488 views

How to use lsim in matlab for a closed loop system

I have designed a system using a minimum realization. I have the A, B, C matrices and I have assigned closed loop poles for the system. I used the place command to find my K matrix. I am wondering ...
0
votes
0answers
41 views

Solving Hertz Impact ODE with Simulink

I have a question about modelling a nonlinear 2nd order ODE for an impact of a sphere on a thin plate in Simulink. Depending on the solver and solver options, my results in Matlab vary a lot. Some are ...
0
votes
1answer
884 views

Design of a lead compensator with root locus in matlab

For the transfer function $G(s)$, I tried to design a lead compensator for the function to have a response to the step with the following specifications: $$\%OS = 10\% \ \rightarrow \ Overshoot $$ $$ ...
1
vote
2answers
97 views

Analizing Vibrations Influence on Dynamic Weighing

I have a very sensitive scale used for dynamic weighing (by dynamic I mean that the scale and load cells are actually beneath a belt conveyor that actively weight product when it´s being transported ...
1
vote
0answers
80 views

How can I do engineering projects for money at home? [closed]

I am a M.Sc. graduate in mechanical engineering and I have experience with engineering software, like MATLAB, CATIA, and ABAQUS. I want to know how I can find industrial projects like finite element ...
0
votes
1answer
35 views

Temperature not changing in my code for 1-D heat equation: Explicit Scheme

I am trying to solve the following 1-D heat equation with provided boundary conditions using explicit scheme on Matlab. I have been trying to plot the results but I realized that my temperatures are ...
1
vote
1answer
108 views

Get results of output for each one value of the input - MATLAB ODE

I am simulating a mass - damper - system in Matlab and I have the following vector (1x100) as input to my system: ...
3
votes
0answers
244 views

3 DOF SISO state space control

As part of a control systems course I have to implement control for a 3 DOF SISO mass spring damper model of a robotic cutter arm. The arm is to follow a 5Hz triangle wave reference which is ...