Newmark Beta Method problem

8 ビュー (過去 30 日間)
Chaudhary P Patel
Chaudhary P Patel 2021 年 1 月 12 日
移動済み: Rik 2022 年 9 月 27 日
alpha=0.25;
delta=0.5;
%-------------------
delt=0.005;
% delt=28;
%-------------------
a0=1/(alpha*delt^2);
a1=delta/(alpha*delt);
a2=1/(alpha*delt);
a3=(1/(2*alpha))-1;
a4=(delta/alpha)-1;
a5=(delt/2)*((delta/alpha)-2);
a6=delt*(1-delta);
a7=delta*delt;
%------------------ Co-efficient of Damping--------------------------------
wn= 2*pi./T(1,1);
xeta=0.05;
R=nf*nodof;
u=zeros(R,1);
udot=zeros(R,1);
%-------------------
uddot=inv(MGf)*(F-(KGf*u));
% uddot=[0;10];
%-------------------
khat=KGf+a0*MGf;
for i=1:1:15
if(i==1)
ftdelt=F+(MGf*((a0*u(:,i))+(a2*udot(:,i))+(a3*uddot(:,i))))+(C*((a1*u(:,i))+(a4*udot(:,i))+(a5*uddot(:,i))));%Force
else
ftdelt=F+(MGf*((a0*utdelt(:,i))+(a2*udottdelt(:,i))+(a3*uddtdelt(:,i))))+(C*((a1*utdelt(:,i))+(a4*udottdelt(:,i))+(a5*uddtdelt(:,i))));%Force
end
utdelt(:,i+1)=inv(khat)*ftdelt;%Displacement
%Unable to perform assignment because the indices on the left side are not compatible with the size of the
right side.
if(i==1)
uddtdelt(:,i+1)=(a0*(utdelt(:,i+1)-u(:,i)))-(a2*udot(:,i))-(a3*uddot(:,i));%Acceleration
else
uddtdelt(:,i+1)=(a0*(utdelt(:,i+1)-utdelt(:,i)))-(a2*udottdelt(:,i))-(a3*uddtdelt(:,i));%Acceleration
end
if(i==1)
udottdelt(:,i+1)=udot(:,i)+(a6*uddot(:,i))+(a7*uddtdelt(:,i+1));%Velocity
else
udottdelt(:,i+1)=udottdelt(:,i)+(a6*uddtdelt(:,i))+(a7*uddtdelt(:,i+1));%Velocity
end
t=(i+1)*delt;
end
  2 件のコメント
Chaudhary P Patel
Chaudhary P Patel 2021 年 1 月 12 日
移動済み: Rik 2022 年 9 月 27 日
problem is comin from the finding displacemet, i wrote error there.
Image Analyst
Image Analyst 2021 年 1 月 12 日
移動済み: Rik 2022 年 9 月 27 日

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

回答 (0 件)

カテゴリ

Help Center および File ExchangeSimultaneous and Synchronized Operations についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by