フィルターのクリア

How to slove it (using matlab)

1 回表示 (過去 30 日間)
Lokas Johnson
Lokas Johnson 2023 年 1 月 25 日
回答済み: Luca Ferro 2023 年 1 月 25 日
Given the displacement x(t):
x(t)=-2.41* 10-5 e-0.4607t sin (3.0003t)
0≤t≤ 20 with an increment 0.01 sec
a. Find the velocity v(t)
b. Using subplot, plot x(t) and v(t) Write the title and the x-axis and the y-axis titles. (Please i need her slove)
  1 件のコメント
Dyuman Joshi
Dyuman Joshi 2023 年 1 月 25 日
This sounds like a homework assignment. If it is, show us the code you've written to try to solve the problem and ask a specific question about where you're having difficulty and we may be able to provide some guidance.
If you aren't sure where to start, I will ask you to look into sym; and how would you calculate velocity from displacement?

サインインしてコメントする。

採用された回答

Luca Ferro
Luca Ferro 2023 年 1 月 25 日
Try this:
syms t
x= (-2.41* 10^5)*(exp((-0.4607*t)))*sin(3.0003*t); %position expression
v= diff(x); %speed as a first derivative of the position
time=0:0.01:20; %time vector
xsol= subs(x,t,time); %evaluates the expressions using the time vector
vsol=subs(v,t,time);
tiledlayout(2,1) %plots both of them
nexttile
plot (time,xsol)
title('Position')
nexttile
plot (time,vsol)
title('Speed')

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSymbolic Math Toolbox についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by