Show
Ignore:
Timestamp:
05/07/08 16:29:10 (8 months ago)
Author:
rjrw
Message:

Stubs for using minpack routines (they don't improve things, possibly
due to the Jacobian fix for species conservation).

Re-order a loop in conv_init_solution.

Remove some out of date comments.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/newmole/source/conv_init_solution.cpp

    r2023 r2031  
    130130        for( i=0; i<mole.num_calc; ++i ) 
    131131        { 
    132                 for (nelem=ipHYDROGEN;nelem<LIMELM;nelem++)  
    133                 { 
    134                         if( dense.lgElmtOn[nelem] && mole.list[i]->location == NULL ) 
     132                if (mole.list[i]->location == NULL) 
     133                { 
     134                        for (nelem=ipHYDROGEN;nelem<LIMELM;nelem++)  
    135135                        { 
    136                                 realnum dens_elemsp = (realnum) mole.list[i]->den*mole.list[i]->nElem[nelem]; 
    137                                 if (    FracMoleMax*dense.gas_phase[nelem] < dens_elemsp )  
     136                                if( dense.lgElmtOn[nelem] ) 
    138137                                { 
    139                                         FracMoleMax = dens_elemsp/dense.gas_phase[nelem]; 
    140                                         ipMax = i; 
     138                                        realnum dens_elemsp = (realnum) mole.list[i]->den*mole.list[i]->nElem[nelem]; 
     139                                        if ( FracMoleMax*dense.gas_phase[nelem] < dens_elemsp )  
     140                                        { 
     141                                                FracMoleMax = dens_elemsp/dense.gas_phase[nelem]; 
     142                                                ipMax = i; 
     143                                        } 
    141144                                } 
    142145                        } 
     
    148151        for(i=0;i<mole.num_calc;++i) 
    149152        { 
    150                 OxyInGrains += (1 - mole.list[i]->lgGas_Phase)*mole.list[i]->den*mole.list[i]->nElem[ipOXYGEN];  
     153                if (! mole.list[i]->lgGas_Phase ) 
     154                        OxyInGrains += mole.list[i]->den*mole.list[i]->nElem[ipOXYGEN];  
    151155        } 
    152156        /* this is now fraction of O in ices */