# Search Results

Results tagged with Search options user 5998
18 results

Questions on the symbolic (DSolve, DifferentialRoot) and numerical (NDSolve) solutions of differential equations in Mathematica.

StateFeedbackGains solves a regulator problem. You need to try AsymptoticOutputTracker to track a reference trajectory (which are constants in your case). pendulum = AffineStateSpaceModel[{(M + m) x …
answered Dec 12 '16 by Suba Thomas
The step function comes on the right-hand side: i[t] /. NDSolve[{i'[t]/c + r i[t] == UnitStep[t], i[0] == 0} /. {c -> 1, r -> 4}, i[t], {t, 0, 5}]; The plot shows the current as the capacitor is …
answered Nov 26 '14 by Suba Thomas
There are some syntactical errors. You need to specify equations and not rules. If $a$ is an input variable, it should be specified as $a[t]$. Only the operating values of states and inputs need t …
answered Nov 14 '16 by Suba Thomas
SysDiff = { Subscript[F, x] == m Subscript[x, G]''[t], -g m + Subscript[F, y] == m Subscript[y, G]''[t], 1/2 l Sin[γ[t]] Subscript[F, x] - 1/2 l Cos[γ[t]] Subscript[F, y] == JG γ''[t]}; eqns = SysD …
answered Nov 12 '15 by Suba Thomas
To convert ODEs (or difference equations) to state-space form you can use the functions StateSpaceModel, AffineStateSpaceModel, or NonlinearStateSpaceModel. The input signatures of all three functio …
answered Aug 13 '15 by Suba Thomas
A solution for scalar transfer functions with delays. The main function accepts the numerator and denominator of the transfer function. tfmToTimeDomain[{num_, den_}, ipvar_, opvar_, s_, t_] := …
answered Mar 19 '14 by Suba Thomas
I'm afraid this is a duplicate of Calculate state-space model from dynamic equations. What is "applied point 1"? StateSpaceModel linearizes by computing the Jacobian matrix around the operating poin …
answered Nov 15 '16 by Suba Thomas
states = {x1, x2}; NonlinearStateSpaceModel[ NonlinearStateSpaceModel[m x''[t] + c x'[t] + k[x[t]] x[t] == F[t], x[t], F[t], x[t], t], states] Update (Pseudo code to order the state names c …
answered Mar 13 '17 by Suba Thomas
More physics than Mathematica as pointed out in the comments..., but here's my shot at it. G = 6.672*10^-11; m[1] = AstronomicalData["Earth", "Mass"]; tmax = 20000; r[1] = AstronomicalData["Earth", " …
answered Nov 6 '13 by Suba Thomas
It can be computed as the impulse response. (I also rationalized it to get the exact result.) tfm=TransferFunctionModel[Rationalize[-((-6.5-3.25 s-5.5 s^2+0.5 s^3+s^4)/((2+s) (1+0.5 s+s^2) (1.5 …
answered Dec 6 '18 by Suba Thomas
You could do the following to get the NonlinearStateSpaceModel nsys = NonlinearStateSpaceModel[x2'[t] == u[t] x2[t], x2[t], u[t], x2[t], t] And then simulate it Plot[Evaluate@OutputResponse[ …
answered Aug 17 by Suba Thomas
The controller blows up at the origin. ctrl /. Thread[{x1, x2, x3, x4, x5, x6} -> 0] During evaluation of In[88]:= Power::infy: Infinite expression 1/0 encountered. {ComplexInfinity} From …
answered Mar 18 '17 by Suba Thomas
One way would be first solve for $u1$ and $u2$ from the flip-flop control law. However that turns out to have no solutions, indicating some problem with the control law? Solve[{u1 == k1*Theta'[t] - ( …
answered Aug 4 '15 by Suba Thomas
StateSpaceModel[Flatten@{x'[t]==F[y[t]], G[y[t]]==0}, Flatten@{x[t],y[t]}, {}, Flatten@{x[t],y[t]}, t] where $t$ is the independent variable. For a concrete example see the documentation [link].
answered Oct 22 '15 by Suba Thomas
Yet another way to get the slopes. D[Interpolation[\[Beta], t], t]/D[Interpolation[\[Rho], t], t]; Plot[%, {t, 2, 5}] The values seem to jive with what is expected from the plot of $\beta$ and \$\ …
answered Jul 1 '13 by Suba Thomas

15 30 50 per page