**UA Dr. Robert Legenstein, WiMAus Prashant Joshi, M.S.
Institute for Theoretical Computer Science
Technische Universität Graz
A-8010 Graz, Austria
{legi, joshi}@igi.tugraz.at **

NACHNAME | Vorname | Matrikelnmr | Teammitglieder |

In this task you have to analyze the action-potential generation mechanism of the Hodgkin-Huxley(HH) model neuron for various current injections.

The Matlab program hh_model.m simulates a HH neuron.

- Find the minimum current (by only varying the variable ) that is required to generate a single action potential.
- Change so that the neuron starts to fire repetitively throughout the simulation. We will call this current as . What is the minimum value for ? Is this transition a sharp one?
- Inject a negative current into the model(onset time 5ms, onset amplitude -100nA, duration 5ms). What happens?
- The gain function of a neuron is defined as the plot between the mean-firing
rate(y-axis) and the input current (x-axis). Plot the gain function for
a HH neuron, and an Integrate and fire neuron
^{2}in the range and compare them.

% hh_neuron implements a HH-Model with current injection Iext

clear all;

csim('destroy');

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% parameters

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

dtSim = 1e-5; % integration time constant for simulation

dtRec = 1e-4; % intervals for recording traces

Tsim = 1.0; % simulation time

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% define the input Iext

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

T1 = 5e-3; % onset of stimulus [sec]

I0 = 1; % DC current injection [nA]

% make the current with a resolution of dtSim

Iext = [zeros(1,ceil(T1/dtSim)) I0*1e-9*ones(1,ceil((Tsim-T1)/dtSim)+1)];

% the time base for the input Iext and the simulation

t=[1:length(Iext)]*dtSim;

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% set up the model

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% create the HHNeuron

hhn = csim('create','HHNeuron');

% create an analog input neuron and a synapse

ain=csim('create','AnalogInputNeuron');

syn=csim('create','StaticAnalogSynapse');

% connect the input neuron to the HH-Neuron

csim('connect',hhn,ain,syn);

% record some values during the simulation

rec=csim('create','MexRecorder');

csim('set',rec,'dt',dtRec);

% tell the recorder to record Vm and the spikes

csim('connect',rec,hhn,'Vm');

csim('connect',rec,hhn,'spikes');

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% simulate model with Iext as input

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% set parameters regarding the simulation control

csim('set','dt',dtSim); % the integration time constant

% define an input signal (Iext) for the simulator

input(1).spiking = 0;

input(1).dt = dtSim;

input(1).idx = ain;

input(1).data = Iext;

% set the integration time constant

csim('set','dt',dtSim);

% set time to 0.0

csim('reset');

% run simulation for Tsim seconds

csim('simulate',Tsim,input);

% get the relevant traces

output=csim('get',rec,'traces');

Vm = output.channel(1).data;

spikes = output.channel(2).data;

nSpikes = length(spikes);

% time base for recorded traces

trec = [dtRec:dtRec:Tsim];

% print number of spikes

fprintf('%i spikes / %g sec n',nSpikes,Tsim);

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% plot the results

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

figure(1); clf reset;

% plot input current

subplot(3,1,1);

plot(t,Iext);

xlabel('time [sec]');

ylabel('Iext [nA]');

title('injected current','Fontweight','bold');

set(gca,'Xlim',[0 Tsim]);

% plot membrane voltage

subplot(3,1,2);

plot(trec,Vm,'r'); hold on;

xlabel('time [sec]');

ylabel('Vm [V]');

title('membrane Voltage','Fontweight','bold');

axis tight

% plot the spikes

subplot(3,1,3);

line([spikes;spikes],[0.03; 0.00]*ones(1,length(spikes)),...

'Color','k','Linewidth',1.5);

hold on;

xlabel('time [sec]');

ylabel('Spikes');

axis([0 1 0 0.1]) ;

This document was generated using the
**LaTeX**2`HTML` translator Version 2002-2-1 (1.70)

Copyright © 1993, 1994, 1995, 1996,
Nikos Drakos,
Computer Based Learning Unit, University of Leeds.

Copyright © 1997, 1998, 1999,
Ross Moore,
Mathematics Department, Macquarie University, Sydney.

The command line arguments were:

**latex2html** `-split=0 -no_navigation ex7.tex`

The translation was initiated by Joshi Prashant on 2006-05-22

- ... SS06
^{1} - Class Website: http://www.igi.tugraz.at/lehre/NNB/SS06/
- ... neuron
^{2} - Hint: you can create a Integrate and fire neuron in csim by following command: lif = csim('create','LifNeuron');

Joshi Prashant 2006-05-22