Releases: Stianpr20/MaXrd
Releases · Stianpr20/MaXrd
4.0.0
Structural changes
- Point- and space group data have been distributed to single files for each group.
- Fractions that are added/subtracted with placeholder string symbols in
$SpaceGroups
are now operated on explicitly with thePlus
/Subtract
functions instead of the+
/-
operator in order to clear associated suggestion from the Wolfram linting, e.g.,1/2 + "x"
is replaced byPlus[1/2, "x"]
. - Placeholder symbols in
$SpaceGroups
and$TransformationMatrices
(a
,b
,c
,h
,k
,l
) are now stored as strings to avoid explicitly setting the context toGlobal`
. - Now using a
MaXrd.wl
file in stead ofDefinitions.nb
master notebook, and each function is defined in its designated file. - Converted paclet context with publisher ID to conform to Paclet Repository structure.
Miscellaneous
- For
FindPixelClusters
, changed the default setting of"PixelDataFile"
toFileNameJoin[{$MaXrdPath, "Kernel", "Data", "UserData", "PixelData.m"}]
. - Changed structure of optional second argument of
SymmetryEquivalentPositions
andExpandCrystal
. - For
ImportCrystalData
, renamed option"ExtractSubdata"
to"ExtractSubData"
. - Fixed a string concatenation bug in
UnitCellTransformation
. - Changed some local variable names to avoid confusion.
- Renamed various error message names and local variables to longer, more understandable names.
- Minor bug fixes and typo corrections.
3.1.0
- Added option
"ShowUnitVectorLabels"
toCrystalPlot
. - Fixed a bug with the
"HighlightReflections"
option ofReciprocalImageCheck
where it would not filter away symmetry equivalent reflections that were in a plane different form the viewing plane. - Minor documentation corrections and edits.
3.0.0
New content
- Created a
MergeDomains
function for conveniently stacking multiple domains. - Created the function
ResizeStructure
which can normalise the unit cell to the new dimensions after an embedding is completed, split the unit cell into sections, or translate the unit cell relative to its content. - Factorised new snippet
InputCheck["RecognizeFractions", _]
(updatedSymmetryEquivalentPositions
).
Improvements to space group database
- Reflection conditions added to
$SpaceGroups
. SystematicAbsentQ
updated to make use of"ReflectionConditions"
now stored in$SpaceGroups
."PermutableIndices"
added to the"Property"
association of relevant space groups, which will have values"Cyclically"
(numbers 195–206) orTrue
(numbers 207–230).
Improvements to DistortStructure
and EmbedStructure
- Changed
DistortStructure
to require a three-dimensional functional input instead. - New option
"ReturnConverter"
added toDistortStructure
. - Added new option
"DistortHost"
toEmbedStructure
. - Refactored the permutation options in
EmbedStructure
and enabled random sampling of discrete values. - Expanded the permutation options of
EmbedStructure
to accept conditions based on entity name.
Improvements to ReciprocalImageCheck
- New options
"HighlightReflections"
and"HighlightSymmetry"
added toReciprocalImageCheck
which are used to generate overlay of coloured disks indicating where the given reflections would be. "RoundPixels"
option ofReciprocalImageCheck
deprecated (alwaysTrue
).- Option
"ShowLattice"
ofReciprocalImageCheck
renamed to"LatticeSize"
with default valueNone
. - Option
"GridThickness"
added.
Improvements to ReciprocalSpaceSimulation
ReciprocalSpaceSimulation
now includes the option"StructureFactorThreshold"
to filter away weak reflections.ReciprocalSpaceSimulation
: added scaling of node radii by structure factor; option:"IntensityScaling"
.
Structural changes
- Deprecated
$MaXrdFunctions
since the same list can be obtained with?MaXrd`*
orNames["MaXrd`*"]
. - Mathematica code sections in documentation pages have been removed; all definitions are accessible in the main definition notebook (
MaXrd > Kernel > Definitions.nb
). - Loading
MaXrd
will initialize the symbolsa
,b
,c
,h
,k
,l
,\[Alpha]
,\[Beta]
, and\[Gamma]
on theGlobal`
context in the Wolfram Language session. - Removed the
Messages.m
file; usage messages now stored inDefinitions.nb
. - Deprecated
$MaXrdChangelog
(viewing theChangelog.md
file is simple enough).
Miscellaneous
- Snippet
InputCheck["CrystalQ", _]
now has a third Boolean option to control abortion. - Updated documentation pages for
SystematicAbsentQ
,StructureFactorTable
andDistortStructure
. - Option
"Threshold"
ofSystematicAbsentQ
deprecated. - Refactored code in
InputCheck
snippet"GetCentringVectors"
and added «reverse» setting"r"
. - Added another possible setting for the
"ExpandIntoNegative"
option inExpandCrystal
:"PlanarOnly"
, which will only use the negative directions of a and b. - Minor documentation improvements (
SynthesiseStructure
). - Fixed a bug in
SynthesiseStructure
by improvingInputCheck
snippet"RotationTransformation"
(anchors are now scalable with unit cell dimensions). - Attempts at plotting a single atom/element with
CrystalPlot
which are not present in$CrystalData
now gives an error and aborts the process. StructureFactor
now aborts if input crystal label is not recognized.- Fixed a bug where
SystematicAbsentQ
would fail if special positions were not given for a non-conventional space group setting.
2.5.0
New content
- Reintroduced
ReciprocalImageCheck
andFindPixelClusters
; now more efficiently integrated with MaXrd and more general purposed. - Created a
GetAtomCoordinates
function which works with crystal labels and crystal plots. - Changed the name of
EquivalentIsotropicADP
toTransformAtomicDisplacementParameters
and added a method for transforming atomic displacement parameters given a transformation matrix P. - Added
"AugmentedMatrix"
option toGetSymmetryOperations
;StructureFactor
,SystematicAbsentQ
andToStandardSetting
updated to comply with changes. - Added Boolean option
"IgnoreTranslations"
toGetSymmetryOperations
in order to simplify use withSymmetryEquivalentReflections
. - Added the Boolean option
"Radians"
toGetLatticeParameters
. - Added the Boolean option
"Bonds"
toCrystalPlot
along with configuration option"BondRadius"
. - Added the option
"AtomRadius"
toCrystalPlot
that can be used to set a fixed radius for all atoms. This takes precedence over"AtomRadiusType"
, but is ignored when it is set to a non-positive number. - Created
InputCheck["GetAtomData", _]
for querying atom data of crystals. - Added possibility to plot ellipsoids in
CrystalPlot
using stored ADPs.
Improvements and fixes
- Misspelling of SchoenfliesSymbol in
$SpaceGroup[[71]]
(thanks to ungerade). - Fixed a formatting bug on the
SynthesiseStructure
documentation page. - When using the signature of
SynthesiseStructure
expecting domain input, the map now recognises more general replacement commands (e.g._Integer -> "SomeEntity"
). - Merged
GetLatticeParameters
withGetCrystalMetric
, and refactored the latter. - Refactored
InputCheck["GetCentringVectors", _]
to also accept crystal entries and space group representations. - Refactored
SymmetryEquivalentPositions
andSymmetryEquivalentReflections
to use augmented matrix representations of symmetry operations. - Altered
InputCheck["GetCrystalSpaceGroup", _]
to accept space group entires and return them. - Updated
InputCheck["CrystalQ", _]
to also check for temporary crystal data. It now returns the crystal data as well.
Miscellaneous
- Minimised large documentation files by clearing large output cells.
- Removed
SynthesiseStructure::DomainPatternMismatch
error check; input blocks/supercells now replace a single domain cell, regardless of block size. - Wavelength values assume angstrom by default in the functions
AttenuationCoefficient
,BraggAngle
,DarwinWidth
,ExtinctionLength
,GetAtomicScatteringFactors
,GetScatteringCrossSections
,ImportCrystalData
,ReciprocalSpaceSimulation
,ReflectionList
,StructureFactor
andStructureFactorTable
; this is now made clear in the documentation pages (thanks to Sterling Baird (sgbaird)). - Changed the way essential data are initialised.
2.4.0
Improvements to SynthesiseStructure
- Creating single element (or void) unit cells now possible with
SynthesiseStructure[<chemical symbol>, _, _]
. - Added
"Shuffled"
as a possible setting to the"SelectionMethod"
option inSynthesiseStructure
. - Added Boolean option
"Padding"
toSynthesiseStructure
which utilises theInputCheck["PadDomain", _, _]
snippet. - Refactored
SynthesiseStructure
; when inputting a list of entities, an appropriate domain representation will be created and relayed to the function expecting a domain signature. "UsePlacementBuffer"
option ofSynthesiseStructure
deprecated;"Padding"
will now be used instead.- If a domain is not covered in the mapping from integers to entities in
SynthesiseStructure
, empty cells will now be used instead of throwing an error.
Improvements to EmbedStructure
- Enabled the possibility to embed in void (message
EmbedStructure::VoidHost
removed).
Improvements to space group database
- Removed entries such as
HermannMauguinFullAlt
in space groups with multiple origins. - For rhombohedral space groups, the note specifying obverse setting was moved to the alternative settings section.
- Regenerated
$GroupSymbolRedirect
. - Minor error corrections.
New InputCheck
snippets
- Added snippet
InputCheck["GenerateTargetPositions", _]
(currently used inConstructDomains
,DomainPlot
,EmbedStructure
,ExpandCrystal
andSynthesiseStructure
). - Added snippet
InputCheck["PadDomain", _, _]
. - Added snippets
InputCheck["ShallowDisplayCrystal", _]
(employed in:ImportCrystalData
,UnitCellTransformation
). - Added snippets
InputCheck["FilterSpecialLabels", _]
andInputCheck["HandleSpecialLabels", _]
for processing chemical element symbols and"Void"
. - Added snippet
InputCheck["CrystalEntityQ", _]
.
Miscellaneous
- Added the option
ImageDimensions
toSimulateDiffractionPattern
for specifying the width and height of the produced image (ExportCrystalData
andInputCheck["GetReciprocalImageOrientation", __]
also updated to comply with this change). - Appended a missing
_alt
to the CIF definition_space_group_name_H-M
in the list of space group search keys inImportCrystalData
. - Fixed errors in the
$GroupSymbolRedirect
data file (thanks to Tobias Hadamek for finding this). ImportCrystalData
now takes away tildes (~
) if they are present in the chemical formulas.- Fixed a bug where
GetScatteringCrossSections
would not work on Windows due to different line break implementations (thanks to Tobias Hadamek for discovering this). - An error is now given when attempting to use a chemical symbol or
"Void"
for the name a crystal to be imported from acif
file throughImportCrystalData
. CrystalPlot
will now plot empty structures without errors.- Demo file
DemoBlocksAB.m
removed (these structures will now be generated on demand). - Updated code part B.2 in
InputCheck["InterpretSpaceGroup", __]
to find origin choice automatically.
2.3.0
New content
- Option
"ShowProgress"
added toConstructDomain
. - Option
"AtomRadiusType"
added toCrystalPlot
. - Added the possibility to filter
"Host"
or"Guest"
atoms only with the"OpacityMap"
option ofCrystalPlot
. - Added another example to the
"SectorRegions"
inConstructDomains
. - Added a modulation example to the
DistortStructure
documentation. - Added the possibility for
ConstructDomains
to store and return the a complete collection of the states in every cycle, andDomainPlot
to present such a series.
Improvements and fixes
- Fixed broken hyperlinks in the See Also section in the documentation of
ExpandCrystal
andCrystalPlot
. - Fixed a bug where
ConstructDomains
would finish each iteration after only three cell visits. - Set a default Windows path for DIFFUSE in
SimulateDiffractionPackage
. - Altered
SimulateDiffractionPattern
to usediscus
throughdiscus_suite
. - Fixed a bug in
SimulateDiffractionPattern["DISCUS", _, _]
where the structure size would not be correctly assessed. - Fixed a bug where
"UnitCellAtomsCount"
would not be correctly updated when usingSynthesiseStructure
. - Default plot options for
CrystalPlot
in cases of trigonal or hexagonal systems have changed ViewPoint to{0, 0, Infinity}
and ViewAngle to90°
for more intuitive visual representations. - The use of
EmbedStructure
with guest and host parameters will now store a"Component"
key in the atom data. - Default/suggested paths for Linux added to the
"ProgramPaths"
option ofSimulateDiffractionPattern
. - Fixed a bug in
SimulateDiffractionPattern["DISCUS", _, _]
where the procedure would not halt despite missing the DISCUS program. - Fixed a bug with too long assembly list in
SynthesiseStructure
. ConstructDomains
now exits early if a single domain reaches complete domination.- Fixed an issue where
InputCheck["ProcessWavelength", _, _]
would not work as expected in combination withBraggAngle
. CrystalPlot
now exits more gracefully if the atom data list is empty.- AtomicMass was renamed to StandardAtomicWeight in
$PeriodicTable
and affected functions updated to comply with this change. - Minor documentation updates.
2.2.0
- Added the Boolean option
"IgnoreSymmetry"
toExpandCrystal
. - Fixed a bug in
SynthesiseStructure
that would occur if the input units did not have a Notes key. - Improved assembly performance of
SynthesiseStructure
. - Fixed bug encountered when using
SynthesiseStructure
with blocks not having size 1x1x1. - Swapped sections 1C and 1D in the internal code for
UnitCellTransformation
to avoid an error for crystals missing notes. - Added the Boolean option
"ReturnData"
toSimulateDiffractionPattern
. - Fixed a bug in
"RelatedFunctionsGraph"
. - Added twin example to the documentation pages of
ReciprocalSpaceSimulation
. - Added coordinate transformation example to the documentation pages of
GetCrystalMetric
. docbuild.xml
file updated to work with both macOS and Windows.- Updated references (
./Misc/References.bib
) README.md
file updated with a Functionality section.- Minor documentation updates.
2.1.1
- Added more examples to the
SimulateDiffractionPattern
documentation page. - When specifying a probability distribution of entities with
EmbedStructure
, the procedure now more closely fulfills that distribution instead of usingRandomChoice
. - Updated
ImportCrystalData
to use the data file in theUserData
directory by default (changed the"DataFile"
option). - Added
"DataFile"
option toEmbedStructure
andExpandCrystal
. - Factorised data file operations for
ImportCrystalData
,EmbedStructure
andExpandCrystal
into aInputCheck
snippet with label"Update$CrystalDataFile"
. - Minor updates in the documentation (
SimulateDiffractionPattern
,EmbedStructure
) and in the package unit test.
2.1.0
New content
- Added the option
"IncludeStructureSizeInfo"
toExportCrystalData
. - Added the option
"ScalingFactor"
toSimulateDiffractionPattern
.
Improvements and fixes
- Fixed a bug in
SimulateDiffractionPattern
where the use of DISCUS would not work correctly. - Created a
UserData
directory in the package root and movedCrystalData.m
here.$CrystalData
andResetCrystalData
updated to conform with this change. ImportCrystalData
now returns instead of aborting if user cancels import.- Improved the package unit test.
$MaXrdPath
updated with support for Windows.- Minor documentation updates.
2.0.0
Changes
InputCheck["DomainRotation"]
has been replaced withInputCheck["RotationTransformation"]
, which is more versatile (now used inDomainPlot
,EmbedStructure
andSynthesiseStructure
) and uses different rotation options ("RotationAnchorReference"
,"RotationAnchorShift"
,"RotationAxes"
).- Angular input parameters in
BraggAngle
,DomainPlot
,EmbedStructure
,ReflectionList
andSynthesiseStructure
are now expected to be in radians. This seems to be more universally adopted and makes it clearer when input is in degrees. "DISCUSPlot"
changed name toSimulateDiffractionPattern"
, as both"DISCUS"
and"DIFFUSE"
can now be used to generate simulations.- Edited
init.m
to print message in case of insufficient Mathematica version. InputCheck
declarations reorganised so snippet labels are always the first parameter (affected:"CrystalQ"
,"GetCentringVectors"
,"GetCrystalFormulaUnits"
,"GetCrystalSpaceGroup"
,"GetCrystalWavelength"
,"GetEnergyWavelength"
,"GetPointSpaceGroupCrystal"
,"InterpretElement"
,"InterpretSpaceGroup"
,"PointGroupQ"
,"PointSpaceGroupQ"
,"Polarisation"
).
New content
- Added functionality to
ConstructDomains
that simplifies creation of sector domains/regions. SynthesiseStructure
now has a designated routine for domains."OpacityMap"
option added toCrystalPlot
.- Created the tutorial Using the rotation options aimed at the usage of
DomainPlot
,EmbedStructure
andSynthesiseStructure
. ExportCrystalData
now supports a new format:"DIFFUSE"
.- Implemented
"DIFFUSE"
as an alternative method of producing simulated diffraction patterns (through Darren Goossens' ZMC program). - New snippet
"GetReciprocalImageOrientation"
added toInputCheck
. - Created the function
ResetCrystalData
.
Miscellaneous
DistortStructure
now checks the dimensions of input.- Fixed a bug where
GetCrystalMetric
had problems with lattice parameters expressed as quantities. - Interstitial defect example added to
DistortStructure
. - Minor documentation updates.
- Corrected misspelling of AsymmetricUnitCellCount in
ExpandCrystal
. - Option
"Flag"
inExportCrystalData
changed to"Detailed"
(now a Boolean type). EmbedStructure
now calculates the (mean) number of atoms per unit cell for the new structure.- Fixed a bug in
GetSymmetryData
where the label"Setting"
would not work as expected. - Renamed error message
GetElements::formula
toGetElements::InvalidFormula
and::invalid
to::InvalidElement
. - Error messages of
InputCheck
updated. - A unit test for the package has been written.
- Reorganised internal layout of the package.
- Documentation pages updated.