Changeset 2034 for branches/c08_branch/source/atmdat_lamda.cpp
- Timestamp:
- 05/10/08 09:03:02 (6 months ago)
- Files:
-
- 1 modified
-
branches/c08_branch/source/atmdat_lamda.cpp (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/c08_branch/source/atmdat_lamda.cpp
r1815 r2034 52 52 ipLo = 0; 53 53 j = 0; 54 while(intlnct < 5)54 while(intlnct < 3) 55 55 { 56 56 intlnct++; … … 61 61 } 62 62 } 63 63 /*Extracting out the molecular weight*/ 64 if(read_whole_line( chLine , (int)sizeof(chLine) , atmolLevDATA ) == NULL ) 65 { 66 fprintf( ioQQQ, " The data file %s is corrupted .\n",chEFilename); 67 cdEXIT(EXIT_FAILURE); 68 } 69 Species[intNS].fmolweight = (realnum)atof(chLine); 70 71 /*Discard this line*/ 72 if(read_whole_line( chLine , (int)sizeof(chLine) , atmolLevDATA ) == NULL ) 73 { 74 fprintf( ioQQQ, " The data file %s is corrupted .\n",chEFilename); 75 cdEXIT(EXIT_FAILURE); 76 } 77 /*Reading in the number of energy levels*/ 64 78 if(read_whole_line( chLine , (int)sizeof(chLine) , atmolLevDATA ) == NULL ) 65 79 { … … 99 113 for( intcollindex = 0; intcollindex <NUM_COLLIDERS; intcollindex++ ) 100 114 { 101 CollRatesArray[intNS][intcollindex] = (double**)MALLOC((unsigned long)(ngMolLevs) * sizeof(double*)); 102 for( ipHi = 0; ipHi<ngMolLevs; ipHi++ ) 103 { 104 CollRatesArray[intNS][intcollindex][ipHi] = (double*)MALLOC((unsigned long)(ngMolLevs) * sizeof(double)); 105 for( ipLo = 0; ipLo<ngMolLevs; ipLo++ ) 106 { 107 CollRatesArray[intNS][intcollindex][ipHi][ipLo] = 0.0; 108 } 109 } 110 } 115 CollRatesArray[intNS][intcollindex] = NULL; 116 } 117 111 118 112 119 if(read_whole_line( chLine , (int)sizeof(chLine) , atmolLevDATA ) == NULL ) … … 224 231 /* don't need the energy in GHz, so throw it away. */ 225 232 FFmtRead( chLine, &i, sizeof(chLine), &lgEOL ); 226 fenergyK = (realnum)FFmtRead( chLine, &i, sizeof(chLine), &lgEOL ); 227 233 fenergyK = (realnum)(((atmolStates[intNS][ipHi].energy) -(atmolStates[intNS][ipLo].energy))*T1CM); 228 234 ASSERT( index == intrtct + 1 ); 229 235 … … 329 335 TotalInsanity(); 330 336 } 337 /*This is where we allocate memory if the collider exists*/ 338 /*Needed to take care of the he collisions*/ 339 CollRatesArray[intNS][intCollIndex] = (double**)MALLOC((unsigned long)(ngMolLevs) * sizeof(double*)); 340 for( ipHi = 0; ipHi<ngMolLevs; ipHi++ ) 341 { 342 CollRatesArray[intNS][intCollIndex][ipHi] = (double*)MALLOC((unsigned long)(ngMolLevs) * sizeof(double)); 343 for( ipLo = 0; ipLo<ngMolLevs; ipLo++ ) 344 { 345 CollRatesArray[intNS][intCollIndex][ipHi][ipLo] = 0.0; 346 } 347 } 331 348 if(read_whole_line( chLine , (int)sizeof(chLine) , atmolLevDATA ) == NULL ) 332 349 {
