Wolfram Language Paclet Repository

Community-contributed installable additions to the Wolfram Language

Primary Navigation

    • Cloud & Deployment
    • Core Language & Structure
    • Data Manipulation & Analysis
    • Engineering Data & Computation
    • External Interfaces & Connections
    • Financial Data & Computation
    • Geographic Data & Computation
    • Geometry
    • Graphs & Networks
    • Higher Mathematical Computation
    • Images
    • Knowledge Representation & Natural Language
    • Machine Learning
    • Notebook Documents & Presentation
    • Scientific and Medical Data & Computation
    • Social, Cultural & Linguistic Data
    • Strings & Text
    • Symbolic & Numeric Computation
    • System Operation & Setup
    • Time-Related Computation
    • User Interface Construction
    • Visualization & Graphics
    • Random Paclet
    • Alphabetical List
  • Using Paclets
    • Get Started
    • Download Definition Notebook
  • Learn More about Wolfram Language

MaXrd

Guides

  • MaXrd – Mathematica X-ray diffraction package

Tech Notes

  • Applying crystal data
  • Basic computations
  • Computations on reflections
  • Formulas in crystallography
  • Importing crystal data
  • Quick guide to conditions
  • References
  • Symmetry calculations
  • The association structure of crystallographic data
  • Using the rotation options

Symbols

  • AttenuationCoefficient
  • BraggAngle
  • ConstructDomains
  • CrystalDensity
  • CrystalFormulaUnits
  • CrystalPlot
  • DarwinWidth
  • DistortStructure
  • DomainPlot
  • EmbedStructure
  • ExpandCrystal
  • ExportCrystalData
  • ExtinctionLength
  • FindPixelClusters
  • GetAtomCoordinates
  • GetAtomicScatteringFactors
  • GetCrystalMetric
  • GetElements
  • GetLatticeParameters
  • GetLaueClass
  • GetScatteringCrossSections
  • GetSymmetryData
  • GetSymmetryOperations
  • ImportCrystalData
  • InputCheck
  • InterplanarSpacing
  • MergeDomains
  • MergeSymmetryEquivalentReflections
  • MillerNotationToList
  • MillerNotationToString
  • ReciprocalImageCheck
  • ReciprocalSpaceSimulation
  • ReflectionList
  • RelatedFunctionsGraph
  • ResetCrystalData
  • ResizeStructure
  • SimulateDiffractionPattern
  • StructureFactor
  • StructureFactorTable
  • SymmetryEquivalentPositions
  • SymmetryEquivalentReflections
  • SymmetryEquivalentReflectionsQ
  • SynthesiseStructure
  • SystematicAbsentQ
  • ToStandardSetting
  • TransformAtomicDisplacementParameters
  • UnitCellTransformation
  • $CrystalData
  • $GroupSymbolRedirect
  • $LaueClasses
  • $MaXrdPath
  • $MaXrdVersion
  • $PeriodicTable
  • $PointGroups
  • $SpaceGroups
  • $TransformationMatrices
StianRamsnes`MaXrd`
EmbedStructure
​
EmbedStructure
[guestUnits,targetPositions,hostCrystal]
embeds
guestUnits
at
targetPositions
into
hostCrystal
.
​
Details and Options

Examples  
(12)
Basic Examples  
(4)
In this example we embed a single iron atom into Ice. Let use place it at
(0.5,0.5,0.5)
in the ice structure.
In[1]:=
EmbedStructure
[​​{"Fe"},​​{{0.5,0.5,0.5}},​​"Ice",​​"NewLabel""IronIce"​​]
Out[1]=
IronIce
We can use
CrystalPlot
to visualise the new structure:
In[2]:=
CrystalPlot
["IronIce",ViewPoint{0.0,-4.8,3.4}]
Out[2]=
Note that we have embedded iron into the asymmetric unit of Ice (consisting of five atoms). If we wanted to put it in an ice network/structure, we could have used
ExpandCrystal
on Ice beforehand.
​
In[1]:=
CrystalPlot
@
EmbedStructure
[​​{"GalliumArsenide"},{{0.75,0.75,0.75}},​​"Sodalite","NewLabel""DemoStructure"]
Out[1]=
​
In[1]:=
CrystalPlot

EmbedStructure
​​{"Fe","Tc","Ni"},{{1/2,1/2,1/2}},​​
ExpandCrystal
["Silicon",{3,3,3}],"NewLabel""DemoStructure",​​ViewPointLeft
Out[1]=
​
The units to be embedded can be placed according to coordinate patterns.
In[1]:=
CrystalPlot

EmbedStructure
​​{​​{x_,y_,z_}/;OddQ@IntegerPart[x+y]"Ni",​​{x_,y_,z_}/;True"Fe"​​},​​{{1/3,2/3,0.5}},​​
ExpandCrystal
["Ice",{5,4,1}],​​"NewLabel""AlternatingNickelIce",​​"UnitCellDisplay""None"
Out[1]=
Distortions and rotations can also be performed according to user specified conditions:
In[2]:=
CrystalPlot

EmbedStructure
​​{​​{x_,y_,z_}/;OddQ@IntegerPart[x+y]"Ni",​​{x_,y_,z_}/;True"Fe"​​},​​{{1/3,2/3,0.5}},​​
ExpandCrystal
["Ice",{5,4,1}],​​"NewLabel""AlternatingNickelIce",​​​​"Distortions"{​​{x_,y_,z_}/;x>1&&y>2{0,0,8}​​}​​,​​"UnitCellDisplay""None",​​ViewPoint{0.,-4.4,3.}
One can also supply discrete values to the permutation options ("Distortions", "Rotations") like this:
The permutation options can also be used to filter by entity label:
One can also make the distortions occur randomly, in addition to randomising the distortion amplitudes:

© 2025 Wolfram. All rights reserved.

  • Legal & Privacy Policy
  • Contact Us
  • WolframAlpha.com
  • WolframCloud.com