# characteristic equation of free vibration of beam using fzero function

4 views (last 30 days)
GOUTAM SARKAR on 8 Aug 2020
Edited: GOUTAM SARKAR on 12 Aug 2020
Hello every one,
I am solving a Euler-Bernoulli Beam equation for a free vibration system. The beam is supported on an elastic soil. To solve the characteristic equation i have use "fzero" function. while running the code its gave a error massage "Exiting fzero: aborting search for an interval containing a sign change because complex function value encountered during search." so it will be verry help full if any one tell me how to eliminate this error. The matlab coading is as follows,
clc
clear
syms W
L= 60
k=2e7;
m= 2355.069
E=2.07e11;
I=0.01076;
T= 2e3;
R=2e4;
K= (m*W/E*I)^0.25; %W=w^2
A1=R;
A2=E*I*K/L;
A3=R;
A4=-E*I*K/L;
B1=-E*I*K^3/L^3;
B2=T;
B3=E*I*K^3/(L^3);
B4=T;
C1=-E*I*K/L*sin(K)+R*cos(K);
C2=-E*I*K/L*cos(K)-R*sin(K);
C3=E*I*K/L*sinh(K)+R*cosh(K);
C4=E*I*K/L*cosh(K)+R*sinh(K);
D1=-E*I*K^3*cos(K)/(L^3)-T*sin(K);
D2=E*I*K^3*sin(K)/(L^3)-T*cos(K);
D3=E*I*K^3*cosh(K)/(L^3)-T*sinh(K);
D4=E*I*K^3*sinh(K)/(L^3)-T*cosh(K);
H=[A1,A2,A3,A4;B1,B2,B3,B4;C1,C2,C3,C4;D1,D2,D3,D4]
Det=det(H)
f = inline(Det,'W')
for i= 1:100
s(i)= fzero(f, i/5);
end
su=(round((s),7));
output = (su(1:3)/L);
f= (output.^.5)/(2*(22/7))