Questions tagged [control-systems]

Questions on the use of Mathematica to analyze, design, and simulate continuous- and discrete-time control systems.

Filter by
Sorted by
Tagged with
2
votes
1answer
260 views

Simulating a combination of PDEs and ODEs

I am trying to simulate a combination of PDEs and ODEs, given below. $$ \begin{matrix} -L\dfrac{\partial}{\partial t}I(t,z)&=&\dfrac{\partial}{\partial z}V(t,z)+RI(t,z)\\ C\dfrac{\...
7
votes
1answer
363 views

Using the LQGRegulator to build a human operator model

I'm trying to build a human operator model using an optimal control model in Mathematica: The vehicle dynamics are given by ...
30
votes
2answers
700 views

Can we use Mathematica for electronics design?

A spoiler alert: I intend to answer my own question. I am posting this because I would like to share my excitement regarding the control theory tools in Mathematica, and also to promote further ...
17
votes
1answer
1k views

Simulating discrete time stochastic dynamic systems

What is the canonical way of simulating discrete time stochastic dynamical systems in Mathematica using the new functionality of Random processes? To take a concrete example, lets consider the ...
6
votes
1answer
210 views

Do we need to know the input signal when we use KalmanEstimator?

The first "Application" in the documentation for KalmanEstimator is copied below with additional variables for clarity. ...
13
votes
1answer
444 views

1D transient heat equation problem with controller

I would appreciate some help with following issue: I am trying to solve a 1D transient heat equation problem with a control loop in order to compensate a time variable boundary condition at one ...
9
votes
1answer
641 views

How to draw block diagrams as Graph objects?

In the documentation ClosedLoopResponsesWithAPIDController, There is a very nice block diagram. I want to create my own block diagrams similar to this. I clicked on the diagram and pressed "command-...
5
votes
2answers
1k views

Evaluation problems with NDSolve using the fixed step ExplicitEuler-Method

Motivation I am using Mathematica to implement System Dynamics (SD) models, e.g. differential equation models as applied to management/economic problems following the "methodology" of Jay W. ...
5
votes
1answer
380 views

Solving optimal control problem when input is constrained

Given a linear time-invariant system: $$x'(t)=Ax(t)+Bu(t)$$ with initial state $x(0)=x0$ and final state $x(T)=xT$. The performance measure to be minimized is: $$∫_0^Tu(t)^2dt$$ The most important ...
12
votes
1answer
2k views

How to calculate the $H_2$ and $H_\infty$ norms of TransferFunctionModels or StateSpaceModels?

Lets assume we have a system model: ...
5
votes
2answers
912 views

Convert DE to first order?

I have the following set of second-order differential equations: ...
5
votes
3answers
3k views

How to fix BodePlot that comes with Mathematica?

I am using Mathematica to go through the examples and exercises on the book Modern Control Systems, 6th edition by Dorf. On page 605, there is a table (Table 8.5) with the Bode plot for several ...
2
votes
1answer
312 views

Help with simulating a system model (inverted pendulum)

In this documentation article, Regulate an Inverted Pendulum, the author started by creating the following system. ...
7
votes
2answers
1k views

How to transform transfer functions into differential equations?

is there a way with Mathematica to transform transferfunctions (Laplace) into differential equations? Let's say I have the transfer function $\frac{Y(s)}{U(s)}=\text{Kp} \left(\frac{1}{s \text{Tn}}+1\...
4
votes
1answer
147 views

How to index multi-dimensional vectors in NDSolve/WhenEvent?

I want to solve a system of coupled ODEs using NDSolve with WhenEvent. But I'm having a hard time trying to index the state ...
4
votes
1answer
185 views

Estimation of parameters of limit cycles for systems of high-order differential equations (n> = 3)

There is a system of differential equations: Then, call the limit cycle the projection of the phase trajectory onto the plane in a pairwise combination of state variables ($x-y,y-z,x-z$). where $x,y,...
5
votes
1answer
9k views

How can I draw an asymptotic bode plot?

When I use Mathematica to draw a bode plot, it always gives the precise version, like this: BodePlot[(10 (s + 3))/(s (s + 2) (s^2 + s + 2))] How can I draw the ...
3
votes
1answer
99 views

System model merge with multiple input and one output

I was curious, and I used the built-in functions of Mathematica to analyze the following scheme: I used SystemModelMerge as: ...
2
votes
1answer
480 views

How To First Evaluate A Differential Equation And Then To Input The Function Parameters?

I have two functions: f1[x1_,x2_] := 2x1*x2 f2[x1_,x2_] := x1+x2*x1 and I would like to compute this matrix (linearization of the system), but the differentials ...
2
votes
1answer
183 views

Defining a non-linear coordinate transformation involving DSolve

This question is related to an other question I've asked yesterday here. Havin not received a reply, I believe there isn't a ready-made function for non-linear coordinate transformation in order to ...
1
vote
1answer
1k views

Calculate state-space model from dynamic equations

I want to find statespace model of calculated dynamic equations from given equations and eliminations in Mathematica (all the commands should be in one line), but it does not work properly, here is a ...
1
vote
1answer
285 views

How to set a limit and initial value for transfer function in Mathematica?

This is actually a follow-up question to this one! Assuming that I have a tf like: ...
1
vote
1answer
81 views

Strange output of a simple statespace model

The output of statespace model seems strange. In the follwing code, the odes are governing equations of a three floors structure, and the output are three accelerations of floors. If I ...
8
votes
1answer
168 views

On using DiracDelta[t] in OutputResposne in version 10. Different result from version 9

I am baffled by this. I was trying to run same example I had working in version 9.01 and found now I get empty plots. The example is here . Here is a simplified version of the above. The same exact ...
8
votes
1answer
1k views

How to convert a transfer function model to a zero-pole-gain model?

Mathematica has a function to convert TransferFunctionModels to StateSpaceModels: mytf=TransferFunctionModel[(2 s + 3)/(s^3 + 4 s^2 + 5), s] StateSpaceModel[mytf] ...
6
votes
1answer
171 views

Non-linear ODE from closed-loop system and Response

I started using Mathematica 12 and ran into difficulties. Namely, I want to compare the results of the calculation of a closed system from Simulink and in Mathematica. I rummaged around a bit on the ...
6
votes
3answers
5k views

DC gain of a transfer function

Consider this example. M = TransferFunctionModel[3/(s^2 - s + 5), s] the DC gain should be the value of the transfer function ...
3
votes
2answers
194 views

Multiple Output with OutputResponse in Mathematica

I have a question here regarding how to derive multiple output from OutputResponse or in general. Here is a screenshot of the codes As seen, I have only one quantity plotted. Tried google but didn't ...
2
votes
1answer
79 views

Complex OutputResponse?

I have the following dynamical system in state space form, yet defined with a transfer function: ...
2
votes
1answer
80 views

OutputResponse and contradictory control models

So I'm trying to learn some control theory for a little project I'm working on and decided I'd try the examples of pendulum and cart one can find all over the internets, and I'm following this post ...
1
vote
0answers
53 views

FullInformationOutputRegulator -how does it work?

How does this function work? I don't understand how the regulator equation is synthesized when the model is nonlinear. Does it make use of a power series approach? Can someone suggest something to ...
1
vote
1answer
469 views

Jacobian of nonlinear dynamic equations

As a supplementary to my question Calculate state-space model from dynamic equations, I have mixed linear and nonlinear dynamic equations, and want to linearize the nonlinear ones around an opperating ...
1
vote
0answers
502 views

No response from DSolve

Using optimal control theory, I am trying to find the optimal paths of d and k such that they will maximize profit as given by lc: ...