2024-02-28 10:34:39 +01:00
|
|
|
(** When an xyz file is read by =xyz_parser.mly=, it is converted into
|
|
|
|
* an ~xyz_file~ data structure. *)
|
2018-03-03 22:13:14 +01:00
|
|
|
|
2020-12-29 18:06:54 +01:00
|
|
|
|
2024-02-28 10:34:39 +01:00
|
|
|
(** Parser *)
|
2020-12-29 18:06:54 +01:00
|
|
|
|
2020-10-09 09:47:57 +02:00
|
|
|
open Common
|
2020-09-26 12:02:53 +02:00
|
|
|
|
2018-02-13 17:36:25 +01:00
|
|
|
type nucleus =
|
|
|
|
{
|
|
|
|
element: Element.t ;
|
2019-06-18 14:29:57 +02:00
|
|
|
coord : Coordinate.angstrom Coordinate.point;
|
2018-02-13 17:36:25 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
type xyz_file =
|
|
|
|
{
|
2018-03-03 22:13:14 +01:00
|
|
|
number_of_atoms : int ;
|
|
|
|
file_title : string ;
|
|
|
|
nuclei : nucleus list ;
|
2018-02-13 17:36:25 +01:00
|
|
|
}
|
2024-02-28 10:34:39 +01:00
|
|
|
|