add unit test

This commit is contained in:
Axel Kohlmeyer
2023-03-07 21:22:57 -05:00
parent 9a8b5ebae0
commit fc8a048662
3 changed files with 93 additions and 3 deletions

View File

@ -123,7 +123,7 @@ LAMMPS *init_lammps(int argc, char **argv, const TestConfig &cfg, const bool new
command("run 0 post no");
command("write_restart " + cfg.basename + ".restart");
command("write_data " + cfg.basename + ".data");
command("write_data " + cfg.basename + ".data nofix");
command("write_coeff " + cfg.basename + "-coeffs.in");
return lmp;

View File

@ -0,0 +1,90 @@
---
lammps_version: 8 Feb 2023
tags: generated
date_generated: Tue Mar 7 21:07:27 2023
epsilon: 2.5e-13
skip_tests: extract
prerequisites: ! |
atom full
bond harmonic/restrain
pre_commands: ! ""
post_commands: ! ""
input_file: in.fourmol
bond_style: harmonic/restrain
bond_coeff: ! |
1 250.0
2 300.0
3 350.0
4 650.0
5 450.0
equilibrium: 5 -1 -1 -1 -1 -1
extract: ! |
k 1
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.009384424442608962
run_stress: ! |2-
1.3334287184173488e+00 3.1110677999939773e-01 -1.4064657849540130e+00 2.6546279385354110e-01 1.5492956756466219e+00 7.2358876924785698e-01
run_forces: ! |2
1 1.1485941046856593e-01 1.4088049450172524e-01 -8.5852076971833030e-02
2 -9.3217481807658653e-02 -7.6867386712704044e-02 1.0932532178570745e-01
3 -2.3741413942894266e-01 -8.5667734110971339e-02 -8.2143831089792743e-02
4 2.3324188168788909e-01 -6.5094431822773302e-02 1.6591701889629748e-01
5 2.6793200848186677e-02 4.1227376782380774e-02 -1.3685685314886964e-01
6 2.4862628338772436e-01 -3.6125357500552457e-01 -7.8230634578348013e-01
7 -3.8706943762359766e-02 1.9888379369193138e-01 9.8933719851963053e-01
8 -3.5267248957722913e-01 4.2911503092501313e-01 1.0190469073820968e-01
9 -5.1632048293607458e-02 -5.5343430872859360e-02 -2.2821606693951479e-01
10 1.2860877826855494e-01 -7.5971599169706849e-01 -5.5343112593256227e-01
11 1.6956002318038377e-01 4.2001247662003161e-01 6.8896503378985918e-01
12 3.4231534762621078e-02 -2.4857235824638585e-01 -6.3964642589377518e-01
13 -2.7815178906130594e-01 1.0946454990993748e-01 5.1669158882660616e-03
14 2.2738751895410908e-01 -4.5437525741145839e-02 5.8956676893113813e-01
15 -4.6207378210972273e-03 1.6438094307388113e-01 5.8917445017986604e-02
16 -1.1399994473799732e-02 1.1329499720204761e-01 -5.0720152745025260e-01
17 -1.1549300733203431e-01 8.0692771502484495e-02 3.0655385964298520e-01
18 1.9145703373728828e+00 1.8373130373081787e+00 -3.9519344330792983e-01
19 -4.7317441908503255e-01 -3.0353033418925196e-01 -5.7175303978447201e-01
20 -1.4413959182878502e+00 -1.5337827031189268e+00 9.6694648309240183e-01
21 -3.3244533656237202e-01 -3.0309080808086836e-01 6.5775553694406208e-01
22 -2.9549353211149859e-01 -7.2150425050573716e-02 -4.6194669575592789e-01
23 6.2793886867387061e-01 3.7524123313144209e-01 -1.9580884118813421e-01
24 8.2698432709098157e-01 -1.4448474780063469e+00 1.2133188519739595e+00
25 -1.5417378702379472e+00 2.4470962384652978e-01 -1.2964818258023694e+00
26 7.1475354314696560e-01 1.2001378541598171e+00 8.3162973828409884e-02
27 2.1885007758012770e-01 -5.7423924185981945e-01 2.7745249319135684e-01
28 -5.2036258696458004e-01 2.2330647386191435e-01 -3.5136945845348061e-01
29 3.0151250938445234e-01 3.5093276799790507e-01 7.3916965262123782e-02
...