* Introduce NCMAT v5 which two updates for the format, both meant to
facilitate modelling of amorphous (i.e. non-crystalline) solids.
Firstly, Debye temperatures can now be specified directly in DYNINFO
sections of vdosdebye type, meaning that such sections can now also be
used in non-crystalline materials where DEBYETEMPERATURE sections are
disallowed. Secondly, a new optional STATEOFMATTER section can be used
to explicitly indicate the state of matter if needed. If STATEOFMATTER
is not specified, materials with crystal structure or vdos curves are
assumed to be solids, otherwise the state will be undefined. Amorphous
solids will currently get both inelastic and elastic physics determined
from the VDOS curves - with coherent components approximated via the
incoherent approximation.
* Improve HKL plane initialisation code to make it 200% faster (i.e. a
factor of 3 speedup)! This was mostly achieved by using our own custom
sin+cos implementations, which are much faster than the standard ones,
but with no impact on precision. As a result, the heuristics picking a
default dcutoff value were updated so that structures with more than 40
atoms per unit cell now defaults to dcutoff=0.2Aa, as opposed to
dcutoff=0.25Aa before (the default value for other materials remain
dcutoff=0.1Aa).
* Add ncrystal_hfg2ncmat script for convenient production of NCMAT files
for hydrogen rich amorphous materials, based on concept and data from
Romanelli et. al. (2021), https://dx.doi.org/10.1088/1361-648X/abfc13
* Add ncrystal_onlinedb2ncmat script for creating materials with crystal
structure taken from online databases (materialprojects.org or
Crystallography Open Database). The script also has options for copying
material dynamics from existing .ncmat files, and for verifying that
NCMAT files containing comments containing specific links to entries in
these databases, actually contain those structure (by overlaying Bragg
cross section curves). Internally the script uses the Python Materials
Genomics (pymatgen) Python module to access the online databases.
* Add ncrystal_verifyatompos script for verifying that the list of
ATOMPOSITIONS in an .ncmat file is consistent with the indicated
SPACEGROUP number. Internally the script uses the Atomic Simulation
Environment (ASE) Python module to handle the symmetries.
* Add 16 new amorphous materials. Most are created with the
ncrystal_hfg2ncmat script: Epoxy_Araldite506_C18H20O3 Kapton_C22H10N2O5
Nylon11_C11H21NO Nylon12_C12H23NO Nylon610_C16H30N2O2
Nylon66or6_C12H22N2O2 PEEK_C19H12O3 Polycarbonate_C16O3H14
Polyester_C10H8O4 Polylactide_C3H4O2 Polypropylene_C3H6 Polystyrene_C8H8
PVC_C2H3Cl Rubber_C5H8. The material Polyethylene_CH2.ncmat is not
created with the ncrystal_hfg2ncmat script (although it could have
been), but is instead based on phonon DOS curves provided by Kemal Ramic
from the ESS Spallation Physics group, (based on modelling with Phonopy,
VASP and OCLIMAX software). Finally, AcrylicGlass_C5O2H8.ncmat
(a.k.a. "Plexiglass" or "Lucite"), is based on a VDOS curve used in
ENDF/B-VIII.0 due to Petersen, et. al. (NCSU)., as it gave a slightly
better fit to experimental data.
* Add CaSiO3_sg2_Wollastonite.ncmat. The main motivation for adding this
is that our library should contain at least one triclinic material, to
make sure we exercise all code paths. For now, the material does not
have VDOS curves and the dynamics are described via the Debye model.
* Thanks to work by K. Ramic and J. I. Marquez Damian from the ESS
Spallation Physics group under the HighNESS EU project, a massive number
(64) of new crystalline materials are added to the data library, which
along with the 16 new amorphous materials brings the number of material
files shipped with NCrystal to a whooping total of 131! Additionally,
VDOS curves were added for 4 existing materials so that now only two
crystalline materials (gamma-calcium and wollastonite) in the entire
library have dynamics based purely on the less accurate Debye model. The
64 new crystalline materials are mostly polyatomic materials of interest
to the wider community of nuclear scientists, neutronics, and neutron
scattering instrumentation. All these materials come fully described
with both crystal structures and phonon VDOS curves, and have been
carefully validated. Crystal structures are mostly taken from the
Crystallography Open Database and the Materials Project, with most
structures verified by verification against multiple DB entries (using
the ncrystal_onlinedb2ncmat script). The VDOS curves are mostly based on
calculations with Phonopy and OCLIMAX software with input files from the
Phonon database at Kyoto university
(http://phonondb.mtl.kyoto-u.ac.jp/). VDOS curves for two materials,
magnesium hydride (MgH2) and magnesium deuteride (MgD2), were provided
by Davide Campi and Marco Bernasconi from University of Milano-Bicocca,
based on DFPT calculations with the Quantum-ESPRESSO package. All
materials were validated against total cross section curves where
available, VDOS curves were verified to be in agreement with
experimentally measured heat capacity curves, predicted material
densities were verified to be in accordance with known densities, and
crystal symmetries were verified with the ncrystal_verifyatompos script.
* Files for a few existing materials (SiLu2O5, UO2, SiO2) were renamed for
consistency, and Crystallography Open Database reference numbers were
added for all existing crystalline files.
* Fixed bug where some hkl planes slightly above the d-spacing cutoff were
left out of the final calculated list. Cubic, tetragonal, and
orthorombic space groups were not affected by this bug, and since our
default d-spacing cut off value is rather low, the effect was in any
case unlikely to have affected many users.
* Fixed bug where some hkl planes could very rarely be left out in
crystals containing elements with negative coherent scattering
lengths. It is not believed to be likely that this bug has affected any
users, but a few of the new materials would have been affected.
* Updated calcium scattering lengths due to improved measurements,
Palomino et al. (2019), DOI:10.1016/j.nima.2019.02.072. This was
implemented as a modification of b_coh for natural Ca and the dominant
isotope Ca40, increasing the values of both b_coh parameters by roughly
23%.
* NCrystal.directMultiCreate now works with NCrystal.TextData objects.
* Improve wrapping and indentation in code produced by the Python
formatVectorForNCMAT utility function.
* Add --stdout option to ncrystal_vdos2ncmat for easier usage in scripts.
* Small fix for NCMAT parser which previously allowed multiple entries in
DENSITY section.
* Add unofficial mechanism for removing certain contributions when
expanding a VDOS to a scattering kernel. This is primarily intended to
allow people working on plugins with detailed coherent physics to avoid
double-counting by making it possible to exclude components otherwise
created based on the incoherent approximation. The mechanism is
implemented via the CUSTOM_ support in NCMAT data, and it should be
understood that files with such sections are always considered "under
development", and unlikely to be suitable for general usage.
* Expose VDOS analysis utilities from NCVDOSEval.hh to Python and C
interfaces. In Python this is available both as a global analyseVDOS
function, and as a member function in DI_VDOS objects. Return value is a
dictionary with quantities derived from the VDOS curve: Debye
temperature, mean-squared-displacements, effective temperature, etc.
* Rename Python crossSectionNonOriented method to crossSectionIsotropic
for consistency, keeping crossSectionNonOriented as a backwards
compatible alias.
* Fix python NCrystal.atomDB method where some situations of querying for
unknown isotopes would always result in an exception even when called
with throwOnErrors=False (github issue 65).
* Type safe VDOSEval::elementMassAMU in C++.
* Conversion from shared_obj<T> to pointer T* in C++ is made explicit to
avoid footgun "const Info* info = NC::createInfo(..)". The footgun is
still available for references (const Info& info = ...), but that is a
necessary tradeoff since the implicit conversion to a reference is so
useful when passing shared objects to functions taking reference
parameters.