<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://chemwiki.ch.ic.ac.uk/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Aprabha</id>
	<title>ChemWiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://chemwiki.ch.ic.ac.uk/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Aprabha"/>
	<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/wiki/Special:Contributions/Aprabha"/>
	<updated>2026-04-06T17:10:44Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.0</generator>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=607360</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=607360"/>
		<updated>2017-03-21T12:52:42Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Not done) &lt;br /&gt;
| &lt;br /&gt;
| Becky (Not done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Not Done)&lt;br /&gt;
|-  &lt;br /&gt;
|&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn  (Done)&lt;br /&gt;
|-&lt;br /&gt;
|Mikkaila (Not done)&lt;br /&gt;
|Jin (Not done)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
|-&lt;br /&gt;
 |13th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
 |14th&lt;br /&gt;
 |15th&lt;br /&gt;
 |16th&lt;br /&gt;
 |17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot;  |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
Ken Away&lt;br /&gt;
|28th&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st March&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |5th&lt;br /&gt;
|-&lt;br /&gt;
|6th Mikkaila Away&lt;br /&gt;
|7th Mikkaila Away&lt;br /&gt;
|8th Mikkaila Away &lt;br /&gt;
|9th Mikkaila Away&lt;br /&gt;
|10th Mikkaila Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
|-&lt;br /&gt;
|13th&lt;br /&gt;
|14th&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
|28th&lt;br /&gt;
|29th&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Nukorn Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
 |&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st April&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |2nd&lt;br /&gt;
|-&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
|6th&lt;br /&gt;
|7th&lt;br /&gt;
Ken Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |9th&lt;br /&gt;
|-&lt;br /&gt;
|10th&lt;br /&gt;
Nukorn Away&lt;br /&gt;
|11th&lt;br /&gt;
Nukorn Away&lt;br /&gt;
|12th&lt;br /&gt;
COLLEGE CLOSURE START&lt;br /&gt;
|13th&lt;br /&gt;
&lt;br /&gt;
|14th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |16th&lt;br /&gt;
|-&lt;br /&gt;
|17th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|18th&lt;br /&gt;
COLLEGE CLOSURE END&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
|19th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away&lt;br /&gt;
|20th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|21st&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |23rd&lt;br /&gt;
|-&lt;br /&gt;
|24th&lt;br /&gt;
Becky away&lt;br /&gt;
|25th&lt;br /&gt;
Becky away&lt;br /&gt;
|26th&lt;br /&gt;
Becky away&lt;br /&gt;
|27th&lt;br /&gt;
Becky away&lt;br /&gt;
|28th&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot;|1st May&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
|-&lt;br /&gt;
|8th&lt;br /&gt;
|9th&lt;br /&gt;
|10th&lt;br /&gt;
|11th&lt;br /&gt;
|12th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
|-&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
|18th&lt;br /&gt;
|19th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
|-&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
|25th&lt;br /&gt;
|26th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
|-&lt;br /&gt;
|29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=602360</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=602360"/>
		<updated>2017-03-14T13:56:33Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Not done) &lt;br /&gt;
| &lt;br /&gt;
| Becky (Not done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn  (Done)&lt;br /&gt;
|-&lt;br /&gt;
|Mikkaila (Not done)&lt;br /&gt;
|Jin (Not done)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
|-&lt;br /&gt;
 |13th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
 |14th&lt;br /&gt;
 |15th&lt;br /&gt;
 |16th&lt;br /&gt;
 |17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot;  |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
Ken Away&lt;br /&gt;
|28th&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st March&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |5th&lt;br /&gt;
|-&lt;br /&gt;
|6th Mikkaila Away&lt;br /&gt;
|7th Mikkaila Away&lt;br /&gt;
|8th Mikkaila Away &lt;br /&gt;
|9th Mikkaila Away&lt;br /&gt;
|10th Mikkaila Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
|-&lt;br /&gt;
|13th&lt;br /&gt;
|14th&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
|28th&lt;br /&gt;
|29th&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Nukorn Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
 |&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st April&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |2nd&lt;br /&gt;
|-&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
|6th&lt;br /&gt;
|7th&lt;br /&gt;
Ken Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |9th&lt;br /&gt;
|-&lt;br /&gt;
|10th&lt;br /&gt;
Nukorn Away&lt;br /&gt;
|11th&lt;br /&gt;
Nukorn Away&lt;br /&gt;
|12th&lt;br /&gt;
COLLEGE CLOSURE START&lt;br /&gt;
|13th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
|14th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |16th&lt;br /&gt;
|-&lt;br /&gt;
|17th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|18th&lt;br /&gt;
COLLEGE CLOSURE END&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away&lt;br /&gt;
|19th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|20th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|21st&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |23rd&lt;br /&gt;
|-&lt;br /&gt;
|24th&lt;br /&gt;
Becky away&lt;br /&gt;
|25th&lt;br /&gt;
Becky away&lt;br /&gt;
|26th&lt;br /&gt;
Becky away&lt;br /&gt;
|27th&lt;br /&gt;
Becky away&lt;br /&gt;
|28th&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot;|1st May&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
|-&lt;br /&gt;
|8th&lt;br /&gt;
|9th&lt;br /&gt;
|10th&lt;br /&gt;
|11th&lt;br /&gt;
|12th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
|-&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
|18th&lt;br /&gt;
|19th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
|-&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
|25th&lt;br /&gt;
|26th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
|-&lt;br /&gt;
|29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=585084</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=585084"/>
		<updated>2017-02-20T10:54:34Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Not done) &lt;br /&gt;
| &lt;br /&gt;
| Becky (Not done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn (Not done)&lt;br /&gt;
|-&lt;br /&gt;
|Mikkaila (Not done)&lt;br /&gt;
|Jin (Not done)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
|-&lt;br /&gt;
 |13th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
 |14th&lt;br /&gt;
 |15th&lt;br /&gt;
 |16th&lt;br /&gt;
 |17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot;  |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
Ken Away&lt;br /&gt;
|28th&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st March&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |5th&lt;br /&gt;
|-&lt;br /&gt;
|6th Mikkaila Away&lt;br /&gt;
|7th Mikkaila Away&lt;br /&gt;
|8th Mikkaila Away &lt;br /&gt;
|9th Mikkaila Away&lt;br /&gt;
|10th Mikkaila Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
|-&lt;br /&gt;
|13th&lt;br /&gt;
|14th&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |19th&lt;br /&gt;
|-&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
|-&lt;br /&gt;
|27th&lt;br /&gt;
|28th&lt;br /&gt;
|29th&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
Ken Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
 |&lt;br /&gt;
   | style=&amp;quot;background: yellow;&amp;quot; |1st April&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |2nd&lt;br /&gt;
|-&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
|6th&lt;br /&gt;
|7th&lt;br /&gt;
Ken Away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |9th&lt;br /&gt;
|-&lt;br /&gt;
|10th&lt;br /&gt;
|11th&lt;br /&gt;
|12th&lt;br /&gt;
COLLEGE CLOSURE START&lt;br /&gt;
|13th&lt;br /&gt;
|14th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |16th&lt;br /&gt;
|-&lt;br /&gt;
|17th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|18th&lt;br /&gt;
COLLEGE CLOSURE END&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|19th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|20th&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|21st&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |23rd&lt;br /&gt;
|-&lt;br /&gt;
|24th&lt;br /&gt;
Becky away&lt;br /&gt;
|25th&lt;br /&gt;
Becky away&lt;br /&gt;
|26th&lt;br /&gt;
Becky away&lt;br /&gt;
|27th&lt;br /&gt;
Becky away&lt;br /&gt;
|28th&lt;br /&gt;
Becky away&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |&lt;br /&gt;
|-&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot;|1st May&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|2nd&lt;br /&gt;
|3rd&lt;br /&gt;
|4th&lt;br /&gt;
|5th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
|-&lt;br /&gt;
|8th&lt;br /&gt;
|9th&lt;br /&gt;
|10th&lt;br /&gt;
|11th&lt;br /&gt;
|12th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
|-&lt;br /&gt;
|15th&lt;br /&gt;
|16th&lt;br /&gt;
|17th&lt;br /&gt;
|18th&lt;br /&gt;
|19th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
|-&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
|24th&lt;br /&gt;
|25th&lt;br /&gt;
|26th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
|-&lt;br /&gt;
|29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
|30th&lt;br /&gt;
|31st&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=579437</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=579437"/>
		<updated>2017-01-30T16:29:07Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| &lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn (Done)&lt;br /&gt;
|-&lt;br /&gt;
|Mikkaila (Done)&lt;br /&gt;
|Jin (done)&lt;br /&gt;
|Shijia (Not done)&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
  |7th&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |12th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |13th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |14th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |15th&lt;br /&gt;
    | style=&amp;quot;background: yellow;&amp;quot; |16th End of term&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |19th&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia at a conference&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
  |20th&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
  |21st&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  |22nd&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
  |23rd&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |24th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |26th College closure&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |27th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |28th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |29th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot;|31st&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot; |1st January&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot;|2nd&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot;|3rd&lt;br /&gt;
|4th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
|5th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
|6th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot; |9th Term starts&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |10th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |11th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |12th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |13th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
  |16th &lt;br /&gt;
  |17th&lt;br /&gt;
  |18th&lt;br /&gt;
  |19th&lt;br /&gt;
  |20th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 |23rd&lt;br /&gt;
 |24th&lt;br /&gt;
 |25th&lt;br /&gt;
 |26th&lt;br /&gt;
 |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |30th&lt;br /&gt;
  |31st&lt;br /&gt;
 | style=&amp;quot;background: yellow;&amp;quot;  |1st February&lt;br /&gt;
  |2nd&lt;br /&gt;
  |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |5th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 |6th&lt;br /&gt;
 |7th&lt;br /&gt;
 |8th&lt;br /&gt;
 |9th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
 |10th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 |13th&lt;br /&gt;
Aiswarya away&lt;br /&gt;
 |14th&lt;br /&gt;
 |15th&lt;br /&gt;
 |16th&lt;br /&gt;
 |17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot;  |19th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=573290</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=573290"/>
		<updated>2016-12-13T10:46:34Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| &lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn (Done)&lt;br /&gt;
|-&lt;br /&gt;
|Mikkaila (Done)&lt;br /&gt;
|Jin (done)&lt;br /&gt;
|Shijia (Not done)&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
  |7th&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |12th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |13th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |14th&lt;br /&gt;
Richard Away&lt;br /&gt;
  |15th&lt;br /&gt;
    | style=&amp;quot;background: yellow;&amp;quot; |16th End of term&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |19th&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia at a conference&lt;br /&gt;
  |20th&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
  |21st&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  |22nd&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  |23rd&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Mikkaila Away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Lennart away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |24th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |25th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |26th College closure&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |27th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |28th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |29th&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot;|31st&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot; |1st January&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot;|2nd&lt;br /&gt;
 | style=&amp;quot;background: red;&amp;quot;|3rd&lt;br /&gt;
|4th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
|5th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
|6th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
&lt;br /&gt;
Nukorn away&lt;br /&gt;
&lt;br /&gt;
Jin away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
  | style=&amp;quot;background: yellow;&amp;quot; |9th Term starts&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |10th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |11th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |12th&lt;br /&gt;
Jin away (exams)&lt;br /&gt;
 |13th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
  |16th &lt;br /&gt;
  |17th&lt;br /&gt;
  |18th&lt;br /&gt;
  |19th&lt;br /&gt;
  |20th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 |23rd&lt;br /&gt;
 |24th&lt;br /&gt;
 |25th&lt;br /&gt;
 |26th&lt;br /&gt;
 |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |30th&lt;br /&gt;
  |31st&lt;br /&gt;
 | style=&amp;quot;background: yellow;&amp;quot;  |1st February&lt;br /&gt;
  |2nd&lt;br /&gt;
  |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |5th&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 |6th&lt;br /&gt;
 |7th&lt;br /&gt;
 |8th&lt;br /&gt;
 |9th&lt;br /&gt;
 |10th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 |13th&lt;br /&gt;
 |14th&lt;br /&gt;
 |15th&lt;br /&gt;
 |16th&lt;br /&gt;
 |17th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
   | style=&amp;quot;background: grey;&amp;quot;  |19th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=563670</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=563670"/>
		<updated>2016-11-10T11:33:24Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Emily (Done)&lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|Anil Bijoy (Done)&lt;br /&gt;
| Lennart Frankemoelle (not done)&lt;br /&gt;
|Nukorn (Not done)&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |22nd&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Tricia wk home&lt;br /&gt;
  |23rd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |24th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |25th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |26th&lt;br /&gt;
Ken Away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: green;&amp;quot;  |29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
  |30th&lt;br /&gt;
Emily away&lt;br /&gt;
  |31st&lt;br /&gt;
Emily away&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |1st SEPTEMBER&lt;br /&gt;
Emily away&lt;br /&gt;
  |2nd&lt;br /&gt;
Emily away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
&lt;br /&gt;
Ken away&lt;br /&gt;
  |6th&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |7th&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  | 12th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |13th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |14th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |15th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
&lt;br /&gt;
Richard F Away&lt;br /&gt;
 |style=&amp;quot;background: pink;&amp;quot; |16th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
|-&lt;br /&gt;
|19th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|20th&lt;br /&gt;
Becky away&lt;br /&gt;
|21st&lt;br /&gt;
Becky away&lt;br /&gt;
|22nd&lt;br /&gt;
Becky away&lt;br /&gt;
|23rd&lt;br /&gt;
Becky away&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|24th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|25th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|26th&lt;br /&gt;
Tricia Holiday-away&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|27th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|28th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|29th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|30th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
&lt;br /&gt;
Becky away&lt;br /&gt;
| style=&amp;quot;background: yellow;&amp;quot;|1st OCTOBER&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|2nd&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
  |3rd&lt;br /&gt;
  |4th&lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
  |7th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |8th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |9th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot;|10th&lt;br /&gt;
  |style=&amp;quot;background: pink;&amp;quot;|11th&lt;br /&gt;
 |style=&amp;quot;background: pink;&amp;quot; |12th&lt;br /&gt;
Richard Away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |13th&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |14th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |15th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |16th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |17th&lt;br /&gt;
  |18th&lt;br /&gt;
  |19th&lt;br /&gt;
Richard Away&lt;br /&gt;
  | 20th&lt;br /&gt;
&lt;br /&gt;
  | 21th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |22nd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |23rd&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; | 24th&lt;br /&gt;
&lt;br /&gt;
| style=&amp;quot;background: pink;&amp;quot; | 25th&lt;br /&gt;
&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; |26th&lt;br /&gt;
&lt;br /&gt;
| style=&amp;quot;background: pink;&amp;quot; | 27th&lt;br /&gt;
&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; | 28th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |29th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 |-&lt;br /&gt;
 ||31st NOVEMBER&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |1st NOVEMBER&lt;br /&gt;
  |2nd &lt;br /&gt;
Richard Away&lt;br /&gt;
  |3rd &lt;br /&gt;
  |4th &lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558073</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558073"/>
		<updated>2016-08-06T00:48:40Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Emily (Done)&lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|Anil Bijoy (Done)&lt;br /&gt;
| &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |25th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
  |26th&lt;br /&gt;
  |27th&lt;br /&gt;
  |28th&lt;br /&gt;
  |29th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |31st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot;|1st AUGUST&lt;br /&gt;
Tricia Holiday-local&lt;br /&gt;
  |style=&amp;quot;background: pink;&amp;quot;|2nd&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
 |style=&amp;quot;background: pink;&amp;quot; |3rd&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |4th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |5th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |8th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
Aiswarya Away&lt;br /&gt;
  |9th&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
Aiswarya Away&lt;br /&gt;
  |10th&lt;br /&gt;
Richard Away&lt;br /&gt;
  | 11th&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
  | 12th&lt;br /&gt;
Richard Away&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; | 15th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
&lt;br /&gt;
| style=&amp;quot;background: pink;&amp;quot; | 16th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; |17th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
&lt;br /&gt;
| style=&amp;quot;background: pink;&amp;quot; | 18th&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
&lt;br /&gt;
 | style=&amp;quot;background: pink;&amp;quot; | 19th&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Tricia Gord. Conf&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |22nd&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
Tricia wk home&lt;br /&gt;
  |23rd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |24th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |25th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |26th&lt;br /&gt;
Ken Away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: green;&amp;quot;  |29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
  |30th&lt;br /&gt;
Emily away&lt;br /&gt;
  |31st&lt;br /&gt;
Emily away&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |1st SEPTEMBER&lt;br /&gt;
Emily away&lt;br /&gt;
  |2nd&lt;br /&gt;
Emily away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
  |6th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |7th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |8th&lt;br /&gt;
Becky away&lt;br /&gt;
  |9th&lt;br /&gt;
Becky away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  | 12th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |13th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |14th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;  |15th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
 |style=&amp;quot;background: pink;&amp;quot; |16th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
Tricia EMLG Conf&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
|-&lt;br /&gt;
|19th&lt;br /&gt;
Tricia wk home&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|24th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|25th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|-&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|26th&lt;br /&gt;
Tricia Holiday-away&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|27th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|28th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|29th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
|style=&amp;quot;background: pink;&amp;quot;|30th&lt;br /&gt;
Tricia Holiday&lt;br /&gt;
| style=&amp;quot;background: yellow;&amp;quot;|1st OCTOBER&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|2nd&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558025</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558025"/>
		<updated>2016-07-25T14:24:25Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Not done) &lt;br /&gt;
| Emily (Done)&lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|Anil Bijoy (Done)&lt;br /&gt;
| &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |25th&lt;br /&gt;
  |26th&lt;br /&gt;
  |27th&lt;br /&gt;
  |28th&lt;br /&gt;
  |29th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |31st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot;|1st AUGUST&lt;br /&gt;
  |2nd&lt;br /&gt;
  |3rd&lt;br /&gt;
  |4th&lt;br /&gt;
  |5th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  |10th&lt;br /&gt;
  | 11th&lt;br /&gt;
&lt;br /&gt;
  | 12th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  | 15th&lt;br /&gt;
&lt;br /&gt;
  | 16th&lt;br /&gt;
&lt;br /&gt;
  |17th&lt;br /&gt;
&lt;br /&gt;
  | 18th&lt;br /&gt;
&lt;br /&gt;
  | 19th&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |22nd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |23rd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |24th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |25th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |26th&lt;br /&gt;
Ken Away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: green;&amp;quot;  |29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
  |30th&lt;br /&gt;
Emily away&lt;br /&gt;
  |31st&lt;br /&gt;
Emily away&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |1st SEPTEMBER&lt;br /&gt;
Emily away&lt;br /&gt;
  |2nd&lt;br /&gt;
Emily away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |7th&lt;br /&gt;
Becky away&lt;br /&gt;
&lt;br /&gt;
Aiswarya away (Conference)&lt;br /&gt;
  |8th&lt;br /&gt;
Becky away&lt;br /&gt;
  |9th&lt;br /&gt;
Becky away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  | 12th&lt;br /&gt;
Becky away&lt;br /&gt;
  |13th&lt;br /&gt;
Becky away&lt;br /&gt;
  |14th&lt;br /&gt;
Becky away&lt;br /&gt;
  |15th&lt;br /&gt;
Becky away&lt;br /&gt;
  |16th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
|-&lt;br /&gt;
|19th&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|24th&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|25th&lt;br /&gt;
|-&lt;br /&gt;
|26th&lt;br /&gt;
|27th&lt;br /&gt;
|28th&lt;br /&gt;
|29th&lt;br /&gt;
|30th&lt;br /&gt;
| style=&amp;quot;background: yellow;&amp;quot;|1st OCTOBER&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|2nd&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558024</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558024"/>
		<updated>2016-07-25T14:22:10Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Not done) &lt;br /&gt;
| Emily (Done)&lt;br /&gt;
| Becky (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Richard (Not done)&lt;br /&gt;
| Ken (Done)&lt;br /&gt;
| Aiswarya (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|Anil Bijoy (Done)&lt;br /&gt;
| &lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |25th&lt;br /&gt;
  |26th&lt;br /&gt;
  |27th&lt;br /&gt;
  |28th&lt;br /&gt;
  |29th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |31st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot;|1st AUGUST&lt;br /&gt;
  |2nd&lt;br /&gt;
  |3rd&lt;br /&gt;
  |4th&lt;br /&gt;
  |5th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |6th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |7th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  |10th&lt;br /&gt;
  | 11th&lt;br /&gt;
&lt;br /&gt;
  | 12th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |14th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  | 15th&lt;br /&gt;
&lt;br /&gt;
  | 16th&lt;br /&gt;
&lt;br /&gt;
  |17th&lt;br /&gt;
&lt;br /&gt;
  | 18th&lt;br /&gt;
&lt;br /&gt;
  | 19th&lt;br /&gt;
Ken Away&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |21st&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |22nd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |23rd&lt;br /&gt;
Ken Away&lt;br /&gt;
  |24th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |25th&lt;br /&gt;
Ken Away&lt;br /&gt;
  |26th&lt;br /&gt;
Ken Away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |28th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
 | style=&amp;quot;background: green;&amp;quot;  |29th&lt;br /&gt;
BANK HOLIDAY&lt;br /&gt;
  |30th&lt;br /&gt;
Emily away&lt;br /&gt;
  |31st&lt;br /&gt;
Emily away&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |1st SEPTEMBER&lt;br /&gt;
Emily away&lt;br /&gt;
  |2nd&lt;br /&gt;
Emily away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |3rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |4th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |5th&lt;br /&gt;
  |6th&lt;br /&gt;
Becky away&lt;br /&gt;
  |7th&lt;br /&gt;
Becky away&lt;br /&gt;
  |8th&lt;br /&gt;
Becky away&lt;br /&gt;
  |9th&lt;br /&gt;
Becky away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |11th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  | 12th&lt;br /&gt;
Becky away&lt;br /&gt;
  |13th&lt;br /&gt;
Becky away&lt;br /&gt;
  |14th&lt;br /&gt;
Becky away&lt;br /&gt;
  |15th&lt;br /&gt;
Becky away&lt;br /&gt;
  |16th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |18th&lt;br /&gt;
|-&lt;br /&gt;
|19th&lt;br /&gt;
|20th&lt;br /&gt;
|21st&lt;br /&gt;
|22nd&lt;br /&gt;
|23rd&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|24th&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|25th&lt;br /&gt;
|-&lt;br /&gt;
|26th&lt;br /&gt;
|27th&lt;br /&gt;
|28th&lt;br /&gt;
|29th&lt;br /&gt;
|30th&lt;br /&gt;
| style=&amp;quot;background: yellow;&amp;quot;|1st OCTOBER&lt;br /&gt;
| style=&amp;quot;background: grey;&amp;quot;|2nd&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558008</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=558008"/>
		<updated>2016-06-27T10:07:35Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-  &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Jan Szopinski (Done)&lt;br /&gt;
| Aimee Darke (Done)&lt;br /&gt;
|-  &lt;br /&gt;
| Vincent Chen (Not Done)&lt;br /&gt;
| Ken Watson (Done)&lt;br /&gt;
| Rebecca Rowe (Done)&lt;br /&gt;
|-  &lt;br /&gt;
|Anil Bijoy (Done)&lt;br /&gt;
| Richard Fogarty (Done)&lt;br /&gt;
|Aiswarya Prabha&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
Everyone should be away during the college closure dates, so you don&#039;t need to add your name on those days&lt;br /&gt;
&lt;br /&gt;
Tricia maybe: Tricia may or may-not be in college i.e. working from home&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;width: 100%&amp;quot;  &lt;br /&gt;
  !Mon&lt;br /&gt;
  !Tue&lt;br /&gt;
  !Wed&lt;br /&gt;
  !Thur&lt;br /&gt;
  !Fri&lt;br /&gt;
  !Sat&lt;br /&gt;
  !Sun&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |7th March&lt;br /&gt;
  |8th&lt;br /&gt;
  |9th&lt;br /&gt;
  |10th&lt;br /&gt;
  |11th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |12th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |13th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |14th&lt;br /&gt;
  |15th&lt;br /&gt;
  |16th&lt;br /&gt;
  |17th&lt;br /&gt;
  |18th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |19th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |20th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |21st&lt;br /&gt;
  |22nd&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |23rd Last day of easter term&lt;br /&gt;
Jan away&lt;br /&gt;
&lt;br /&gt;
Ken at Burlington House&lt;br /&gt;
&lt;br /&gt;
Richard at Burlington House&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |24th College Closure Start&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |25th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |26th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |27th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |28th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |29th&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |30th College Closure End&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: lime;&amp;quot; |31st&lt;br /&gt;
Jan away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: blue; color: white;&amp;quot; |1st April&lt;br /&gt;
Jan away&lt;br /&gt;
&lt;br /&gt;
Richard away&lt;br /&gt;
&lt;br /&gt;
Tricia away&lt;br /&gt;
&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |2nd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |3rd&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |4th&lt;br /&gt;
Jan away &lt;br /&gt;
&lt;br /&gt;
Ken away &lt;br /&gt;
&lt;br /&gt;
Tricia away &lt;br /&gt;
  |5th&lt;br /&gt;
Jan away&lt;br /&gt;
  |6th&lt;br /&gt;
Jan away&lt;br /&gt;
  |7th&lt;br /&gt;
Jan away&lt;br /&gt;
  |8th&lt;br /&gt;
Jan away?&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |9th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |10th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |11th&lt;br /&gt;
Anil away&lt;br /&gt;
  |12th&lt;br /&gt;
Anil away&lt;br /&gt;
  |13th&lt;br /&gt;
Anil away&lt;br /&gt;
  |14th&lt;br /&gt;
Becky away&lt;br /&gt;
  |15th&lt;br /&gt;
Becky away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |16th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |17th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |18th&lt;br /&gt;
Becky away&lt;br /&gt;
  |19th&lt;br /&gt;
Becky away&lt;br /&gt;
  |20th&lt;br /&gt;
Becky away&lt;br /&gt;
  |21st&lt;br /&gt;
Becky away&lt;br /&gt;
  |22nd&lt;br /&gt;
Becky away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |23rd&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |24th&lt;br /&gt;
 &lt;br /&gt;
 |-&lt;br /&gt;
  |style=&amp;quot;background: yellow;&amp;quot; |25th 1st day of summer term&lt;br /&gt;
Aimee away&lt;br /&gt;
  |26th&lt;br /&gt;
Aimee away&lt;br /&gt;
  |27th&lt;br /&gt;
Aimee away&lt;br /&gt;
  |28th&lt;br /&gt;
Aimee away&lt;br /&gt;
  |29th&lt;br /&gt;
Aimee away&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |30th&lt;br /&gt;
  | style=&amp;quot;background: grey;&amp;quot; |1st May&lt;br /&gt;
 &lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=514432</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=514432"/>
		<updated>2015-11-27T15:04:28Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
::*If [H] is selected: With a hard boundary, the whole molecule (i.e. all of its atoms) has to be within the boundary. In other words, for any atom whose distance away from the origin is greater than the specified cluster radius, it’s associated molecule will not be included in the cluster. Since only full molecules are included, there will not be any dangling bonds under any circumstances.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first solvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
::*Here four options are present, [S], [M], [A] and [N], but in the next step to select from these options, the programme lists only two options(S/N). This is just an error in the output to screen and you can still select the other two options. This will be fixed in the next version.&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*Data objects:This was setup mainly so that it would be easier for Vincent to run some tests if there was something wrong with the clusters. He will have this option removed from the next version and perhaps instead have a ‘debug’ version of MolCluster. &lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500127</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500127"/>
		<updated>2015-08-24T14:57:59Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|- &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
! 4&lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Bryan Ward (Done)&lt;br /&gt;
| Claire Ashworth (Done)&lt;br /&gt;
| Precious Ugbomah (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Vincent Chen (Done)&lt;br /&gt;
| Gabriel Lau (Done)&lt;br /&gt;
| Rebecca Rowe (Done)&lt;br /&gt;
| Ken Watson (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Aiswarya Prabha (Done)&lt;br /&gt;
| Richard Fogarty (Not Done)&lt;br /&gt;
| Christopher Sewell (Done)&lt;br /&gt;
| Chen Chen (Not Done)&lt;br /&gt;
|- &lt;br /&gt;
|Ziyun Zhang (Done)&lt;br /&gt;
|Julie Schmauck (Not Done)&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;5&amp;quot; width=&amp;quot;1190&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr bgcolor=&amp;quot;#66CCFF&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Mon&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Tues&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Wed&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Thur&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Fri&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sat&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sun&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st June&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;7th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;14th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;21st&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;28th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;29th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st July&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;11th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Claire Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;25th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;31st&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st August&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;2nd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;8th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;9th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;22nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;23rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;29th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;30th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#33CC99&amp;quot;&amp;gt;31st&amp;lt;br&amp;gt;&#039;&#039;&#039;Bank Holiday&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st September&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st October&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#ffff66&amp;quot;&amp;gt;3rd&amp;lt;br&amp;gt;&#039;&#039;&#039;TERM BEGINS&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500126</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500126"/>
		<updated>2015-08-24T14:57:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|- &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
! 4&lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Bryan Ward (Done)&lt;br /&gt;
| Claire Ashworth (Done)&lt;br /&gt;
| Precious Ugbomah (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Vincent Chen (Done)&lt;br /&gt;
| Gabriel Lau (Done)&lt;br /&gt;
| Rebecca Rowe (Done)&lt;br /&gt;
| Ken Watson (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Aiswarya Prabha (Not Done)&lt;br /&gt;
| Richard Fogarty (Not Done)&lt;br /&gt;
| Christopher Sewell (Done)&lt;br /&gt;
| Chen Chen (Not Done)&lt;br /&gt;
|- &lt;br /&gt;
|Ziyun Zhang (Done)&lt;br /&gt;
|Julie Schmauck (Not Done)&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;5&amp;quot; width=&amp;quot;1190&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr bgcolor=&amp;quot;#66CCFF&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Mon&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Tues&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Wed&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Thur&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Fri&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sat&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sun&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st June&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;7th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;14th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;21st&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;28th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;29th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st July&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;11th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Claire Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;25th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;31st&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st August&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;2nd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;8th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;9th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;22nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;23rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;29th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;30th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#33CC99&amp;quot;&amp;gt;31st&amp;lt;br&amp;gt;&#039;&#039;&#039;Bank Holiday&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st September&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st October&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#ffff66&amp;quot;&amp;gt;3rd&amp;lt;br&amp;gt;&#039;&#039;&#039;TERM BEGINS&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500125</id>
		<title>Mod:Hunt Research Group/calendar</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Mod:Hunt_Research_Group/calendar&amp;diff=500125"/>
		<updated>2015-08-24T14:56:01Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Calendar */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Back to the main [https://www.ch.ic.ac.uk/wiki/index.php/Mod:Hunt_Research_Group wiki-page]&lt;br /&gt;
== Calendar ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|- &lt;br /&gt;
! 1 &lt;br /&gt;
! 2 &lt;br /&gt;
! 3 &lt;br /&gt;
! 4&lt;br /&gt;
|-&lt;br /&gt;
| Tricia (Done) &lt;br /&gt;
| Bryan Ward (Done)&lt;br /&gt;
| Claire Ashworth (Done)&lt;br /&gt;
| Precious Ugbomah (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Vincent Chen (Done)&lt;br /&gt;
| Gabriel Lau (Done)&lt;br /&gt;
| Rebecca Rowe (Done)&lt;br /&gt;
| Ken Watson (Done)&lt;br /&gt;
|- &lt;br /&gt;
| Aiswarya Prabha (Not Done)&lt;br /&gt;
| Richard Fogarty (Not Done)&lt;br /&gt;
| Christopher Sewell (Done)&lt;br /&gt;
| Chen Chen (Not Done)&lt;br /&gt;
|- &lt;br /&gt;
|Ziyun Zhang (Done)&lt;br /&gt;
|Julie Schmauck (Not Done)&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|-)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot; cellpadding=&amp;quot;5&amp;quot; width=&amp;quot;1190&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr bgcolor=&amp;quot;#66CCFF&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Mon&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Tues&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Wed&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Thur&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Fri&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sat&amp;lt;/th&amp;gt;&lt;br /&gt;
   &amp;lt;th width=&amp;quot;170px&amp;quot;&amp;gt;Sun&amp;lt;/th&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st June&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;7th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;14th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;21st&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away (Boulder Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;28th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;29th&amp;lt;br&amp;gt;Bryan Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st July&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td &amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Richard F Exp&amp;lt;br&amp;gt;Gabriel Away&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;11th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Gabriel Away (FOMMS Conference)&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Claire Away&amp;lt;br&amp;gt;Chris Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;25th&amp;lt;br&amp;gt;Claire Away&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;31st&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away (UCL)&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st August&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;2nd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;5th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;6th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;8th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;9th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Richard F Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Julie Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;19th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;20th&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Richard F Away (Conference)&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;22nd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;23rd&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;26th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;27th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Ken Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;29th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;30th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#33CC99&amp;quot;&amp;gt;31st&amp;lt;br&amp;gt;&#039;&#039;&#039;Bank Holiday&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st September&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;3rd&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;4th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;5th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;6th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;7th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;8th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;9th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;10th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;11th&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;12th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;13th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;14th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;15th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;16th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;17th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;18th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;19th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;20th&amp;lt;br&amp;gt;Tricia Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;21st&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;22nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;Aiswarya Away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;23rd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;24th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;25th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;26th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;27th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr valign=&amp;quot;top&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;28th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;29th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;30th&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#4357CFF&amp;quot;&amp;gt;&amp;lt;span style=&amp;quot;color:white&amp;quot;&amp;gt;&#039;&#039;&#039;1st October&#039;&#039;&#039;&amp;lt;/span&amp;gt;&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;2nd&amp;lt;br&amp;gt;Becky away&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#ffff66&amp;quot;&amp;gt;3rd&amp;lt;br&amp;gt;&#039;&#039;&#039;TERM BEGINS&#039;&#039;&#039;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;td bgcolor=&amp;quot;#cccccc&amp;quot;&amp;gt;4th&amp;lt;br&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500097</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500097"/>
		<updated>2015-07-30T10:22:54Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
::*If [H] is selected: With a hard boundary, the whole molecule (i.e. all of its atoms) has to be within the boundary. In other words, for any atom whose distance away from the origin is greater than the specified cluster radius, it’s associated molecule will not be included in the cluster. Since only full molecules are included, there will not be any dangling bonds under any circumstances.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
::*Here four options are present, [S], [M], [A] and [N], but in the next step to select from these options, the programme lists only two options(S/N). This is just an error in the output to screen and you can still select the other two options. This will be fixed in the next version.&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*Data objects:This was setup mainly so that it would be easier for Vincent to run some tests if there was something wrong with the clusters. He will have this option removed from the next version and perhaps instead have a ‘debug’ version of MolCluster. &lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500096</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500096"/>
		<updated>2015-07-30T10:21:53Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
::*If [H] is selected: With a hard boundary, the whole molecule (i.e. all of its atoms) has to be within the boundary. In other words, for any atom whose distance away from the origin is greater than the specified cluster radius, it’s associated molecule will not be included in the cluster. Since only full molecules are included, there will not be any dangling bonds under any circumstances.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
::Here four options are present, [S], [M], [A] and [N], but in the next step to select from these options, the programme lists only two options(S/N). This is just an error in the output to screen and you can still select the other two options. This will be fixed in the next version.&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*Data objects:This was setup mainly so that it would be easier for Vincent to run some tests if there was something wrong with the clusters. He will have this option removed from the next version and perhaps instead have a ‘debug’ version of MolCluster. &lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500083</id>
		<title>Talk:Mod:Hunt Research Group/ChemShell</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500083"/>
		<updated>2015-07-28T15:57:01Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Input for ChemShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
&lt;br /&gt;
::*ff.dat : the forcefield in ChemShell format&lt;br /&gt;
::*opt.chm: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
::*cluster.pun: coordinate, atom_charges and connectivity records&lt;br /&gt;
&lt;br /&gt;
::*as part of generating the &amp;quot;cut&amp;quot; cluster using MolCluster you will have generated a range files, e.g. check the directory &amp;quot;cluster_1&amp;quot;, and the files you need now are cluster_1.chm, ff.dat and opt.hm&lt;br /&gt;
&lt;br /&gt;
::*note that MolCluster has not generated cluster.pun, but has generated cluster_n.chm, the coordinates file, which is used to generate cluster.pun&lt;br /&gt;
&lt;br /&gt;
*login to CX1 and copy your cluster directories over then ...&lt;br /&gt;
&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell mpi&lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::*successful result will generate a file cluster.pun and the screen info will look like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Initialising ChemShell 3.5.0 on linux&lt;br /&gt;
c_create/======================================== Tstep:    0.1 Ttot:    0.1 ==&lt;br /&gt;
ChemShell exiting code 0&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
:add some more information on this&lt;br /&gt;
:if you have only water molecules there should be no issue, but if you have a solvated species spurious &amp;quot;connectivity&amp;quot; may occur.&lt;br /&gt;
:in the CuSO4 example ....&lt;br /&gt;
search for /conn&lt;br /&gt;
lines to remove, total number to change&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
edit the number of nproc so it is one less than the number called by PBS&lt;br /&gt;
mocluster generates defaults, maxcyc should relate to the number of degrees of freedom, so g09 suggests 3N+20 so for 51 atoms =173)&lt;br /&gt;
memory is in bytes 1,000,000 is 1 MB.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*you will beed to add conn and mxexcl options manually to this file after the mm_theory. &lt;br /&gt;
::*mxexcl depends on the QM region, in the chemshell manual this is &amp;quot;Allocation parameter for excluded atom list, may need to be increased for qm/mm calculations with a large qm region&amp;quot; please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
chemshell has a list of all the atoms, and those in the QM region need to be excluded from the MM computation&lt;br /&gt;
this number needs checking!!  This relates to the number ...&lt;br /&gt;
::*conn=cluster.pun tells chemshell to read the connectivity from the cluster.pun file&lt;br /&gt;
::*for our example you will need to change ...&lt;br /&gt;
&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
this script submit the job, note that only the xx file is redirected while the job is running all other files are only copied over at the termination&lt;br /&gt;
add a comment re maxcycle being changed as wall time is hard, it will kill the job&lt;br /&gt;
cuso4+water QM +x active +y frozen a maxcycl of x and wall time of y are a good option&lt;br /&gt;
*don&#039;t forget different ques have different waltzes, and the more processors you use the &amp;quot;more&amp;quot; time you have&lt;br /&gt;
&lt;br /&gt;
::* to submit the job&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
qsub submit_opt.sh&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500070</id>
		<title>Talk:Mod:Hunt Research Group/ChemShell</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500070"/>
		<updated>2015-07-28T14:01:19Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Input for ChemShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
&lt;br /&gt;
::*ff.dat : the forcefield in ChemShell format&lt;br /&gt;
::*opt.chm: ChemShell input file. Options for the ChemShell optimisation specified here.*MolCluster will not generate cluster.pun, but it generates cluster_n.chm, the coordinates file, which is used to generate cluster.pun&lt;br /&gt;
::*cluster.pun: coordinate, atom_charges and connectivity records&lt;br /&gt;
&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500069</id>
		<title>Talk:Mod:Hunt Research Group/ChemShell</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500069"/>
		<updated>2015-07-28T13:59:25Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Input for ChemShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
&lt;br /&gt;
::*ff.dat : the forcefield in ChemShell format&lt;br /&gt;
::*opt.chm: ChemShell input file. Options for the ChemShell optimisation specified here.*MolCluster will not generate cluster.pun, but it generates cluster_n.chm, the coordinates file, which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500067</id>
		<title>Talk:Mod:Hunt Research Group/ChemShell</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell&amp;diff=500067"/>
		<updated>2015-07-28T13:56:37Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Input for ChemShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500063</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500063"/>
		<updated>2015-07-28T12:16:24Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* OLD instructions that relate to MolCluster v1-7 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500062</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500062"/>
		<updated>2015-07-28T12:16:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Input for ChemShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500061</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500061"/>
		<updated>2015-07-28T12:13:19Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I)&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500060</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500060"/>
		<updated>2015-07-28T12:12:38Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500059</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500059"/>
		<updated>2015-07-28T12:10:27Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:--&amp;gt;[n]: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:--&amp;gt;[c]: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500058</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500058"/>
		<updated>2015-07-28T12:09:57Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:--&amp;gt;[AN]: Atom number&lt;br /&gt;
:--&amp;gt;[AT]&#039;: Atom type&lt;br /&gt;
:--&amp;gt;[MN]&#039;: Molecule number&lt;br /&gt;
:--&amp;gt;[MT]: Molecule type&lt;br /&gt;
:--&amp;gt;[C]: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500057</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500057"/>
		<updated>2015-07-28T12:08:27Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Using MolClusterV2.3: Basic Instructions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolClusterV2.3: Basic Instructions===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
:*if you need a demo file to practice on download this history file: [[Media:TEST_CUSO4_DLPOLY_HISTORY.rtf]]&lt;br /&gt;
&lt;br /&gt;
4. Select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
:*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; step or configuration. &lt;br /&gt;
:*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
::*normally option n will be selected&lt;br /&gt;
::*once you have made the n or c selection options will relate to which clusters are to be cut, N.B: numbering starts from 1 (i.e. 1st timestep). &lt;br /&gt;
::* For option n you will give an integer to identify the &amp;quot;nth&amp;quot; step to cut at.  Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::* The demo HISTORY file has only 5 steps, so if using this file select 2 to get 2 structures&lt;br /&gt;
::* For option c you will need to give the integer number of the specific step you want cut.&lt;br /&gt;
::*MolCluster will then tell you the the relevant coordinates have been generated&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
:*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
:*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
:*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
:*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
:*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
::* If using the demo HISTORY file choose AT&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
::* If using the demo HISTORY file choose number 6 (this file has Cu-SO4+2000 waters, and O3 is the oxygen atom between Cu and S i.e. Cu-O-S&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
:Available cluster construction definition:&lt;br /&gt;
:--&amp;gt;[R] Fixed radius&lt;br /&gt;
:--&amp;gt;[M] Specify number of each molecule type (i.e. the number of those molecules to include within the cluster radius)&lt;br /&gt;
::* If using the demo HISTORY file you want to select R&lt;br /&gt;
::MolCluster will then print out some information for you this will give you some idea of the number of atoms within various radii&lt;br /&gt;
&lt;br /&gt;
7. In the next step, if &#039;R&#039; was chosen, it will ask for the radius (in Angstroms) of the cluster(s) to be cut. If &#039;M&#039; was chosen it will ask for the number of each molecule (check ... will it be just for the water)&lt;br /&gt;
::* If using the demo HISTORY file you want to select 20 (this is a big radius so that we can have a QM region surrounded by an active MM region which is in turn surrounded with an inactive MM region)&lt;br /&gt;
&lt;br /&gt;
8. Next it is possible that your chosen radius can cut through a molecule, thus MolCluster has two options for deciding which atoms to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius to be included (i.e. molecules can be cut with some atoms appearing in the cluster and others not).&lt;br /&gt;
:--&amp;gt;[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the whole molecule will be included.&lt;br /&gt;
::* If using the demo HISTORY file you want to select S the soft option&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
:Vincent will add something here about how a cluster is neutralised (important for the ILs)&lt;br /&gt;
::* If using the demo HISTORY file you want to select Y option to have a neutral cluster&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output format, this can be for chemshell or a simple xyz:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
:--&amp;gt;[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
::*If [X] is selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
::*If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
::* If using the demo HISTORY file you want to select C for chemshell and Y for QM/MM&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the &#039;&#039;&#039;QM region&#039;&#039;&#039;. Available options are:&lt;br /&gt;
&lt;br /&gt;
:--&amp;gt;[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily completely spherical if you have chosen a soft bondry)&lt;br /&gt;
:--&amp;gt;[M]: Choose the number of molecules closest to the origin that will be included.&lt;br /&gt;
:--&amp;gt;[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
:--&amp;gt;[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
:--&amp;gt;[O]: Spherical regions centred about one or more origins (for example we could choose S of SO4 as an origin and Cu as an origin and have two intersecting &amp;quot;regions&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
::* If using the demo HISTORY file you want to select O for multiple origins. Then choose the number of origins as &#039;2&#039;, since we want to define the regions centred about S and Cu. After choosing &#039;2&#039;, it will list the atoms and the corresponding number, choose numbers corresponding to S and then include the desired radius. then choose Cu( by choosing the number corresponding to copper from the list) and then enter the radius. To choose the radii for each region, look at the radial distribution plot obtained for Cu-O(water) and S-O(water) from DL_POLY production run. Use the distance of the first minima as the radius. &lt;br /&gt;
&lt;br /&gt;
:If [S] is selected, MolCluster will print out some information, estimating the number of atoms in the regions defined by specific radii to help you evaluate the best radius to choose.  Choose a radius!&lt;br /&gt;
::* If using the demo HISTORY file you want to select 5.0 for the first salvation sphere around the Cu-SO4 ion-pair&lt;br /&gt;
&lt;br /&gt;
:If [O] is selected ...&lt;br /&gt;
&lt;br /&gt;
:Next MolCluster will ask you to specify the QM radius you want (in Angstroms)&lt;br /&gt;
::Note this radius must be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
&lt;br /&gt;
:If [C] is selected once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. Now MolCluster will ask you to select the type of &#039;&#039;&#039;active region&#039;&#039;&#039; definition from,&lt;br /&gt;
:--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
:--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
:--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
:--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
::this is similar to choosing the total cluster size options, however the radius should be larger than the QM and smaller than the total cluster size!&lt;br /&gt;
::* If using the demo HISTORY file choose &#039;S&#039;&lt;br /&gt;
&lt;br /&gt;
13. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
::* If using the demo HISTORY file choose give a radius of 15.0Å for the active region&lt;br /&gt;
&lt;br /&gt;
14. Next MolCluster will ask you to select a coordinate system under which the optimisation will take place.  Three different co-ordinate systems are available in ChemShell for optimisation. &lt;br /&gt;
:--&amp;gt;[C]artesian (constraints not permitted)&lt;br /&gt;
:--&amp;gt;[D]elocalised internal coordinates (DLC)&lt;br /&gt;
:--&amp;gt;[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
::Select C, D or H to define the coordinate system&lt;br /&gt;
::* If using the demo HISTORY file choose C the cartesian coordinates&lt;br /&gt;
::* we have had problems with the hybrid HDLC option so only choose this if you are an expert&lt;br /&gt;
::* HDLC are ...&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory into which MolCluster should write files, followed by a base name &#039;cluster&#039;&lt;br /&gt;
::* if using one of the in-house python scripts you must use &#039;cluster&#039;&lt;br /&gt;
::* If using the demo HISTORY file perhaps use the directory &amp;quot;test1&amp;quot; and &amp;quot;cluster&amp;quot;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
::*what are these data objects??&lt;br /&gt;
::* If using the demo HISTORY file chose N&lt;br /&gt;
&lt;br /&gt;
:MolCluster will now generate the clusters and files required&lt;br /&gt;
::* if you used a central radius you will see something like this&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Please give output basename (no spaces and only alphanumeric and underscore&lt;br /&gt;
characters allowed): cluster&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Do you want the bulk and cluster data objects to be generated for debug purposes&lt;br /&gt;
[Y/N]? N&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Creating directory &#039;test1/cluster_1&#039;&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 1 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_1/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 18 molecules (54 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_1/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Creating directory &#039;test1/cluster_2&#039;&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Generating 2x2x2 supercell...&lt;br /&gt;
&lt;br /&gt;
Cluster 2 out of 5 generated...&lt;br /&gt;
&lt;br /&gt;
ChemShell potential file test1/cluster_2/ff.dat...&lt;br /&gt;
&lt;br /&gt;
...generated&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
There are 19 molecules (57 atoms) in the QM region.&lt;br /&gt;
&lt;br /&gt;
The total charge of the QM region is 0.0.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO      System information written to test1/cluster_2/system_info.txt       OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and once all the clusters have been generated you should see this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
III                         All clusters generated.                          III&lt;br /&gt;
&lt;br /&gt;
IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
Please report any bugs to Vincent Chen (vhc08@ic.ac.uk) or Gabriel Lau&lt;br /&gt;
&lt;br /&gt;
(gvl07@ic.ac.uk). The log file can be found in &#039;temp/molcluster.log&#039;.&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
OOO                       Log file copied to &#039;test1&#039;.                        OOO&lt;br /&gt;
&lt;br /&gt;
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO&lt;br /&gt;
&lt;br /&gt;
--------------------------------------------------------------------------------&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&lt;br /&gt;
EEE                            Exiting molcluster                            EEE&lt;br /&gt;
&lt;br /&gt;
EEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;br /&gt;
&lt;br /&gt;
===&#039;&#039;&#039;OLD instructions that relate to MolCluster v1-7&#039;&#039;&#039;===&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500025</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500025"/>
		<updated>2015-07-24T13:29:16Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* MolClusterV2.3 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R&#039; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined .&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Now MolCluster will ask you to select the type of active region definition from,&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
&lt;br /&gt;
15.Three different co-ordinate systems are available for ChemShell optimisation. Now, select the co-ordinate systems: C, D or H&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory followed by the base name &#039;cluster&#039;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500024</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500024"/>
		<updated>2015-07-24T13:27:52Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* MolClusterV2.3 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R&#039; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Now MolCluster will ask you to select the type of active region definition from,&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
&lt;br /&gt;
15.Three different co-ordinate systems are available for ChemShell optimisation. Now, select the co-ordinate systems: C, D or H&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory followed by the base name &#039;cluster&#039;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500023</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500023"/>
		<updated>2015-07-24T13:22:37Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* MolClusterV2.3 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R&#039; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 10 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Now MolCluster will ask you to select the type of active region definition from,&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
&lt;br /&gt;
15.Three different co-ordinate systems are available for ChemShell optimisation. Now, select the co-ordinate systems: C, D or H&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory followed by the base name &#039;cluster&#039;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500022</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500022"/>
		<updated>2015-07-24T13:21:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* MolClusterV2.3 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R&#039; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Now MolCluster will ask you to select the type of active region definition from,&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
&lt;br /&gt;
15.Three different co-ordinate systems are available for ChemShell optimisation. Now, select the co-ordinate systems: C, D or H&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory followed by the base name &#039;cluster&#039;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500006</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500006"/>
		<updated>2015-07-20T15:03:27Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* MolClusterV2.3 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R&#039; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Now MolCluster will ask you to select the type of active region definition from,&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. If [S] is selected, MolCluster will estimate the number of atoms within a set of radii and will ask you to enter the desired radius of the active region&lt;br /&gt;
&lt;br /&gt;
15.Three different co-ordinate systems are available for ChemShell optimisation. Now, select the co-ordinate systems: C, D or H&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
&lt;br /&gt;
15. Give the name of the output directory followed by the base name &#039;cluster&#039;&lt;br /&gt;
&lt;br /&gt;
16. In the next step, we can save the bulk and cluster data objects to be generated for debug purposes by selecting &#039;Y&#039;. if not required, select &#039;N&#039; and MolCluster will generate the clusters.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500005</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500005"/>
		<updated>2015-07-20T14:50:21Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500004</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500004"/>
		<updated>2015-07-20T14:50:03Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
 --&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link] and run the optimization&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500003</id>
		<title>Talk:Mod:Hunt Research Group/submit opt embedded2.sh</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500003"/>
		<updated>2015-07-20T14:49:24Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
#PBS -l walltime=72:00:00&lt;br /&gt;
#PBS -lselect=1:ncpus=16:mem=64000mb&lt;br /&gt;
#PBS -j oe&lt;br /&gt;
&lt;br /&gt;
module load dl_poly/2.19&lt;br /&gt;
module load mpi&lt;br /&gt;
module load intel-suite/2013&lt;br /&gt;
module load intel-suite/2012&lt;br /&gt;
module load gaussian/g09&lt;br /&gt;
module load chemshell/3.5.0&lt;br /&gt;
&lt;br /&gt;
cp $PBS_O_WORKDIR/opt.chm $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/ff.dat $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/embedded_cluster_*.pun $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/path* $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/*.chk $TMPDIR/.&lt;br /&gt;
#cd $TMPDIR&lt;br /&gt;
#chemsh.x opt.chm &amp;gt; opt.out&lt;br /&gt;
chemsh.x $TMPDIR/opt.chm &amp;gt; $PBS_O_WORKDIR/opt.out&lt;br /&gt;
&lt;br /&gt;
cp $TMPDIR/embedded_cluster* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/dlf_* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/gaussian.* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/opt* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/path* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/param.defs /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/hybrid* /$PBS_O_WORKDIR/&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500002</id>
		<title>Talk:Mod:Hunt Research Group/submit opt embedded2.sh</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500002"/>
		<updated>2015-07-20T14:49:01Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
#PBS -l walltime=72:00:00&lt;br /&gt;
#PBS -lselect=1:ncpus=16:mem=64000mb&lt;br /&gt;
#PBS -j oe&lt;br /&gt;
&lt;br /&gt;
module load dl_poly/2.19&lt;br /&gt;
module load mpi&lt;br /&gt;
module load intel-suite/2013&lt;br /&gt;
module load intel-suite/2012&lt;br /&gt;
module load gaussian/g09&lt;br /&gt;
module load chemshell/3.5.0&lt;br /&gt;
&lt;br /&gt;
cp $PBS_O_WORKDIR/opt.chm $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/ff.dat $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/embedded_cluster_*.pun $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/path* $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/*.chk $TMPDIR/.&lt;br /&gt;
cd $TMPDIR&lt;br /&gt;
#cd $TMPDIR&lt;br /&gt;
#chemsh.x opt.chm &amp;gt; opt.out&lt;br /&gt;
chemsh.x $TMPDIR/opt.chm &amp;gt; $PBS_O_WORKDIR/opt.out&lt;br /&gt;
&lt;br /&gt;
cp $TMPDIR/embedded_cluster* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/dlf_* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/gaussian.* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/opt* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/path* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/param.defs /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/hybrid* /$PBS_O_WORKDIR/&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500001</id>
		<title>Talk:Mod:Hunt Research Group/submit opt embedded2.sh</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh&amp;diff=500001"/>
		<updated>2015-07-20T14:48:39Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: Created page with &amp;quot;#!/bin/sh #PBS -l walltime=72:00:00 #PBS -lselect=1:ncpus=16:mem=64000mb #PBS -j oe  module load dl_poly/2.19 module load mpi module load intel-suite/2013 module load intel-su...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#!/bin/sh&lt;br /&gt;
#PBS -l walltime=72:00:00&lt;br /&gt;
#PBS -lselect=1:ncpus=16:mem=64000mb&lt;br /&gt;
#PBS -j oe&lt;br /&gt;
&lt;br /&gt;
module load dl_poly/2.19&lt;br /&gt;
module load mpi&lt;br /&gt;
module load intel-suite/2013&lt;br /&gt;
module load intel-suite/2012&lt;br /&gt;
module load gaussian/g09&lt;br /&gt;
module load chemshell/3.5.0&lt;br /&gt;
&lt;br /&gt;
cp $PBS_O_WORKDIR/opt.chm $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/ff.dat $TMPDIR/.&lt;br /&gt;
cp $PBS_O_WORKDIR/embedded_cluster_*.pun $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/path* $TMPDIR/.&lt;br /&gt;
#cp $PBS_O_WORKDIR/*.chk $TMPDIR/.&lt;br /&gt;
cd $TMPDIR&lt;br /&gt;
#cd $TMPDIR&lt;br /&gt;
#chemsh.x opt.chm &amp;gt; opt.out&lt;br /&gt;
chemsh.x $TMPDIR/opt.chm &amp;gt; $PBS_O_WORKDIR/opt.out&lt;br /&gt;
&lt;br /&gt;
cp $TMPDIR/embedded_cluster* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/dlf_* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/gaussian.* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/opt* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/path* /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/param.defs /$PBS_O_WORKDIR/&lt;br /&gt;
cp $TMPDIR/hybrid* /$PBS_O_WORKDIR/&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500000</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=500000"/>
		<updated>2015-07-20T14:42:40Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
 --&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes in the opt.chm as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link]&lt;br /&gt;
&lt;br /&gt;
28. The submit script [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded2.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499999</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499999"/>
		<updated>2015-07-20T14:41:15Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
 --&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;. Also make changes as described in  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499998</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499998"/>
		<updated>2015-07-20T14:40:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
 --&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;br /&gt;
&lt;br /&gt;
27. open opt.chm and edit the first line &amp;quot;dl-find coords=embedded_cluster_n.pun\&amp;quot;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499997</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499997"/>
		<updated>2015-07-20T14:38:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolClusterV2.3: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;br /&gt;
&lt;br /&gt;
*In the second step, clusters with different regions (QM and MM) with point charges outside are cut using MolCluster&lt;br /&gt;
&lt;br /&gt;
17. When the job is finished transfer the folder to the local machine with MolClusterV2.3&lt;br /&gt;
&lt;br /&gt;
18.  Load MolClusterV2.3: ./MolCluster.py&lt;br /&gt;
&lt;br /&gt;
19. Enter the same directory containing the FIELD and HISTORY files as given in the first step&lt;br /&gt;
&lt;br /&gt;
20. select option [5] to cut cluster and add point charges&lt;br /&gt;
&lt;br /&gt;
21. MolCluster will ask for the directory containing &#039;embedded_cluster_specs.obj&#039; of the embedded cluster(s) generated by ChemShell. (the folder containing ChemSehll output)&lt;br /&gt;
&lt;br /&gt;
22. Now the cluster specifications will be asked for. enter &#039;Y&#039; if you want to use the same radius for the regions as entered before or &#039;N&#039; if want to change the  radius&lt;br /&gt;
&lt;br /&gt;
23.In the next step MolCluster will ask for the type of QM region you want to specify&lt;br /&gt;
 --&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific number of molecules closest to the origin of each molecule type&lt;br /&gt;
--&amp;gt;[C] Custom region&lt;br /&gt;
--&amp;gt;[O] Spherical volumes centred about one or more user-defined origins&lt;br /&gt;
&lt;br /&gt;
24. Clusters will be cut at this point and saved to the folder having the &#039;embedded_cluster_specs.obj&#039;  file.&lt;br /&gt;
&lt;br /&gt;
::* open embedded_cluster_n, it will have the opt.chm, ff. dat and embedded_cluster_n.chm &lt;br /&gt;
&lt;br /&gt;
25. transfer the folder to cx1 &lt;br /&gt;
&lt;br /&gt;
26. load chemshell on cx1 and run&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;module load chemshell mpi &lt;br /&gt;
  chemsh.x embedded_cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* embedded_cluster_n.pun will be generated&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499996</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499996"/>
		<updated>2015-07-20T14:17:16Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded2.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=File:Embedded2.png&amp;diff=499995</id>
		<title>File:Embedded2.png</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=File:Embedded2.png&amp;diff=499995"/>
		<updated>2015-07-20T14:16:51Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499994</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499994"/>
		<updated>2015-07-20T14:14:10Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges [[File:Embedded1.png]]&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=File:Embedded1.png&amp;diff=499993</id>
		<title>File:Embedded1.png</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=File:Embedded1.png&amp;diff=499993"/>
		<updated>2015-07-20T14:13:41Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499992</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499992"/>
		<updated>2015-07-20T14:12:46Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Select option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499991</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499991"/>
		<updated>2015-07-20T14:12:22Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are generated in two steps&lt;br /&gt;
*First a cluster of specific radius is generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Selecy option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499990</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499990"/>
		<updated>2015-07-20T13:51:04Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Cutting Embedded Cluster */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Cutting Embedded Cluster=&lt;br /&gt;
*Embedded clusters are first generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Selecy option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499989</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499989"/>
		<updated>2015-07-20T13:50:34Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Step-By-Step Example: Ionic Liquid Clusters */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
=Step-By-Step Example: Ionic Liquid Clusters=&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Cutting Embedded Cluster==&lt;br /&gt;
*Embedded clusters are first generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Selecy option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
	<entry>
		<id>https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499988</id>
		<title>Talk:Mod:Hunt Research Group/MolCluster</title>
		<link rel="alternate" type="text/html" href="https://chemwiki.ch.ic.ac.uk/index.php?title=Talk:Mod:Hunt_Research_Group/MolCluster&amp;diff=499988"/>
		<updated>2015-07-20T13:50:08Z</updated>

		<summary type="html">&lt;p&gt;Aprabha: /* Step-By-Step Example: Ionic Liquid Clusters */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===What is MolCluster?===&lt;br /&gt;
MolCluster is a tool (developed by Vincent and Gabriel) that can be used to cut clusters from MD trajectories and create the input files for ChemShell. &lt;br /&gt;
&lt;br /&gt;
To use MolCluster, you will need:&lt;br /&gt;
* The latest version of MolCluster (available from Vincent).&lt;br /&gt;
* Python version 2.7.6, or above.&lt;br /&gt;
* The HISTORY file from which the clusters are to be cut, and the corresponding FIELD file. Note: these need to be in DL_POLY format. If you have used the &#039;restart&#039; option in DL_POLY, the header of the HISTORY file may need to be amended. Additional transformations of the HISTORY and FIELD files, to convert atom labels into an acceptable format for MolCluster/ChemShell, may also be required (example given later).&lt;br /&gt;
&lt;br /&gt;
===Using MolCluster: Basic Instructions===&lt;br /&gt;
&#039;&#039;&#039;Please note that these instructions relate to MolCluster v1-7. New instructions for MolCluster v1-8 will be created shortly.&#039;&#039;&#039; &lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will estimate the number of atoms within a region, for a range of radii with respect to  your origin. Use this information to help you decide on the total radius (in Angstroms) of the clusters to be cut. You will be asked to specify this.&lt;br /&gt;
&lt;br /&gt;
7. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
::*&#039;&#039;&#039;[H]&#039;&#039;&#039;: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
&lt;br /&gt;
8. Specify if the clusters are required to be neutral (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
9. Decide on the output formats:&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
::*&#039;&#039;&#039;[X]&#039;&#039;&#039;: Generates the .xyz co-ordinates file only.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[X]&#039;&#039;&#039; selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If &#039;&#039;&#039;[C]&#039;&#039;&#039; selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (&#039;&#039;&#039;Y/N&#039;&#039;&#039;).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
10. If your answer to step 9 was &#039;&#039;&#039;[C]&#039;&#039;&#039; (generate a ChemShell fragment input) and &#039;&#039;&#039;Y&#039;&#039;&#039; (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
::*&#039;&#039;&#039;[S]&#039;&#039;&#039;: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
::::  If &#039;&#039;&#039;[S]&#039;&#039;&#039; selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
::*&#039;&#039;&#039;[M]&#039;&#039;&#039;: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
::*&#039;&#039;&#039;[A]&#039;&#039;&#039;: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
::*&#039;&#039;&#039;[O]&#039;&#039;&#039;: Spherical regions centred about one or more origins&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
If options &#039;&#039;&#039;[C]&#039;&#039;&#039; or &#039;&#039;&#039;[O]&#039;&#039;&#039; selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined &#039;&#039;per&#039;&#039; cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
NOTE: there can be a central active QM region (C), an active MM region (S&amp;lt;sub&amp;gt;A&amp;lt;/sub&amp;gt;) and a frozen MM region (S&amp;lt;sub&amp;gt;F&amp;lt;/sub&amp;gt;) (Figure I), so far you have selected the maximum radius for the size of the cluster, now select the radius of the active MM smaller than this. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure I.png]]&lt;br /&gt;
&lt;br /&gt;
11. MolCluster will estimate the number of atoms that would be in the active and frozen regions for a range of active radii. This information can be used to help decide upon an appropriate active radius, specified (in Angstroms) and must, be less than, or equal to, the total radius of the cluster. If all atoms are to be included, simply enter &amp;quot;ALL&amp;quot;. Soft boundary conditions are implemented.  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12. Specify the output directory (i.e. where your final clusters and associated files will be saved) and specify the base-name for the output files (e.g. if you type &amp;quot;cluster&amp;quot; here, your clusters will be saved as cluster_1, cluster_2 etc.). NOTE: if you are going to use the trajectory_analysis scripts later the base filename must be &amp;quot;cluster&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13.  Unless in step 10 above you selected options &#039;&#039;&#039;[C&#039;&#039;&#039;] or &#039;&#039;&#039;[O]&#039;&#039;&#039; (in which case, see point 14), MolCluster will generate the specified clusters and then terminate. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14. If option &#039;&#039;&#039;[C]&#039;&#039;&#039; was selected in step 10, MolCluster will at this point list all the molecules in the first cluster, along with the distances to the origin. You will be asked to list all the molecules to be included in the QM region for this cluster. The same procedure is carried out for each cluster, before the clusters are generated and MolCluster terminates.&lt;br /&gt;
&lt;br /&gt;
If option &#039;&#039;&#039;[O]&#039;&#039;&#039; was selected in step 10, you will be asked to specify how many region centers you employed in setting up a non-spherical QM region.&lt;br /&gt;
You can choose the centre of the multiple regions via atom/molecule or use the current cluster origin.  A table is provided to help you make this choice identifying atom numbers and molecules and their distance from the cluster origin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=&#039;&#039;&#039;MolClusterV2.3&#039;&#039;&#039;=&lt;br /&gt;
&lt;br /&gt;
1. Create a directory within the main MolCluster directory. Put the required HISTORY and FIELD files here.&lt;br /&gt;
&lt;br /&gt;
2. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
3. Requests directory name to be specified (this is the location of the FIELD and HISTORY files).  After specifying, the code will attempt to read and give an overview of the system.&lt;br /&gt;
&lt;br /&gt;
4. First select option 2 to cut clusters, then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. MolCluster will now ask for &lt;br /&gt;
::Available cluster construction definition:&lt;br /&gt;
::--&amp;gt;[R] Fixed radius&lt;br /&gt;
::--&amp;gt;[M] Specify number of each molecule type&lt;br /&gt;
&lt;br /&gt;
7. In the next step it will ask for the radius (in Angstroms) of the cluster(s) to be cut if &#039;R; was chosen in the precious step or number of each molecule if M was chosen&lt;br /&gt;
&lt;br /&gt;
8. MolCluster has two options for deciding which molecules to include/exclude at the boundary of the clusters being cut:&lt;br /&gt;
&lt;br /&gt;
[H]: Hard boundary - all atoms of a molecule must be within the cutoff radius for the molecule to be included.&lt;br /&gt;
[S]: Soft boundary - if the centre of mass of a molecule is within the cutoff radius, the molecule will be included.&lt;br /&gt;
9. Specify if the clusters are required to be neutral (Y/N).&lt;br /&gt;
&lt;br /&gt;
10. Decide on the output formats:&lt;br /&gt;
&lt;br /&gt;
[C]: Generates a ChemShell fragment input file, with accompanying .xyz co-ordinates file.&lt;br /&gt;
[X]: Generates the .xyz co-ordinates file only.&lt;br /&gt;
If [X] selected, the clusters will be cut, .xyz files generated and MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
If [C] selected, you will be asked if you would also like to generate the necessary ChemShell input files for a QM/MM optimisation (Y/N).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11. If your answer to step 9 was [C] (generate a ChemShell fragment input) and Y (generate ChemShell input files for a QM/MM optimisation), you will then be asked to define the QM region. Available options are:&lt;br /&gt;
&lt;br /&gt;
[S]: Spherical region (or threshold) centred about the defined origin (although not necessarily spherical??!!)&lt;br /&gt;
If [S] selected, MolCluster will estimate the number of atoms in regions defined by a range of radii. Specify the QM radius. This must be specified (in Angstroms) and must, obviously, be less than, or equal to, the total radius of the cluster. Soft boundary conditions are implemented.&lt;br /&gt;
[M]: By number of molecules. Molecules closest to the origin will be included.&lt;br /&gt;
[A]: By an upper limit of atoms. Only whole molecules &amp;amp; those closest to the origin included.&lt;br /&gt;
[C]: Custom region i.e. can select molecules individually to be in the QM region&lt;br /&gt;
[O]: Spherical regions centred about one or more origins&lt;br /&gt;
&lt;br /&gt;
If options [C] or [O] selected, MolCluster will go straight to steps 11 and 12. Once the active region and the directory/filenames have been defined, MolCluster will then ask for the custom QM regions to be defined per cluster (see step 14).&lt;br /&gt;
&lt;br /&gt;
12. If &#039;S&#039; is chosen it will ask for the radius of the QM region&lt;br /&gt;
&lt;br /&gt;
13. Available active region definitions:&lt;br /&gt;
--&amp;gt;[S] Spherical region centred about the origin&lt;br /&gt;
--&amp;gt;[M] By number of total molcules closest to the origin&lt;br /&gt;
--&amp;gt;[A] By an upper limit of total atoms closest to the origin&lt;br /&gt;
--&amp;gt;[N] Specific numbers of each molecule type&lt;br /&gt;
&lt;br /&gt;
14. Now enter the radius of the active region&lt;br /&gt;
&lt;br /&gt;
15. Available co-ordinate systems:&lt;br /&gt;
[C]artesian (constraints not permitted)&lt;br /&gt;
[D]elocalised internal coordinates (DLC)&lt;br /&gt;
[H]ybrid delocalised internal coordinates (HDLC)&lt;br /&gt;
Please select co-ordinate system to be used during optimisation [C/D/H]:&lt;br /&gt;
&lt;br /&gt;
===The Output Files===&lt;br /&gt;
* Each cluster will have its own directory within the directory named in step 12. These subdirectories will be named: &#039;&#039;&#039;cluster_1&#039;&#039;&#039;, &#039;&#039;&#039;cluster_2&#039;&#039;&#039;...&#039;&#039;&#039;cluster_n&#039;&#039;&#039;. &lt;br /&gt;
* Within the main directory one will also find a file called &#039;&#039;&#039;molcluster.log&#039;&#039;&#039; and a file called &#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039;. &lt;br /&gt;
::*&#039;&#039;&#039;molcluster.log&#039;&#039;&#039; is a record of the user responses to each of the MolCluster options (look at  this if you have forgotten, for example, the cluster radius). &lt;br /&gt;
::*&#039;&#039;&#039;bulk_system_info.txt&#039;&#039;&#039; summarises information relating to the system before clusters are cut (e.g. number and type of molecules, total number of atoms, total system charge, atom labels within a molecule, atomic charges).&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[X]&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
&lt;br /&gt;
*If option &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;Y&#039;&#039;&#039; selected in step 9, each subdirectory &#039;&#039;&#039;cluster_n&#039;&#039;&#039; will contain:&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.xyz&#039;&#039;&#039; coordinates file&lt;br /&gt;
::*&#039;&#039;&#039;system_info.txt&#039;&#039;&#039;: Summary of the cluster (e.g. total number of molecules, total number of atoms, total charge)&lt;br /&gt;
::*The &#039;&#039;&#039;cluster_n.chm&#039;&#039;&#039; coordinates file. This will be used to create the &#039;&#039;&#039;cluster.pun&#039;&#039;&#039; ChemShell input file.&lt;br /&gt;
::*&#039;&#039;&#039;cluster_tiered.xyz&#039;&#039;&#039;: xyz coordinates with the QM, active and frozen regions defined (all QM atoms listed as X1 (X=element symbol), active as X2 and frozen as X3). This file can be used to easily visualise the different regions in VMD.&lt;br /&gt;
::*&#039;&#039;&#039;conn.txt&#039;&#039;&#039; : the connectivity data needed by ChemShell&lt;br /&gt;
::*&#039;&#039;&#039;ff.dat&#039;&#039;&#039; : the forcefield in ChemShell format&lt;br /&gt;
::*&#039;&#039;&#039;opt.chm&#039;&#039;&#039;: ChemShell input file. Options for the ChemShell optimisation specified here.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== To visualise in VMD ==&lt;br /&gt;
&lt;br /&gt;
::* open the cluster_tiered.xyz file in vmd: File → New Molecule → Browse → select the file type → Load the file&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIa.png]]&lt;br /&gt;
&lt;br /&gt;
::*To highlight each layer in the cluster, open graphical representation &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIb.png]]&lt;br /&gt;
&lt;br /&gt;
::* To create a new representation: click on &#039;Create Rep&#039;, a new line will appear&lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IIc.png]]&lt;br /&gt;
&lt;br /&gt;
::* In the &#039;Selected Atoms&#039; type       &lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*1&amp;quot;&#039;&#039;&#039;  for the 1&amp;lt;sup&amp;gt;st&amp;lt;/sup&amp;gt; QM region  and  from the &#039;Drawing Method&#039; select VDW&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*2&amp;quot;&#039;&#039;&#039;  for the 2&amp;lt;sup&amp;gt;nd&amp;lt;/sup&amp;gt; active MM region,  from the &#039;Drawing Method&#039; select CPK&lt;br /&gt;
  &#039;&#039;&#039;name &amp;quot;.*3&amp;quot;&#039;&#039;&#039; for the 3&amp;lt;sup&amp;gt;rd&amp;lt;/sup&amp;gt; frozen MM region, from the &#039;Drawing Method&#039; select Lines&lt;br /&gt;
&lt;br /&gt;
::* The highlighted layers are shown in Figure II. &lt;br /&gt;
&lt;br /&gt;
[[File:Figure_IId.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Input for ChemShell ==&lt;br /&gt;
&lt;br /&gt;
*To run a QM/MM optimisation, three input files are required:&lt;br /&gt;
  opt.chm&lt;br /&gt;
  cluster.pun&lt;br /&gt;
  ff.dat&lt;br /&gt;
*MolCluster will not generate cluster.pun, but it generates cluster_n.chm which is used to generate cluster.pun&lt;br /&gt;
*To generate cluster.pun from cluster_n.chm, load ChemShell and then run cluster_n.chm directly on the cx1 login shell&lt;br /&gt;
  &amp;lt;pre&amp;gt;module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&amp;lt;/pre&amp;gt;&lt;br /&gt;
::&#039;&#039;&#039;NB&#039;&#039;&#039;: check the connectivity in the cluster.pun &lt;br /&gt;
*edit the opt.chm according to the system under study&lt;br /&gt;
*open opt.chm and edit the &#039;qm_theory&#039; options (nproc, scfconv, g98_mem, charge, multiplicity, basis set, method etc )&lt;br /&gt;
*include the conn and mxexcl after the mm_theory. mxexcl depends on the QM region, please refer ChemShell manual for more details [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/ChemShell_manual link]&lt;br /&gt;
     qm_theory=gaussian : { nproc=15 maxcyc=200 scfconv=5 basis=631gdp g98_mem=640000000 charge=0 mult=2 hamiltonian=b3lyp } \&lt;br /&gt;
      mm_theory=dl_poly : { mm_defs=ff.dat \&lt;br /&gt;
      conn=cluster.pun \&lt;br /&gt;
      mxexcl=500 \&lt;br /&gt;
&#039;&#039;&#039;NB:&#039;&#039;&#039; please make sure that there is no space left after the backslash in every line. If there is any space after the &#039;\&#039;, the job will be terminated&lt;br /&gt;
*the submit script, submit_opt.sh, to run ChemShell optimisation is here  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
*the ChemShell optimisation creates as set of checkpoint files, gaussian files and &#039;path&#039; files along with the output &#039;opt.out&#039;&lt;br /&gt;
*load &#039;path_active.xyz&#039; in VMD to follow the optimisation&lt;br /&gt;
&lt;br /&gt;
*&#039;&#039;&#039;To restart a job&#039;&#039;&#039;&lt;br /&gt;
::*rename the &#039;op.out&#039; to &#039;opt.out-n&#039; (n=1,2,3..), else the previous opt.out will be overwritten and will loose the data. Please maintain the format as &#039;opt.out-n&#039;, since the python script to analyse the data reads this file format&lt;br /&gt;
:*open opt.chm&lt;br /&gt;
::::*increase maxcyle at the end of the file and add &#039;restart = yes \&#039; command as the second last line&lt;br /&gt;
&lt;br /&gt;
      list_option = full \&lt;br /&gt;
      maxcycle = 1500 \&lt;br /&gt;
      dump = 1 \&lt;br /&gt;
      restart = yes \&lt;br /&gt;
      result = cluster_opt.pun&lt;br /&gt;
::*edit the submit script to read the checkpoint files before submitting the job [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt.sh link]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
::*To run ChemShell in Cartesian coordinate (MolCluster1.7):&lt;br /&gt;
&lt;br /&gt;
::*open opt.chm and delete the lines:&lt;br /&gt;
  coordinates=hdlc \&lt;br /&gt;
  residues=&lt;br /&gt;
::* then run &lt;br /&gt;
  module load chemshell/3.5.0 &lt;br /&gt;
  chemsh.x cluster_n.chm&lt;br /&gt;
*follow the same steps as in the previous case&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
*Analysis of the ChemShell optimisation &lt;br /&gt;
::* A python utility has been developed by Vincent to extract the various contributions to the total QM/MM energy, atom-atom distances and other parameters from the ChemShell output&lt;br /&gt;
:::*Among the files generated &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; lists the number of each of the water oxygens in the first salvation shell (here for the first salvation shell of Cu along with the distance of each of the Ow from Cu) and &#039;n&#039; is the cluster number [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/Cu_OW_first_solvation link]&lt;br /&gt;
*To trace back the particular water molecule in the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; to the DL_POLY HISTORY file, first map it to the Ow atom number in the opt.chm&lt;br /&gt;
*To map the Ow number to that in opt.chm, go to &#039;active_atoms&#039; in opt.chm&lt;br /&gt;
&amp;lt;pre&amp;gt;active_atoms = { 1 2 3 4 5 6 7 8 9 13 14 15 16 17 18 31 32 33 52 53 54 55 56 57 58 59 60 61 62 63 67 68 69 73 74 75 76 77 78 79 80 81 85 86 87 88 89 90  &amp;lt;/pre&amp;gt;&lt;br /&gt;
*bring the curser to &#039;{&#039; &lt;br /&gt;
*say for example the Ow number from the &#039;n_Cu_OW_first_solvation_shell_init_and_final_dist.txt&#039; is 163, type &#039;163&#039; and press &#039;w&#039;&lt;br /&gt;
*It will give the Ow number in opt.chm (e.g365). to go back to &#039;{&#039;, enter163 and press &#039;b&#039;&lt;br /&gt;
*In the cluster folder has &#039;atom_no_mapping.txt&#039; created by MolCluster, which contain a list of &#039;orig_atom_no&#039; and &#039; new_atom_no&#039;. &#039;orig_atom_no&#039; is the number in the HISTORY file and &#039;new_atom_no&#039; is the corresponding atom number in the opt.chm&lt;br /&gt;
*open &#039;atom_no_mapping.txt&#039; and map the atom number &#039;365&#039; to  &#039;orig_atom_no&#039; list. &lt;br /&gt;
*e.g if the  &#039;orig_atom_no&#039; is &#039;643&#039;, use &#039;643&#039; in the script to draw the path of the centre of mass of a molecule throughout an animation [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/VmdScriptsMapCoMoverTraj link]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Step-By-Step Example: Ionic Liquid Clusters==&lt;br /&gt;
&lt;br /&gt;
Our example system:&lt;br /&gt;
* 256 ion pairs of [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;]&lt;br /&gt;
* In total, the production run is 20ns in length; 4 lots of 5ns employing the &amp;quot;restart&amp;quot; keyword in DL_Poly.  &lt;br /&gt;
* Our aim is to cut clusters from the last 5ns of the trajectory and create the input files for a ChemShell optimisation. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
1). Create a directory within the main MolCluster directory and put the &#039;&#039;&#039;HISTORY&#039;&#039;&#039; and &#039;&#039;&#039;FIELD&#039;&#039;&#039; files here. Our directory will be called: &#039;&#039;&#039;BMIM_MESO4_EXAMPLE&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2). We now need to check to see if the HISTORY and FIELD files are in the correct format.&lt;br /&gt;
&lt;br /&gt;
*As the &#039;&#039;restart&#039;&#039; keyword has been employed, two lines are missing from the header of the HISTORY file, &#039;&#039;&#039;Figure 1a&#039;&#039;&#039; and &#039;&#039;&#039;1b&#039;&#039;&#039;. MolCluster does not like this. Therefore, we need to add in the two lines that it is expecting to see, &#039;&#039;&#039;Figure 1c&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MolCluster-HISTORY-header.png|frame|center|850px|&#039;&#039;&#039;Figure 1&#039;&#039;&#039;. Headers from selected HISTORY files &#039;&#039;&#039;(a)&#039;&#039;&#039; first 5ns of our simulation, without the use of the restart keyword, &#039;&#039;&#039;(b)&#039;&#039;&#039; last 5ns of our simulation with the restart keyword and &#039;&#039;&#039;(c)&#039;&#039;&#039; same HISTORY file as in (b), with missing lines added in.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*The second problem we need to address is the atom labelling. The original atom labelling for [C&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;C&amp;lt;sub&amp;gt;1&amp;lt;/sub&amp;gt;im][MeSO&amp;lt;sub&amp;gt;4&amp;lt;/sub&amp;gt;], as used in the DL_Poly simulation, is shown in &#039;&#039;&#039;Figure 2a&#039;&#039;&#039;. Unfortunately, ChemShell has issues with this. To keep ChemShell happy, we have to change the atom labels in the HISTORY and FIELD files to the format &#039;&#039;elementsymbolnumber&#039;&#039; e.g. C2 rather than CR. Thankfully, this is quite easy to do using a script (&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;, see below) written by Vincent. Firstly, however, we need to decide upon the new atom labelling. This is shown in &#039;&#039;&#039;Figure 2b&#039;&#039;&#039; for our example system. &#039;&#039;&#039;sub_script.sh&#039;&#039;&#039; requires that we have defined the atom label mappings in a file called &#039;&#039;&#039;sub_map.txt&#039;&#039;&#039; (also shown below for this system).  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:BMIM-MESO4-numbering.png|thumb|center|850px|&#039;&#039;&#039;Figure 2&#039;&#039;&#039;. Original atom labelling (as used in DL_POLY MD simulation) shown in &#039;&#039;&#039;(a)&#039;&#039;&#039; and new atom labelling (suitable for MolCluster) shown in &#039;&#039;&#039;(b)&#039;&#039;&#039;. Within &#039;&#039;&#039;(b)&#039;&#039;&#039;, atom labels that already had the correct format are in red.  ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_script.sh&#039;&#039;&#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;#!/bin/bash&lt;br /&gt;
&lt;br /&gt;
while read line&lt;br /&gt;
&lt;br /&gt;
do&lt;br /&gt;
&lt;br /&gt;
#echo $line&lt;br /&gt;
&lt;br /&gt;
s1=$(echo $line | awk &#039;{ print $1 }&#039;)&lt;br /&gt;
&lt;br /&gt;
s2=$(echo $line | awk &#039;{ print $2 }&#039;)&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;$s1 $s2&amp;quot;&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; FIELD&lt;br /&gt;
&lt;br /&gt;
gsed -i_bu2 &amp;quot;s|\&amp;lt;$s1\&amp;gt;|$s2|g&amp;quot; HISTORY&lt;br /&gt;
&lt;br /&gt;
done &amp;lt; sub_map.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;sub_map.txt&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;pre&amp;gt;CR C3&lt;br /&gt;
&lt;br /&gt;
NA N1&lt;br /&gt;
&lt;br /&gt;
CW C4&lt;br /&gt;
&lt;br /&gt;
HCR H2&lt;br /&gt;
&lt;br /&gt;
HCW H3&lt;br /&gt;
&lt;br /&gt;
HC H4&lt;br /&gt;
&lt;br /&gt;
CT C6&lt;br /&gt;
&lt;br /&gt;
OS4 O4&lt;br /&gt;
&lt;br /&gt;
OC4 O5&lt;br /&gt;
&lt;br /&gt;
HS4 H5&lt;br /&gt;
&lt;br /&gt;
CS C5&lt;br /&gt;
&lt;br /&gt;
CS4 C7&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Run &#039;&#039;&#039;./sub_script.sh&#039;&#039;&#039;&lt;br /&gt;
Note: this process may take a while, depending on the size of the file. Progress can be seen in the terminal (example shown in &#039;&#039;&#039;Figure 3&#039;&#039;&#039;), with each of the mappings specified in sub_map.txt considered in turn. The first few lines of the HISTORY file, before, and after, the relabelling can be seen in &#039;&#039;&#039;Figure 4&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:sub_map_mappings.png|thumb|center|800px|&#039;&#039;&#039;Figure 3&#039;&#039;&#039;. Example terminal output whilst running sub_script.sh ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:HISTORY-before-after.png|thumb|center|1000px|&#039;&#039;&#039;Figure 4&#039;&#039;&#039;. First few lines of the HISTORY file before &#039;&#039;&#039;(a)&#039;&#039;&#039; and after &#039;&#039;&#039;(b)&#039;&#039;&#039; the relabelling. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
3). Now our files are in the correct format, we can run MolCluster: &#039;&#039;&#039;./MolCluster.py&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
4). The first thing MolCluster does is to ask us to specify the directory containing the FIELD and HISTORY files. Our directory is called BMIM_MESO4_EXAMPLE. Once this has been specified, MolCluster will attempt to read the files and generate a summary of the system (from timestep 1 of the trajectory). This is shown in &#039;&#039;&#039;Figure 5&#039;&#039;&#039; for our system, and it can be seen that the information summarised by MolCluster is correct.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-read-files-annotate.png|thumb|center|800px|&#039;&#039;&#039;Figure 5&#039;&#039;&#039;. After specifying the directory for the FIELD and HISTORY files, MolCluster summarises the bulk system information.   ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
5). MolCluster works out how many configurations in the HISTORY file (5000 in our example) and then asks us to specify the configurations we would like to cut a cluster from. In this case, we are going to select the &#039;&#039;&#039;[n]&#039;&#039;&#039; option (cut a cluster from every &#039;n&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt;&#039; configuration) and then specify n as an integer, in this case 1000 (i.e. n=1000, therefore cut a cluster every 1000&amp;lt;sup&amp;gt;th&amp;lt;/sup&amp;gt; time step), &#039;&#039;&#039;Figure 6&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:MC-specify-config.png|thumb|center|800px|&#039;&#039;&#039;Figure 6&#039;&#039;&#039;. Specifying the configurations to create clusters for. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
6). We must now select how we would like to define the origin of the clusters to be cut. We are going to select option &#039;&#039;&#039;[AN]&#039;&#039;&#039; (atom number) and choose atom 1 to be the origin (for reference, in our case this is a C3 atom), &#039;&#039;&#039;Figure 7&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:origin-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 7&#039;&#039;&#039;. Defining the cluster origin. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
7). An estimate of the number of atoms in regions with varying radii (with respect to our defined origin) is provided by MolCluster. We need to cut a cluster large enough to incorporate a reasonable number of ion pairs (bearing in mind that our cation alone, in all trans form, is over 9 Angstroms in width), but not so large that the calculation is unfeasible. The ideal size is still being investigated, but for now, let us specify a cluster radius of 15 Angstroms, &#039;&#039;&#039;Figure 8&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster-radius-cut.png|thumb|center|900px|&#039;&#039;&#039;Figure 8&#039;&#039;&#039;. Choosing the cluster radius. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
8). MolCluster now asks us to tell it which boundary condition to use when cutting the clusters (essentially this is just how MolCluster will decide whether or not to include a molecule in the cluster for molecules at the boundary). We will select &#039;&#039;&#039;[S]&#039;&#039;&#039; (soft boundary) here. We are then asked to specify if the cluster needs to be neutral. Obviously this is only really applicable to charged systems (with counter ions), such as ionic liquids . We will select yes here, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, so that all our clusters have the same total charge, &#039;&#039;&#039;Figure 9&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:boundary-neutral.png|thumb|center|850px|&#039;&#039;&#039;Figure 9&#039;&#039;&#039;. Selecting boundary conditions. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
9). We now need to decide on the output file type. As the ultimate aim is to run QM/MM optimisations of our clusters, we need to select the options that will generate the ChemShell input files: &#039;&#039;&#039;[C]&#039;&#039;&#039;, &#039;&#039;&#039;[Y]&#039;&#039;&#039;, &#039;&#039;&#039;Figure 10&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:output-filetype.png|thumb|center|850px| ]]&lt;br /&gt;
&lt;br /&gt;
10). A decision on how the QM region will be defined is now made. We are going to select &#039;&#039;&#039;[S]&#039;&#039;&#039; (spherical region). MolCluster then estimates the number of atoms in regions of varying radii with respect to our origin. Again, as with step 7, the optimum size has not yet been deduced. However, from previous tests, a QM radius of 7 Angstroms results in a manageable number of ions and is large enough to observe local structural features. Therefore, we shall specify a radius of 7 Angstroms in this example, &#039;&#039;&#039;Figure 11&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:QM-define.png|thumb|center|800px|&#039;&#039;&#039;Figure 11&#039;&#039;&#039;. QM region defined. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
11). After defining the QM region, we then need to define the size of the active region. Again MolCluster helps us by estimating the number of atoms for a range of radii. Molecules not included in the active region, will be in the Frozen region. Fir this example, we shall define the specify active region to have a radius of 11 Angstroms, &#039;&#039;&#039;Figure 12&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Active-region .png|thumb|center|800px|&#039;&#039;&#039;Figure 12&#039;&#039;&#039;. Radius of active region specified. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
12). Finally, we are asked to specify the output directory where all our files will be placed, and the basename for each of our clusters. In this example the output directory will be &#039;&#039;BMIM_MESO4_EXAMPLE/example&#039;&#039; and the base name will be &#039;&#039;cluster&#039;&#039;, &#039;&#039;&#039;Figure 13&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:Ouput-filenames.png|thumb|center|800px| ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
13). MolCluster then sets about creating the clusters according to our specifications. The terminal output for the first cluster (cluster_1) is shown in &#039;&#039;&#039;Figure 14&#039;&#039;&#039;. After creating all the clusters, MolCluster will terminate.&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 14&#039;&#039;&#039;. Cluster_1 created. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
14). Within the named output directory, each cluster has it&#039;s own subdirectory: cluster_1, cluster_2 etc. Within each of the subdirectories can be found the requested output files, &#039;&#039;&#039;Figure 15&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
[[Image:directory-files.png|thumb|center|1100px|&#039;&#039;&#039;Figure 15&#039;&#039;&#039;. Output files. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
15). The file called system_info.txt summarises key information relating to the cluster. This is shown in &#039;&#039;&#039;Figure 16&#039;&#039;&#039; for cluster 1. We can see that in total there are 72 molecules (36 cations and 36 anions) and that, as requested, the total charge of the system is zero.&lt;br /&gt;
&lt;br /&gt;
[[Image:system-info-cluster_1.png|thumb|center|800px|&#039;&#039;&#039;Figure 16&#039;&#039;&#039;. Total system information for cluster 1. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*To find out how many molecules in the QM and active regions, we can open the file called &#039;&#039;molcluster.log&#039;&#039; in the parent directory. This is a record of all the options we selected. By scrolling through we can find the information relating to cluster 1, &#039;&#039;&#039;Figure 17&#039;&#039;&#039;, and can see that there are 9 molecules in the QM region; 4 cations and 5 anions, resulting in a total charge of -1. There are 35 molecules in the active region. &lt;br /&gt;
&lt;br /&gt;
[[Image:molcluster-log-cluster1-annot.png|thumb|center|800px|&#039;&#039;&#039;Figure 17&#039;&#039;&#039;. Information about cluster 1, found in the output file molcluster.log. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
*Returning to the files in our subdirectory &#039;&#039;cluster_1&#039;&#039;, we can open &#039;&#039;cluster.xyz&#039;&#039; (or &#039;&#039;cluster_tiered.xyz&#039;&#039;) in VMD to visualise the cut cluster, &#039;&#039;&#039;Figure 18&#039;&#039;&#039; for our cluster 1. &#039;&#039;cluster_tiered.xyz&#039;&#039; is particularly useful, as it allows us to visualise each of the distinct regions. All of the atoms in the QM region are labelled with a 1 (active labelled with 2 and frozen labelled with 3), therefore we can choose to visualise the QM region only, &#039;&#039;&#039;Figure 19a&#039;&#039;&#039;. In &#039;&#039;&#039;Figure 19b&#039;&#039;&#039;, all the regions are shown in different colours.&lt;br /&gt;
&lt;br /&gt;
[[Image:full-cluster-1.png|thumb|center|800px|&#039;&#039;&#039;Figure 18&#039;&#039;&#039;. Cluster 1 visualised in VMD. ]]&lt;br /&gt;
&lt;br /&gt;
[[Image:cluster_tiered-edit.png|thumb|center|800px|&#039;&#039;&#039;Figure 19&#039;&#039;&#039;. &#039;&#039;&#039;(a)&#039;&#039;&#039; QM region visualised in VMD. &#039;&#039;&#039;(b)&#039;&#039;&#039; All regions, visualised in different colours. ]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Cutting Embedded Cluster==&lt;br /&gt;
*Embedded clusters are first generated using MolCLuster and Chemshell &lt;br /&gt;
1. Load MolCluster: ./MolCluster.py &lt;br /&gt;
&lt;br /&gt;
2. Enter the directory containing the FIELD and HISTORY files as in the previous case&lt;br /&gt;
&lt;br /&gt;
3. Selecy option [4] to Generate ChemShell input for cutting embedded cluster&lt;br /&gt;
&lt;br /&gt;
4. then you will be asked to identify the mechanism for choosing the clusters to cut, giving n or c: &lt;br /&gt;
::*&#039;&#039;&#039;[n]&#039;&#039;&#039;: Cut a cluster every &amp;quot;nth&amp;quot; configuration. N.B: numbering starts from 1 (i.e. 1st timestep). Therefore, if you request n=1000, clusters for configurations 1, 1001, 2001 etc. will be created.&lt;br /&gt;
::*&#039;&#039;&#039;[c]&#039;&#039;&#039;: Select a custom set of configurations i.e. you can specify exactly which configurations you want.&lt;br /&gt;
After this you can choose the step at which the clusters are to be cut&lt;br /&gt;
&lt;br /&gt;
5. Once the configurations have been extracted, you will be asked to choose how the origin will be defined in the clusters to be cut. Options are:&lt;br /&gt;
::*&#039;&#039;&#039;[AN]&#039;&#039;&#039;: Atom number&lt;br /&gt;
::*&#039;&#039;&#039;[AT]&#039;&#039;&#039;: Atom type&lt;br /&gt;
::*&#039;&#039;&#039;[MN]&#039;&#039;&#039;: Molecule number&lt;br /&gt;
::*&#039;&#039;&#039;[MT]&#039;&#039;&#039;: Molecule type&lt;br /&gt;
::*&#039;&#039;&#039;[C]&#039;&#039;&#039;: Custom coordinates&lt;br /&gt;
&lt;br /&gt;
You will then see a number of options from which you can specify the exact atom number/type.&lt;br /&gt;
&lt;br /&gt;
6. Enter the radius (in Angstroms) of the embedded cluster(s) to be cut&lt;br /&gt;
&lt;br /&gt;
7. Enter the projected radius (in Angstroms) of the active regions ( this can be any value &amp;lt; embedded cluster radius)&lt;br /&gt;
&lt;br /&gt;
8. Then enter the charge margin - distance (in Angstroms) from the cluster boundary to the outer point charges&lt;br /&gt;
&lt;br /&gt;
9. enter the number of added point charges. This is calculated from the charge density; (4 * density * density + 2)&lt;br /&gt;
&lt;br /&gt;
10. enter the symbol to represent point charge &#039;X&#039;&lt;br /&gt;
&lt;br /&gt;
11.Specify the output directory&lt;br /&gt;
&lt;br /&gt;
12. The output directory will haven inputs &#039;embedded_cluster_n&#039;, if chosen &#039;n&#039; in step 4 and an embedded_cluster_specs.obj file &lt;br /&gt;
&lt;br /&gt;
13.  Upload the directory to cx1 login shell&lt;br /&gt;
&lt;br /&gt;
14. In each of the &#039;embedded_cluster_n&#039; will contain a &#039;bulk_fragment.chm&#039; having the coordinates&lt;br /&gt;
&lt;br /&gt;
15. generate bulk.pun from bulk_fragment.chm by loading chemshell &#039;module load chemshell mpi&#039; and &#039;chemsh.x bulk_fragment.chm&#039;&lt;br /&gt;
&lt;br /&gt;
16. submit the job using the submit script  [https://wiki.ch.ic.ac.uk/wiki/index.php?title=Talk:Mod:Hunt_Research_Group/submit_opt_embedded.sh link]&lt;/div&gt;</summary>
		<author><name>Aprabha</name></author>
	</entry>
</feed>