From 792f86dfbcedda5a1449f31acfa093bacf94f26b Mon Sep 17 00:00:00 2001 From: trisyoungs Date: Mon, 15 Apr 2024 12:34:50 +0100 Subject: [PATCH 1/4] Consistency between UI control and code. --- src/io/import/cif.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/io/import/cif.h b/src/io/import/cif.h index 7f0732ab83..9922a0cdf7 100644 --- a/src/io/import/cif.h +++ b/src/io/import/cif.h @@ -119,7 +119,7 @@ class CIFHandler // Bonding tolerance, if calculating bonding rather than using CIF definitions double bondingTolerance_{1.1}; // Whether to prevent metallic bonding - bool preventMetallicBonds_{false}; + bool preventMetallicBonds_{true}; // Whether to remove free atomic moieties in clean-up bool removeAtomics_{false}; // Whether to remove water and coordinated oxygen atoms in clean-up From 2777779f8dfd13feace0e4eb361b3981b7a751a9 Mon Sep 17 00:00:00 2001 From: Tristan Youngs Date: Mon, 15 Apr 2024 13:22:39 +0100 Subject: [PATCH 2/4] Copy box for supercell species. --- src/io/import/cif.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/io/import/cif.cpp b/src/io/import/cif.cpp index 33d3dd56ce..66e6b70c93 100644 --- a/src/io/import/cif.cpp +++ b/src/io/import/cif.cpp @@ -973,12 +973,14 @@ void CIFHandler::finalise(CoreData &coreData, const Flags &flags) c { auto *sp = coreData.addSpecies(); sp->copyBasic(&supercellSpecies_); - if (flags.isSet(OutputFlags::OutputFramework)) + if (flags.isSet(OutputFlags::OutputSupermolecule)) { sp->removePeriodicBonds(); sp->updateIntramolecularTerms(); sp->removeBox(); } + else + sp->createBox(supercellSpecies_.box()->axisLengths(), supercellSpecies_.box()->axisAngles()); if (flags.isSet(OutputFlags::OutputConfiguration)) { From 069f267a68b839bb43380df0640a96ed8a8d273e Mon Sep 17 00:00:00 2001 From: Tristan Youngs Date: Mon, 15 Apr 2024 13:26:05 +0100 Subject: [PATCH 3/4] Tweak UI. --- src/gui/importCIFDialog.ui | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/src/gui/importCIFDialog.ui b/src/gui/importCIFDialog.ui index 26ac27cd09..c85e18bbff 100644 --- a/src/gui/importCIFDialog.ui +++ b/src/gui/importCIFDialog.ui @@ -135,7 +135,7 @@ 0 0 - 162 + 292 639 @@ -392,8 +392,8 @@ 0 0 - 407 - 675 + 296 + 625 @@ -482,7 +482,7 @@ Remove any water molecules or coordinated oxygens without hydrogens - Remove water and coordinated oxygen + Remove water and coordinated oxygens @@ -598,8 +598,8 @@ 0 0 - 407 - 675 + 276 + 93 @@ -691,8 +691,8 @@ 0 0 - 407 - 675 + 96 + 78 @@ -728,6 +728,14 @@ + + + 0 + 0 + 96 + 78 + + :/general/icons/threeSpecies.svg:/general/icons/threeSpecies.svg @@ -757,6 +765,14 @@ + + + 0 + 0 + 167 + 142 + + :/general/icons/configuration.svg:/general/icons/configuration.svg From c3e4a34ad0dfece3e892591e6f00db621b76f751 Mon Sep 17 00:00:00 2001 From: Tristan Youngs Date: Mon, 15 Apr 2024 13:26:10 +0100 Subject: [PATCH 4/4] Update docs. --- web/docs/examples/cu-btc/step1.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web/docs/examples/cu-btc/step1.md b/web/docs/examples/cu-btc/step1.md index 1875915984..8ffec4118a 100644 --- a/web/docs/examples/cu-btc/step1.md +++ b/web/docs/examples/cu-btc/step1.md @@ -22,7 +22,7 @@ The default options get us most of the way there, but it's instructive to take a Before we proceed, make sure that the default Cu-BTC groups (`Global/Default`, `B/Default`, and `A/1`) are the only ones enabled. -Now, if you look closely at the crystal structure you'll see "extra" oxygen atoms attached to the copper sites: +Now, if you look closely at the crystal structure you'll see some oxygen atoms floating around in space... {{< cimage src="../cu-btc-default-zoom.png" caption="Dangling oxygens on Cu sites" >}} @@ -30,9 +30,9 @@ These are in fact from coordinated water molecules present when the crystal stru {{< action type="mouse" >}}Open the {{}} section{{< /action >}} -The _Structure Cleanup_ page has several options for cleaning up various aspects of the structure we currently have, for example removing free atoms/ions. We want to use the option to remove water molecules, which will also remove terminal oxygen atoms based on the assumption that hydrogen positions were not available in the CIF. So: +The _Structure Cleanup_ page has several options for cleaning up various aspects of the structure we currently have, for example removing free atoms/ions. There is a specific option for removing water molecules (_Remove water and coordinated oxygens_) which will also remove terminal oxygen atoms based on the assumption that hydrogen positions were not available in the CIF. Ours are just free atoms, however, so: -{{< action type="check" >}}Enable the _Remove water and coordinated oxygen_ option{{< /action >}} +{{< action type="check" >}}Enable the _Remove unbound atoms_ option{{< /action >}} You should see those terminal oxygen atoms disappear from the structure, leaving us with a "pure" Cu-BTC framework. There are a couple of pages left in the wizard which allow us to create a supercell from the unit cell,