create('axon');
%-------------------------------------------------------------------------------------------
global axon
%-------------------------------------------------------------------------------------------
axon.nseg =55; % change the number of segments
axon.dia =10; % um diameter
axon.Lmode =2;
axon.Linter_D =100;
axon.L =axon.Linter_D*axon.dia*(axon.nseg); %um change the length of axon
axon.da_D =0.6;
axon.lnodal =1;
axon.dn_D =0.33;
insert(axon,'Schwarz')
PW=50;
Factor=5;
Iexstim([0 0 0], 1,PW,0) %(xyz(um),amp(uA),dur(us),delay(us))
Iexstim([0 0 0],-1/Factor,Factor*PW,PW) %(xyz(um),amp(uA),dur(us),delay(us))
%The parameters that are used in NeuroSim are
%.name % unused, just a reference for the computation.
%.nseg % number of segments for the variable.
%.dia % um - the outer diameter of the variable.
%.L % um - the total length of the variable.
%.Lmode % 1=fix, 2 = L_D x D x nseg
%.da_D % - axon/Fiber diameter ratio for calculating the axonal resistance
% for myelinated axon. if this value is empty(default),
% .dia will be used instead.
%.lnodal % um - lengh of node of Ranvior for calculating the membrane resistance
% and membrane capacitance for myelinated axon. If this value is empty(default),
% .laxial will be used instead.
%.dn_D % - node/Fiber diameter ratio for node of Ranvior for calculating the membrane resistance
% and membrane capacitance for myelinated axon. If this value is empty(default),
% .dia will be used instead.
%.cm % uf/cm2 - for calculating membrane capacitance
%.ra % ohm-cm - for calculating axonal resistance
%.rm % kohm-cm2 - for calculating membrane resistance.
%.vini % mV
%.ve % mV
%.xyz % um