Merge branch 'master' into relres-update
This commit is contained in:
@ -127,3 +127,24 @@ foreach(TEST ${FIX_TIMESTEP_TESTS})
|
||||
set_tests_properties(${TNAME} PROPERTIES ENVIRONMENT "LAMMPS_POTENTIALS=${LAMMPS_POTENTIALS_DIR};PYTHONPATH=${TEST_INPUT_FOLDER}:$ENV{PYTHONPATH}")
|
||||
endforeach()
|
||||
|
||||
# dihedral style tester
|
||||
add_executable(test_dihedral_style test_dihedral_style.cpp)
|
||||
target_link_libraries(test_dihedral_style PRIVATE lammps style_tests)
|
||||
|
||||
file(GLOB DIHEDRAL_TESTS LIST_DIRECTORIES false ${TEST_INPUT_FOLDER}/dihedral-*.yaml)
|
||||
foreach(TEST ${DIHEDRAL_TESTS})
|
||||
string(REGEX REPLACE "^.*dihedral-(.*)\.yaml" "DihedralStyle:\\1" TNAME ${TEST})
|
||||
add_test(NAME ${TNAME} COMMAND test_dihedral_style ${TEST} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
||||
set_tests_properties(${TNAME} PROPERTIES ENVIRONMENT "LAMMPS_POTENTIALS=${LAMMPS_POTENTIALS_DIR};PYTHONPATH=${TEST_INPUT_FOLDER}:$ENV{PYTHONPATH}")
|
||||
endforeach()
|
||||
|
||||
# improper style tester
|
||||
add_executable(test_improper_style test_improper_style.cpp)
|
||||
target_link_libraries(test_improper_style PRIVATE lammps style_tests)
|
||||
|
||||
file(GLOB IMPROPER_TESTS LIST_DIRECTORIES false ${TEST_INPUT_FOLDER}/improper-*.yaml)
|
||||
foreach(TEST ${IMPROPER_TESTS})
|
||||
string(REGEX REPLACE "^.*improper-(.*)\.yaml" "ImproperStyle:\\1" TNAME ${TEST})
|
||||
add_test(NAME ${TNAME} COMMAND test_improper_style ${TEST} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
||||
set_tests_properties(${TNAME} PROPERTIES ENVIRONMENT "LAMMPS_POTENTIALS=${LAMMPS_POTENTIALS_DIR};PYTHONPATH=${TEST_INPUT_FOLDER}:$ENV{PYTHONPATH}")
|
||||
endforeach()
|
||||
|
||||
@ -57,6 +57,10 @@ TestConfigReader::TestConfigReader(TestConfig &config) : YamlReader(), config(co
|
||||
consumers["bond_coeff"] = &TestConfigReader::bond_coeff;
|
||||
consumers["angle_style"] = &TestConfigReader::angle_style;
|
||||
consumers["angle_coeff"] = &TestConfigReader::angle_coeff;
|
||||
consumers["dihedral_style"] = &TestConfigReader::dihedral_style;
|
||||
consumers["dihedral_coeff"] = &TestConfigReader::dihedral_coeff;
|
||||
consumers["improper_style"] = &TestConfigReader::improper_style;
|
||||
consumers["improper_coeff"] = &TestConfigReader::improper_coeff;
|
||||
consumers["init_energy"] = &TestConfigReader::init_energy;
|
||||
consumers["run_energy"] = &TestConfigReader::run_energy;
|
||||
consumers["equilibrium"] = &TestConfigReader::equilibrium;
|
||||
@ -259,6 +263,38 @@ void TestConfigReader::angle_coeff(const yaml_event_t &event)
|
||||
}
|
||||
}
|
||||
|
||||
void TestConfigReader::dihedral_style(const yaml_event_t &event)
|
||||
{
|
||||
config.dihedral_style = (char *)event.data.scalar.value;
|
||||
}
|
||||
|
||||
void TestConfigReader::dihedral_coeff(const yaml_event_t &event)
|
||||
{
|
||||
config.dihedral_coeff.clear();
|
||||
std::stringstream data((char *)event.data.scalar.value);
|
||||
std::string line;
|
||||
|
||||
while (std::getline(data, line, '\n')) {
|
||||
config.dihedral_coeff.push_back(line);
|
||||
}
|
||||
}
|
||||
|
||||
void TestConfigReader::improper_style(const yaml_event_t &event)
|
||||
{
|
||||
config.improper_style = (char *)event.data.scalar.value;
|
||||
}
|
||||
|
||||
void TestConfigReader::improper_coeff(const yaml_event_t &event)
|
||||
{
|
||||
config.improper_coeff.clear();
|
||||
std::stringstream data((char *)event.data.scalar.value);
|
||||
std::string line;
|
||||
|
||||
while (std::getline(data, line, '\n')) {
|
||||
config.improper_coeff.push_back(line);
|
||||
}
|
||||
}
|
||||
|
||||
void TestConfigReader::equilibrium(const yaml_event_t &event)
|
||||
{
|
||||
std::stringstream data((char *)event.data.scalar.value);
|
||||
|
||||
@ -44,6 +44,10 @@ public:
|
||||
void bond_coeff(const yaml_event_t &event);
|
||||
void angle_style(const yaml_event_t &event);
|
||||
void angle_coeff(const yaml_event_t &event);
|
||||
void dihedral_style(const yaml_event_t &event);
|
||||
void dihedral_coeff(const yaml_event_t &event);
|
||||
void improper_style(const yaml_event_t &event);
|
||||
void improper_coeff(const yaml_event_t &event);
|
||||
void equilibrium(const yaml_event_t &event);
|
||||
void init_vdwl(const yaml_event_t &event);
|
||||
void init_coul(const yaml_event_t &event);
|
||||
|
||||
743
unittest/force-styles/test_dihedral_style.cpp
Normal file
743
unittest/force-styles/test_dihedral_style.cpp
Normal file
@ -0,0 +1,743 @@
|
||||
/* ----------------------------------------------------------------------
|
||||
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
|
||||
https://lammps.sandia.gov/, Sandia National Laboratories
|
||||
Steve Plimpton, sjplimp@sandia.gov
|
||||
|
||||
Copyright (2003) Sandia Corporation. Under the terms of Contract
|
||||
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
|
||||
certain rights in this software. This software is distributed under
|
||||
the GNU General Public License.
|
||||
|
||||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
// unit tests for dihedral styles intended for molecular systems
|
||||
|
||||
#include "error_stats.h"
|
||||
#include "test_config.h"
|
||||
#include "test_config_reader.h"
|
||||
#include "test_main.h"
|
||||
#include "yaml_reader.h"
|
||||
#include "yaml_writer.h"
|
||||
|
||||
#include "gmock/gmock.h"
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
#include "atom.h"
|
||||
#include "compute.h"
|
||||
#include "dihedral.h"
|
||||
#include "fmt/format.h"
|
||||
#include "force.h"
|
||||
#include "info.h"
|
||||
#include "input.h"
|
||||
#include "lammps.h"
|
||||
#include "modify.h"
|
||||
#include "universe.h"
|
||||
|
||||
#include <cctype>
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <ctime>
|
||||
#include <mpi.h>
|
||||
|
||||
#include <map>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
using ::testing::HasSubstr;
|
||||
using ::testing::StartsWith;
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
static void delete_file(const std::string &filename)
|
||||
{
|
||||
remove(filename.c_str());
|
||||
};
|
||||
|
||||
void cleanup_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
delete_file(cfg.basename + ".restart");
|
||||
delete_file(cfg.basename + ".data");
|
||||
delete_file(cfg.basename + "-coeffs.in");
|
||||
delete lmp;
|
||||
}
|
||||
|
||||
LAMMPS *init_lammps(int argc, char **argv, const TestConfig &cfg, const bool newton = true)
|
||||
{
|
||||
LAMMPS *lmp;
|
||||
|
||||
lmp = new LAMMPS(argc, argv, MPI_COMM_WORLD);
|
||||
|
||||
// check if prerequisite styles are available
|
||||
Info *info = new Info(lmp);
|
||||
int nfail = 0;
|
||||
for (auto &prerequisite : cfg.prerequisites) {
|
||||
std::string style = prerequisite.second;
|
||||
|
||||
// this is a test for dihedral styles, so if the suffixed
|
||||
// version is not available, there is no reason to test.
|
||||
if (prerequisite.first == "dihedral") {
|
||||
if (lmp->suffix_enable) {
|
||||
style += "/";
|
||||
style += lmp->suffix;
|
||||
}
|
||||
}
|
||||
|
||||
if (!info->has_style(prerequisite.first, style)) ++nfail;
|
||||
}
|
||||
delete info;
|
||||
if (nfail > 0) {
|
||||
cleanup_lammps(lmp, cfg);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// utility lambdas to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
auto parse_input_script = [&](const std::string &filename) {
|
||||
lmp->input->file(filename.c_str());
|
||||
};
|
||||
|
||||
if (newton) {
|
||||
command("variable newton_bond index on");
|
||||
} else {
|
||||
command("variable newton_bond index off");
|
||||
}
|
||||
|
||||
command("variable input_dir index " + INPUT_FOLDER);
|
||||
|
||||
for (auto &pre_command : cfg.pre_commands) {
|
||||
command(pre_command);
|
||||
}
|
||||
|
||||
std::string input_file = INPUT_FOLDER + PATH_SEP + cfg.input_file;
|
||||
parse_input_script(input_file);
|
||||
|
||||
command("dihedral_style " + cfg.dihedral_style);
|
||||
|
||||
for (auto &dihedral_coeff : cfg.dihedral_coeff) {
|
||||
command("dihedral_coeff " + dihedral_coeff);
|
||||
}
|
||||
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
|
||||
command("run 0 post no");
|
||||
command("write_restart " + cfg.basename + ".restart");
|
||||
command("write_data " + cfg.basename + ".data");
|
||||
command("write_coeff " + cfg.basename + "-coeffs.in");
|
||||
|
||||
return lmp;
|
||||
}
|
||||
|
||||
void run_lammps(LAMMPS *lmp)
|
||||
{
|
||||
// utility lambda to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
|
||||
command("fix 1 all nve");
|
||||
command("compute pe all pe/atom dihedral");
|
||||
command("compute sum all reduce sum c_pe");
|
||||
command("thermo_style custom step temp pe press c_sum");
|
||||
command("thermo 2");
|
||||
command("run 4 post no");
|
||||
}
|
||||
|
||||
void restart_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
// utility lambda to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
|
||||
command("clear");
|
||||
command("read_restart " + cfg.basename + ".restart");
|
||||
|
||||
if (!lmp->force->dihedral) {
|
||||
command("dihedral_style " + cfg.dihedral_style);
|
||||
}
|
||||
|
||||
if ((cfg.dihedral_style.substr(0, 6) == "hybrid") || !lmp->force->dihedral->writedata) {
|
||||
for (auto &dihedral_coeff : cfg.dihedral_coeff) {
|
||||
command("dihedral_coeff " + dihedral_coeff);
|
||||
}
|
||||
}
|
||||
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
|
||||
command("run 0 post no");
|
||||
}
|
||||
|
||||
void data_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
// utility lambdas to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
auto parse_input_script = [&](const std::string &filename) {
|
||||
lmp->input->file(filename.c_str());
|
||||
};
|
||||
|
||||
command("clear");
|
||||
command("variable dihedral_style delete");
|
||||
command("variable data_file delete");
|
||||
command("variable newton_bond delete");
|
||||
command("variable newton_bond index on");
|
||||
|
||||
for (auto &pre_command : cfg.pre_commands) {
|
||||
command(pre_command);
|
||||
}
|
||||
|
||||
command("variable dihedral_style index '" + cfg.dihedral_style + "'");
|
||||
command("variable data_file index " + cfg.basename + ".data");
|
||||
|
||||
// special treatment for dihedral styles charmm and charmmfsw
|
||||
if (cfg.dihedral_style == "charmm") {
|
||||
command("variable pair_style delete");
|
||||
command("variable pair_style index 'lj/charmm/coul/charmm 7.0 8.0'");
|
||||
} else if (cfg.dihedral_style == "charmmfsw") {
|
||||
command("variable pair_style delete");
|
||||
command("variable pair_style index 'lj/charmmfsw/coul/charmmfsh 7.0 8.0'");
|
||||
}
|
||||
|
||||
std::string input_file = INPUT_FOLDER + PATH_SEP + cfg.input_file;
|
||||
parse_input_script(input_file);
|
||||
|
||||
for (auto &dihedral_coeff : cfg.dihedral_coeff) {
|
||||
command("dihedral_coeff " + dihedral_coeff);
|
||||
}
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
command("run 0 post no");
|
||||
}
|
||||
|
||||
// re-generate yaml file with current settings.
|
||||
|
||||
void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
{
|
||||
// initialize system geometry
|
||||
const char *args[] = {"DihedralStyle", "-log", "none", "-echo", "screen", "-nocite"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
LAMMPS *lmp = init_lammps(argc, argv, config);
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles are not available "
|
||||
"in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
const int natoms = lmp->atom->natoms;
|
||||
std::string block("");
|
||||
|
||||
YamlWriter writer(outfile);
|
||||
|
||||
// lammps_version
|
||||
writer.emit("lammps_version", lmp->version);
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
writer.emit("epsilon", config.epsilon);
|
||||
|
||||
// prerequisites
|
||||
block.clear();
|
||||
for (auto &prerequisite : config.prerequisites) {
|
||||
block += prerequisite.first + " " + prerequisite.second + "\n";
|
||||
}
|
||||
writer.emit_block("prerequisites", block);
|
||||
|
||||
// pre_commands
|
||||
block.clear();
|
||||
for (auto &command : config.pre_commands) {
|
||||
block += command + "\n";
|
||||
}
|
||||
writer.emit_block("pre_commands", block);
|
||||
|
||||
// post_commands
|
||||
block.clear();
|
||||
for (auto &command : config.post_commands) {
|
||||
block += command + "\n";
|
||||
}
|
||||
writer.emit_block("post_commands", block);
|
||||
|
||||
// input_file
|
||||
writer.emit("input_file", config.input_file);
|
||||
|
||||
// dihedral_style
|
||||
writer.emit("dihedral_style", config.dihedral_style);
|
||||
|
||||
// dihedral_coeff
|
||||
block.clear();
|
||||
for (auto &dihedral_coeff : config.dihedral_coeff) {
|
||||
block += dihedral_coeff + "\n";
|
||||
}
|
||||
writer.emit_block("dihedral_coeff", block);
|
||||
|
||||
// extract
|
||||
block.clear();
|
||||
for (auto data : config.extract)
|
||||
block += fmt::format("{} {}\n", data.first, data.second);
|
||||
writer.emit_block("extract", block);
|
||||
|
||||
// natoms
|
||||
writer.emit("natoms", natoms);
|
||||
|
||||
// init_energy
|
||||
writer.emit("init_energy", lmp->force->dihedral->energy);
|
||||
|
||||
// init_stress
|
||||
auto stress = lmp->force->dihedral->virial;
|
||||
block = fmt::format("{:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e}", stress[0],
|
||||
stress[1], stress[2], stress[3], stress[4], stress[5]);
|
||||
writer.emit_block("init_stress", block);
|
||||
|
||||
// init_forces
|
||||
block.clear();
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
for (int i = 1; i <= natoms; ++i) {
|
||||
const int j = lmp->atom->map(i);
|
||||
block += fmt::format("{:3} {:23.16e} {:23.16e} {:23.16e}\n", i, f[j][0], f[j][1], f[j][2]);
|
||||
}
|
||||
writer.emit_block("init_forces", block);
|
||||
|
||||
// do a few steps of MD
|
||||
run_lammps(lmp);
|
||||
|
||||
// run_energy
|
||||
writer.emit("run_energy", lmp->force->dihedral->energy);
|
||||
|
||||
// run_stress
|
||||
stress = lmp->force->dihedral->virial;
|
||||
block = fmt::format("{:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e}", stress[0],
|
||||
stress[1], stress[2], stress[3], stress[4], stress[5]);
|
||||
writer.emit_block("run_stress", block);
|
||||
|
||||
block.clear();
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
for (int i = 1; i <= natoms; ++i) {
|
||||
const int j = lmp->atom->map(i);
|
||||
block += fmt::format("{:3} {:23.16e} {:23.16e} {:23.16e}\n", i, f[j][0], f[j][1], f[j][2]);
|
||||
}
|
||||
writer.emit_block("run_forces", block);
|
||||
|
||||
cleanup_lammps(lmp, config);
|
||||
return;
|
||||
}
|
||||
|
||||
TEST(DihedralStyle, plain)
|
||||
{
|
||||
const char *args[] = {"DihedralStyle", "-log", "none", "-echo", "screen", "-nocite"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
|
||||
::testing::internal::CaptureStdout();
|
||||
LAMMPS *lmp = init_lammps(argc, argv, test_config, true);
|
||||
|
||||
std::string output = ::testing::internal::GetCapturedStdout();
|
||||
if (verbose) std::cout << output;
|
||||
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles are not available "
|
||||
"in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : test_config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
EXPECT_THAT(output, StartsWith("LAMMPS ("));
|
||||
EXPECT_THAT(output, HasSubstr("Loop time"));
|
||||
|
||||
// abort if running in parallel and not all atoms are local
|
||||
const int nlocal = lmp->atom->nlocal;
|
||||
ASSERT_EQ(lmp->atom->natoms, nlocal);
|
||||
|
||||
double epsilon = test_config.epsilon;
|
||||
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
ErrorStats stats;
|
||||
stats.reset();
|
||||
const std::vector<coord_t> &f_ref = test_config.init_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
auto dihedral = lmp->force->dihedral;
|
||||
auto stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = dihedral->virial;
|
||||
|
||||
const std::vector<coord_t> &f_run = test_config.run_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_run.size());
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
int id = lmp->modify->find_compute("sum");
|
||||
double energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.run_energy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
lmp = init_lammps(argc, argv, test_config, false);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
// skip over these tests if newton bond is forced to be on
|
||||
if (lmp->force->newton_bond == 0) {
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
dihedral = lmp->force->dihedral;
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 2 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton off:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
id = lmp->modify->find_compute("sum");
|
||||
energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.run_energy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton off:" << stats << std::endl;
|
||||
}
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
restart_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "restart_forces stats:" << stats << std::endl;
|
||||
|
||||
dihedral = lmp->force->dihedral;
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "restart_stress stats:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "restart_energy stats:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
data_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "data_forces stats:" << stats << std::endl;
|
||||
|
||||
dihedral = lmp->force->dihedral;
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "data_stress stats:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "data_energy stats:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
};
|
||||
|
||||
TEST(DihedralStyle, omp)
|
||||
{
|
||||
if (!LAMMPS::is_installed_pkg("USER-OMP")) GTEST_SKIP();
|
||||
const char *args[] = {"DihedralStyle", "-log", "none", "-echo", "screen", "-nocite",
|
||||
"-pk", "omp", "4", "-sf", "omp"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
|
||||
::testing::internal::CaptureStdout();
|
||||
LAMMPS *lmp = init_lammps(argc, argv, test_config, true);
|
||||
|
||||
std::string output = ::testing::internal::GetCapturedStdout();
|
||||
if (verbose) std::cout << output;
|
||||
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles with /omp suffix\n"
|
||||
"are not available in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : test_config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
EXPECT_THAT(output, StartsWith("LAMMPS ("));
|
||||
EXPECT_THAT(output, HasSubstr("Loop time"));
|
||||
|
||||
// abort if running in parallel and not all atoms are local
|
||||
const int nlocal = lmp->atom->nlocal;
|
||||
ASSERT_EQ(lmp->atom->natoms, nlocal);
|
||||
|
||||
// relax error a bit for USER-OMP package
|
||||
double epsilon = 5.0 * test_config.epsilon;
|
||||
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
|
||||
const std::vector<coord_t> &f_ref = test_config.init_forces;
|
||||
ErrorStats stats;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
auto dihedral = lmp->force->dihedral;
|
||||
auto stress = dihedral->virial;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = dihedral->virial;
|
||||
|
||||
const std::vector<coord_t> &f_run = test_config.run_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_run.size());
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
int id = lmp->modify->find_compute("sum");
|
||||
double energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.run_energy, epsilon);
|
||||
// TODO: this is currently broken for USER-OMP with dihedral style hybrid
|
||||
// needs to be fixed in the main code somewhere. Not sure where, though.
|
||||
if (test_config.dihedral_style.substr(0, 6) != "hybrid")
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
lmp = init_lammps(argc, argv, test_config, false);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
// skip over these tests if newton bond is forced to be on
|
||||
if (lmp->force->newton_bond == 0) {
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
dihedral = lmp->force->dihedral;
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton off:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
stress = dihedral->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
id = lmp->modify->find_compute("sum");
|
||||
energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, test_config.run_energy, epsilon);
|
||||
// TODO: this is currently broken for USER-OMP with dihedral style hybrid
|
||||
// needs to be fixed in the main code somewhere. Not sure where, though.
|
||||
if (test_config.dihedral_style.substr(0, 6) != "hybrid")
|
||||
EXPECT_FP_LE_WITH_EPS(dihedral->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton off:" << stats << std::endl;
|
||||
}
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
};
|
||||
734
unittest/force-styles/test_improper_style.cpp
Normal file
734
unittest/force-styles/test_improper_style.cpp
Normal file
@ -0,0 +1,734 @@
|
||||
/* ----------------------------------------------------------------------
|
||||
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
|
||||
https://lammps.sandia.gov/, Sandia National Laboratories
|
||||
Steve Plimpton, sjplimp@sandia.gov
|
||||
|
||||
Copyright (2003) Sandia Corporation. Under the terms of Contract
|
||||
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
|
||||
certain rights in this software. This software is distributed under
|
||||
the GNU General Public License.
|
||||
|
||||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
// unit tests for improper styles intended for molecular systems
|
||||
|
||||
#include "error_stats.h"
|
||||
#include "test_config.h"
|
||||
#include "test_config_reader.h"
|
||||
#include "test_main.h"
|
||||
#include "yaml_reader.h"
|
||||
#include "yaml_writer.h"
|
||||
|
||||
#include "gmock/gmock.h"
|
||||
#include "gtest/gtest.h"
|
||||
|
||||
#include "atom.h"
|
||||
#include "compute.h"
|
||||
#include "fmt/format.h"
|
||||
#include "force.h"
|
||||
#include "improper.h"
|
||||
#include "info.h"
|
||||
#include "input.h"
|
||||
#include "lammps.h"
|
||||
#include "modify.h"
|
||||
#include "universe.h"
|
||||
|
||||
#include <cctype>
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <ctime>
|
||||
#include <mpi.h>
|
||||
|
||||
#include <map>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
using ::testing::HasSubstr;
|
||||
using ::testing::StartsWith;
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
static void delete_file(const std::string &filename)
|
||||
{
|
||||
remove(filename.c_str());
|
||||
};
|
||||
|
||||
void cleanup_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
delete_file(cfg.basename + ".restart");
|
||||
delete_file(cfg.basename + ".data");
|
||||
delete_file(cfg.basename + "-coeffs.in");
|
||||
delete lmp;
|
||||
}
|
||||
|
||||
LAMMPS *init_lammps(int argc, char **argv, const TestConfig &cfg, const bool newton = true)
|
||||
{
|
||||
LAMMPS *lmp;
|
||||
|
||||
lmp = new LAMMPS(argc, argv, MPI_COMM_WORLD);
|
||||
|
||||
// check if prerequisite styles are available
|
||||
Info *info = new Info(lmp);
|
||||
int nfail = 0;
|
||||
for (auto &prerequisite : cfg.prerequisites) {
|
||||
std::string style = prerequisite.second;
|
||||
|
||||
// this is a test for improper styles, so if the suffixed
|
||||
// version is not available, there is no reason to test.
|
||||
if (prerequisite.first == "improper") {
|
||||
if (lmp->suffix_enable) {
|
||||
style += "/";
|
||||
style += lmp->suffix;
|
||||
}
|
||||
}
|
||||
|
||||
if (!info->has_style(prerequisite.first, style)) ++nfail;
|
||||
}
|
||||
delete info;
|
||||
if (nfail > 0) {
|
||||
cleanup_lammps(lmp, cfg);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// utility lambdas to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
auto parse_input_script = [&](const std::string &filename) {
|
||||
lmp->input->file(filename.c_str());
|
||||
};
|
||||
|
||||
if (newton) {
|
||||
command("variable newton_bond index on");
|
||||
} else {
|
||||
command("variable newton_bond index off");
|
||||
}
|
||||
|
||||
command("variable input_dir index " + INPUT_FOLDER);
|
||||
|
||||
for (auto &pre_command : cfg.pre_commands) {
|
||||
command(pre_command);
|
||||
}
|
||||
|
||||
std::string input_file = INPUT_FOLDER + PATH_SEP + cfg.input_file;
|
||||
parse_input_script(input_file);
|
||||
|
||||
command("improper_style " + cfg.improper_style);
|
||||
|
||||
for (auto &improper_coeff : cfg.improper_coeff) {
|
||||
command("improper_coeff " + improper_coeff);
|
||||
}
|
||||
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
|
||||
command("run 0 post no");
|
||||
command("write_restart " + cfg.basename + ".restart");
|
||||
command("write_data " + cfg.basename + ".data");
|
||||
command("write_coeff " + cfg.basename + "-coeffs.in");
|
||||
|
||||
return lmp;
|
||||
}
|
||||
|
||||
void run_lammps(LAMMPS *lmp)
|
||||
{
|
||||
// utility lambda to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
|
||||
command("fix 1 all nve");
|
||||
command("compute pe all pe/atom improper");
|
||||
command("compute sum all reduce sum c_pe");
|
||||
command("thermo_style custom step temp pe press c_sum");
|
||||
command("thermo 2");
|
||||
command("run 4 post no");
|
||||
}
|
||||
|
||||
void restart_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
// utility lambda to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
|
||||
command("clear");
|
||||
command("read_restart " + cfg.basename + ".restart");
|
||||
|
||||
if (!lmp->force->improper) {
|
||||
command("improper_style " + cfg.improper_style);
|
||||
}
|
||||
|
||||
if ((cfg.improper_style.substr(0, 6) == "hybrid") || !lmp->force->improper->writedata) {
|
||||
for (auto &improper_coeff : cfg.improper_coeff) {
|
||||
command("improper_coeff " + improper_coeff);
|
||||
}
|
||||
}
|
||||
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
|
||||
command("run 0 post no");
|
||||
}
|
||||
|
||||
void data_lammps(LAMMPS *lmp, const TestConfig &cfg)
|
||||
{
|
||||
// utility lambdas to improve readability
|
||||
auto command = [&](const std::string &line) {
|
||||
lmp->input->one(line.c_str());
|
||||
};
|
||||
auto parse_input_script = [&](const std::string &filename) {
|
||||
lmp->input->file(filename.c_str());
|
||||
};
|
||||
|
||||
command("clear");
|
||||
command("variable improper_style delete");
|
||||
command("variable data_file delete");
|
||||
command("variable newton_bond delete");
|
||||
command("variable newton_bond index on");
|
||||
|
||||
for (auto &pre_command : cfg.pre_commands) {
|
||||
command(pre_command);
|
||||
}
|
||||
|
||||
command("variable improper_style index '" + cfg.improper_style + "'");
|
||||
command("variable data_file index " + cfg.basename + ".data");
|
||||
|
||||
std::string input_file = INPUT_FOLDER + PATH_SEP + cfg.input_file;
|
||||
parse_input_script(input_file);
|
||||
|
||||
for (auto &improper_coeff : cfg.improper_coeff) {
|
||||
command("improper_coeff " + improper_coeff);
|
||||
}
|
||||
for (auto &post_command : cfg.post_commands) {
|
||||
command(post_command);
|
||||
}
|
||||
command("run 0 post no");
|
||||
}
|
||||
|
||||
// re-generate yaml file with current settings.
|
||||
|
||||
void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
{
|
||||
// initialize system geometry
|
||||
const char *args[] = {"ImproperStyle", "-log", "none", "-echo", "screen", "-nocite"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
LAMMPS *lmp = init_lammps(argc, argv, config);
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles are not available "
|
||||
"in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
const int natoms = lmp->atom->natoms;
|
||||
std::string block("");
|
||||
|
||||
YamlWriter writer(outfile);
|
||||
|
||||
// lammps_version
|
||||
writer.emit("lammps_version", lmp->version);
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
writer.emit("epsilon", config.epsilon);
|
||||
|
||||
// prerequisites
|
||||
block.clear();
|
||||
for (auto &prerequisite : config.prerequisites) {
|
||||
block += prerequisite.first + " " + prerequisite.second + "\n";
|
||||
}
|
||||
writer.emit_block("prerequisites", block);
|
||||
|
||||
// pre_commands
|
||||
block.clear();
|
||||
for (auto &command : config.pre_commands) {
|
||||
block += command + "\n";
|
||||
}
|
||||
writer.emit_block("pre_commands", block);
|
||||
|
||||
// post_commands
|
||||
block.clear();
|
||||
for (auto &command : config.post_commands) {
|
||||
block += command + "\n";
|
||||
}
|
||||
writer.emit_block("post_commands", block);
|
||||
|
||||
// input_file
|
||||
writer.emit("input_file", config.input_file);
|
||||
|
||||
// improper_style
|
||||
writer.emit("improper_style", config.improper_style);
|
||||
|
||||
// improper_coeff
|
||||
block.clear();
|
||||
for (auto &improper_coeff : config.improper_coeff) {
|
||||
block += improper_coeff + "\n";
|
||||
}
|
||||
writer.emit_block("improper_coeff", block);
|
||||
|
||||
// extract
|
||||
block.clear();
|
||||
for (auto data : config.extract)
|
||||
block += fmt::format("{} {}\n", data.first, data.second);
|
||||
writer.emit_block("extract", block);
|
||||
|
||||
// natoms
|
||||
writer.emit("natoms", natoms);
|
||||
|
||||
// init_energy
|
||||
writer.emit("init_energy", lmp->force->improper->energy);
|
||||
|
||||
// init_stress
|
||||
auto stress = lmp->force->improper->virial;
|
||||
block = fmt::format("{:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e}", stress[0],
|
||||
stress[1], stress[2], stress[3], stress[4], stress[5]);
|
||||
writer.emit_block("init_stress", block);
|
||||
|
||||
// init_forces
|
||||
block.clear();
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
for (int i = 1; i <= natoms; ++i) {
|
||||
const int j = lmp->atom->map(i);
|
||||
block += fmt::format("{:3} {:23.16e} {:23.16e} {:23.16e}\n", i, f[j][0], f[j][1], f[j][2]);
|
||||
}
|
||||
writer.emit_block("init_forces", block);
|
||||
|
||||
// do a few steps of MD
|
||||
run_lammps(lmp);
|
||||
|
||||
// run_energy
|
||||
writer.emit("run_energy", lmp->force->improper->energy);
|
||||
|
||||
// run_stress
|
||||
stress = lmp->force->improper->virial;
|
||||
block = fmt::format("{:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e} {:23.16e}", stress[0],
|
||||
stress[1], stress[2], stress[3], stress[4], stress[5]);
|
||||
writer.emit_block("run_stress", block);
|
||||
|
||||
block.clear();
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
for (int i = 1; i <= natoms; ++i) {
|
||||
const int j = lmp->atom->map(i);
|
||||
block += fmt::format("{:3} {:23.16e} {:23.16e} {:23.16e}\n", i, f[j][0], f[j][1], f[j][2]);
|
||||
}
|
||||
writer.emit_block("run_forces", block);
|
||||
|
||||
cleanup_lammps(lmp, config);
|
||||
return;
|
||||
}
|
||||
|
||||
TEST(ImproperStyle, plain)
|
||||
{
|
||||
const char *args[] = {"ImproperStyle", "-log", "none", "-echo", "screen", "-nocite"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
|
||||
::testing::internal::CaptureStdout();
|
||||
LAMMPS *lmp = init_lammps(argc, argv, test_config, true);
|
||||
|
||||
std::string output = ::testing::internal::GetCapturedStdout();
|
||||
if (verbose) std::cout << output;
|
||||
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles are not available "
|
||||
"in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : test_config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
EXPECT_THAT(output, StartsWith("LAMMPS ("));
|
||||
EXPECT_THAT(output, HasSubstr("Loop time"));
|
||||
|
||||
// abort if running in parallel and not all atoms are local
|
||||
const int nlocal = lmp->atom->nlocal;
|
||||
ASSERT_EQ(lmp->atom->natoms, nlocal);
|
||||
|
||||
double epsilon = test_config.epsilon;
|
||||
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
ErrorStats stats;
|
||||
stats.reset();
|
||||
const std::vector<coord_t> &f_ref = test_config.init_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
auto improper = lmp->force->improper;
|
||||
auto stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = improper->virial;
|
||||
|
||||
const std::vector<coord_t> &f_run = test_config.run_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_run.size());
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
int id = lmp->modify->find_compute("sum");
|
||||
double energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.run_energy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
lmp = init_lammps(argc, argv, test_config, false);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
// skip over these tests if newton bond is forced to be on
|
||||
if (lmp->force->newton_bond == 0) {
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
improper = lmp->force->improper;
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 2 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 2 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton off:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
id = lmp->modify->find_compute("sum");
|
||||
energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.run_energy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton off:" << stats << std::endl;
|
||||
}
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
restart_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "restart_forces stats:" << stats << std::endl;
|
||||
|
||||
improper = lmp->force->improper;
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "restart_stress stats:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "restart_energy stats:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
data_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
ASSERT_EQ(nlocal + 1, f_ref.size());
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "data_forces stats:" << stats << std::endl;
|
||||
|
||||
improper = lmp->force->improper;
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, epsilon);
|
||||
if (print_stats) std::cerr << "data_stress stats:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "data_energy stats:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
};
|
||||
|
||||
TEST(ImproperStyle, omp)
|
||||
{
|
||||
if (!LAMMPS::is_installed_pkg("USER-OMP")) GTEST_SKIP();
|
||||
const char *args[] = {"ImproperStyle", "-log", "none", "-echo", "screen", "-nocite",
|
||||
"-pk", "omp", "4", "-sf", "omp"};
|
||||
|
||||
char **argv = (char **)args;
|
||||
int argc = sizeof(args) / sizeof(char *);
|
||||
|
||||
::testing::internal::CaptureStdout();
|
||||
LAMMPS *lmp = init_lammps(argc, argv, test_config, true);
|
||||
|
||||
std::string output = ::testing::internal::GetCapturedStdout();
|
||||
if (verbose) std::cout << output;
|
||||
|
||||
if (!lmp) {
|
||||
std::cerr << "One or more prerequisite styles with /omp suffix\n"
|
||||
"are not available in this LAMMPS configuration:\n";
|
||||
for (auto &prerequisite : test_config.prerequisites) {
|
||||
std::cerr << prerequisite.first << "_style " << prerequisite.second << "\n";
|
||||
}
|
||||
GTEST_SKIP();
|
||||
}
|
||||
|
||||
EXPECT_THAT(output, StartsWith("LAMMPS ("));
|
||||
EXPECT_THAT(output, HasSubstr("Loop time"));
|
||||
|
||||
// abort if running in parallel and not all atoms are local
|
||||
const int nlocal = lmp->atom->nlocal;
|
||||
ASSERT_EQ(lmp->atom->natoms, nlocal);
|
||||
|
||||
// relax error a bit for USER-OMP package
|
||||
double epsilon = 5.0 * test_config.epsilon;
|
||||
|
||||
auto f = lmp->atom->f;
|
||||
auto tag = lmp->atom->tag;
|
||||
|
||||
const std::vector<coord_t> &f_ref = test_config.init_forces;
|
||||
ErrorStats stats;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
auto improper = lmp->force->improper;
|
||||
auto stress = improper->virial;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stress = improper->virial;
|
||||
|
||||
const std::vector<coord_t> &f_run = test_config.run_forces;
|
||||
ASSERT_EQ(nlocal + 1, f_run.size());
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton on: " << stats << std::endl;
|
||||
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton on: " << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
int id = lmp->modify->find_compute("sum");
|
||||
double energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.run_energy, epsilon);
|
||||
// TODO: this is currently broken for USER-OMP with improper style hybrid
|
||||
// needs to be fixed in the main code somewhere. Not sure where, though.
|
||||
if (test_config.improper_style.substr(0, 6) != "hybrid")
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton on: " << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
lmp = init_lammps(argc, argv, test_config, false);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
// skip over these tests if newton bond is forced to be on
|
||||
if (lmp->force->newton_bond == 0) {
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_ref[tag[i]].x, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_ref[tag[i]].y, epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_ref[tag[i]].z, epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "init_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
improper = lmp->force->improper;
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.init_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.init_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.init_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.init_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.init_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.init_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "init_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.init_energy, epsilon);
|
||||
if (print_stats) std::cerr << "init_energy stats, newton off:" << stats << std::endl;
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
run_lammps(lmp);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
|
||||
f = lmp->atom->f;
|
||||
tag = lmp->atom->tag;
|
||||
stats.reset();
|
||||
for (int i = 0; i < nlocal; ++i) {
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][0], f_run[tag[i]].x, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][1], f_run[tag[i]].y, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(f[i][2], f_run[tag[i]].z, 10 * epsilon);
|
||||
}
|
||||
if (print_stats) std::cerr << "run_forces stats, newton off:" << stats << std::endl;
|
||||
|
||||
stress = improper->virial;
|
||||
stats.reset();
|
||||
EXPECT_FP_LE_WITH_EPS(stress[0], test_config.run_stress.xx, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[1], test_config.run_stress.yy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[2], test_config.run_stress.zz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[3], test_config.run_stress.xy, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[4], test_config.run_stress.xz, 10 * epsilon);
|
||||
EXPECT_FP_LE_WITH_EPS(stress[5], test_config.run_stress.yz, 10 * epsilon);
|
||||
if (print_stats) std::cerr << "run_stress stats, newton off:" << stats << std::endl;
|
||||
|
||||
stats.reset();
|
||||
id = lmp->modify->find_compute("sum");
|
||||
energy = lmp->modify->compute[id]->compute_scalar();
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, test_config.run_energy, epsilon);
|
||||
// TODO: this is currently broken for USER-OMP with improper style hybrid
|
||||
// needs to be fixed in the main code somewhere. Not sure where, though.
|
||||
if (test_config.improper_style.substr(0, 6) != "hybrid")
|
||||
EXPECT_FP_LE_WITH_EPS(improper->energy, energy, epsilon);
|
||||
if (print_stats) std::cerr << "run_energy stats, newton off:" << stats << std::endl;
|
||||
}
|
||||
|
||||
if (!verbose) ::testing::internal::CaptureStdout();
|
||||
cleanup_lammps(lmp, test_config);
|
||||
if (!verbose) ::testing::internal::GetCapturedStdout();
|
||||
};
|
||||
@ -1,7 +1,7 @@
|
||||
---
|
||||
lammps_version: 24 Aug 2020
|
||||
date_generated: Tue Sep 15 09:44:35 202
|
||||
epsilon: 2.5e-13
|
||||
epsilon: 4e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
angle quartic
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
---
|
||||
lammps_version: 24 Aug 2020
|
||||
date_generated: Tue Sep 15 09:44:25 202
|
||||
epsilon: 1e-10
|
||||
epsilon: 2e-10
|
||||
prerequisites: ! |
|
||||
pair reax/c
|
||||
fix qeq/reax
|
||||
|
||||
@ -46,6 +46,19 @@ Angle Coeffs # zero
|
||||
3 120
|
||||
4 108.5
|
||||
|
||||
Dihedral Coeffs # zero
|
||||
|
||||
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
|
||||
Improper Coeffs # zero
|
||||
|
||||
1
|
||||
2
|
||||
|
||||
Atoms # full
|
||||
|
||||
10 2 1 7.0000000000000007e-02 2.0185283555536988e+00 -1.4283966846517357e+00 -9.6733527271133024e-01 0 0 0
|
||||
|
||||
89
unittest/force-styles/tests/dihedral-charmm.yaml
Normal file
89
unittest/force-styles/tests/dihedral-charmm.yaml
Normal file
@ -0,0 +1,89 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:32:00 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral charmm
|
||||
pre_commands: ! ""
|
||||
post_commands: ! |
|
||||
special_bonds charmm
|
||||
pair_style lj/charmm/coul/charmm 7.0 8.0
|
||||
pair_coeff * * 0.1 3.0
|
||||
input_file: in.fourmol
|
||||
dihedral_style: charmm
|
||||
dihedral_coeff: ! |
|
||||
1 75.0 2 160 0.5
|
||||
2 45.0 4 120 1.0
|
||||
3 56.0 0 110 0.0
|
||||
4 23.0 1 180 0.5
|
||||
5 19.0 3 90 1.0
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 1317.95984412099
|
||||
init_stress: ! |2-
|
||||
1.1266474992363544e+02 -1.4270359924600960e+01 -9.8394389999034431e+01 -1.4122826669412839e+02 1.1178234052730829e+02 -5.8711817976295805e+01
|
||||
init_forces: ! |2
|
||||
1 -9.0728070828324405e+00 -4.2409023620772402e+01 1.3161109399402682e+02
|
||||
2 3.3181828946933209e+01 1.4051671303009513e+01 6.3548249417335567e+00
|
||||
3 5.5350289840861464e+01 1.1131831288815475e+02 -3.9480881018342950e+02
|
||||
4 -1.1844907978543657e+02 -2.8998271771801804e+01 1.2935080865553104e+02
|
||||
5 -1.1583671402383914e+01 5.0372406935691121e+00 -3.9128008893243305e-02
|
||||
6 1.0321597937823311e+02 2.6974953442199936e+01 1.1570366758787367e+02
|
||||
7 -8.9000331915157602e+01 -2.3564688140264529e+01 3.2374751781728959e+00
|
||||
8 -5.6173305934035355e+01 1.4732923726825511e+01 -6.4812947497159044e+01
|
||||
9 -1.0285573098962932e+02 -4.0305092163391558e+00 3.5869756696647038e+01
|
||||
10 -4.3851647747590441e+01 -1.5710005359777315e+02 1.3867075586374912e+02
|
||||
11 -2.1619094578728090e+02 -3.3233741870916771e+02 1.4579886837322184e+02
|
||||
12 7.1261053740020756e+01 -4.9392232887317356e+01 1.0428582135201829e+01
|
||||
13 1.3045274807944942e+01 3.7064676200410256e+00 -1.7391883697148632e+01
|
||||
14 2.1115231856154324e+02 4.1325149711628239e+02 -1.8182836867325446e+02
|
||||
15 6.6217480580178957e+01 7.9628926680111661e+01 -9.6844899654306644e+01
|
||||
16 7.8335001553658429e+01 3.3029014991818336e+01 6.4117995352193278e+00
|
||||
17 1.7022736711084285e+01 -6.4494546990630354e+01 3.0252482246684398e+01
|
||||
18 6.6888062606310128e-01 2.5109175640033401e+00 3.5221262532274022e+00
|
||||
19 -1.0595281330291315e+00 -2.2909074264278830e+00 -7.4205308886987997e-01
|
||||
20 -5.6590649610114355e-02 -1.3306687981692766e-01 -1.1723524532058045e+00
|
||||
21 -1.3602839150541590e+00 -5.2316783809516321e-02 2.6862171884490484e+00
|
||||
22 2.1188881771188520e-01 7.6506576725652897e-01 -9.9588370661762238e-01
|
||||
23 1.7197280817140093e-01 3.2328958511427264e-01 -7.9666865784211760e-01
|
||||
24 8.3440060469976285e-01 -6.3373419421074084e-01 2.0837043868722125e+00
|
||||
25 -1.0278907497984688e+00 3.6727316840487179e-01 -1.2445837805673781e+00
|
||||
26 -5.4322936895149698e-01 -4.6377955792927761e-01 -1.3336861388577368e+00
|
||||
27 -1.3095161641895547e+00 -1.2565785999785013e+00 1.5351009379260916e-01
|
||||
28 6.7218786721800217e-01 7.6800634603799567e-01 -1.7119977008252721e-01
|
||||
29 1.1932647806568950e+00 6.9156748341000629e-01 4.6792179831738293e-02
|
||||
run_energy: 1317.13089096787
|
||||
run_stress: ! |2-
|
||||
1.1432326918192217e+02 -1.5602913994604187e+01 -9.8720355187318063e+01 -1.4093459949789184e+02 1.1435885495687606e+02 -5.7664013010033671e+01
|
||||
run_forces: ! |2
|
||||
1 -8.6738392290797321e+00 -4.3410976862478378e+01 1.3347585412854920e+02
|
||||
2 3.2238389882602903e+01 1.3927988326640385e+01 6.0326853193447016e+00
|
||||
3 5.5781319921623364e+01 1.1281438896518540e+02 -3.9723915447363220e+02
|
||||
4 -1.1781245729470949e+02 -2.8715133630261910e+01 1.2947327229271528e+02
|
||||
5 -1.1698125655644814e+01 4.8914276366056813e+00 -1.2206916593051020e-01
|
||||
6 1.0064255236909239e+02 2.4089902585533437e+01 1.1708688508535455e+02
|
||||
7 -8.8938396678183068e+01 -2.4269612244372958e+01 3.4046423133252497e+00
|
||||
8 -5.2440942113044144e+01 1.8663724891736056e+01 -6.5986905005646207e+01
|
||||
9 -1.0273771792476782e+02 -3.4152751230288336e+00 3.5403342910779550e+01
|
||||
10 -4.6264267786523504e+01 -1.5988311874558323e+02 1.3948502740217890e+02
|
||||
11 -2.0740380294773800e+02 -3.1362984721556523e+02 1.3680307896600868e+02
|
||||
12 7.1727029511898778e+01 -4.9953583843530197e+01 1.0566391313536254e+01
|
||||
13 1.2717601183517756e+01 3.6639042127491406e+00 -1.6991918462597582e+01
|
||||
14 2.0160316516219288e+02 3.9605544797472220e+02 -1.7309385003473275e+02
|
||||
15 6.6950478180516200e+01 8.0016328186605023e+01 -9.7109615235144631e+01
|
||||
16 7.9788925340074712e+01 3.4209121284318734e+01 6.5473927657876567e+00
|
||||
17 1.6122485334835080e+01 -6.5651549116138114e+01 3.0223626886103975e+01
|
||||
18 6.7123875238643738e-01 2.5225106816598521e+00 3.5235417346122380e+00
|
||||
19 -1.0614663134700668e+00 -2.3016803913636772e+00 -7.2888942997786199e-01
|
||||
20 -5.4056934695977041e-02 -1.3199262460437394e-01 -1.1690871662309097e+00
|
||||
21 -1.3614683789342612e+00 -6.1659172840990539e-02 2.6843872547994612e+00
|
||||
22 2.1301744794630889e-01 7.6998500648265933e-01 -9.9626778434974805e-01
|
||||
23 1.7137646754555280e-01 3.2261162434818480e-01 -7.9603557873164577e-01
|
||||
24 8.3450290990328380e-01 -6.2976630391752642e-01 2.0675159711292510e+00
|
||||
25 -1.0267254825899825e+00 3.6901966109757989e-01 -1.2397266170577683e+00
|
||||
26 -5.4220092253858421e-01 -4.6310693711038375e-01 -1.3315676468107509e+00
|
||||
27 -1.3087239984049934e+00 -1.2556095274814956e+00 1.5425738299910141e-01
|
||||
28 6.7103315457032875e-01 7.6674467322075168e-01 -1.7140189867370823e-01
|
||||
29 1.1910760416184893e+00 6.8980602737225627e-01 4.4586772292204771e-02
|
||||
...
|
||||
89
unittest/force-styles/tests/dihedral-charmmfsw.yaml
Normal file
89
unittest/force-styles/tests/dihedral-charmmfsw.yaml
Normal file
@ -0,0 +1,89 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:32:07 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral charmmfsw
|
||||
pre_commands: ! ""
|
||||
post_commands: ! |
|
||||
special_bonds charmm
|
||||
pair_style lj/charmmfsw/coul/charmmfsh 7.0 8.0
|
||||
pair_coeff * * 0.1 3.0
|
||||
input_file: in.fourmol
|
||||
dihedral_style: charmmfsw
|
||||
dihedral_coeff: ! |
|
||||
1 75.0 2 160 0.5
|
||||
2 45.0 4 120 1.0
|
||||
3 56.0 0 110 0.0
|
||||
4 23.0 1 180 0.5
|
||||
5 19.0 3 90 1.0
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 1317.95984412099
|
||||
init_stress: ! |2-
|
||||
1.1266474992363544e+02 -1.4270359924600960e+01 -9.8394389999034431e+01 -1.4122826669412839e+02 1.1178234052730829e+02 -5.8711817976295805e+01
|
||||
init_forces: ! |2
|
||||
1 -8.9693997732828734e+00 -4.2090832180473811e+01 1.3129896410266406e+02
|
||||
2 3.2939174268614089e+01 1.3776993828220547e+01 6.6047608190284564e+00
|
||||
3 5.5339891213774308e+01 1.1132435962327280e+02 -3.9478906486222957e+02
|
||||
4 -1.1853376295969241e+02 -2.8731355857128989e+01 1.2940461683448865e+02
|
||||
5 -1.1704542931552981e+01 5.1612910145764337e+00 1.1531982356444204e-01
|
||||
6 1.0315985347478912e+02 2.7858195004320272e+01 1.1495266502109652e+02
|
||||
7 -8.8909058225650583e+01 -2.3837347272152069e+01 3.9392213448182849e+00
|
||||
8 -5.5853617515784052e+01 1.3539223737174332e+01 -6.3713599961688189e+01
|
||||
9 -1.0311156651288640e+02 -3.6164116725708757e+00 3.5075828453521936e+01
|
||||
10 -4.3826637468354527e+01 -1.5710289244173734e+02 1.3864307003008477e+02
|
||||
11 -2.1622582834796196e+02 -3.3219826841101195e+02 1.4556774326995796e+02
|
||||
12 7.1412702974492348e+01 -4.9974052650356612e+01 1.0723258124306223e+01
|
||||
13 1.2983841333488790e+01 3.6226253549259608e+00 -1.7369216643277348e+01
|
||||
14 2.1111361658245866e+02 4.1312473179030422e+02 -1.8177665169218727e+02
|
||||
15 6.6205967662062449e+01 7.9562081373822039e+01 -9.6816806108613221e+01
|
||||
16 7.8024062158787302e+01 3.4094331075850761e+01 5.9763314082458487e+00
|
||||
17 1.7445214070241107e+01 -6.4435014330300476e+01 2.9813113022057500e+01
|
||||
18 2.0800160412943211e-01 2.2891124106778022e+00 3.4660835897877700e+00
|
||||
19 -8.0963080390688746e-01 -2.4045945217436877e+00 -1.8583563864926739e-01
|
||||
20 -3.8753637434211785e-02 -5.5448402782730866e-01 -6.7086657947375039e-01
|
||||
21 -1.3905969243613909e+00 9.2263911023596146e-01 2.4245678407761346e+00
|
||||
22 1.3613731081665018e-01 8.4084293030416840e-02 -8.1025131035386821e-01
|
||||
23 4.1866083933707599e-01 -5.5509350762570908e-02 -7.0997382727305158e-01
|
||||
24 7.1694861345295280e-01 -2.3511767137443013e-01 8.0781359710835909e-01
|
||||
25 -1.0629765873976795e+00 -1.8433966653787029e-01 -1.2964080715678894e+00
|
||||
26 -3.5304755132121918e-01 -1.9129024515386733e-01 -4.7932022297094667e-01
|
||||
27 -7.5085140414840501e-01 -2.1332740916449014e-01 -3.4556428061080330e-01
|
||||
28 3.0509542011027740e-01 4.6221002204910822e-02 8.8498260667955922e-02
|
||||
29 1.1311031171809240e+00 4.1894808967987129e-01 6.1703656720310460e-02
|
||||
run_energy: 1317.13142783318
|
||||
run_stress: ! |2-
|
||||
1.1432271538886499e+02 -1.5603844203952541e+01 -9.8718871184912416e+01 -1.4093580634465189e+02 1.1435865928680047e+02 -5.7664143378423546e+01
|
||||
run_forces: ! |2
|
||||
1 -8.5717926119025947e+00 -4.3091412260618227e+01 1.3316006725249042e+02
|
||||
2 3.1997674214676874e+01 1.3654655784189870e+01 6.2828676384712061e+00
|
||||
3 5.5770382737530170e+01 1.1281783434187146e+02 -3.9721453377879095e+02
|
||||
4 -1.1789680795379847e+02 -2.8447706749956993e+01 1.2952665428714013e+02
|
||||
5 -1.1819996113850017e+01 5.0146666822935302e+00 3.2281792318776925e-02
|
||||
6 1.0058447730534851e+02 2.4972369765865452e+01 1.1633752546321533e+02
|
||||
7 -8.8848296871465919e+01 -2.4542246520962529e+01 4.1058609991775068e+00
|
||||
8 -5.2109635323526945e+01 1.7483153474801384e+01 -6.4894524111023628e+01
|
||||
9 -1.0299581329057062e+02 -3.0071901661917311e+00 3.4614355229661122e+01
|
||||
10 -4.6248656852080643e+01 -1.5989736943052526e+02 1.3946110129960286e+02
|
||||
11 -2.0744046131487352e+02 -3.1349391104875059e+02 1.3657355191843646e+02
|
||||
12 7.1878446763226236e+01 -5.0535379590486308e+01 1.0860480569904183e+01
|
||||
13 1.2656630660306188e+01 3.5801817290072018e+00 -1.6968929416398453e+01
|
||||
14 2.0156828471782353e+02 3.9593474256507108e+02 -1.7304498843642651e+02
|
||||
15 6.6938931982383480e+01 7.9950072669406069e+01 -9.7082424123877473e+01
|
||||
16 7.9480812177410172e+01 3.5274424529763422e+01 6.1163506563185468e+00
|
||||
17 1.6544041468715115e+01 -6.5589692620159624e+01 2.9781616838343403e+01
|
||||
18 2.1267286099045599e-01 2.2942619216574771e+00 3.4659719272782654e+00
|
||||
19 -8.1337490705231874e-01 -2.4098575977295353e+00 -1.8396289009644590e-01
|
||||
20 -3.7941149699885969e-02 -5.5340608883683873e-01 -6.6993848517114352e-01
|
||||
21 -1.3889998509458839e+00 9.1890355468961316e-01 2.4229472564481020e+00
|
||||
22 1.3595436261854707e-01 8.5481963099478642e-02 -8.0999717836214991e-01
|
||||
23 4.1797076633887387e-01 -5.5351208630107784e-02 -7.0920364554695203e-01
|
||||
24 7.1594583142507817e-01 -2.3421203522820028e-01 8.0152300676926436e-01
|
||||
25 -1.0620978751652836e+00 -1.8302578820695936e-01 -1.2914119694215400e+00
|
||||
26 -3.5226930669430428e-01 -1.9104656198469849e-01 -4.7741349806842143e-01
|
||||
27 -7.4942338430179933e-01 -2.1202918409495525e-01 -3.4599837098455843e-01
|
||||
28 3.0447869914249726e-01 4.5993592160623709e-02 8.8399467006803928e-02
|
||||
29 1.1288622579925440e+00 4.1709427848592429e-01 6.1770301585805341e-02
|
||||
...
|
||||
87
unittest/force-styles/tests/dihedral-class2.yaml
Normal file
87
unittest/force-styles/tests/dihedral-class2.yaml
Normal file
@ -0,0 +1,87 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 8e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral class2
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: class2
|
||||
dihedral_coeff: ! |
|
||||
* 75.0 169 45.0 10 24.0 40.0
|
||||
* mbt 75 42 31 5.2
|
||||
* ebt 75 42 31 75 42 31 1.4 1.4
|
||||
* at 75 42 31 75 42 31 120 50
|
||||
* aat 75 120 160
|
||||
* bb13 75 1.4 1.4
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 3355.00747173759
|
||||
init_stress: ! |2-
|
||||
2.1875123407705587e+01 -7.3463171958190321e+02 7.0422332087828568e+02 -2.0890942199873339e+02 -3.6451752675970380e+02 1.3400265327626121e+02
|
||||
init_forces: ! |2
|
||||
1 -1.0952511200405197e+03 6.4823297173207970e+02 -4.4760954488358391e+02
|
||||
2 9.0092068008499132e+02 -3.6118332267415013e+02 3.5713667026397326e+02
|
||||
3 -7.7532838532500693e+02 -1.2468325260439517e+03 3.8359187812682325e+02
|
||||
4 1.2904186368708332e+02 2.2136621866894416e+02 -1.4642984375119335e+02
|
||||
5 5.9556699584425348e+02 1.5024609743159468e+02 2.2329142626092334e+02
|
||||
6 7.3251103695180063e+02 1.1448501937143062e+03 -3.0258310893753855e+02
|
||||
7 -5.6987565445561142e+02 -6.9068345660300258e+02 1.5974567786362655e+02
|
||||
8 2.3172356712469091e+03 1.7621991394557467e+03 -1.0823598208966904e+02
|
||||
9 -1.0665980086873585e+03 -9.7028318259088303e+02 4.0830286870801143e+02
|
||||
10 -1.1831159209684265e+03 -1.2136533632807443e+03 1.0278790875590396e+03
|
||||
11 -6.8651636455995185e+02 9.1292605610303031e+02 -5.0138124218536382e+02
|
||||
12 9.4590221018670803e+01 -1.4167468342595586e+02 -3.9159227689650663e+02
|
||||
13 1.7016834910937868e+02 3.5891736246788633e+02 8.2250630442549743e+02
|
||||
14 5.6198417641541641e+02 -7.5542769524397647e+02 -2.9572420497952066e+02
|
||||
15 -7.0833278096116078e+02 2.2547367398085970e+02 -6.9838585028829266e+02
|
||||
16 9.0926990053407053e+02 1.5375356733249265e+02 -3.5329802202150256e+02
|
||||
17 -3.2627065989453854e+02 -1.9822705102427648e+02 -1.3721383717472295e+02
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 3232.22368557986
|
||||
run_stress: ! |2-
|
||||
3.4186200218682700e+01 -7.5351720154542477e+02 5.8894003293457865e+02 -1.4452761583493597e+02 -3.8479488337510423e+02 1.2221118941124658e+02
|
||||
run_forces: ! |2
|
||||
1 -1.1114877010468704e+03 6.6412899312329989e+02 -4.8306781555357099e+02
|
||||
2 9.0918809418895717e+02 -3.7552925375399423e+02 3.7963210720241710e+02
|
||||
3 -7.4768553265259493e+02 -1.2526329500283782e+03 3.9165439571062751e+02
|
||||
4 1.1598833343613694e+02 2.0353476227252435e+02 -1.2759176729615673e+02
|
||||
5 5.9446880390197896e+02 1.5266302110358913e+02 2.1506481482921635e+02
|
||||
6 7.6270375928437579e+02 1.1975511187402499e+03 -3.1848407740344737e+02
|
||||
7 -5.6563612620259039e+02 -6.9106367799535462e+02 1.6626389201928362e+02
|
||||
8 2.2261446006370847e+03 1.6471763697379154e+03 -5.9204553180719302e+01
|
||||
9 -1.0508281810786864e+03 -9.5153190588270775e+02 3.6074532374710634e+02
|
||||
10 -1.1002869875539902e+03 -1.1259097891078113e+03 9.9461497198463974e+02
|
||||
11 -6.8671642743708378e+02 9.0225692086600691e+02 -4.6762764620034005e+02
|
||||
12 8.0194355742839932e+01 -1.4025133105503551e+02 -4.1215700309601090e+02
|
||||
13 1.6121978561368979e+02 3.6583968779424583e+02 8.2543084661182979e+02
|
||||
14 5.6039463771180522e+02 -7.5245341384736207e+02 -2.8267617778550414e+02
|
||||
15 -6.9314762831894063e+02 2.1107046433802870e+02 -6.8684015745129102e+02
|
||||
16 8.5054295795981488e+02 1.2889703114277438e+02 -3.6104879490120936e+02
|
||||
17 -3.0505674418592668e+02 -1.8374604744798970e+02 -1.3470835923687093e+02
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml
Normal file
86
unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral cosine/shift/exp
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: cosine/shift/exp
|
||||
dihedral_coeff: ! |
|
||||
1 75 160 5.1
|
||||
2 45 120 2.4
|
||||
3 56 110 7.5
|
||||
4 23 180 5.5
|
||||
5 19 90 2.1
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: -252.253036379603
|
||||
init_stress: ! |2-
|
||||
1.2648173379127915e+01 9.8987186508472114e+00 -2.2546892029975140e+01 -4.8774048841283184e+00 2.3394385854749725e+01 8.0008046681362437e+00
|
||||
init_forces: ! |2
|
||||
1 -2.1552264641323678e+01 9.3802303976266224e+00 -5.7580855394682011e+00
|
||||
2 1.7542053448836405e+01 -9.0585245111022275e+00 8.5707996887760274e+00
|
||||
3 -4.5368370292539865e+01 6.2901866813565608e+00 -1.8171838280442625e+01
|
||||
4 -3.9437738551082751e+00 -4.2378540140894083e+00 3.8839120634338524e+00
|
||||
5 3.0958932417316447e+01 -1.7216940826097481e+01 8.8151959108927258e-01
|
||||
6 1.2935503074785331e+01 4.8389291078610510e+00 1.2199210336313424e+01
|
||||
7 1.0262636687925307e+01 1.0876998682721958e+01 -1.7791589083223791e+00
|
||||
8 1.8474452366832249e+01 1.9606544103980980e+01 6.2220353299406197e+00
|
||||
9 1.7020916758045722e+01 1.2650017097294752e+01 -6.9250534440155018e+00
|
||||
10 -6.9954140460001156e+01 -4.0784510598700408e+01 -7.4483410064839335e+00
|
||||
11 9.9800939432401670e+00 -4.1410083603937675e-01 -2.2031105090375496e+00
|
||||
12 6.9055058996213878e+00 2.5245282650526435e+00 1.4073615205210855e+01
|
||||
13 -7.1665608596457320e-02 -1.6473434103906204e-01 -3.4575048440907352e-01
|
||||
14 2.4318532883817405e+00 -3.3839834090561496e+00 -1.2032631916318084e+00
|
||||
15 -8.5093986224928719e-01 2.8808607565855016e-01 -8.7054599213134165e-01
|
||||
16 9.8383158994739350e+00 4.3782146730454237e+00 -1.9942921984521147e+00
|
||||
17 5.3908909353600105e+00 4.4269134515255688e+00 8.6834733963048583e-01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: -252.29533087732
|
||||
run_stress: ! |2-
|
||||
1.2679233523358512e+01 9.9049911944774891e+00 -2.2584224717836005e+01 -4.9222953229219746e+00 2.3439232765403958e+01 8.0455044326920557e+00
|
||||
run_forces: ! |2
|
||||
1 -2.1681260602243135e+01 9.4640446498660182e+00 -5.8153660416206314e+00
|
||||
2 1.7622228873435517e+01 -9.1203004442484552e+00 8.6207493217103508e+00
|
||||
3 -4.5422186497022935e+01 6.2789238657259032e+00 -1.8158223155939911e+01
|
||||
4 -3.9417660078991212e+00 -4.2340583918337522e+00 3.8803641977291665e+00
|
||||
5 3.1033325732076925e+01 -1.7261278784796644e+01 8.6126955781857584e-01
|
||||
6 1.3057761350645071e+01 5.0037796191582586e+00 1.2206425951334531e+01
|
||||
7 1.0204581390079650e+01 1.0787383771900220e+01 -1.7693012874559422e+00
|
||||
8 1.8495759477703640e+01 1.9607876365921989e+01 6.2445967454739897e+00
|
||||
9 1.6979375388826224e+01 1.2610145808112222e+01 -6.9025331116309552e+00
|
||||
10 -6.9958416307959141e+01 -4.0778006073824884e+01 -7.4878188339111018e+00
|
||||
11 9.9719586693041080e+00 -4.1438168249956409e-01 -2.1985928209527419e+00
|
||||
12 6.8945633023312496e+00 2.5226410282917007e+00 1.4050126397293486e+01
|
||||
13 -6.8568730429444003e-02 -1.5852707806876509e-01 -3.3190435067363921e-01
|
||||
14 2.4388776536331709e+00 -3.3933646938491453e+00 -1.2019882913884326e+00
|
||||
15 -8.5054571191848705e-01 2.8798818238768842e-01 -8.7036353952742662e-01
|
||||
16 9.8265119994301369e+00 4.3670820826747221e+00 -1.9950230823005020e+00
|
||||
17 5.3978000200065610e+00 4.4300517750824797e+00 8.6758234404118428e-01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-fourier.yaml
Normal file
86
unittest/force-styles/tests/dihedral-fourier.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral fourier
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: fourier
|
||||
dihedral_coeff: ! |
|
||||
1 1 75 1 120
|
||||
2 2 75 1 120 42 2 140
|
||||
3 3 75 1 120 42 2 140 35 1 160
|
||||
4 4 75 1 120 42 2 140 35 2 160 21 2 110
|
||||
5 5 75 1 120 42 2 140 35 2 160 21 2 110 10 2 20
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 4237.11651056645
|
||||
init_stress: ! |-
|
||||
-1.3707440529302690e+02 -1.1775005714687839e+02 2.5482446243990526e+02 -6.0912155352783621e+01 -5.1858430299845004e+01 6.0101035915715130e+01
|
||||
init_forces: ! |2
|
||||
1 1.2746097289536124e+01 1.7790368163729774e+01 -6.0266215656413465e+01
|
||||
2 -1.1610373332641466e+01 5.9954697848533023e+00 -5.6726645165123202e+00
|
||||
3 -3.0005227165688689e+02 -4.9050080271628303e+02 3.9338967778175328e+02
|
||||
4 2.2841720862146582e+02 2.7139158135197215e+02 -2.1470031526034018e+02
|
||||
5 8.8728374601790705e+00 5.0910313257182963e+01 1.7059542215878547e+01
|
||||
6 -1.7146773646607862e+01 5.7418005757422108e+01 -1.2055217754071802e+02
|
||||
7 -1.3811348109784333e+01 -1.6092405824046040e+01 2.6858660625110637e+00
|
||||
8 2.7655221748363908e+02 2.5865412863270615e+02 5.0126271505349962e+01
|
||||
9 -7.2800478794159957e+01 -8.5596953503127224e+01 3.7283780582768628e+01
|
||||
10 -2.4238052366585617e+02 -2.5593760501061624e+01 -9.7931335578075107e+01
|
||||
11 1.0347877593619343e+01 -4.9780495945302690e+01 2.7793211018332766e+01
|
||||
12 -6.7005988611830034e+00 1.4693253477499198e+01 1.1054970688694432e+01
|
||||
13 5.9402228888983188e+00 1.3654509078936314e+01 2.8658585080877884e+01
|
||||
14 5.1102705146276143e+01 -7.1110665762227086e+01 -2.5285244134215667e+01
|
||||
15 -2.2979041686027728e+01 7.7795649674038003e+00 -2.3508491645829253e+01
|
||||
16 2.7292929150263575e+01 -1.3982140480955508e+01 -3.0800243561758844e+01
|
||||
17 6.6209314119270019e+01 5.4370030261297515e+01 1.0664782957696374e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 4233.36580637715
|
||||
run_stress: ! |-
|
||||
-1.3658608701216593e+02 -1.1640355380892572e+02 2.5298964082109160e+02 -5.9498600086177774e+01 -5.3758494802170190e+01 5.9305904454019270e+01
|
||||
run_forces: ! |2
|
||||
1 1.2656448076133628e+01 1.7635520324005068e+01 -6.0006796640617665e+01
|
||||
2 -1.1573163528233266e+01 5.9836034352265699e+00 -5.6594485084542114e+00
|
||||
3 -2.9941157363456563e+02 -4.8872262595805654e+02 3.9031433907767348e+02
|
||||
4 2.2905499925998637e+02 2.7059530582038133e+02 -2.1229559164622748e+02
|
||||
5 8.1750794627657726e+00 5.0657842720903609e+01 1.6780715006767107e+01
|
||||
6 -1.7443005461507592e+01 5.7218771827645256e+01 -1.2012649417671597e+02
|
||||
7 -1.3525119390116430e+01 -1.6087558115506980e+01 2.7080662413770291e+00
|
||||
8 2.7459081991569656e+02 2.5647694865384881e+02 5.0613483765327558e+01
|
||||
9 -7.2124239500896806e+01 -8.4574727373775019e+01 3.6604250699658223e+01
|
||||
10 -2.4164669112795698e+02 -2.5230852547950050e+01 -9.7455774332284349e+01
|
||||
11 1.0412773068661206e+01 -4.9306338476077684e+01 2.7538061026160925e+01
|
||||
12 -6.0804141958446536e+00 1.4416738345165744e+01 1.1575195905170951e+01
|
||||
13 5.8163363064274805e+00 1.3466130968991664e+01 2.8195551304909998e+01
|
||||
14 5.0845396842328462e+01 -7.0714301419334163e+01 -2.4989421719429810e+01
|
||||
15 -2.3126568730718233e+01 7.8313348391903830e+00 -2.3688838429532481e+01
|
||||
16 2.6928856175808562e+01 -1.4197456731253766e+01 -3.0770505097537921e+01
|
||||
17 6.6450066462031486e+01 5.4551663686595774e+01 1.0663207523754473e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-harmonic.yaml
Normal file
86
unittest/force-styles/tests/dihedral-harmonic.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral harmonic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: harmonic
|
||||
dihedral_coeff: ! |
|
||||
1 75.0 +1 2
|
||||
2 45.0 -1 4
|
||||
3 56.0 -1 2
|
||||
4 23.0 +1 1
|
||||
5 19.0 -1 3
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 789.17395858648
|
||||
init_stress: ! |-
|
||||
-6.2042484436524219e+01 1.2714037725306221e+02 -6.5097892816538135e+01 2.6648135399224223e+01 1.3495574921305175e+02 1.6236422290928121e+02
|
||||
init_forces: ! |2
|
||||
1 -2.1511698742845866e+01 4.0249060564855860e+01 -9.0013321196300495e+01
|
||||
2 -8.1931697051663761e+00 4.2308632119002461e+00 -4.0030670619001576e+00
|
||||
3 9.1213724359021342e+01 -1.3766351447039605e+02 8.1969246558440773e+01
|
||||
4 -4.8202572898596316e+01 -8.0465316960733553e+00 6.4757081520864901e+01
|
||||
5 -6.2252471689207432e+01 2.2804485244022331e+01 -5.3285277341381354e+00
|
||||
6 9.1271091191895337e+01 1.3743691097166200e+02 -3.9344000137592637e+01
|
||||
7 -4.7435622518386936e+01 -5.1206081255886986e+01 8.4101355581705430e+00
|
||||
8 2.2568717344776448e+02 1.6221073825524249e+02 5.7667169753528370e+01
|
||||
9 -2.0794865226210746e+00 5.0314964909952629e+00 -7.5468528100469179e-01
|
||||
10 -4.0476567806811568e+02 -4.7270660984257171e+02 -9.9999223894595431e+01
|
||||
11 3.9909170606249432e+01 2.0810704935563001e+02 -1.3665198019985243e+02
|
||||
12 6.2493704719337885e+01 7.0253447917427593e+01 1.9569964347346627e+02
|
||||
13 2.9234925409867770e+01 6.7200938735330823e+01 1.4104379799580224e+02
|
||||
14 7.2099736490024156e+01 -1.0032854911322366e+02 -3.5674421421421059e+01
|
||||
15 -1.0059762933494233e+02 3.4057372960589944e+01 -1.0291545492293889e+02
|
||||
16 -9.2273705073611623e+01 -1.2566881299602966e+02 -6.3115663814665538e+01
|
||||
17 1.7540250832933316e+02 1.4403773566652495e+02 2.8253270804136417e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 786.186635855008
|
||||
run_stress: ! |-
|
||||
-6.1891690150881182e+01 1.2738938495389695e+02 -6.5497694803015833e+01 2.6197221636385819e+01 1.3475397071041999e+02 1.6145289649182780e+02
|
||||
run_forces: ! |2
|
||||
1 -2.2302877929458532e+01 4.0672550312262075e+01 -9.0501596668366560e+01
|
||||
2 -7.6795593796038659e+00 3.9696254383022342e+00 -3.7581780677357415e+00
|
||||
3 9.2113038158654348e+01 -1.3743858583367683e+02 8.2424527694664079e+01
|
||||
4 -4.8297128598674483e+01 -8.1171172512686596e+00 6.4789088490585272e+01
|
||||
5 -6.2249945690217793e+01 2.2813353689490402e+01 -5.3758961093281030e+00
|
||||
6 9.1082266628006465e+01 1.3760435354837995e+02 -3.9497610280357797e+01
|
||||
7 -4.6896902011280687e+01 -5.0626904069869454e+01 8.3785410081476979e+00
|
||||
8 2.2272760695742204e+02 1.5895499756012089e+02 5.7194518287049874e+01
|
||||
9 -1.3424389406805730e+00 5.5961120716834856e+00 -1.0522843139661155e+00
|
||||
10 -4.0569661830987485e+02 -4.7090645706702168e+02 -9.7628440388580174e+01
|
||||
11 4.2260633810406503e+01 2.0874271156158215e+02 -1.3676519733514763e+02
|
||||
12 6.2351939715965052e+01 6.8740733618467218e+01 1.9368291702263934e+02
|
||||
13 2.9034913938879313e+01 6.7392732937882698e+01 1.4128237950589556e+02
|
||||
14 7.1584708215786904e+01 -9.9391162196277406e+01 -3.5112483074387470e+01
|
||||
15 -1.0011391208839508e+02 3.3797184010534480e+01 -1.0280672267359482e+02
|
||||
16 -9.3370884293886093e+01 -1.2693997516553819e+02 -6.3467167983741767e+01
|
||||
17 1.7679515981695124e+02 1.4513584683494673e+02 2.8213604886224289e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-helix.yaml
Normal file
86
unittest/force-styles/tests/dihedral-helix.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 4e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral helix
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: helix
|
||||
dihedral_coeff: ! |
|
||||
1 75 60 42
|
||||
2 45 20 75
|
||||
3 56 10 32
|
||||
4 23 80 61
|
||||
5 19 90 13
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 4634.43654570767
|
||||
init_stress: ! |-
|
||||
-8.0823732518007063e+01 9.9479187244686372e+01 -1.8655454726675949e+01 3.1101576556766464e+01 7.4461883645297817e+01 4.1747530138691431e+01
|
||||
init_forces: ! |2
|
||||
1 1.5382329638267035e+02 -8.7367671314025870e+01 9.6804569946208261e+01
|
||||
2 -1.1019792518885538e+02 5.6905003129041866e+01 -5.3841150676408077e+01
|
||||
3 2.3246539083975540e+02 4.0296299562627843e+02 -1.1393686865859719e+02
|
||||
4 3.1568060813146815e+01 7.2317480245219112e+00 -4.1634456256848267e+01
|
||||
5 6.2738188559800125e+00 -1.7156050770489149e+00 7.1235927088545736e-01
|
||||
6 -1.0269680933720128e+03 -1.1690454281502080e+03 2.1661954258810474e+02
|
||||
7 4.5805034065516077e+02 4.9842112368971334e+02 -8.2004595690709891e+01
|
||||
8 -5.7825681205863634e+02 -3.5494272038879524e+02 -3.0370616059225443e+02
|
||||
9 4.4268140801703601e+02 4.4489087402560148e+02 -2.0831276526993508e+02
|
||||
10 -8.7951164139994106e+01 1.0636363540938811e+02 -5.4515993120398562e+01
|
||||
11 7.1220902371740760e+02 -3.3016873225873167e+02 2.5993521030531866e+01
|
||||
12 -1.7787675730154284e+01 1.3423193485792939e+02 1.6661355844612928e+02
|
||||
13 -1.3886141645948561e+02 -3.1919416278193785e+02 -6.6993643041455698e+02
|
||||
14 -3.7790416886453352e+02 5.2586290618778116e+02 1.8698421427449404e+02
|
||||
15 4.7485173910262199e+02 -1.6076127127963423e+02 4.8579258849115138e+02
|
||||
16 -2.4610027154189740e+02 1.8711434954391689e+02 3.3675371434963506e+02
|
||||
17 7.2104448971790220e+01 5.9211020756208853e+01 1.1614352282568388e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 4604.29767615419
|
||||
run_stress: ! |-
|
||||
-7.9493088618049043e+01 1.0569468868590617e+02 -2.6201600067857370e+01 4.3225252542366661e+01 6.6510401367367706e+01 3.7958321007398133e+01
|
||||
run_forces: ! |2
|
||||
1 1.5239538662222483e+02 -8.5304318790181981e+01 9.1857296044358804e+01
|
||||
2 -1.0967028219095423e+02 5.6694684619133220e+01 -5.3333029655051035e+01
|
||||
3 2.4083923292691799e+02 4.0545658790486630e+02 -1.0928376525899010e+02
|
||||
4 2.9004572124849197e+01 3.3433497097463150e+00 -3.9484083494241339e+01
|
||||
5 5.4495253574218356e+00 -2.3234784690594568e+00 3.6744082833339320e-01
|
||||
6 -1.0416416920207600e+03 -1.1728713553808166e+03 2.1517006495886761e+02
|
||||
7 4.6730984467782685e+02 5.0224210584028452e+02 -7.9280667353675966e+01
|
||||
8 -5.6864896514161364e+02 -3.4977436236350320e+02 -3.0403472535369667e+02
|
||||
9 4.3781190409126589e+02 4.4179927003638215e+02 -2.1089303274257958e+02
|
||||
10 -8.5863568189987490e+01 1.0020124487504943e+02 -6.5522998341248922e+01
|
||||
11 7.1073054117197967e+02 -3.3058374406671203e+02 3.2522201110837969e+01
|
||||
12 -2.4832249967654064e+01 1.3872033356079328e+02 1.6239068437785096e+02
|
||||
13 -1.4153451065060841e+02 -3.1548547899029609e+02 -6.6874565279275259e+02
|
||||
14 -3.7582648536581155e+02 5.2528558881481820e+02 1.8878887552977594e+02
|
||||
15 4.8083127351494102e+02 -1.6542050766651528e+02 4.8868255420903807e+02
|
||||
16 -2.5031689931311919e+02 1.8736345330256745e+02 3.3892450313503065e+02
|
||||
17 7.3962372353081548e+01 6.0656627063443544e+01 1.1874334798142684e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
87
unittest/force-styles/tests/dihedral-hybrid.yaml
Normal file
87
unittest/force-styles/tests/dihedral-hybrid.yaml
Normal file
@ -0,0 +1,87 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 20:43:34 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral harmonic
|
||||
dihedral opls
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: hybrid harmonic opls
|
||||
dihedral_coeff: ! |
|
||||
1 harmonic 75.0 +1 2
|
||||
2 harmonic 45.0 -1 4
|
||||
3 opls 56 10 32 84
|
||||
4 opls 23 80 61 83
|
||||
5 opls 19 90 13 15
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 1501.66406241746
|
||||
init_stress: ! |-
|
||||
-2.4645376253219257e+02 2.3613233899749815e+01 2.2284052863244389e+02 -1.0599361078821747e+02 1.5465939277742063e+02 2.1207702997596056e+02
|
||||
init_forces: ! |2
|
||||
1 1.4485898476422688e+02 -4.5669120902309771e+01 -8.7100920472046255e+00
|
||||
2 -1.3855214618931836e+02 7.1546812691134122e+01 -6.7694622804688365e+01
|
||||
3 6.5964354373895731e+01 -2.7120798820857840e+02 5.7779867477146780e+01
|
||||
4 3.8353068558669833e+01 1.2204757513167141e+02 -5.8324764485431615e+00
|
||||
5 -3.7665970146318045e+01 1.7971807362873875e+02 4.6710944552079511e+01
|
||||
6 -1.7267806226531070e+02 -1.4225589912924301e+02 2.2077313521312504e+01
|
||||
7 -3.7144952722106751e+01 -3.8425708934662325e+01 6.2505576173423023e+00
|
||||
8 5.2208543487497695e+02 4.6179315154002813e+02 -1.5460707336634505e+02
|
||||
9 -2.0849607802277379e+02 -1.7315826143535537e+02 8.9258128356805344e+01
|
||||
10 -6.3617202713506140e+02 -6.2240030689383138e+02 -1.4760361206040028e+02
|
||||
11 2.5886970042458915e+02 1.5666256285978619e+02 -1.5917139508413430e+02
|
||||
12 4.2729200582282026e+01 1.3521565741148760e+02 2.5947570019542530e+02
|
||||
13 -9.3214628811766573e+00 -2.1426805343932180e+01 -4.4971365899031198e+01
|
||||
14 -8.9873999491195278e+00 1.2506187138703197e+01 4.4468996542326877e+00
|
||||
15 2.2596508786687970e+01 -7.6500582811265403e+00 2.3117144974751533e+01
|
||||
16 -1.3401658013513540e+01 4.5597188897388733e+01 5.2580299101894475e+01
|
||||
17 1.6696250495937039e+02 1.3710693983010100e+02 2.6893782259356598e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 1495.65001965091
|
||||
run_stress: ! |-
|
||||
-2.4383465439885845e+02 2.5649599381834832e+01 2.1818505501701961e+02 -1.0616938394760371e+02 1.5358337500265804e+02 2.1056893001808325e+02
|
||||
run_forces: ! |2
|
||||
1 1.4397575702511341e+02 -4.5331119446881701e+01 -9.1122967211867660e+00
|
||||
2 -1.3764123886019212e+02 7.1062183101822228e+01 -6.6967960649665798e+01
|
||||
3 6.7085675178242056e+01 -2.6933932441988645e+02 5.4616974104117872e+01
|
||||
4 3.6908108135605985e+01 1.2125433276949988e+02 -3.9610937280282741e+00
|
||||
5 -3.7050315406580609e+01 1.7986384304333143e+02 4.6504988994828153e+01
|
||||
6 -1.6439068516180080e+02 -1.3508359739557659e+02 2.0551321088938856e+01
|
||||
7 -3.6875480266122125e+01 -3.8594365820736940e+01 6.2927149422567155e+00
|
||||
8 4.9895893276330048e+02 4.4194751828933101e+02 -1.4833194600243888e+02
|
||||
9 -2.0282594711246924e+02 -1.7015693059626273e+02 8.5956679467201681e+01
|
||||
10 -6.3121339395976145e+02 -6.1281424455658635e+02 -1.4607947541321980e+02
|
||||
11 2.6261030068321173e+02 1.5729875558190750e+02 -1.5871767602077460e+02
|
||||
12 4.2642412010734539e+01 1.3415403646699093e+02 2.5857538812174545e+02
|
||||
13 -9.3211564144894474e+00 -2.1403608395474237e+01 -4.5071336492666035e+01
|
||||
14 -9.4170480596117798e+00 1.3082488091561686e+01 4.6355646706629088e+00
|
||||
15 2.2722879492421981e+01 -7.7075345088958080e+00 2.3305867532534780e+01
|
||||
16 -1.6645135391836931e+01 4.1502173593178441e+01 5.0575052872103598e+01
|
||||
17 1.7047633534423403e+02 1.4026539420267756e+02 2.7227233233590255e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-multi_harmonic.yaml
Normal file
86
unittest/force-styles/tests/dihedral-multi_harmonic.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral multi/harmonic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: multi/harmonic
|
||||
dihedral_coeff: ! |
|
||||
1 75 60 42 23 91
|
||||
2 45 20 75 52 24
|
||||
3 56 10 32 84 52
|
||||
4 23 80 61 83 74
|
||||
5 19 90 13 15 58
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 2854.98573165667
|
||||
init_stress: ! |2-
|
||||
1.5681915450818258e+02 1.8843677355938829e+02 -3.4525592806757135e+02 1.8730498639126836e+02 3.9598161309144100e+00 -4.8403883145099769e+01
|
||||
init_forces: ! |2
|
||||
1 1.3738709657144352e+02 -8.1922817594424572e+01 9.7075104799546850e+01
|
||||
2 -1.0659916463476705e+02 5.5046642545209522e+01 -5.2082847070338147e+01
|
||||
3 1.5886334395918402e+02 2.5338186929832096e+02 -1.6850515833682286e+02
|
||||
4 -9.5225444536502579e+01 -1.1265598934657196e+02 8.9698661383677717e+01
|
||||
5 -1.2852852144878329e+02 -9.0809475595387653e+01 -5.2501247333692461e+01
|
||||
6 4.9246759553241205e+01 -1.8277982378705346e+01 7.0990893782854002e+01
|
||||
7 7.4663926284829870e+01 8.0704027294328569e+01 -1.3258721042376479e+01
|
||||
8 -5.7664771790647706e+02 -5.3918019517298592e+02 1.5396929378643614e+02
|
||||
9 2.9901970531305994e+02 2.8758255690187787e+02 -1.3756295870594514e+02
|
||||
10 4.5524976502054687e+02 4.2063419413217622e+02 -1.3246733864751559e+02
|
||||
11 -8.1758898081829770e+01 -1.4048792663689201e+02 1.0573752188920433e+02
|
||||
12 1.3599907767871962e+01 -1.1383028650554325e+01 4.1418406115814665e+00
|
||||
13 -2.8222212138596170e+00 -6.4873062691689682e+00 -1.3615796627027152e+01
|
||||
14 -3.5095181390137633e+01 4.8835804416914783e+01 1.7364838648837505e+01
|
||||
15 3.4824444714752772e+01 -1.1789831526216862e+01 3.5626819378860084e+01
|
||||
16 -2.0052943268182560e+02 -1.3676403262886782e+02 -5.3118534908764730e+00
|
||||
17 4.3516327092523319e+00 3.5734912109474788e+00 7.0094697359617353e-01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 2849.07207400097
|
||||
run_stress: ! |2-
|
||||
1.6000445937817227e+02 1.9195362353354110e+02 -3.5195808291171227e+02 1.9139433603598457e+02 1.5540720550179767e+00 -4.9876733950141848e+01
|
||||
run_forces: ! |2
|
||||
1 1.3690524660841163e+02 -8.1763135128653829e+01 9.6470097213552307e+01
|
||||
2 -1.0625167472058520e+02 5.4933080224948007e+01 -5.1680471871853584e+01
|
||||
3 1.5673974552236709e+02 2.5097042976431126e+02 -1.6860187704443382e+02
|
||||
4 -9.5460708012333725e+01 -1.1311361496535775e+02 9.0478655531755578e+01
|
||||
5 -1.2825502974007455e+02 -9.0458764515265173e+01 -5.2676495841154534e+01
|
||||
6 6.3049547051303456e+01 -4.3984759358165917e+00 6.7752322411553308e+01
|
||||
7 7.2063814036924853e+01 7.7736010485627787e+01 -1.2790559661004870e+01
|
||||
8 -5.9873994171892593e+02 -5.6106760521575166e+02 1.6173242713877039e+02
|
||||
9 3.0322958895200122e+02 2.9158961031453970e+02 -1.4193327505162301e+02
|
||||
10 4.6742911058701714e+02 4.3476296748266782e+02 -1.3368162420202023e+02
|
||||
11 -8.2306796650785643e+01 -1.4192288611323806e+02 1.0746321420675316e+02
|
||||
12 1.3859227344215885e+01 -1.1441899351494421e+01 4.4569325586518920e+00
|
||||
13 -2.7707098933678509e+00 -6.4032868562592995e+00 -1.3395365036245792e+01
|
||||
14 -3.5084705415423898e+01 4.8852109825670325e+01 1.7330779402092446e+01
|
||||
15 3.4829566930810564e+01 -1.1798517720623494e+01 3.5597334528573512e+01
|
||||
16 -2.0666495176453031e+02 -1.4254747520758420e+02 -7.7166962667997083e+00
|
||||
17 7.4286708829750996e+00 6.0714529122795415e+00 1.1946019834330359e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-nharmonic.yaml
Normal file
86
unittest/force-styles/tests/dihedral-nharmonic.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral nharmonic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: nharmonic
|
||||
dihedral_coeff: ! |
|
||||
1 1 75
|
||||
2 2 75 42
|
||||
3 3 75 42 35
|
||||
4 4 75 42 35 21
|
||||
5 5 75 42 35 21 10
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 2981.00073511673
|
||||
init_stress: ! |2-
|
||||
9.7597564011001154e+01 5.1552482481468100e+00 -1.0275281225914760e+02 1.8493829126960399e+01 -2.0812476993720594e+01 -1.8522149185389509e+01
|
||||
init_forces: ! |2
|
||||
1 -2.2513291756353219e+01 4.7119202966322113e+00 7.8626223248943488e+00
|
||||
2 1.6503301622376316e+01 -8.5221244306678052e+00 8.0632802095482496e+00
|
||||
3 1.6036976766592576e+02 1.6287909459293988e+02 -7.5360356553197050e+01
|
||||
4 -5.5774232874990290e+01 -5.3058913648795475e+01 5.7643742847181294e+01
|
||||
5 -5.5693897474981654e+01 -4.6866567575987339e+01 -2.5012126373852766e+01
|
||||
6 -1.4807705653098827e+02 -1.7439629259562869e+02 4.3508953332564516e+01
|
||||
7 5.7230190824331977e+01 6.2118378860762746e+01 -1.0214660840095114e+01
|
||||
8 -4.9646451985301219e+01 -1.6916018705669373e+01 -4.3263724045252935e+01
|
||||
9 5.6208167529396206e+01 5.1711293643508995e+01 -2.5287150384768847e+01
|
||||
10 3.0991849000677316e+01 7.1919803329260148e+01 6.0749104476882920e+01
|
||||
11 4.5844405619977813e+01 -3.2881788637711445e+01 8.7606207362048369e+00
|
||||
12 1.1196936677514067e+01 -5.1163625458728184e+01 -5.6831813719102982e+01
|
||||
13 -5.9988298526181154e+00 -1.3789226131337799e+01 -2.8941334177588317e+01
|
||||
14 -4.7822307931026252e+01 6.6545912697330365e+01 2.3662127623898343e+01
|
||||
15 4.0718083591203595e+01 -1.3785125636399199e+01 4.1656250988047944e+01
|
||||
16 -2.7739760389786966e+01 -3.7464205631044081e+00 1.3938205295403176e+01
|
||||
17 -5.7968737353570745e+00 -4.7603000364046579e+00 -9.3374174076756766e-01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 2980.50579322915
|
||||
run_stress: ! |2-
|
||||
9.7895434490619337e+01 5.4213709524395828e+00 -1.0331680544305857e+02 1.8675877873066675e+01 -2.0991434453341569e+01 -1.8585983190992422e+01
|
||||
run_forces: ! |2
|
||||
1 -2.2591052968690096e+01 4.7210385354547846e+00 7.9294392105535936e+00
|
||||
2 1.6498095517116187e+01 -8.5356068598615717e+00 8.0720766878856693e+00
|
||||
3 1.6108997640769729e+02 1.6342942942760337e+02 -7.5708178587991824e+01
|
||||
4 -5.5915690600613786e+01 -5.3286178349242775e+01 5.7920314335763067e+01
|
||||
5 -5.5815960140690187e+01 -4.6852076880395700e+01 -2.5129655662229876e+01
|
||||
6 -1.4887539913047536e+02 -1.7507990917559269e+02 4.3681610088691990e+01
|
||||
7 5.7525784565224839e+01 6.2341547610308091e+01 -1.0221945594991276e+01
|
||||
8 -4.9834734857855565e+01 -1.7115522841200708e+01 -4.3399122618009173e+01
|
||||
9 5.6179010600229461e+01 5.1726594605296690e+01 -2.5317658955721360e+01
|
||||
10 3.1482397830029917e+01 7.2536730495593062e+01 6.0942772446916798e+01
|
||||
11 4.5792301818163743e+01 -3.2904155663801774e+01 8.8203497710706404e+00
|
||||
12 1.1154082762390011e+01 -5.1190045193979515e+01 -5.6802626362359284e+01
|
||||
13 -5.9632993131627696e+00 -1.3785699614683910e+01 -2.8834090735086761e+01
|
||||
14 -4.7767992294731812e+01 6.6549040073025040e+01 2.3624991066144862e+01
|
||||
15 4.0707922113447012e+01 -1.3798576461581593e+01 4.1602789182915110e+01
|
||||
16 -2.8021580173481375e+01 -4.1280758811589067e+00 1.3726590420250155e+01
|
||||
17 -5.6438621345975122e+00 -4.6285338257819220e+00 -9.0765469380235686e-01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-opls.yaml
Normal file
86
unittest/force-styles/tests/dihedral-opls.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral opls
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: opls
|
||||
dihedral_coeff: ! |
|
||||
1 75 60 42 23
|
||||
2 45 20 75 52
|
||||
3 56 10 32 84
|
||||
4 23 80 61 83
|
||||
5 19 90 13 15
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 2260.68345252858
|
||||
init_stress: ! |-
|
||||
-3.2511829957222659e+02 -2.5747791683620072e+01 3.5086609125584744e+02 -1.7284868467618747e+02 2.1513133474621105e+02 1.2517993158427078e+02
|
||||
init_forces: ! |2
|
||||
1 3.8418843300789013e+02 -2.0215855127626560e+02 1.9798867612265633e+02
|
||||
2 -2.9487545045054014e+02 1.5227045701458118e+02 -1.4407198258290703e+02
|
||||
3 -9.8281517150962827e+01 -1.6227125420394071e+02 -6.7942361484037406e+01
|
||||
4 1.0637245492200609e+02 1.3269987633301724e+02 -9.7489660444067837e+01
|
||||
5 -3.7665970146318045e+01 1.7971807362873875e+02 4.6710944552079511e+01
|
||||
6 1.1702706522755878e+02 8.6982608420528493e+01 3.1913126533391559e+01
|
||||
7 -7.7554238578063618e+01 -8.2420107806847682e+01 1.3489747654226816e+01
|
||||
8 9.1569783748212430e+00 -4.0548521525557376e+01 -1.0326672032405810e+01
|
||||
9 -1.7725494652391845e+02 -1.4026459257463597e+02 7.4192724911953562e+01
|
||||
10 -4.1110104786839429e+02 -2.5073752258808298e+02 -1.5153435376208625e+02
|
||||
11 2.5176689706800320e+02 6.4942280703724947e+01 -1.0152404897547778e+02
|
||||
12 5.0683700189254068e+01 5.3499935743815783e+01 1.5370438642303918e+02
|
||||
13 -9.3214628811766573e+00 -2.1426805343932180e+01 -4.4971365899031198e+01
|
||||
14 -3.2894997260227250e+01 4.5774194315657610e+01 1.6276203659637716e+01
|
||||
15 2.2596508786687970e+01 -7.6500582811265403e+00 2.3117144974751533e+01
|
||||
16 1.2469191655312414e+01 3.9926824651176759e+01 3.0718477775528918e+01
|
||||
17 1.8468840162806748e+02 1.5166316278914834e+02 2.9749012572748249e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 2256.24323239172
|
||||
run_stress: ! |-
|
||||
-3.2088111205783395e+02 -2.5173179880186485e+01 3.4605429193802195e+02 -1.7344996511494091e+02 2.1594264221200305e+02 1.2609209164416541e+02
|
||||
run_forces: ! |2
|
||||
1 3.8221543296352581e+02 -2.0141948919000066e+02 1.9557532679638945e+02
|
||||
2 -2.9287695305319323e+02 1.5117733528609159e+02 -1.4124998061827318e+02
|
||||
3 -9.6968901157768613e+01 -1.6021972846441955e+02 -7.1973012575105997e+01
|
||||
4 1.0455346745780875e+02 1.3193080713496886e+02 -9.4604433863044719e+01
|
||||
5 -3.6711061261645170e+01 1.7985412946903816e+02 4.6622409203885653e+01
|
||||
6 1.1487205026090723e+02 8.2985262131686909e+01 3.2425068981410632e+01
|
||||
7 -7.6158592387354744e+01 -8.0468484105613015e+01 1.3255468327869348e+01
|
||||
8 6.8336233635044792e+00 -4.1069837122711107e+01 -9.2791833285164600e+00
|
||||
9 -1.7541465338683531e+02 -1.3916262246574487e+02 7.2948347484376768e+01
|
||||
10 -4.1175393396497520e+02 -2.5092469444234629e+02 -1.5026151846272987e+02
|
||||
11 2.5362614760259910e+02 6.5949894447338195e+01 -1.0158950310115290e+02
|
||||
12 5.0514163619643369e+01 5.3693737562222708e+01 1.5397975467197989e+02
|
||||
13 -9.3356957620871128e+00 -2.1480978772005329e+01 -4.5135381377713500e+01
|
||||
14 -3.2924384373551227e+01 4.5813164716459632e+01 1.6248139979025197e+01
|
||||
15 2.2683225187118740e+01 -7.6931274678125519e+00 2.3250324273162178e+01
|
||||
16 1.0385303766648718e+01 3.7834438086310726e+01 2.9952789739539185e+01
|
||||
17 1.8646076112565459e+02 1.5320019319653665e+02 2.9835383868898358e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
86
unittest/force-styles/tests/dihedral-quadratic.yaml
Normal file
86
unittest/force-styles/tests/dihedral-quadratic.yaml
Normal file
@ -0,0 +1,86 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:38 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral quadratic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: quadratic
|
||||
dihedral_coeff: ! |
|
||||
1 75 80
|
||||
2 45 90
|
||||
3 25 100
|
||||
4 35 110
|
||||
5 85 120
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 6216.3143470666
|
||||
init_stress: ! |2-
|
||||
6.9779660668723466e+01 -3.5532909094858701e+02 2.8554943027986320e+02 -4.9195840209475091e+02 7.3625341259057109e+02 -5.7010808043243844e+02
|
||||
init_forces: ! |2
|
||||
1 4.2330351198219410e+02 -3.2157263606983582e+02 4.8778446156448956e+02
|
||||
2 -2.4731144590894337e+02 1.2770892536477226e+02 -1.2083288138468879e+02
|
||||
3 -7.8939273526109889e+02 7.0450732881259448e+00 -5.2024350705025233e+02
|
||||
4 1.1820902510544397e+02 -2.2739138675734630e+01 -1.7558731859455980e+02
|
||||
5 3.0369134495339995e+02 1.6621679527137749e+02 1.0950010087265598e+02
|
||||
6 5.3094552802676981e+02 4.1513822725059362e+02 1.6474930951841779e+02
|
||||
7 -2.2028979466774942e+02 -2.3907831487255675e+02 3.9312736084302557e+01
|
||||
8 7.8491627811935388e+01 1.9735852288549398e+02 -5.2192413944442262e+02
|
||||
9 -2.8367449741415754e+02 -2.8350394814708659e+02 1.3310271596792248e+02
|
||||
10 -4.8781250510817031e+01 -1.0212176931805116e+02 8.8424441377470021e+02
|
||||
11 2.0944884829071029e+01 2.1822885786540940e+02 -1.3815486499448144e+02
|
||||
12 3.8244902894578240e+02 -7.6125709989502195e+02 -5.1943097774583589e+02
|
||||
13 5.0397372105344857e+01 1.1584605289021295e+02 2.4314194994820485e+02
|
||||
14 -3.2177811487291126e+02 4.4776212748092655e+02 1.5921345393203961e+02
|
||||
15 -1.2952882986009081e+02 4.3852043998034915e+01 -1.3251324647326337e+02
|
||||
16 6.6046898428214291e+01 -6.3309698641791229e+01 -1.0303796344626588e+02
|
||||
17 6.6277446307612905e+01 5.4425979325130847e+01 1.0675757471036833e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 6196.72060735877
|
||||
run_stress: ! |2-
|
||||
7.0261972144691427e+01 -3.5373405634218659e+02 2.8347208419750029e+02 -4.8865483402926805e+02 7.2876073597774234e+02 -5.6606999011775088e+02
|
||||
run_forces: ! |2
|
||||
1 4.2048805036280135e+02 -3.2098883336228914e+02 4.8133144294258966e+02
|
||||
2 -2.4638508167332805e+02 1.2771427799183493e+02 -1.1845857169474056e+02
|
||||
3 -7.8090653128164217e+02 7.7347653120906923e+00 -5.1089110800733431e+02
|
||||
4 1.1828653714235912e+02 -2.3836151757910606e+01 -1.7502245420136003e+02
|
||||
5 3.0116800952549943e+02 1.6644824943256549e+02 1.0724428776328493e+02
|
||||
6 5.2331235440479884e+02 4.1190555250658440e+02 1.6106037061688073e+02
|
||||
7 -2.1738257230469571e+02 -2.3702803403246628e+02 3.9820689089564297e+01
|
||||
8 7.7945242814964388e+01 1.9436339870992802e+02 -5.1831375505772166e+02
|
||||
9 -2.8274735843011172e+02 -2.8181035502307088e+02 1.3037631882953369e+02
|
||||
10 -4.9156603181203891e+01 -9.9440732966891247e+01 8.8031773533285389e+02
|
||||
11 2.1802748924420044e+01 2.1742855576365230e+02 -1.3687149147206901e+02
|
||||
12 3.7798592499807688e+02 -7.6110435443270001e+02 -5.1897593040591187e+02
|
||||
13 4.9125595068401822e+01 1.1632903508964128e+02 2.4001894504147648e+02
|
||||
14 -3.1754978564411869e+02 4.4690923754437381e+02 1.6101841542472408e+02
|
||||
15 -1.2826093316555171e+02 4.3110002165735139e+01 -1.3123185051917795e+02
|
||||
16 6.5989015641509909e+01 -6.2103984719981298e+01 -1.0207004280125696e+02
|
||||
17 6.6285386797820053e+01 5.4369371778903684e+01 1.0646999118664509e+01
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
82
unittest/force-styles/tests/dihedral-zero.yaml
Normal file
82
unittest/force-styles/tests/dihedral-zero.yaml
Normal file
@ -0,0 +1,82 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 18:38:39 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
dihedral zero
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
dihedral_style: zero
|
||||
dihedral_coeff: ! |
|
||||
*
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 0
|
||||
init_stress: ! |2-
|
||||
0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
7 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
8 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
9 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
10 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 0
|
||||
run_stress: ! |2-
|
||||
0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
7 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
8 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
9 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
10 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
@ -1,7 +1,7 @@
|
||||
---
|
||||
lammps_version: 24 Aug 2020
|
||||
date_generated: Tue Sep 15 09:44:40 202
|
||||
epsilon: 4e-14
|
||||
epsilon: 5e-14
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
fix momentum
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
---
|
||||
lammps_version: 24 Aug 2020
|
||||
date_generated: Tue Sep 15 09:44:43 202
|
||||
epsilon: 2e-14
|
||||
epsilon: 3e-14
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
fix temp/csvr
|
||||
|
||||
84
unittest/force-styles/tests/improper-class2.yaml
Normal file
84
unittest/force-styles/tests/improper-class2.yaml
Normal file
@ -0,0 +1,84 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:14 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper class2
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: class2
|
||||
improper_coeff: ! |
|
||||
1 75.0 169
|
||||
2 45.0 10
|
||||
* aa 75 42 31 125.4 130.01 115.06
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 1375.73723669752
|
||||
init_stress: ! |-
|
||||
-1.7468868485439822e+02 -9.2086842555214787e+01 2.6677552740961301e+02 1.4938930562506283e+02 2.2947660920769948e+01 5.9390297771307900e+01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.8105909268304131e+01 -1.7448027996896207e+02 -1.1942909039947361e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 3.8384848080007407e+02 2.4743113398704139e+02 -6.2651869231333542e+01
|
||||
7 -1.7774406979068704e+02 -5.5990310445575943e+01 -6.1771623434942981e+01
|
||||
8 -1.1390550618440670e+02 -9.6594897230345566e+01 1.9743164026142125e+02
|
||||
9 -6.6272434058996311e+01 1.1515005775861550e+02 8.1891641120509050e+01
|
||||
10 -7.8205614976798818e+00 -3.5515704100773377e+01 -1.4295687967570640e+02
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 1374.65492729307
|
||||
run_stress: ! |-
|
||||
-1.7447800608448503e+02 -9.2290397546656749e+01 2.6676840363114184e+02 1.5021277934074519e+02 2.2884061959854989e+01 5.9138100588497707e+01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.7877127195851671e+01 -1.7485562042675718e+02 -1.2104329692939839e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 3.8368269756132827e+02 2.4785995896298414e+02 -6.2391528992069937e+01
|
||||
7 -1.7763823119536448e+02 -5.5958318518613538e+01 -6.1721057453874508e+01
|
||||
8 -1.1424566465431873e+02 -9.6849247974043806e+01 1.9733669735220542e+02
|
||||
9 -6.6225563148766426e+01 1.1510944978037821e+02 8.1848368493984395e+01
|
||||
10 -7.6961113670268748e+00 -3.5306221823947865e+01 -1.4296814970730554e+02
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-cossq.yaml
Normal file
83
unittest/force-styles/tests/improper-cossq.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:38:24 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper cossq
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: cossq
|
||||
improper_coeff: ! |
|
||||
1 75.0 120.2
|
||||
2 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 47.9012064519622
|
||||
init_stress: ! |-
|
||||
-4.5136832793911459e+01 -4.0792102522859011e+01 8.5928935316770463e+01 4.5396318866546366e+01 -1.0360009267990996e+01 2.9226619105197486e+01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 1.5572001864023761e+01 -8.5523301687707303e+00 3.6389919233505481e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -9.9783749351847923e+00 -8.2089544597829125e+00 -6.4006295980405298e+01
|
||||
7 1.9329901359391172e+01 -2.0093109058858744e+01 -1.4251303737688040e+01
|
||||
8 -2.4923528288230141e+01 3.6854393687412383e+01 4.1867680484587865e+01
|
||||
9 1.3969666290783055e+01 -9.0595563105928818e+00 1.5851381427541192e+01
|
||||
10 -1.3969666290783055e+01 9.0595563105928818e+00 -1.5851381427541192e+01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 47.8940525577889
|
||||
run_stress: ! |-
|
||||
-4.5134157244665538e+01 -4.0785439102386391e+01 8.5919596347051922e+01 4.5379718139339566e+01 -1.0358055502390599e+01 2.9188541576075529e+01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 1.5565271557423275e+01 -8.5443470803693895e+00 3.6386232031931790e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -9.9696439098796361e+00 -8.1933636544228481e+00 -6.3999211000100260e+01
|
||||
7 1.9327277770496639e+01 -2.0087061982273390e+01 -1.4244341309507911e+01
|
||||
8 -2.4922905418040280e+01 3.6824772717065628e+01 4.1857320277676386e+01
|
||||
9 1.3974042259259667e+01 -9.0786457408306251e+00 1.5847251171627661e+01
|
||||
10 -1.3974042259259667e+01 9.0786457408306251e+00 -1.5847251171627661e+01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-cvff.yaml
Normal file
83
unittest/force-styles/tests/improper-cvff.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:14 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper cvff
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: cvff
|
||||
improper_coeff: ! |
|
||||
1 75.0 -1 5
|
||||
2 45.0 +1 2
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 89.3326668855358
|
||||
init_stress: ! |2-
|
||||
6.3735186906797781e-01 5.1961496386521944e-01 -1.1569668329364793e+00 6.0239243426043387e-01 -3.1000536955332481e-01 -5.5270895482870697e-01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 2.8670207225427475e+00 3.0986561256939922e+00 -4.7143280681370925e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -6.0211065055074187e-01 -1.3523452665328648e+00 -3.9074689491948789e-01
|
||||
7 3.1857235094213934e+00 3.4440604439155891e+00 -5.5417013356316147e-01
|
||||
8 -2.0494336190966692e+01 -1.9987202220980407e+01 5.9716646066503358e+00
|
||||
9 7.4704052240849492e+00 7.2103972597448092e+00 -2.9798194738552723e+00
|
||||
10 7.5732973854683436e+00 7.5864336581588816e+00 -1.5754952974987049e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 89.3292146995311
|
||||
run_stress: ! |2-
|
||||
6.4099342941199167e-01 5.2185345018626172e-01 -1.1628468796005447e+00 6.0557206546498987e-01 -3.1107455425782704e-01 -5.5667330437418350e-01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 3.2086242062364363e+00 3.4667614839920589e+00 -5.2430001018683470e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -1.6257387255683398e+00 -2.4566238490662329e+00 -2.1669074891443074e-01
|
||||
7 3.5595931382690651e+00 3.8471494110538060e+00 -6.1949417285075015e-01
|
||||
8 -2.0283099241227319e+01 -1.9754544182200959e+01 5.9266840444229842e+00
|
||||
9 7.5154358978159550e+00 7.2557031439539230e+00 -2.9932893233552846e+00
|
||||
10 7.6251847244742024e+00 7.6415539922674043e+00 -1.5729097891156840e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-distance.yaml
Normal file
83
unittest/force-styles/tests/improper-distance.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:14 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper distance
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: distance
|
||||
improper_coeff: ! |
|
||||
1 75.0 120.2
|
||||
2 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 0.0747454910197192
|
||||
init_stress: ! |-
|
||||
-7.1626258371141380e-02 -6.6864359523888722e-02 -1.1321733383756704e-02 -6.9200372914993966e-02 2.8440344655334970e-02 2.7462143864170636e-02
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 9.2587063678939222e-02 1.0009514092855977e-01 -1.6105912924789512e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -1.2089773558102879e+00 -1.2010461236624599e+00 4.1596894802557804e-01
|
||||
7 1.0296888485071545e-01 1.1131884553687889e-01 -1.7911874807036772e-02
|
||||
8 2.6332581959317372e+00 2.5530903957220037e+00 -1.0280769141856356e+00
|
||||
9 -8.0758330134986755e-01 -7.7947530935740217e-01 3.2213144748348443e-01
|
||||
10 -8.1225348730123659e-01 -7.8398294916758027e-01 3.2399430640839921e-01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 0.0752844479361218
|
||||
run_stress: ! |-
|
||||
-7.2139939776107845e-02 -6.7406713268567800e-02 -1.1347012542302529e-02 -6.9728309368254873e-02 2.8565942982875535e-02 2.7592710278142397e-02
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 1.0288555683471934e-01 1.1120513018944293e-01 -1.7911068100772955e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -1.2439801426180097e+00 -1.2387390158824270e+00 4.2202889806762822e-01
|
||||
7 1.1424856855606622e-01 1.2348698234335116e-01 -1.9889224054167612e-02
|
||||
8 2.6509814064111206e+00 2.5720332669790174e+00 -1.0309531824160236e+00
|
||||
9 -8.0938056918098189e-01 -7.8139895473866405e-01 3.2229228506413127e-01
|
||||
10 -8.1475482000291433e-01 -7.8658740889072098e-01 3.2443229143920493e-01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-distharm.yaml
Normal file
83
unittest/force-styles/tests/improper-distharm.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:14 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper distharm
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: distharm
|
||||
improper_coeff: ! |
|
||||
1 75.0 5.5
|
||||
2 45.0 6.2
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 3973.60160543212
|
||||
init_stress: ! |2-
|
||||
1.1840727036793918e+01 1.1289853753674723e+01 1.7432289710119591e+00 1.1555189021102050e+01 -4.4774070829341710e+00 -4.3435896298765657e+00
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.7473337799460541e+02 -1.8890287044789150e+02 3.0395613158165197e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 6.9437218597542744e+02 7.3464844578309237e+02 -1.5190297358296280e+02
|
||||
7 -1.9432629530939255e+02 -2.1008461811218564e+02 3.3803884332082340e+01
|
||||
8 -5.7037248775573312e+02 -5.7219160312749318e+02 1.8545379406266761e+02
|
||||
9 1.2217671872491661e+02 1.1792434968032947e+02 -4.8734245972960537e+01
|
||||
10 1.2288325635938702e+02 1.1860629622414842e+02 -4.9016071996991819e+01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 3968.00170122936
|
||||
run_stress: ! |2-
|
||||
1.4455848528830730e+01 1.4061051246688471e+01 1.9392778677831757e+00 1.4242047809332975e+01 -5.1418231006541211e+00 -5.0085768779968713e+00
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.7482430199147572e+02 -1.8876843450710658e+02 3.0286687089759670e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 6.9441282586292846e+02 7.3371176726656495e+02 -1.5134496252786545e+02
|
||||
7 -1.9421569416493116e+02 -2.0970650033547753e+02 3.3646065736218624e+01
|
||||
8 -5.7051576044708054e+02 -5.7143770138676177e+02 1.8486636160758883e+02
|
||||
9 1.2210842195376864e+02 1.1765428146764884e+02 -4.8542997614082267e+01
|
||||
10 1.2303450878679030e+02 1.1854658749513212e+02 -4.8911154291619411e+01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-fourier.yaml
Normal file
83
unittest/force-styles/tests/improper-fourier.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper fourier
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: fourier
|
||||
improper_coeff: ! |
|
||||
1 75.0 0.9 0.2 0.3 1
|
||||
2 45.0 0.5 0.1 0.8 0
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 376.79153906023
|
||||
init_stress: ! |2-
|
||||
1.0624187547924073e+00 1.0206113657070901e+00 -2.0830301204995032e+00 1.0486115899411781e+00 -8.1208166417311556e-01 -8.4664058797741759e-01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -9.8391444288760999e-01 -1.0673132465389159e+00 1.7028327091432724e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.7963105161091494e+01 1.8053041435172950e+01 -4.6174995421006741e+00
|
||||
7 -1.0960561193757341e+00 -1.1844708233263612e+00 1.9458545204481797e-01
|
||||
8 -4.1759331079525076e+01 -4.1347011251431233e+01 1.3790137646614266e+01
|
||||
9 1.2719332702204108e+01 1.2533732960069898e+01 -5.9247184042288126e+00
|
||||
10 1.3156863778492818e+01 1.3012020926053667e+01 -3.6127884232439245e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 376.767592296021
|
||||
run_stress: ! |2-
|
||||
1.0819691800876623e+00 1.0419669360880310e+00 -2.1239361161756918e+00 1.0713168006483549e+00 -8.2631137022352130e-01 -8.5923448323782503e-01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.1367662402999945e+00 -1.2333572437388785e+00 1.9662545682687999e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.8583351068234631e+01 1.8715185769425609e+01 -4.7132198429265015e+00
|
||||
7 -1.2647698942333347e+00 -1.3662546204309729e+00 2.2529255947347671e-01
|
||||
8 -4.2287512224736716e+01 -4.1900310923507604e+01 1.3889016794364066e+01
|
||||
9 1.2824760088271818e+01 1.2644947834712323e+01 -5.9740050647587033e+00
|
||||
10 1.3280937202763594e+01 1.3139789183539529e+01 -3.6237099029792179e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-harmonic.yaml
Normal file
83
unittest/force-styles/tests/improper-harmonic.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper harmonic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: harmonic
|
||||
improper_coeff: ! |
|
||||
1 75.0 120.2
|
||||
2 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 369.340964796184
|
||||
init_stress: ! |2-
|
||||
4.2200353970159981e+00 3.7101799973801128e+00 -7.9302153943075808e+00 4.0937388495186724e+00 -1.9761982391039652e+00 -3.2729597741471910e+00
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.0477948676235974e+02 -1.1324494306933775e+02 1.7229204920731718e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 3.7989457613970035e+02 4.0678659525075454e+02 -6.6164267808209388e+01
|
||||
7 -1.1642694859483163e+02 -1.2586825161550951e+02 2.0252962148915685e+01
|
||||
8 -2.4087469265734444e+02 -2.4851124636626128e+02 5.3568634557991118e+01
|
||||
9 4.0812216407774713e+01 3.9391744426659102e+01 -1.6279309297840655e+01
|
||||
10 4.1374335467060746e+01 4.1446101373694887e+01 -8.6072245215884777e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 367.815769347681
|
||||
run_stress: ! |2-
|
||||
4.9041475165932553e+00 4.4679825636530310e+00 -9.3721300803182039e+00 4.8178760617236946e+00 -2.2166981793365235e+00 -3.5416380080536864e+00
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.0482614415683929e+02 -1.1320746446493285e+02 1.6386443655785115e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 3.7962195714568907e+02 4.0626725504279830e+02 -6.3749142171259109e+01
|
||||
7 -1.1622759345497252e+02 -1.2558388063592429e+02 2.0198325739038410e+01
|
||||
8 -2.4054487769196521e+02 -2.4809955664319341e+02 5.1543474184702063e+01
|
||||
9 4.0680827895392440e+01 3.9230443932044977e+01 -1.6173170322991950e+01
|
||||
10 4.1295830262695517e+01 4.1393202769207278e+01 -8.2059310852745284e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
84
unittest/force-styles/tests/improper-hybrid.yaml
Normal file
84
unittest/force-styles/tests/improper-hybrid.yaml
Normal file
@ -0,0 +1,84 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 20:50:39 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper harmonic
|
||||
improper umbrella
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: hybrid harmonic umbrella
|
||||
improper_coeff: ! |
|
||||
1 umbrella 75.0 120.2
|
||||
2 harmonic 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 154.104984286114
|
||||
init_stress: ! |2-
|
||||
3.5812398303195279e+00 2.9556506659556878e+00 -6.5368904962744523e+00 3.3989946629488741e+00 -1.7306448874103899e+00 -3.0544949874314882e+00
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -5.2700533802598715e-01 -5.6962783430288022e-01 8.8061897610235584e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 4.8219397236633263e+01 4.8285164511929111e+01 -1.0747638213349413e+01
|
||||
7 -5.8634607194216692e-01 -6.3233743629156669e-01 1.0383344595612556e-01
|
||||
8 -1.2929259770150057e+02 -1.2792104504168864e+02 3.5442276689212186e+01
|
||||
9 4.0812216407774713e+01 3.9391744426659102e+01 -1.6279309297840655e+01
|
||||
10 4.1374335467060746e+01 4.1446101373694887e+01 -8.6072245215884777e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 153.944034579107
|
||||
run_stress: ! |2-
|
||||
3.6531403476456785e+00 3.0213732444931751e+00 -6.6745135921400935e+00 3.4700902950870214e+00 -1.7529962884030181e+00 -3.1023752144878927e+00
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -6.4941210537619865e-01 -7.0149944148454779e-01 1.0740164906453588e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 4.8545243042483662e+01 4.8676978011046344e+01 -1.0613025311713429e+01
|
||||
7 -7.2155874473929338e-01 -7.7726240841103933e-01 1.2819678201933732e-01
|
||||
8 -1.2924287528593078e+02 -1.2796250108943184e+02 3.5027244361064206e+01
|
||||
9 4.0733850146077884e+01 3.9322136988774787e+01 -1.6232754109658686e+01
|
||||
10 4.1334752947484731e+01 4.1442147939506299e+01 -8.4170633707759634e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-inversion_harmonic.yaml
Normal file
83
unittest/force-styles/tests/improper-inversion_harmonic.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper inversion/harmonic
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: inversion/harmonic
|
||||
improper_coeff: ! |
|
||||
1 75.0 0.1
|
||||
2 45.0 1.0
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 0.352301150271594
|
||||
init_stress: ! |-
|
||||
-2.0258575599327061e-01 -1.7811780014253070e-01 3.8070355613579143e-01 -5.5279767824605708e-01 2.6080018124128801e-01 2.2225526588362821e-01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 3.4413547454876281e-01 3.7330079439129671e-01 -5.9551821804014762e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -6.3739983279198285e+00 -6.0934584293714114e+00 2.0039260400812213e+00
|
||||
7 3.8333655805108796e-01 4.1429603615837074e-01 -6.8062101489123866e-02
|
||||
8 1.4627595538566258e+01 1.4187714263990550e+01 -5.5778104590457476e+00
|
||||
9 -4.4960658258070012e+00 -4.3225204799384791e+00 2.0680155785480876e+00
|
||||
10 -4.4850034174392803e+00 -4.5593321852303257e+00 1.6334827637095772e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 0.353545934459527
|
||||
run_stress: ! |-
|
||||
-2.0321693754031284e-01 -1.7922721758319698e-01 3.8244415512349306e-01 -5.5486273508472495e-01 2.6112525268542269e-01 2.2234067034718155e-01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 3.9014332813152885e-01 4.2327140508149619e-01 -6.7539051541204195e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 -6.5255364896166164e+00 -6.2573839228988852e+00 2.0273465795604100e+00
|
||||
7 4.3399151919768653e-01 4.6893758346905956e-01 -7.7275277613397475e-02
|
||||
8 1.4691225330577421e+01 1.4258632722113326e+01 -5.5807433641165485e+00
|
||||
9 -4.4985056127326644e+00 -4.3264374066943745e+00 2.0661986223843822e+00
|
||||
10 -4.4913180755573556e+00 -4.5670203810706225e+00 1.6320124913263574e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-ring.yaml
Normal file
83
unittest/force-styles/tests/improper-ring.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper ring
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: ring
|
||||
improper_coeff: ! |
|
||||
1 75.0 120.2
|
||||
2 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 31535.2377170405
|
||||
init_stress: ! |-
|
||||
-1.7744033713230339e+04 1.8012468654826118e+03 1.5942786847747706e+04 9.7803086281804881e+03 -2.0937834320538430e+04 2.8406351733476626e+04
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 1.7217635864591148e+01 -1.7654643590530949e+01 -1.0323631100262270e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.5514430270979008e+04 -1.1833964695203202e+04 7.5404548607963734e+03
|
||||
7 -2.0346715672832374e+01 1.5237083750885695e+01 -2.1806116546599725e+01
|
||||
8 -9.9214622223763376e+02 -3.0515877728365367e+03 -2.1156754748395269e+03
|
||||
9 -1.2756197963298097e+04 2.0686953537230125e+04 1.5305219667798992e+04
|
||||
10 -1.7629570056350353e+03 -5.7989835093507400e+03 -2.0697869306108976e+04
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 22428.4452488262
|
||||
run_stress: ! |-
|
||||
-1.6326115243382674e+04 4.8102071032932008e+03 1.1515908140089472e+04 7.3331418747017933e+03 -2.3084241239771301e+04 2.9022908238937845e+04
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 1.6895843359114675e+01 -1.7678287512275894e+01 -1.1267164656438265e+01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.6033317778033499e+04 -1.1017014206433545e+04 1.0976709852924871e+04
|
||||
7 -2.0989908775549029e+01 1.5740619976601257e+01 -2.2519703415227681e+01
|
||||
8 -6.0494693524996796e+02 -4.0721523508558912e+03 -3.9360086774616957e+03
|
||||
9 -1.3496690912247876e+04 1.9654078370364114e+04 1.0900768028085979e+04
|
||||
10 -1.9275858651192229e+03 -4.5629741455390040e+03 -1.7907682335477486e+04
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-sqdistharm.yaml
Normal file
83
unittest/force-styles/tests/improper-sqdistharm.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper sqdistharm
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: sqdistharm
|
||||
improper_coeff: ! |
|
||||
1 75.0 5.5
|
||||
2 45.0 6.2
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 3997.62616072489
|
||||
init_stress: ! |2-
|
||||
8.8331084794471149e-01 8.2440317190202461e-01 1.3972148029707115e-01 8.5330491729171176e-01 -3.5090607165293775e-01 -3.3882109899026652e-01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.0184284349421904e+00 -1.1010149114857324e+00 1.7715995131012763e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.4526688812516666e+01 1.4396696002909508e+01 -5.0654832290218712e+00
|
||||
7 -1.1326251862776240e+00 -1.2244721145151010e+00 1.9702496117457491e-01
|
||||
8 -3.2369402362851083e+01 -3.1369091715714088e+01 1.2666477036621034e+01
|
||||
9 9.9680613577558290e+00 9.6211223009973672e+00 -3.9760926562137620e+00
|
||||
10 1.0025705813798401e+01 9.6767604378080474e+00 -3.9990860638701031e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 3997.61003372028
|
||||
run_stress: ! |2-
|
||||
8.9867618231995117e-01 8.3953557023913883e-01 1.4147031268478960e-01 8.6854554531065609e-01 -3.5603505602114510e-01 -3.4388329133386453e-01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -1.1691473811017943e+00 -1.2635696778456222e+00 2.0345273768978395e-01
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 1.5089575984014470e+01 1.4996327001938443e+01 -5.1759841256486734e+00
|
||||
7 -1.2983204496665137e+00 -1.4031749793422010e+00 2.2593118211867663e-01
|
||||
8 -3.2767054343771939e+01 -3.1777449992301968e+01 1.2769678270571790e+01
|
||||
9 1.0039076049105660e+01 9.6916924205303019e+00 -3.9982380731119491e+00
|
||||
10 1.0105870141420118e+01 9.7561752270210462e+00 -4.0248399916196274e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-umbrella.yaml
Normal file
83
unittest/force-styles/tests/improper-umbrella.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:35:15 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper umbrella
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: umbrella
|
||||
improper_coeff: ! |
|
||||
1 75.0 120.2
|
||||
2 45.0 59.5
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 120.517350302608
|
||||
init_stress: ! |2-
|
||||
2.1450057027702318e-01 2.0615370183731152e-01 -4.2065427211433370e-01 2.1056696695589994e-01 -1.6180636745642774e-01 -1.7032228908699515e-01
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -5.2700533802598715e-01 -5.6962783430288022e-01 8.8061897610235584e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 4.6316011413846114e+00 4.7333019972392645e+00 -1.0973617459579506e+00
|
||||
7 -5.8634607194216692e-01 -6.3233743629156669e-01 1.0383344595612556e-01
|
||||
8 -8.6744372319406793e+00 -8.6216790023095449e+00 2.8059456141128507e+00
|
||||
9 2.5345017125309544e+00 2.4975184151129270e+00 -1.1805815048127062e+00
|
||||
10 2.6216857879932691e+00 2.5928238605518015e+00 -7.1989770690855515e-01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 120.514295597906
|
||||
run_stress: ! |2-
|
||||
2.1714787012179959e-01 2.0917208550038957e-01 -4.2631995562218900e-01 2.1344346192068486e-01 -1.6315541446960830e-01 -1.7170717562954185e-01
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 -5.9277911840046704e-01 -6.4055100624086503e-01 9.8614815449870358e-02
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 4.8527203285046401e+00 4.9710539161058183e+00 -1.1321659447268115e+00
|
||||
7 -6.5856809087782398e-01 -7.0983267920957549e-01 1.1694708697603289e-01
|
||||
8 -8.7798595289958783e+00 -8.7350810314923404e+00 2.8208076433208200e+00
|
||||
9 2.5441791960303624e+00 2.5083240922953607e+00 -1.1841240316111015e+00
|
||||
10 2.6343072137391670e+00 2.6060867085416022e+00 -7.2007956940881002e-01
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
83
unittest/force-styles/tests/improper-zero.yaml
Normal file
83
unittest/force-styles/tests/improper-zero.yaml
Normal file
@ -0,0 +1,83 @@
|
||||
---
|
||||
lammps_version: 10 Feb 2021
|
||||
date_generated: Wed Feb 24 19:37:56 202
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
improper zero
|
||||
pre_commands: ! ""
|
||||
post_commands: ! ""
|
||||
input_file: in.fourmol
|
||||
improper_style: zero
|
||||
improper_coeff: ! |
|
||||
1
|
||||
2
|
||||
extract: ! ""
|
||||
natoms: 29
|
||||
init_energy: 0
|
||||
init_stress: ! |2-
|
||||
0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
init_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
7 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
8 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
9 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
10 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_energy: 0
|
||||
run_stress: ! |2-
|
||||
0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
run_forces: ! |2
|
||||
1 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
2 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
3 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
4 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
5 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
6 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
7 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
8 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
9 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
10 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
11 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
12 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
13 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
14 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
15 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
16 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
17 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
18 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
20 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
21 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
22 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
23 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
24 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
25 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
26 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00
|
||||
...
|
||||
@ -28,6 +28,3 @@ dihedral_style ${dihedral_style}
|
||||
improper_style ${improper_style}
|
||||
|
||||
read_data ${data_file}
|
||||
dihedral_coeff *
|
||||
improper_coeff *
|
||||
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
---
|
||||
lammps_version: 24 Aug 2020
|
||||
date_generated: Tue Sep 15 09:44:20 202
|
||||
epsilon: 1e-13
|
||||
epsilon: 2.5e-13
|
||||
prerequisites: ! |
|
||||
atom full
|
||||
pair tip4p/long
|
||||
|
||||
Reference in New Issue
Block a user