Changeset 543ce4 for molecuilder/src/datacreator.cpp
- Timestamp:
- Nov 4, 2009, 7:56:04 PM (16 years ago)
- Children:
- 4ef101, aa8542
- Parents:
- ec70ec
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
molecuilder/src/datacreator.cpp
rec70ec r543ce4 25 25 output.open(name.str().c_str(), ios::out); 26 26 if (output == NULL) { 27 cout<< "Unable to open " << name.str() << " for writing, is directory correct?" << endl;27 Log() << Verbose(0) << "Unable to open " << name.str() << " for writing, is directory correct?" << endl; 28 28 return false; 29 29 } … … 43 43 output.open(name.str().c_str(), ios::app); 44 44 if (output == NULL) { 45 cout<< "Unable to open " << name.str() << " for writing, is directory correct?" << endl;45 Log() << Verbose(0) << "Unable to open " << name.str() << " for writing, is directory correct?" << endl; 46 46 return false; 47 47 } … … 63 63 filename << prefix << ".dat"; 64 64 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 65 cout<< msg << endl;65 Log() << Verbose(0) << msg << endl; 66 66 output << "# " << msg << ", created on " << datum; 67 67 output << "#Order\tFrag.No.\t" << Fragments.Header[Fragments.MatrixCounter] << endl; … … 96 96 filename << prefix << ".dat"; 97 97 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 98 cout<< msg << endl;98 Log() << Verbose(0) << msg << endl; 99 99 output << "# " << msg << ", created on " << datum; 100 100 output << "#Order\tFrag.No.\t" << Fragments.Header[Fragments.MatrixCounter] << endl; … … 133 133 filename << prefix << ".dat"; 134 134 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 135 cout<< msg << endl;135 Log() << Verbose(0) << msg << endl; 136 136 output << "# " << msg << ", created on " << datum; 137 137 output << "# Order\tFrag.No.\t" << Fragments.Header[Fragments.MatrixCounter] << endl; … … 165 165 filename << prefix << ".dat"; 166 166 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 167 cout<< msg << endl;167 Log() << Verbose(0) << msg << endl; 168 168 output << "# " << msg << ", created on " << datum; 169 169 output << "# Order\tFrag.No.\t" << Fragments.Header[Fragments.MatrixCounter] << endl; … … 198 198 filename << prefix << ".dat"; 199 199 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 200 cout<< msg << endl;200 Log() << Verbose(0) << msg << endl; 201 201 output << "# " << msg << ", created on " << datum; 202 202 output << "# AtomNo\t" << Fragments.Header[Fragments.MatrixCounter] << endl; 203 203 Fragments.SetLastMatrix(Force.Matrix[Force.MatrixCounter], 0); 204 204 for (int BondOrder=0;BondOrder<KeySets.Order;BondOrder++) { 205 // cout<< "Current order is " << BondOrder << "." << endl;205 //Log() << Verbose(0) << "Current order is " << BondOrder << "." << endl; 206 206 Fragments.SumSubForces(Fragments, KeySets, BondOrder, -1.); 207 207 // errors per atom … … 244 244 filename << prefix << ".dat"; 245 245 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 246 cout<< msg << endl;246 Log() << Verbose(0) << msg << endl; 247 247 output << "# " << msg << ", created on " << datum; 248 248 output << "# AtomNo\t" << Fragments.Header[Fragments.MatrixCounter] << endl; 249 249 for (int BondOrder=0;BondOrder<KeySets.Order;BondOrder++) { 250 // cout<< "Current order is " << BondOrder << "." << endl;250 //Log() << Verbose(0) << "Current order is " << BondOrder << "." << endl; 251 251 Fragments.SumSubForces(Fragments, KeySets, BondOrder, 1.); 252 252 // errors per atom … … 281 281 filename << prefix << ".dat"; 282 282 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 283 cout<< msg << endl;283 Log() << Verbose(0) << msg << endl; 284 284 output << "# " << msg << ", created on " << datum; 285 285 output << "# AtomNo\t" << Fragments.Header[Fragments.MatrixCounter] << endl; 286 286 Fragments.SetLastMatrix(Hessian.Matrix[Hessian.MatrixCounter], 0); 287 287 for (int BondOrder=0;BondOrder<KeySets.Order;BondOrder++) { 288 // cout<< "Current order is " << BondOrder << "." << endl;288 //Log() << Verbose(0) << "Current order is " << BondOrder << "." << endl; 289 289 Fragments.SumSubHessians(Fragments, KeySets, BondOrder, -1.); 290 290 // errors per atom … … 321 321 filename << prefix << ".dat"; 322 322 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 323 cout<< msg << endl;323 Log() << Verbose(0) << msg << endl; 324 324 output << "# " << msg << ", created on " << datum; 325 325 output << "# AtomNo\t"; … … 331 331 output << Fragments.RowCounter[ Fragments.MatrixCounter ] << "\t"; 332 332 for (int BondOrder=0;BondOrder<KeySets.Order;BondOrder++) { 333 // cout<< "Current order is " << BondOrder << "." << endl;333 //Log() << Verbose(0) << "Current order is " << BondOrder << "." << endl; 334 334 Fragments.SumSubHessians(Fragments, KeySets, BondOrder, -1.); 335 335 // frobenius norm of errors per atom … … 363 363 filename << prefix << ".dat"; 364 364 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 365 cout<< msg << endl;365 Log() << Verbose(0) << msg << endl; 366 366 output << "# " << msg << ", created on " << datum; 367 367 output << "# AtomNo\t" << Fragments.Header[ Fragments.MatrixCounter ] << endl; 368 368 Fragments.SetLastMatrix(0., 0); 369 369 for (int BondOrder=0;BondOrder<KeySets.Order;BondOrder++) { 370 // cout<< "Current order is " << BondOrder << "." << endl;370 //Log() << Verbose(0) << "Current order is " << BondOrder << "." << endl; 371 371 Fragments.SumSubHessians(Fragments, KeySets, BondOrder, 1.); 372 372 // errors per atom … … 393 393 filename << prefix << ".dat"; 394 394 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 395 cout<< msg << endl;395 Log() << Verbose(0) << msg << endl; 396 396 output << "# " << msg << ", created on " << datum << endl; 397 397 output << "#Order\tFrag.No.\t" << Fragment.Header[ Fragment.MatrixCounter ] << endl; … … 458 458 filename << prefix << ".dat"; 459 459 if (!OpenOutputFile(output, dir, filename.str().c_str())) return false; 460 cout<< msg << endl;460 Log() << Verbose(0) << msg << endl; 461 461 output << "# " << msg << ", created on " << datum; 462 462 output << "#Order\tFrag.No.\t" << Fragment.Header[ Fragment.MatrixCounter ] << endl;
Note:
See TracChangeset
for help on using the changeset viewer.