Commit e6936bec by Jens Wehner

### changed interface

parent 68ff2253
Pipeline #92363134 failed with stages
in 13 minutes and 58 seconds
 ... @@ -463,14 +463,14 @@ void CGForceMatching::EvalConfiguration(Topology *conf, Topology *) { ... @@ -463,14 +463,14 @@ void CGForceMatching::EvalConfiguration(Topology *conf, Topology *) { void CGForceMatching::FmatchAccumulateData() { void CGForceMatching::FmatchAccumulateData() { if (_constr_least_sq) { // Constrained Least Squares if (_constr_least_sq) { // Constrained Least Squares // Solving linear equations system // Solving linear equations system votca::tools::linalg_constrained_qrsolve(_x, _A, _b, _B_constr); _x = votca::tools::linalg_constrained_qrsolve(_A, _b, _B_constr); } else { // Simple Least Squares } else { // Simple Least Squares Eigen::HouseholderQR dec(_A); Eigen::HouseholderQR dec(_A); _x = dec.solve(_b); _x = dec.solve(_b); Eigen::VectorXd residual = _b - _A * _x; Eigen::VectorXd residual = _b - _A * _x; // calculate FM residual - quality of FM // calculate FM residual - quality of FM // FM residual is initially calculated in (kJ/(mol*nm))^2 // FM residual is calculated in (kJ/(mol*nm))^2 double fm_resid = residual.cwiseAbs2().sum(); double fm_resid = residual.cwiseAbs2().sum(); fm_resid /= (double)(3 * _nbeads * _frame_counter); fm_resid /= (double)(3 * _nbeads * _frame_counter); ... @@ -492,7 +492,7 @@ void CGForceMatching::FmatchAccumulateData() { ... @@ -492,7 +492,7 @@ void CGForceMatching::FmatchAccumulateData() { sinfo->block_res_f[i] = _x[i + mp]; sinfo->block_res_f[i] = _x[i + mp]; sinfo->block_res_f2[i] = _x[i + mp + ngp]; sinfo->block_res_f2[i] = _x[i + mp + ngp]; } } // result cutted before is assigned to the corresponding spline // result cut before is assigned to the corresponding spline sinfo->Spline.setSplineData(sinfo->block_res_f, sinfo->block_res_f2); sinfo->Spline.setSplineData(sinfo->block_res_f, sinfo->block_res_f2); // first output point = first grid point // first output point = first grid point ... ...
 ... @@ -230,7 +230,7 @@ int main(int argc, char **argv) { ... @@ -230,7 +230,7 @@ int main(int argc, char **argv) { } } out.GenerateGridSpacing(min, max, step); out.GenerateGridSpacing(min, max, step); spline->Calculate(out.x(), out.y()); out.y() = spline->Calculate(out.x()); // store a comment line // store a comment line if (vm.count("comment")) { if (vm.count("comment")) { ... @@ -264,7 +264,7 @@ int main(int argc, char **argv) { ... @@ -264,7 +264,7 @@ int main(int argc, char **argv) { out.Save(out_file); out.Save(out_file); if (vm.count("derivative")) { if (vm.count("derivative")) { spline->CalculateDerivative(der.x(), der.y()); der.y() = spline->CalculateDerivative(der.x()); der.Save(vm["derivative"].as()); der.Save(vm["derivative"].as()); } } ... ...
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!