Effacer les filtres
Effacer les filtres

i=dsolve('​Dy=-8*y+40​*sin(8*t)'​,'y(0)=5') Warning: Support for character vector or string inputs will be removed in a future release. Instead, use syms to declare variables and replace inputs such as dsolve('Dy = -3*y') with syms y(t); dsolve(diff(y,

1 vue (au cours des 30 derniers jours)
i=dsolve('Dy=-8*y+40*sin(8*t)','y(0)=5')
Warning: Support for character vector or string inputs will be
removed in a future release. Instead, use syms to declare
variables and replace inputs such as dsolve('Dy = -3*y') with syms
y(t); dsolve(diff(y,t) == -3*y). > In dsolve (line 126)
  2 commentaires
Noah Prisament
Noah Prisament le 27 Nov 2023
Hi Juan, this question would be better posted in MATLAB Answers. But to resolve this warning, you can use the dsolve syntax described in the warning and explained in this documentation: https://www.mathworks.com/help/symbolic/dsolve.html which uses symbolic equations instead of an equation string.
Walter Roberson
Walter Roberson le 11 Déc 2023
syms y(t)
i = dsolve(diff(y) == -8*y + 40*sin(8*t), y(0) == 5)
This leads to the result
i =
(15*exp(-8*t))/2 - (5*2^(1/2)*cos(8*t + pi/4))/2

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Formula Manipulation and Simplification dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by