Questions tagged [matlab]

Use of Matlab to solve engineering problems.

Matlab is a high-level language and interactive programming environment for numerical computation and visualization developed by MathWorks. It can be programmed to numerically solve many engineering problems using its core functions and/or the available specialized toolboxes.

101 questions
6
votes
1 answer

mass calculation from transfer function or bodeplot

I have a double mass rotary model. The two masses are connected by an axis which together acts as a spring damper system of the fourth order. The system is actuated by a motor and the angle of rotation is measured by rotary encoders at each end of…
6
votes
1 answer

Programmable parameter change of Pro/E simulation by using Excel VBA , Matlab, Labview or Pro/E own function

Now, I've been conducting beam simulation by using Pro/E. I would like to change payload(force) of beam step by step, and then plot the relation between deflection and payload(load range : 50kg to 500kg, step size : 25kg). But, this task is too much…
KKS
  • 354
  • 1
  • 11
5
votes
1 answer

dSPACE compiler linker error -- fscanf undefined

I'm dealing with a somewhat intractable problem. We're running dSPACE 7.4 (RTI 1006) on MATLAB 2011a, which I understand uses the dSPACE DS1006 C Compiler v. 2.2. When I try to compile one of our models, I wind up with a linker error claiming that…
ZStamler
  • 51
  • 3
4
votes
1 answer

Is it normal to get different solutions with different ODE methods in MATLAB simulink?

I made a block diagram using simulink. When I solve it with ode45 and ode23 it gives me different graphs. Is it normal? Should I use the proper one? m1=1.3608; m2=0.096; r=0.0592; I2=0.0002175; k1=186.3; g=9.81; Here is what the model looks…
Deccoyi
  • 41
  • 1
4
votes
2 answers

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^\infty \epsilon^2(t) \ dt $$ The object being…
4
votes
0 answers

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 positioning it. As you can see from the picture, the…
4
votes
1 answer

Convolution with RTD laminar flow

I have laminar flow in a tube. Consider the tube to be 0.2 m long and with an average velocity of 0.05 m/s. The analytical expression for my transfer function is: $E(t)= \frac{\tau^2}{2*t^3}$ for $t$>=$\frac{\tau }{2}$ and $E(t)=0$ for $t < \frac…
Gesetzt
  • 93
  • 4
4
votes
1 answer

How to design the right input to obtain a desired output for a linear system?

If I have a state-space model, so that matrices $A$, $B$, $C$ and $D$ are known, how can I design the right input $u$, so that $y$ is a desired signal, say, a sine wave with constant amplitude? $$\begin{aligned} \dot{x} &= A x + B u \\ y &= C x + D…
3
votes
1 answer

How do I create a graph of the phase angle and response of a harmonic excitation in Matlab?

In my course of dynamics of structures, I am struggling with some basic principles. As a practice, I am plotting (or attempting to plot) the curves that are shown in the course book, with the help of Matlab. For example, I want to plot the phase…
3
votes
0 answers

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 this heading is converted, by the heading…
3
votes
0 answers

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: %% Continuous Time clear all; close all; clc; % Parameters n = 2; m = 1; A = [1 1; 0 1]; B = [0.5; 1]; C = [1 0]; Q = eye(2); QT =…
3
votes
1 answer

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 following two degree of freedom scheme: where $C_{f}=…
3
votes
0 answers

How to solve LMIs with equality constraints using MATLAB?

I would like to find n by n matrices P and Q that minimize J = norm(P) + w*norm(Q), where w is a given weight, subject to P>=0, Q>=0, and f(P,Q)=0, where f(P,Q)=0 is a given function of P and R. I tried to solve this problem using the lmi solver of…
David
  • 31
  • 1
3
votes
1 answer

What are the Singular Values of a dynamic system and how are they calculated in the *sigma* function in Matlab?

According to Matlab documentation: sigma plots the singular values of the frequency response of a dynamic system. bode creates a Bode plot of the frequency response of a dynamic system. I am reasonably familiar with Bode plots and dynamic systems…
2
votes
1 answer

Active suspension with accelerometers and displacement observer/estimator problem

I faced a logical dilemma, while designing and simulating Active suspension system. This is what I have planned: My system will be controlling actuators of a vehicle, using PI. It is 2nd order mechanical system with mass-spring-damper-actuator. In…
Aurimas
  • 21
  • 2
1
2 3 4 5 6 7