]> hackdaworld.org Git - physik/nlsop.git/commitdiff
dr_cc added to diffusion part
authorhackbard <hackbard>
Wed, 6 Aug 2003 10:55:47 +0000 (10:55 +0000)
committerhackbard <hackbard>
Wed, 6 Aug 2003 10:55:47 +0000 (10:55 +0000)
nlsop.c

diff --git a/nlsop.c b/nlsop.c
index 9f0e08ce61e68d0ac05b60eb14de595a5f63072f..26a6e6169857dc39b75a1e4b7fe363528b3b64ed 100644 (file)
--- a/nlsop.c
+++ b/nlsop.c
@@ -194,7 +194,7 @@ int distrib_c(d3_lattice *d3_l,info *my_info,int step,double c_ratio)
        carry=0;
        if(!(*(d3_l->status+off)&AMORPH))
        {
-        carry=(*(d3_l->extra+off)-*(d3_l->extra+offset))/2;
+        carry=(int)(my_info->dr_cc*(*(d3_l->extra+off)-*(d3_l->extra+offset))/2);
         if(carry!=0)
         {
          *(d3_l->extra+offset)+=carry;
@@ -211,7 +211,7 @@ int distrib_c(d3_lattice *d3_l,info *my_info,int step,double c_ratio)
        carry=0;
        if(!(*(d3_l->status+off)&AMORPH))
        {
-       carry=(*(d3_l->extra+off)-*(d3_l->extra+offset))/2;
+       carry=(int)(my_info->dr_cc*(*(d3_l->extra+off)-*(d3_l->extra+offset))/2);
        if(carry!=0)
         {
          *(d3_l->extra+offset)+=carry;
@@ -675,9 +675,9 @@ int main(int argc,char **argv)
  sprintf(s_txt,"steps: %d",my_info.steps);
  sprintf(dose_txt,"dose: %.2fe+17 C/cm²",my_info.steps*1.0/(d3_l.max_x*d3_l.max_y*CELL_LENGTH*CELL_LENGTH*1000));
  sprintf(r_txt,"pressure range: %d",my_info.range);
- sprintf(ap_txt,"a_ap: %.2f  b_ap: %.3f",my_info.a_ap,my_info.b_ap);
- sprintf(el_txt,"a_el: %.2f  b_el: %.3f",my_info.a_el,my_info.b_el);
- sprintf(cd_txt,"a_cd: %.2f  b_cd: %.3f",my_info.a_cd,my_info.b_cd);
+ sprintf(ap_txt,"a_ap: %.3f  b_ap: %.3f",my_info.a_ap,my_info.b_ap);
+ sprintf(el_txt,"a_el: %.3f  b_el: %.3f",my_info.a_el,my_info.b_el);
+ sprintf(cd_txt,"a_cd: %.3f  b_cd: %.3f",my_info.a_cd,my_info.b_cd);
  sprintf(cp_txt,"a_cp: %.4f",my_info.a_cp);
  sprintf(dr_ac_txt,"a/c diffusion rate: %.4f",my_info.dr_ac);
  sprintf(dr_cc_txt,"c/c diffusion rate: %.4f",my_info.dr_cc);