MOOSE - Multiscale Object Oriented Simulation Environment
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
ChannelStruct Struct Reference

#include <HSolveStruct.h>

+ Collaboration diagram for ChannelStruct:

Public Member Functions

void process (double *&state, CurrentStruct &current)
 
void setPowers (double Xpower, double Ypower, double Zpower)
 

Public Attributes

double Gbar_
 
int instant_
 
double modulation_
 
PFDD takeXpower_
 
PFDD takeYpower_
 
PFDD takeZpower_
 
double Xpower_
 
double Ypower_
 
double Zpower_
 

Static Private Member Functions

static double power1 (double x, double p)
 
static double power2 (double x, double p)
 
static double power3 (double x, double p)
 
static double power4 (double x, double p)
 
static double powerN (double x, double p)
 
static PFDD selectPower (double power)
 

Detailed Description

Structure for a channel.

Definition at line 55 of file HSolveStruct.h.

Member Function Documentation

static double ChannelStruct::power1 ( double  x,
double  p 
)
inlinestaticprivate

The aforementioned clever stuff.

Definition at line 95 of file HSolveStruct.h.

Referenced by selectPower().

95  {
96  return x;
97  }

+ Here is the caller graph for this function:

static double ChannelStruct::power2 ( double  x,
double  p 
)
inlinestaticprivate

Definition at line 98 of file HSolveStruct.h.

Referenced by power4(), and selectPower().

98  {
99  return x * x;
100  }

+ Here is the caller graph for this function:

static double ChannelStruct::power3 ( double  x,
double  p 
)
inlinestaticprivate

Definition at line 101 of file HSolveStruct.h.

Referenced by selectPower().

101  {
102  return x * x * x;
103  }

+ Here is the caller graph for this function:

static double ChannelStruct::power4 ( double  x,
double  p 
)
inlinestaticprivate

Definition at line 104 of file HSolveStruct.h.

References power2().

Referenced by selectPower().

104  {
105  return power2( x * x, p );
106  }
static double power2(double x, double p)
Definition: HSolveStruct.h:98

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

double ChannelStruct::powerN ( double  x,
double  p 
)
staticprivate

Definition at line 30 of file HSolveStruct.cpp.

References moose::log().

Referenced by selectPower().

31 {
32  if ( x > 0.0 )
33  return exp( p * log( x ) );
34  return 0.0;
35 }
void log(string msg, serverity_level_ type=debug, bool redirectToConsole=true, bool removeTicks=true)
Log to console (and to a log-file)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void ChannelStruct::process ( double *&  state,
CurrentStruct current 
)

Finds the fraction for each gate by raising the "state" to the appropriate power. current.Gk is then set to Gbar_ times the calculated fraction. Note, "current" is a parameter.

Definition at line 53 of file HSolveStruct.cpp.

References Gbar_, CurrentStruct::Gk, modulation_, takeXpower_, takeYpower_, takeZpower_, Xpower_, Ypower_, and Zpower_.

54 {
55  double fraction = modulation_;
56 
57  if( Xpower_ > 0.0 )
58  fraction *= takeXpower_( *( state++ ), Xpower_ );
59  if( Ypower_ > 0.0 )
60  fraction *= takeYpower_( *( state++ ), Ypower_ );
61  if( Zpower_ > 0.0 )
62  fraction *= takeZpower_( *( state++ ), Zpower_ );
63 
64  current.Gk = Gbar_ * fraction;
65 }
double Xpower_
Definition: HSolveStruct.h:62
double Zpower_
Definition: HSolveStruct.h:64
double Ypower_
Definition: HSolveStruct.h:63
double modulation_
Definition: HSolveStruct.h:77
PFDD ChannelStruct::selectPower ( double  power)
staticprivate

Definition at line 37 of file HSolveStruct.cpp.

References power1(), power2(), power3(), power4(), and powerN().

Referenced by setPowers().

38 {
39  if ( power == 0.0 )
40  return powerN;
41  else if ( power == 1.0 )
42  return power1;
43  else if ( power == 2.0 )
44  return power2;
45  else if ( power == 3.0 )
46  return power3;
47  else if ( power == 4.0 )
48  return power4;
49  else
50  return powerN;
51 }
static double power3(double x, double p)
Definition: HSolveStruct.h:101
static double power4(double x, double p)
Definition: HSolveStruct.h:104
static double power1(double x, double p)
Definition: HSolveStruct.h:95
static double powerN(double x, double p)
static double power2(double x, double p)
Definition: HSolveStruct.h:98

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void ChannelStruct::setPowers ( double  Xpower,
double  Ypower,
double  Zpower 
)

Sets the powers and accordingly sets the takePower_ functions.

Definition at line 15 of file HSolveStruct.cpp.

References selectPower(), takeXpower_, takeYpower_, takeZpower_, Xpower_, Ypower_, and Zpower_.

Referenced by HSolveActive::readHHChannels().

19 {
20  Xpower_ = Xpower;
21  takeXpower_ = selectPower( Xpower );
22 
23  Ypower_ = Ypower;
24  takeYpower_ = selectPower( Ypower );
25 
26  Zpower_ = Zpower;
27  takeZpower_ = selectPower( Zpower );
28 }
double Xpower_
Definition: HSolveStruct.h:62
double Zpower_
Definition: HSolveStruct.h:64
static PFDD selectPower(double power)
double Ypower_
Definition: HSolveStruct.h:63

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Member Data Documentation

double ChannelStruct::Gbar_

Definition at line 58 of file HSolveStruct.h.

Referenced by process(), and HSolveActive::readHHChannels().

int ChannelStruct::instant_

Instantaneously change conductance - conductance follows no kinetics It's like tau = 0 => conductance change directly mirrors voltage step.

Definition at line 71 of file HSolveStruct.h.

Referenced by HSolveActive::readHHChannels().

double ChannelStruct::modulation_

Scale factor for conductance, used when there is biochemical and other multiscale modulation of conductance.

Definition at line 77 of file HSolveStruct.h.

Referenced by process(), and HSolveActive::readHHChannels().

PFDD ChannelStruct::takeXpower_

Definition at line 59 of file HSolveStruct.h.

Referenced by process(), and setPowers().

PFDD ChannelStruct::takeYpower_

Definition at line 60 of file HSolveStruct.h.

Referenced by process(), and setPowers().

PFDD ChannelStruct::takeZpower_

Definition at line 61 of file HSolveStruct.h.

Referenced by process(), and setPowers().

double ChannelStruct::Xpower_

Definition at line 62 of file HSolveStruct.h.

Referenced by process(), and setPowers().

double ChannelStruct::Ypower_

Definition at line 63 of file HSolveStruct.h.

Referenced by process(), and setPowers().

double ChannelStruct::Zpower_

Definition at line 64 of file HSolveStruct.h.

Referenced by process(), and setPowers().


The documentation for this struct was generated from the following files: