代码搜索:persistent
找到约 2,751 项符合「persistent」的源代码
代码结果 2,751
www.eeworm.com/read/128477/14294604
m button_clicked.m
function button_clicked
% Declare and initialize variable to store the count
persistent count
if isempty(count)
count = 0;
end
% Update count
count = count + 1;
% Create new string
www.eeworm.com/read/227046/14442791
m chap7_10f.m
%Discrete Kalman filter
%x=Ax+B(u+w(k));
%y=Cx+D+v(k)
function [u]=kalman(u1,u2,u3)
persistent A B C D Q R P x
yv=u2;
if u3==0
x=zeros(2,1);
ts=0.001;
a=25;b=133;
sys=tf(b,[1,a
www.eeworm.com/read/225852/14513466
m agvobs.m
function y=agvobs(x,w)
% Prediction of observation
%
% Check if variables should be initailized
persistent C % Make variables static
if nargin==1
return
end
y = x(1:3)+w;
www.eeworm.com/read/225852/14513492
m bodydot.m
function xdot=bodydot(x,u,v)
% Falling body example. State equation.
persistent gamma
if nargin==1,
gamma = x(4);
else
xdot = [-x(2)+v(1);
-exp(-gamma*x(1))*x(2)*x(2)*x(3)+v(2);
www.eeworm.com/read/225852/14513506
m body2.m
function y=body2(x,w)
% Falling body example. Output equation.
persistent M H
if nargin==1,
M = x(2);
H = x(3);
else
tmp = x(1)-H;
y = sqrt(M*M+tmp*tmp)+w;
end