testing membrane ion transport

This commit is contained in:
James McClure
2022-04-06 22:25:05 -04:00
parent cca06f7964
commit 9c013e6169
3 changed files with 74 additions and 8 deletions

View File

@@ -1356,7 +1356,11 @@ void Membrane::RecvD3Q7AA(double *dist){
//...................................................................................
Lock=false; // unlock the communicator after communications complete
//...................................................................................
}
void Membrane::IonTransport(double *dist, double *den){
ScaLBL_D3Q7_Membrane_IonTransport(MembraneLinks,MembraneCoef, dist, den, membraneLinkCount, Np);
}
// std::shared_ptr<Database> db){
@@ -1372,12 +1376,22 @@ void Membrane::AssignCoefficients(int *Map, double *Psi, string method){
ThresholdMassFractionOut = 0.0;
ThresholdMassFractionIn = 0.0;
if (method == "ones"){
/* Initializing */
printf(".... initialize permeable membrane \n");
MassFractionIn = 1.0;
MassFractionOut = 1.0;
ThresholdMassFractionOut = 1.0;
ThresholdMassFractionIn = 1.0;
}
if (method == "Voltage Gated Potassium"){
MassFractionIn = 0.0;
MassFractionOut = 0.0;
ThresholdMassFractionOut = 0.0;
ThresholdMassFractionIn = 1.0;
}
ScaLBL_D3Q7_Membrane_AssignLinkCoef(MembraneLinks, Map, MembraneDistance, Psi, MembraneCoef,
Threshold, MassFractionIn, MassFractionOut, ThresholdMassFractionIn, ThresholdMassFractionOut,
membraneLinkCount, Nx, Ny, Nz, Np);

View File

@@ -96,6 +96,7 @@ public:
void SendD3Q7AA(double *dist);
void RecvD3Q7AA(double *dist);
void AssignCoefficients(int *Map, double *Psi, std::string method);
void IonTransport(double *dist, double *den);
//......................................................................................
// Buffers to store data sent and recieved by this MPI process
double *sendbuf_x, *sendbuf_y, *sendbuf_z, *sendbuf_X, *sendbuf_Y, *sendbuf_Z;