How do i transform this equation system in to three dimensions?

1 回表示 (過去 30 日間)
Joel Andersson
Joel Andersson 2021 年 12 月 8 日
回答済み: Bjorn Gustavsson 2021 年 12 月 9 日
  1 件のコメント
Sam Chak
Sam Chak 2021 年 12 月 9 日
Looks like a motion of a rigid body with mass m that is constrained to the 2-dimensional x-y plane.

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

回答 (1 件)

Bjorn Gustavsson
Bjorn Gustavsson 2021 年 12 月 9 日
Since this looks like the equations of motion for a solid body falling in a constant gravitational field with some velocity-dependent drag you only have to realize that the motion will be in a vertical plane, Therefore you can always select a coordinate-system such that one of the two horizontal components (both position and velocity) are identical to zero. Conversely, since the horizontal propagation-direction remains constant you can simply convert the x and vx into two components in an arbitrarily rotated coordinate system. Just integrate the 2-D equations of motion (I'd shift the initial x-coordinate to zero). Then it should be as simple as:
phi0 = pi/sqrt(3);
r0v0_original = [0,1,3,4*cos(phi0),4*sin(phi0),5];
r0v0_for2D = [0,r0v0_original(3),sqrt(r0v0_original(4)^2+r0v0_original(5)),r0v0_original(6)];
[t,rv] = ode45(... % etc
x1 = r0v0_original(1) + rv(:,1)*cos(phi0);
x2 = r0v0_original(2) + rv(:,2)*sin(phi0);
vx1 = rv(:,4)*cos(phi0);
vx2 = rv(:,5)*sin(phi0);
Here I've assumed that you have the position-components as the first 3 (2 in the eqs-of-motion function) and the velocity-components as the last 3 (last 2 in the equation-of-motion).
HTH

カテゴリ

Help Center および File ExchangeAssembly についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by