SNN脉冲神经网络SNN脉冲神经网络的工作原理演示MATLAB仿真带GUI界面
Posted fpga&matlab
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了SNN脉冲神经网络SNN脉冲神经网络的工作原理演示MATLAB仿真带GUI界面相关的知识,希望对你有一定的参考价值。
clc;clear all;close all;
% 初始参数
I = 10;
sigma = 0.04;beta = 5;gamma = 140;
a = 0.02;b = 0.2;
c = -65;d = 2;
% 步长,改进欧拉法的相关参数
step = 0.1;
timeConter = 0:step:1000;
v = zeros(1,length(timeConter));
u = zeros(1,length(timeConter));
v(1) = -65;%v(2) = -60;
u(1) = 1;%u(1) = 1;
for i_conter = 2:length(timeConter)
K1_1 = sigma*v(i_conter-1)^2+beta*v(i_conter-1)+gamma-u(i_conter-1)+I;
vpn = v(i_conter-1)+step*(sigma*v(i_conter)^2+beta*v(i_conter)+gamma-u(i_conter)+I);
K2_1 = sigma*vpn^2+beta*vpn+gamma-u(i_conter)+I;
v(i_conter) = v(i_conter-1)+step/2*(K1_1+K2_1);
% K1_1 = sigma*v(i_conter-1)^2+beta*v(i_conter-1)+gamma+I;
% vpn = v(i_conter-1)+step*(sigma*v(i_conter)^2+beta*v(i_conter)+gamma+I);
% K2_1 = sigma*vpn^2+beta*vpn+gamma+I;
% v(i_conter) = v(i_conter-1)+step/2*(K1_1+K2_1);
K2_1 = a*(b*v(i_conter-1)-u(i_conter-1));
upn = u(i_conter-1)+step*(a*(b*v(i_conter)-u(i_conter)));
K2_2 = a*(b*v(i_conter)-upn);
u(i_conter) = u(i_conter-1)+step/2*(K2_1+K2_2);
if(v(i_conter)>30)
v(i_conter) = c;
u(i_conter) = u(i_conter)+d;
end
end
plot(timeConter,v)
% figure(2)
% plot(timeConter,u)
D210
以上是关于SNN脉冲神经网络SNN脉冲神经网络的工作原理演示MATLAB仿真带GUI界面的主要内容,如果未能解决你的问题,请参考以下文章