Add effective pressure
Added effective pressure 1 / k_eff to the output. To be used in history matching of core flooding.
This commit is contained in:
@@ -96,7 +96,7 @@ SubPhase::SubPhase(std::shared_ptr <Domain> dm):
|
||||
{
|
||||
// If timelog is empty, write a short header to list the averages
|
||||
//fprintf(TIMELOG,"--------------------------------------------------------------------------------------\n");
|
||||
fprintf(TIMELOG,"sw krw krn krwf krnf vw vn force pw pn wet\n");
|
||||
fprintf(TIMELOG,"sw krw krn krwf krnf vw vn force pw pn wet peff\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -378,15 +378,18 @@ void SubPhase::Basic(){
|
||||
double not_water_film_flow_rate=gnb.V*(giwn.Pnx*dir_x + giwn.Pny*dir_y + giwn.Pnz*dir_z)/gnb.M / Dm->Volume;
|
||||
//double total_flow_rate = water_flow_rate + not_water_flow_rate;
|
||||
//double fractional_flow = water_flow_rate / total_flow_rate;
|
||||
|
||||
double h = Dm->voxel_length;
|
||||
double krn = h*h*nu_n*not_water_flow_rate / force_mag ;
|
||||
double krw = h*h*nu_w*water_flow_rate / force_mag;
|
||||
/* not counting films */
|
||||
double krnf = krn - h*h*nu_n*not_water_film_flow_rate / force_mag ;
|
||||
double krwf = krw - h*h*nu_w*water_film_flow_rate / force_mag;
|
||||
//printf(" water saturation = %f, fractional flow =%f \n",saturation,fractional_flow);
|
||||
fprintf(TIMELOG,"%.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g\n",saturation,krw,krn,krwf,krnf,h*water_flow_rate,h*not_water_flow_rate, force_mag, gwb.p, gnb.p, total_wetting_interaction_global);
|
||||
double eff_pressure = 1.0 / (krn + krw); // effective pressure drop
|
||||
|
||||
fprintf(TIMELOG,"%.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g %.8g\n",
|
||||
saturation, krw, krn, krwf, krnf, h*water_flow_rate,
|
||||
h*not_water_flow_rate, force_mag,
|
||||
gwb.p, gnb.p, total_wetting_interaction_global, eff_pressure);
|
||||
fflush(TIMELOG);
|
||||
}
|
||||
if (err==true){
|
||||
|
||||
@@ -875,7 +875,8 @@ double ScaLBL_ColorModel::Run(int returntime){
|
||||
//double kBeff_filmB = h*h*muB*(flow_rate_B_filmB)/(force_mag);
|
||||
|
||||
double viscous_pressure_drop = (rhoA*volA + rhoB*volB)*force_mag;
|
||||
double Mobility = muA/muB;
|
||||
double Mobility = muA/muB; // visc contrast
|
||||
double eff_pres = 1.0 / (kAeff + kBeff); // effective pressure drop
|
||||
|
||||
bool WriteHeader=false;
|
||||
FILE * kr_log_file = fopen("relperm.csv","r");
|
||||
@@ -891,7 +892,7 @@ double ScaLBL_ColorModel::Run(int returntime){
|
||||
fprintf(kr_log_file, "eff.perm.oil.connected.upper.bound eff.perm.water.connected.upper.bound ");
|
||||
fprintf(kr_log_file, "eff.perm.oil.connected.lower.bound eff.perm.water.connected.lower.bound ");
|
||||
fprintf(kr_log_file, "eff.perm.oil.disconnected eff.perm.water.disconnected ");
|
||||
fprintf(kr_log_file, "cap.pressure cap.pressure.connected pressure.drop Ca M\n");
|
||||
fprintf(kr_log_file, "cap.pressure cap.pressure.connected pressure.drop Ca M eff.pressure\n");
|
||||
|
||||
}
|
||||
fprintf(kr_log_file,"%i %.5g ", CURRENT_TIMESTEP,current_saturation);
|
||||
@@ -900,7 +901,8 @@ double ScaLBL_ColorModel::Run(int returntime){
|
||||
fprintf(kr_log_file,"%.5g %.5g ", kAeff_connected, kBeff_connected);
|
||||
fprintf(kr_log_file,"%.5g %.5g ", kAeff_connected_low, kBeff_connected_low);
|
||||
fprintf(kr_log_file,"%.5g %.5g ", kAeff_disconnected, kBeff_disconnected);
|
||||
fprintf(kr_log_file,"%.5g %.5g %.5g %.5g %.5g\n", pAB, pAB_connected, viscous_pressure_drop, Ca, Mobility);
|
||||
fprintf(kr_log_file,"%.5g %.5g %.5g %.5g %.5g ", pAB, pAB_connected, viscous_pressure_drop, Ca, Mobility);
|
||||
fprintf(kr_log_file,"%.5g\n", eff_pres);
|
||||
fclose(kr_log_file);
|
||||
|
||||
printf(" Measured capillary number %f \n ",Ca);
|
||||
|
||||
Reference in New Issue
Block a user