Changeset e138de for src/vector.cpp
- Timestamp:
- Nov 4, 2009, 7:56:04 PM (16 years ago)
- Branches:
- Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, Candidate_v1.7.0, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
- Children:
- 1614174, e5ad5c
- Parents:
- 7326b2
- File:
-
- 1 edited
-
src/vector.cpp (modified) (33 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/vector.cpp
r7326b2 re138de 10 10 #include "memoryallocator.hpp" 11 11 #include "leastsquaremin.hpp" 12 #include "log.hpp" 12 13 #include "vector.hpp" 13 14 #include "verbose.hpp" … … 131 132 * Tries to translate a vector into each adjacent neighbouring cell. 132 133 */ 133 void Vector::KeepPeriodic( ofstream *out,const double * const matrix)134 void Vector::KeepPeriodic(const double * const matrix) 134 135 { 135 136 // int N[NDIM]; … … 137 138 //vector Shifted, TranslationVector; 138 139 Vector TestVector; 139 // *out<< Verbose(1) << "Begin of KeepPeriodic." << endl;140 // *out<< Verbose(2) << "Vector is: ";140 // Log() << Verbose(1) << "Begin of KeepPeriodic." << endl; 141 // Log() << Verbose(2) << "Vector is: "; 141 142 // Output(out); 142 // *out<< endl;143 // Log() << Verbose(0) << endl; 143 144 TestVector.CopyVector(this); 144 145 TestVector.InverseMatrixMultiplication(matrix); … … 152 153 TestVector.MatrixMultiplication(matrix); 153 154 CopyVector(&TestVector); 154 // *out<< Verbose(2) << "New corrected vector is: ";155 // Log() << Verbose(2) << "New corrected vector is: "; 155 156 // Output(out); 156 // *out<< endl;157 // *out<< Verbose(1) << "End of KeepPeriodic." << endl;157 // Log() << Verbose(0) << endl; 158 // Log() << Verbose(1) << "End of KeepPeriodic." << endl; 158 159 }; 159 160 … … 216 217 * \return true - \a this contains intersection point on return, false - line is parallel to plane 217 218 */ 218 bool Vector::GetIntersectionWithPlane( ofstream *out,const Vector * const PlaneNormal, const Vector * const PlaneOffset, const Vector * const Origin, const Vector * const LineVector)219 bool Vector::GetIntersectionWithPlane(const Vector * const PlaneNormal, const Vector * const PlaneOffset, const Vector * const Origin, const Vector * const LineVector) 219 220 { 220 221 double factor; … … 225 226 Direction.SubtractVector(Origin); 226 227 Direction.Normalize(); 227 // *out<< Verbose(4) << "INFO: Direction is " << Direction << "." << endl;228 //Log() << Verbose(4) << "INFO: Direction is " << Direction << "." << endl; 228 229 factor = Direction.ScalarProduct(PlaneNormal); 229 230 if (factor < MYEPSILON) { // Uniqueness: line parallel to plane? 230 *out<< Verbose(2) << "WARNING: Line is parallel to plane, no intersection." << endl;231 Log() << Verbose(2) << "WARNING: Line is parallel to plane, no intersection." << endl; 231 232 return false; 232 233 } … … 235 236 factor = helper.ScalarProduct(PlaneNormal)/factor; 236 237 if (factor < MYEPSILON) { // Origin is in-plane 237 // *out<< Verbose(2) << "Origin of line is in-plane, simple." << endl;238 //Log() << Verbose(2) << "Origin of line is in-plane, simple." << endl; 238 239 CopyVector(Origin); 239 240 return true; … … 242 243 Direction.Scale(factor); 243 244 CopyVector(Origin); 244 // *out<< Verbose(4) << "INFO: Scaled direction is " << Direction << "." << endl;245 //Log() << Verbose(4) << "INFO: Scaled direction is " << Direction << "." << endl; 245 246 AddVector(&Direction); 246 247 … … 249 250 helper.SubtractVector(PlaneOffset); 250 251 if (helper.ScalarProduct(PlaneNormal) < MYEPSILON) { 251 // *out<< Verbose(2) << "INFO: Intersection at " << *this << " is good." << endl;252 //Log() << Verbose(2) << "INFO: Intersection at " << *this << " is good." << endl; 252 253 return true; 253 254 } else { 254 *out<< Verbose(2) << "WARNING: Intersection point " << *this << " is not on plane." << endl;255 Log() << Verbose(2) << "WARNING: Intersection point " << *this << " is not on plane." << endl; 255 256 return false; 256 257 } … … 263 264 * \return distance to plane 264 265 */ 265 double Vector::DistanceToPlane( ofstream *out,const Vector * const PlaneNormal, const Vector * const PlaneOffset) const266 double Vector::DistanceToPlane(const Vector * const PlaneNormal, const Vector * const PlaneOffset) const 266 267 { 267 268 Vector temp; … … 296 297 * \return true - \a this will contain the intersection on return, false - lines are parallel 297 298 */ 298 bool Vector::GetIntersectionOfTwoLinesOnPlane( ofstream *out,const Vector * const Line1a, const Vector * const Line1b, const Vector * const Line2a, const Vector * const Line2b, const Vector *PlaneNormal)299 bool Vector::GetIntersectionOfTwoLinesOnPlane(const Vector * const Line1a, const Vector * const Line1b, const Vector * const Line2a, const Vector * const Line2b, const Vector *PlaneNormal) 299 300 { 300 301 bool result = true; … … 320 321 OtherDirection.Normalize(); 321 322 322 // *out<< Verbose(4) << "INFO: Normalized Direction " << Direction << " and OtherDirection " << OtherDirection << "." << endl;323 //Log() << Verbose(4) << "INFO: Normalized Direction " << Direction << " and OtherDirection " << OtherDirection << "." << endl; 323 324 324 325 if (fabs(OtherDirection.ScalarProduct(&Direction) - 1.) < MYEPSILON) { // lines are parallel … … 329 330 else 330 331 return false; 331 *out<< Verbose(4) << "INFO: Intersection is " << *this << "." << endl;332 Log() << Verbose(4) << "INFO: Intersection is " << *this << "." << endl; 332 333 return true; 333 334 } else { … … 342 343 343 344 AuxiliaryNormal.MakeNormalVector(&OtherDirection, Normal); 344 // *out<< Verbose(4) << "INFO: PlaneNormal is " << *Normal << " and AuxiliaryNormal " << AuxiliaryNormal << "." << endl;345 //Log() << Verbose(4) << "INFO: PlaneNormal is " << *Normal << " and AuxiliaryNormal " << AuxiliaryNormal << "." << endl; 345 346 346 347 Distance.CopyVector(Line2a); 347 348 Distance.SubtractVector(Line1a); 348 // *out<< Verbose(4) << "INFO: Distance is " << Distance << "." << endl;349 //Log() << Verbose(4) << "INFO: Distance is " << Distance << "." << endl; 349 350 if (Distance.IsZero()) { 350 351 // offsets are equal, match found … … 353 354 } else { 354 355 CopyVector(Distance.Projection(&AuxiliaryNormal)); 355 // *out<< Verbose(4) << "INFO: Projected Distance is " << *this << "." << endl;356 //Log() << Verbose(4) << "INFO: Projected Distance is " << *this << "." << endl; 356 357 double factor = Direction.ScalarProduct(&AuxiliaryNormal); 357 // *out<< Verbose(4) << "INFO: Scaling factor is " << factor << "." << endl;358 //Log() << Verbose(4) << "INFO: Scaling factor is " << factor << "." << endl; 358 359 Scale(1./(factor*factor)); 359 // *out<< Verbose(4) << "INFO: Scaled Distance is " << *this << "." << endl;360 //Log() << Verbose(4) << "INFO: Scaled Distance is " << *this << "." << endl; 360 361 CopyVector(Projection(&Direction)); 361 // *out<< Verbose(4) << "INFO: Distance, projected into Direction, is " << *this << "." << endl;362 //Log() << Verbose(4) << "INFO: Distance, projected into Direction, is " << *this << "." << endl; 362 363 if (this->IsZero()) 363 364 result = false; … … 371 372 } 372 373 if (result) 373 *out<< Verbose(4) << "INFO: Intersection is " << *this << "." << endl;374 Log() << Verbose(4) << "INFO: Intersection is " << *this << "." << endl; 374 375 375 376 return result; … … 492 493 angle = this->ScalarProduct(y)/norm1/norm2; 493 494 // -1-MYEPSILON occured due to numerical imprecision, catch ... 494 // cout<< Verbose(2) << "INFO: acos(-1) = " << acos(-1) << ", acos(-1+MYEPSILON) = " << acos(-1+MYEPSILON) << ", acos(-1-MYEPSILON) = " << acos(-1-MYEPSILON) << "." << endl;495 //Log() << Verbose(2) << "INFO: acos(-1) = " << acos(-1) << ", acos(-1+MYEPSILON) = " << acos(-1+MYEPSILON) << ", acos(-1-MYEPSILON) = " << acos(-1-MYEPSILON) << "." << endl; 495 496 if (angle < -1) 496 497 angle = -1; … … 628 629 /** Prints a 3dim vector. 629 630 * prints no end of line. 630 * \param *out output stream 631 */ 632 bool Vector::Output(ofstream *out) const 633 { 634 if (out != NULL) { 635 *out << "("; 636 for (int i=0;i<NDIM;i++) { 637 *out << x[i]; 638 if (i != 2) 639 *out << ","; 640 } 641 *out << ")"; 642 return true; 643 } else 644 return false; 631 */ 632 void Vector::Output() const 633 { 634 Log() << Verbose(0) << "("; 635 for (int i=0;i<NDIM;i++) { 636 Log() << Verbose(0) << x[i]; 637 if (i != 2) 638 Log() << Verbose(0) << ","; 639 } 640 Log() << Verbose(0) << ")"; 645 641 }; 646 642 … … 751 747 x[i] = C.x[i]; 752 748 } else { 753 cerr<< "ERROR: inverse of matrix does not exists: det A = " << detA << "." << endl;749 eLog() << Verbose(0) << "ERROR: inverse of matrix does not exists: det A = " << detA << "." << endl; 754 750 } 755 751 }; … … 777 773 projection = ScalarProduct(n)/n->ScalarProduct(n); // remove constancy from n (keep as logical one) 778 774 // withdraw projected vector twice from original one 779 cout<< Verbose(1) << "Vector: ";780 Output( (ofstream *)&cout);781 cout<< "\t";775 Log() << Verbose(1) << "Vector: "; 776 Output(); 777 Log() << Verbose(0) << "\t"; 782 778 for (int i=NDIM;i--;) 783 779 x[i] -= 2.*projection*n->x[i]; 784 cout<< "Projected vector: ";785 Output( (ofstream *)&cout);786 cout<< endl;780 Log() << Verbose(0) << "Projected vector: "; 781 Output(); 782 Log() << Verbose(0) << endl; 787 783 }; 788 784 … … 803 799 x2.SubtractVector(y2); 804 800 if ((fabs(x1.Norm()) < MYEPSILON) || (fabs(x2.Norm()) < MYEPSILON) || (fabs(x1.Angle(&x2)) < MYEPSILON)) { 805 cout<< Verbose(4) << "WARNING: Given vectors are linear dependent." << endl;801 Log() << Verbose(4) << "WARNING: Given vectors are linear dependent." << endl; 806 802 return false; 807 803 } 808 // cout<< Verbose(4) << "relative, first plane coordinates:";804 // Log() << Verbose(4) << "relative, first plane coordinates:"; 809 805 // x1.Output((ofstream *)&cout); 810 // cout<< endl;811 // cout<< Verbose(4) << "second plane coordinates:";806 // Log() << Verbose(0) << endl; 807 // Log() << Verbose(4) << "second plane coordinates:"; 812 808 // x2.Output((ofstream *)&cout); 813 // cout<< endl;809 // Log() << Verbose(0) << endl; 814 810 815 811 this->x[0] = (x1.x[1]*x2.x[2] - x1.x[2]*x2.x[1]); … … 837 833 Zero(); 838 834 if ((fabs(x1.Norm()) < MYEPSILON) || (fabs(x2.Norm()) < MYEPSILON) || (fabs(x1.Angle(&x2)) < MYEPSILON)) { 839 cout<< Verbose(4) << "WARNING: Given vectors are linear dependent." << endl;835 Log() << Verbose(4) << "WARNING: Given vectors are linear dependent." << endl; 840 836 return false; 841 837 } 842 // cout<< Verbose(4) << "relative, first plane coordinates:";838 // Log() << Verbose(4) << "relative, first plane coordinates:"; 843 839 // x1.Output((ofstream *)&cout); 844 // cout<< endl;845 // cout<< Verbose(4) << "second plane coordinates:";840 // Log() << Verbose(0) << endl; 841 // Log() << Verbose(4) << "second plane coordinates:"; 846 842 // x2.Output((ofstream *)&cout); 847 // cout<< endl;843 // Log() << Verbose(0) << endl; 848 844 849 845 this->x[0] = (x1.x[1]*x2.x[2] - x1.x[2]*x2.x[1]); … … 888 884 double norm; 889 885 890 cout<< Verbose(4);891 GivenVector->Output( (ofstream *)&cout);892 cout<< endl;886 Log() << Verbose(4); 887 GivenVector->Output(); 888 Log() << Verbose(0) << endl; 893 889 for (j=NDIM;j--;) 894 890 Components[j] = -1; … … 897 893 if (fabs(GivenVector->x[j]) > MYEPSILON) 898 894 Components[Last++] = j; 899 cout<< Verbose(4) << Last << " Components != 0: (" << Components[0] << "," << Components[1] << "," << Components[2] << ")" << endl;895 Log() << Verbose(4) << Last << " Components != 0: (" << Components[0] << "," << Components[1] << "," << Components[2] << ")" << endl; 900 896 901 897 switch(Last) { … … 929 925 double Vector::CutsPlaneAt(const Vector * const A, const Vector * const B, const Vector * const C) const 930 926 { 931 // cout<< Verbose(3) << "For comparison: ";932 // cout<< "A " << A->Projection(this) << "\t";933 // cout<< "B " << B->Projection(this) << "\t";934 // cout<< "C " << C->Projection(this) << "\t";935 // cout<< endl;927 // Log() << Verbose(3) << "For comparison: "; 928 // Log() << Verbose(0) << "A " << A->Projection(this) << "\t"; 929 // Log() << Verbose(0) << "B " << B->Projection(this) << "\t"; 930 // Log() << Verbose(0) << "C " << C->Projection(this) << "\t"; 931 // Log() << Verbose(0) << endl; 936 932 return A->ScalarProduct(this); 937 933 }; … … 947 943 948 944 for (j=0;j<num;j++) { 949 cout<< Verbose(1) << j << "th atom's vector: ";950 (vectors[j])->Output( (ofstream *)&cout);951 cout<< endl;945 Log() << Verbose(1) << j << "th atom's vector: "; 946 (vectors[j])->Output(); 947 Log() << Verbose(0) << endl; 952 948 } 953 949 … … 1069 1065 j += i+1; 1070 1066 do { 1071 cout<< Verbose(0) << coords[i] << "[0.." << cell_size[j] << "]: ";1067 Log() << Verbose(0) << coords[i] << "[0.." << cell_size[j] << "]: "; 1072 1068 cin >> x[i]; 1073 1069 } while (((x[i] < 0) || (x[i] >= cell_size[j])) && (check)); … … 1100 1096 B2 = cos(beta) * x2->Norm() * c; 1101 1097 C = c * c; 1102 cout<< Verbose(2) << "A " << A << "\tB " << B1 << "\tC " << C << endl;1098 Log() << Verbose(2) << "A " << A << "\tB " << B1 << "\tC " << C << endl; 1103 1099 int flag = 0; 1104 1100 if (fabs(x1->x[0]) < MYEPSILON) { // check for zero components for the later flipping and back-flipping … … 1139 1135 D2 = -y->x[0]/x1->x[0]*x1->x[2]+y->x[2]; 1140 1136 D3 = y->x[0]/x1->x[0]*A-B1; 1141 cout<< Verbose(2) << "D1 " << D1 << "\tD2 " << D2 << "\tD3 " << D3 << "\n";1137 Log() << Verbose(2) << "D1 " << D1 << "\tD2 " << D2 << "\tD3 " << D3 << "\n"; 1142 1138 if (fabs(D1) < MYEPSILON) { 1143 cout<< Verbose(2) << "D1 == 0!\n";1139 Log() << Verbose(2) << "D1 == 0!\n"; 1144 1140 if (fabs(D2) > MYEPSILON) { 1145 cout<< Verbose(3) << "D2 != 0!\n";1141 Log() << Verbose(3) << "D2 != 0!\n"; 1146 1142 x[2] = -D3/D2; 1147 1143 E1 = A/x1->x[0] + x1->x[2]/x1->x[0]*D3/D2; 1148 1144 E2 = -x1->x[1]/x1->x[0]; 1149 cout<< Verbose(3) << "E1 " << E1 << "\tE2 " << E2 << "\n";1145 Log() << Verbose(3) << "E1 " << E1 << "\tE2 " << E2 << "\n"; 1150 1146 F1 = E1*E1 + 1.; 1151 1147 F2 = -E1*E2; 1152 1148 F3 = E1*E1 + D3*D3/(D2*D2) - C; 1153 cout<< Verbose(3) << "F1 " << F1 << "\tF2 " << F2 << "\tF3 " << F3 << "\n";1149 Log() << Verbose(3) << "F1 " << F1 << "\tF2 " << F2 << "\tF3 " << F3 << "\n"; 1154 1150 if (fabs(F1) < MYEPSILON) { 1155 cout<< Verbose(4) << "F1 == 0!\n";1156 cout<< Verbose(4) << "Gleichungssystem linear\n";1151 Log() << Verbose(4) << "F1 == 0!\n"; 1152 Log() << Verbose(4) << "Gleichungssystem linear\n"; 1157 1153 x[1] = F3/(2.*F2); 1158 1154 } else { 1159 1155 p = F2/F1; 1160 1156 q = p*p - F3/F1; 1161 cout<< Verbose(4) << "p " << p << "\tq " << q << endl;1157 Log() << Verbose(4) << "p " << p << "\tq " << q << endl; 1162 1158 if (q < 0) { 1163 cout<< Verbose(4) << "q < 0" << endl;1159 Log() << Verbose(4) << "q < 0" << endl; 1164 1160 return false; 1165 1161 } … … 1168 1164 x[0] = A/x1->x[0] - x1->x[1]/x1->x[0]*x[1] + x1->x[2]/x1->x[0]*x[2]; 1169 1165 } else { 1170 cout<< Verbose(2) << "Gleichungssystem unterbestimmt\n";1166 Log() << Verbose(2) << "Gleichungssystem unterbestimmt\n"; 1171 1167 return false; 1172 1168 } … … 1174 1170 E1 = A/x1->x[0]+x1->x[1]/x1->x[0]*D3/D1; 1175 1171 E2 = x1->x[1]/x1->x[0]*D2/D1 - x1->x[2]; 1176 cout<< Verbose(2) << "E1 " << E1 << "\tE2 " << E2 << "\n";1172 Log() << Verbose(2) << "E1 " << E1 << "\tE2 " << E2 << "\n"; 1177 1173 F1 = E2*E2 + D2*D2/(D1*D1) + 1.; 1178 1174 F2 = -(E1*E2 + D2*D3/(D1*D1)); 1179 1175 F3 = E1*E1 + D3*D3/(D1*D1) - C; 1180 cout<< Verbose(2) << "F1 " << F1 << "\tF2 " << F2 << "\tF3 " << F3 << "\n";1176 Log() << Verbose(2) << "F1 " << F1 << "\tF2 " << F2 << "\tF3 " << F3 << "\n"; 1181 1177 if (fabs(F1) < MYEPSILON) { 1182 cout<< Verbose(3) << "F1 == 0!\n";1183 cout<< Verbose(3) << "Gleichungssystem linear\n";1178 Log() << Verbose(3) << "F1 == 0!\n"; 1179 Log() << Verbose(3) << "Gleichungssystem linear\n"; 1184 1180 x[2] = F3/(2.*F2); 1185 1181 } else { 1186 1182 p = F2/F1; 1187 1183 q = p*p - F3/F1; 1188 cout<< Verbose(3) << "p " << p << "\tq " << q << endl;1184 Log() << Verbose(3) << "p " << p << "\tq " << q << endl; 1189 1185 if (q < 0) { 1190 cout<< Verbose(3) << "q < 0" << endl;1186 Log() << Verbose(3) << "q < 0" << endl; 1191 1187 return false; 1192 1188 } … … 1226 1222 for (j=2;j>=0;j--) { 1227 1223 k = (i & pot(2,j)) << j; 1228 cout<< Verbose(2) << "k " << k << "\tpot(2,j) " << pot(2,j) << endl;1224 Log() << Verbose(2) << "k " << k << "\tpot(2,j) " << pot(2,j) << endl; 1229 1225 sign[j] = (k == 0) ? 1. : -1.; 1230 1226 } 1231 cout<< Verbose(2) << i << ": sign matrix is " << sign[0] << "\t" << sign[1] << "\t" << sign[2] << "\n";1227 Log() << Verbose(2) << i << ": sign matrix is " << sign[0] << "\t" << sign[1] << "\t" << sign[2] << "\n"; 1232 1228 // apply sign matrix 1233 1229 for (j=NDIM;j--;) … … 1235 1231 // calculate angle and check 1236 1232 ang = x2->Angle (this); 1237 cout<< Verbose(1) << i << "th angle " << ang << "\tbeta " << cos(beta) << " :\t";1233 Log() << Verbose(1) << i << "th angle " << ang << "\tbeta " << cos(beta) << " :\t"; 1238 1234 if (fabs(ang - cos(beta)) < MYEPSILON) { 1239 1235 break;
Note:
See TracChangeset
for help on using the changeset viewer.
