please find the answer of the programme it is showing some error,i've tried a lot to slove but could not ablie to,. please help
Informazioni
Questa domanda è chiusa. Riaprila per modificarla o per rispondere.
Mostra commenti meno recenti
clc
clear all
var w;
alpha=0.05
mu=0.05;
ztap=0;
ztaa=sqrt(3*mu/(8*(1+mu)));
omegaa=(1/(1+mu));
a1=1-alpha;
a2=2*ztaa*omegaa+2*ztap+2*ztaa*omegaa*mu;
a3=omegaa^2+4*ztap*ztaa*omegaa+mu*omegaa^2+1;
a4=2*ztap*omegaa^2+2*ztaa*omegaa;
a5=omegaa^2;
A=a1*omegaa^2*w^4-a3*omegaa^2*w^2+a5*omegaa^2-a1*w^6+a3*w^4-a5*w^2+2*ztaa*omegaa*a4*w^2-2*ztaa*omegaa*a2*w^2;
B=a4*w^3-a2*w^3-a4*omegaa^2*w+a2*omegaa^2*w+2*ztaa*omegaa*w^5-2*ztaa*omeggaa*a3*w^3+2*ztaa*omegaa*w*a5;
C=(a1*w^4-a3*w^2+a5)^2+(a4*w-a2*w)^2;
G=sqrt(A^2+B^2)/C^2;
Q=@(w) G;
S=quad(G,0,2);
2 Commenti
Walter Roberson
il 22 Nov 2012
Modificato: Walter Roberson
il 22 Nov 2012
What error is it showing, at what line?
Are you sure that you want to calculate the variance of the string 'w' ? That is what
var w;
will do. It is equivalent to
var('w')
and var() is the variance function.
Muruganandham Subramanian
il 22 Nov 2012
value for w?
Risposte (1)
Walter Roberson
il 22 Nov 2012
After fixing the var() issue, replace
Q=@(w) G;
with
Q = matlabFunction(G);
Questa domanda è chiusa.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!