How to convert PDE into matrix form

10 ビュー (過去 30 日間)
Sandeep Nair
Sandeep Nair 2022 年 11 月 25 日
編集済み: Torsten 2022 年 11 月 28 日
i have a partial differential equation like
m1*diff(x1(t), t, t) + c1*x1d + k1*x1 + (c2*(2*x1d - 2*x2d))/2 + (k2*(2*x1 - 2*x2))/2 =0
m2*diff(x2(t), t, t) - (c2*(2*x1d - 2*x2d))/2 - (k2*(2*x1 - 2*x2))/2 = 0
and i want to bring this form into
matrix form of x1 ,how is it possible to do in matlab
  2 件のコメント
Torsten
Torsten 2022 年 11 月 25 日
This is not a partial differential equation, but two second-order ordinary differential equation for functions x1 and x2.
What do you mean by "matrix form of x1" ?
Sandeep Nair
Sandeep Nair 2022 年 11 月 25 日
Please find the form in which i want,i have attached the fig

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

回答 (1 件)

Torsten
Torsten 2022 年 11 月 25 日
編集済み: Torsten 2022 年 11 月 25 日
Can you write this in matrix form ?
m1*diff(x1(t), t, t) + 0*m2*diff(x2(t), t, t) + (c1 + c2) * x1d - c2 * x2d + (k1 + k2) * x1 - k2 * x2 = 0
0*diff(x1(t), t, t) + m2*m2*diff(x2(t), t, t) - c2 * x1d + c2 * x2d - k2 * x1 + k2 * x2 = 0
This is something you must do by yourself. MATLAB can't help you with this (or only with a lot of effort in advance from your side).
  2 件のコメント
Sandeep Nair
Sandeep Nair 2022 年 11 月 28 日
Hi,am not able to write in this form hence wanted help from this forum on how to do it
Torsten
Torsten 2022 年 11 月 28 日
編集済み: Torsten 2022 年 11 月 28 日
But exactly this system is already written in matrix form in your attached "Matrixformulation.png" with P1(t) and P2(t) being 0. So what exactly is your question ?
I already wrote that MATLAB has no tool to convert written equations in matrix form - that's a task you have to do by yourself.
E.g. if you have the 2 equations
a1*x + b1*y = c1
a2*x + b2*y = c2
you can write them in matrix form as
U*z = w
with
U = [a1 b1 ; a2 b2], z = [x;y], w = [c1;c2]

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

カテゴリ

Help Center および File ExchangeGeometry and Mesh についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by