I want the value of 'gama1' to be obtained from the following equation

조회 수: 1 (최근 30일)
following is the code that i have written for obtaining the value of the 'gama1' variable. The issue i am facing is that when i run the code, i am gettin an error message that 'gama1' is an unknown parameter while i am actually trying to find out 'gama1' using the given FZERO function.
zeta=linspace(0,2);
alpha=10;
k=54;
c=500;
rho=7800;
w=0.5;
m=0.019;
n=0.015;
v=-0.38;
V=15;
t1=0.5;
%Tint(1)=500;
beta=1;
Tw=30;
mu0=3750e6;
h=0.025e-3;
gama_p=0.01;
y=500;
Q=zeros(10,1);
i=[1:1:10];
Tint=zeros(10,1);
for i=1:1:10,
Tint(i)=y;
u=i;
y=y+100;
Q(i)=i;
end
%display(Q)
for i=1:10,
if Tint(i)<=955,
mu(i)=1-(3.44e-4)*Tint(i);
else
A=1-((Tint(i)-955)./(1500-955));
mu(i)=0.68*power(A,1.7);
end;
end;
lamda=atan(mu)*180/pi;
phi = 35 + (0.5*(alpha-(atan(mu)*180/pi)));
vc=V*sind(phi)/cosd(phi-alpha);
%lc=t1*sind(phi+lamda-alpha)./(sind(phi)*cosd(lamda));
lc=t1*(sind(phi-alpha)+(tand(lamda).*cosd(phi-alpha)))/sind(phi);
%strain=tand(phi-alpha)+(1./tand(phi));
ref_strain=(V*cosd(alpha))./(h*cosd(phi-alpha));
ref_stress=mu0*(Tw^v).*power(ref_strain,m);
B=(beta*ref_stress)/(rho*c*Tw);
C=(sind(phi).*cosd(phi-alpha))./cosd(alpha);
D=((rho*(V^2))*sind(phi)*cosd(alpha))./(ref_stress.*cosd(phi-alpha));
K=k*cosd(phi-alpha)./(rho*c*h*V*cosd(alpha));
gmma2=(1./tand(phi))+tand(phi-alpha);
T0= (4.5e-4-(8*Tw*K))./((4.5e-4)-20*K);
T1=(4*T0-Tw)/3;
%gama1=0;
der1=(gama1-gama_p)/(2*h);
% AA=m*C.*power(T0,v)*(gama_p^n)*power(der1,(m-1))* (gama1+gama_p)/(h^2);
% BB= v*C.*power(T0,v-1)*(gama_p^(n))*power(der1,m).*((T1-Tw)/(2*h));
% ZZ=n*C*power(der1,m+1).*power(T0,v)*(gama_p^(n-1))-C.*D*der1;
% function F=hola(gama1,gama_p,h,m,C,T0,v,n,T1,Tw,D)
%F=@(gama1) AA+BB+ZZ;
%syms gama1
%F=inline('m*C.*power(T0,v)*(gama_p^n)*power(der1,(m-1))* (gama1+gama_p)/(h^2))+(v*C.*power(T0,v-1)*(gama_p^(n))*power(der1,m).*((T1-Tw)/(2*h)))+(n*C*power(der1,m+1).*power(T0,v)*(gama_p^(n-1))-C.*D*der1')
F=@(gama1) (m*C.*power(T0,v)*(gama_p^n)*power(der1,(m-1))* (gama1+gama_p)/(h^2))+(v*C.*power(T0,v-1)*(gama_p^(n))*power(der1,m).*((T1-Tw)/(2*h)))+(n*C*power(der1,m+1).*power(T0,v)*(gama_p^(n-1))-C.*D*der1);
gama1=fzero(F,0);
M=(power(T0,v));
N=M';
tou0=C*(((gama1-gama_p)/(2*h))^(m))*N*(gama_p^(n));
tou=rho*(power(V*sin(phi),2)*gama1)+tou0;

채택된 답변

Purushottama Rao
Purushottama Rao 2015년 5월 4일
gamma1 variable has been used in the equations prior to its declaration. MATLAB does not understand what is gamma1 until it faces gamma1=fzero(F,0)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 File Operations에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by