vitroid / GenIce

A swiss army knife to generate proton-disordered ice structures.
MIT License
61 stars 20 forks source link

Logo

GenIce2

A Swiss army knife to generate hydrogen-disordered ice structures.

version 2.2.5.8

New in GenIce2.2

Demo

The new GenIce works very well with interactive execution. Try instantly on Google Colaboratory.

Requirements

Note: The package management system poetry, new in GenIce version 2.1, ignores all symlinks in package directories. Because of this, some module "aliases" do not work correctly. (e.g. genice2 1h does not work, but genice ice1h does, because 1h.py is an alias for ice1h.py .)

Installation

GenIce is registered to PyPI (Python Package Index). Install with pip3.

pip3 install genice2

Uninstallation

pip3 uninstall genice2

Usage

usage: genice2 [-h] [--version] [--rep REP REP REP] [--reshape RESHAPE]
               [--shift SHIFT SHIFT SHIFT] [--dens DENS] [--add_noise percent]
               [--seed SEED] [--format name] [--water model] [--guest 14=me]
               [--Guest 13=me] [--Group 13=bu-:0] [--anion 3=Cl]
               [--cation 3=Na] [--depol DEPOL] [--asis] [--debug] [--quiet]
               [--assess_cages]
               Type

GenIce is a swiss army knife to generate hydrogen-disordered ice structures.
(version 2.2.5.8.1)

positional arguments:
  Type                  Crystal type (1c, 1h, etc. See
                        https://github.com/vitroid/GenIce for available ice
                        structures.)
                        If you want to analyze your own structures, please try
                        analice tool.

                        [Available lattice structures]

                        1. Lattice structures served with GenIce

                        0, ice0         Metastable ice "0".
                        11, XI, ice11   A candidate for an antiferroelectric
                                        Ice XI #19.
                        115_2_114, 12_1_11, 144_2_7301, 151_2_4949650,
                                        153_2_155471, 176_2_5256, 207_1_4435,
                                        2_2_623457, ACO, CS4, DDR, IWV, LTA,
                                        MAR, NON, PCOD8007225, PCOD8036144,
                                        PCOD8204698, PCOD8301974, PCOD8321499,
                                        PCOD8324623, SGT, SOD, engel01,
                                        engel03, engel04, engel17, engel20,
                                        engel23, engel24, engel26, engel29,
                                        engel30, engel31, engel34, sVII
                                        Hypothetical zeolitic ice
                        11i             Sixteen candidates for Ice XI.
                        12, XII, ice12  Metastable high-pressure ice XII.
                        13, XIII, ice13 Ice XIII, a hydrogen-ordered
                                        counterpart of ice V.
                        16, CS2, MTN, XVI, ice16, sII   Ultralow-density Ice
                                        XVI.
                        17, XVII, ice17 Ultralow-density Ice XVII.
                        1c, Ic, ice1c   Cubic type of ice I.
                        1h, Ih, ice1h   Most popular Ice I (hexagonal)
                        2, II, ice2     Hydrogen-ordered ice II.
                        2D3             Trilayer honeycomb ice.
                        2d, ice2d, ice2rect             A hydrogen-disordered
                                        counterpart of ice II.
                        3, III, ice3    Ice III.
                        4, IV, ice4     Ice IV.
                        4R              Orthogonalized ice IV.
                        5, V, ice5      Monoclinic ice V (testing).
                        5R              Ice V with orthogonal unit cell.
                                        (testing)
                        6, VI, ice6     Conventional high-pressure ice VI.
                        6h              Half lattice of ice VI.
                        7, VII, ice7    Conventional high-pressure ice VII.
                        8, VIII, ice8   Ice VIII, a hydrogen-ordered
                                        counterpart of ice VII.
                        9, IX, ice9     Ice IX, a hydrogen-ordered counterpart
                                        of ice III.
                        A, iceA         Hypothetical ice A.
                        A15, Struct33   Cubic Structure I of clathrate hydrate.
                        B, iceB         Hypothetical ice B.
                        BSV, engel05    Hypothetical zeolitic ice of the gyroid
                                         structure.
                        C14, C15, C36, FK6layers, FK9layers, HS2, Hcomp,
                                        Struct01, Struct03, Struct04, Struct05,
                                         Struct06, Struct07, Struct08,
                                        Struct09, Struct10, Struct11, Struct12,
                                         Struct13, Struct14, Struct15,
                                        Struct16, Struct17, Struct18, Struct19,
                                         Struct20, Struct21, Struct22,
                                        Struct23, Struct24, Struct25, Struct26,
                                         Struct27, Struct28, Struct29,
                                        Struct30, Struct31, Struct32, Struct34,
                                         Struct35, Struct36, Struct37,
                                        Struct38, Struct39, Struct40, Struct41,
                                         Struct42, Struct43, Struct44,
                                        Struct45, Struct46, Struct47, Struct48,
                                         Struct49, Struct50, Struct51,
                                        Struct52, Struct53, Struct54, Struct55,
                                         Struct56, Struct57, Struct58,
                                        Struct59, Struct60, Struct61, Struct62,
                                         Struct63, Struct64, Struct65,
                                        Struct66, Struct67, Struct68, Struct69,
                                         Struct70, Struct71, Struct72,
                                        Struct73, Struct74, Struct75, Struct76,
                                         Struct77, Struct78, Struct79,
                                        Struct80, Struct81, Struct82, Struct83,
                                         Struct84, Z, delta, mu, psigma, sV,
                                        sigma, zra-d     A space fullerene.
                        CRN1, CRN2, CRN3                A continuous random
                                        network of Sillium.
                        CS1, MEP, sI    Clathrate hydrates sI.
                        DOH, HS3, sH    Clathrate type H.
                        EMT             Hypothetical ice with a large cavity.
                        FAU             Hypothetical ice at negative pressure
                                        ice 'sIV'.
                        RHO             Hypothetical ice at negative pressure
                                        ice 'sIII'.
                        Struct02        A space fullerene. (I phase?)
                        T               Hypothetical clathrate type T.
                        XIc-a           A candidate for the proton-ordered
                                        counterpart of ice Ic. The structure
                                        'a' in Figure 1.
                        bilayer         A Bilayer Honeycomb Ice Phase in
                                        Hydrophobic Nanopores.
                        c0te            Filled ice C0 by Teeratchanan
                                        (Hydrogen-disordered.) (Positions of
                                        guests are supplied.)
                        c1te            Hydrogen-ordered hydrogen hydrate C1 by
                                         Teeratchanan. (Positions of guests are
                                         supplied.)
                        c2te            Filled ice C2 (cubic ice) by
                                        Teeratchanan (Hydrogen disordered).
                                        (Positions of guests are supplied.)
                        eleven          Ice XI w/ stacking faults.
                        i               Hypothetical ice "i".
                        ice1hte         Filled ice Ih by Teeratchanan (Hydrogen
                                         disordered). (Positions of guests are
                                        supplied.)
                        iceR            Hypothetical ice R.
                        iceT            Hypothetical ice T.
                        iceT2           Hypothetical ice T2.
                        one             Ice I w/ stacking disorder.
                        oprism          Hydrogen-ordered ice nanotubes.
                        sTprime         Filled ice sT'.
                        xFAU            Aeroice xFAU.
                        xdtc            A porous ice with cylindrical channels.
                        ----
                        (Undocumented) 1h_unit HS1 TS1 dtc ice1h_unit sIII sIV

                        2. Lattice structures served by external plugins

                        cif             Read a CIF file.
                        ----
                        (Undocumented) zeolite

                        3. Lattice structures served locally

                        (None)
                        ----

options:
  -h, --help            show this help message and exit
  --version, -V         show program's version number and exit
  --rep REP REP REP, -r REP REP REP
                        Repeat the unit cell along a, b, and c axes. [1,1,1]
  --reshape RESHAPE, -R RESHAPE
                        Convert the unit cell shape by specifying the new
                        (a,b,c) set from the original (a,b,c) of the unit
                        cell. The combination of (a,b,c) is specified by nine
                        integers. For example, '--reshape 3,0,0,0,2,0,0,0,1'
                        specifies that the new cell vectors are (3a, 2b, c),
                        which is equivalent to '--rep 3 2 1'.
  --shift SHIFT SHIFT SHIFT, -S SHIFT SHIFT SHIFT
                        Shift the unit cell along a, b, and c axes. (0.5==half
                        cell) [0,0,0]
  --dens DENS, -d DENS  Specify the ice density in g/cm3 (Guests are not
                        included.)
  --add_noise percent   Add a Gauss noise with given width (SD) to the
                        molecular positions of water. The value 1 corresponds
                        to 1 percent of the molecular diameter of water.
  --seed SEED, -s SEED  Random seed [1000]
  --format name, -f name
                        Specify the output file format. [gromacs]

                        [Available formatters]

                        1. Formatters served with GenIce

                        _KG             Kirkworrd G factor.
                        _ringstat       Bond direction statistics.
                        d, digraph      Directed graph of HBs.
                        e, euler        Rigid rotor (Euler angle).
                        exmol           Extended XMol file format.
                        exyz            Extended XYZ format.
                        g, gromacs      Gromacs .gro file.
                        graph           Undirected graph of HBs.
                        m, mdview       MDView file (in Angdtrom).
                        mdv_au          MDView file (in au).
                        p, python       Cell-reshaper.
                        povray          Povray.
                        q, quaternion   Rigid rotor (Quaternion).
                        raw             Raw data. (For use with Jupyter)
                        rings           Show rings in Yaplot.
                        y, yaplot       Yaplot.
                        ----
                        (Undocumented) c cif cif2 com null r rcom towhee xyz

                        2. Formatters served by external plugins

                        cage            Cage analysis.
                        mdanalysis      MDAnalysis integration.
                        png             PNG (Portable Network Graphics).
                        svg             SVG (Standard Vector Graphics).
                        ----

                        3. Formatters served locally

                        (None)
                        ----

  --water model, -w model
                        Specify the water model. [tip3p]

                        [Available molecules]

                        1. Molecules served with GenIce

                        3site, tip3p    A typical 3-site model.
                        4site, tip4p    A typical 4-site model.
                        5site, tip5p    A typical 5-site model.
                        6site, NvdE     A 6-site water model.
                        7site           A seven-site water model.
                        physical_water  Physical model of water; Oxygen atom is
                                         on the lattice point.
                        ----
                        (Undocumented) ice spce

                        2. Molecules served by external plugins

                        (None)
                        ----

                        3. Molecules served locally

                        (None)
                        ----

  --guest 14=me, -g 14=me
                        Specify guest(s) in the cage type. (D=empty,
                        T=co2*0.5+me*0.3, etc.)

                        [Available molecules]

                        1. Molecules served with GenIce

                        H2              Hydrogen molecule.
                        ch4             An all-atom methane model.
                        et              A united-atom ethane model.
                        me              A united-atom methane model.
                        mol             Loader for MOL files (generated by
                                        MolView.org), e.g. mol[THF.mol].
                        thf             An all-atom tetrahydrofuran (THF)
                                        model.
                        uathf           A united-atom five-site tetrahydrofuran
                                         (THF) model.
                        ----
                        (Undocumented) co2 empty g12 g14 g15 g16 one uathf6

                        2. Molecules served by external plugins

                        (None)
                        ----

                        3. Molecules served locally

                        (None)
                        ----

  --Guest 13=me, -G 13=me
                        Specify guest in the specific cage. (13=me, 32=co2,
                        etc.)
  --Group 13=bu-:0, -H 13=bu-:0
                        Specify the group. (-H 13=bu-:0, etc.)
  --anion 3=Cl, -a 3=Cl
                        Specify a monatomic anion that replaces a water
                        molecule. (3=Cl, 39=F, etc.)
  --cation 3=Na, -c 3=Na
                        Specify a monatomic cation that replaces a water
                        molecule. (3=Na, 39=NH4, etc.)
  --depol DEPOL         Depolarization. (strict, optimal, or none) ["strict"]
  --asis                Assumes all given HB pairs to be fixed. No shuffle and
                        no depolarization.
  --debug, -D           Output debugging info.
  --quiet, -q           Do not output progress messages.
  --assess_cages, -A    Assess the locations of cages based on the HB network
                        topology. Note: it may fail when the unit cell is too
                        small.

Use ./genice.x instead of genice2 if you want to use it inside the source tree.

Examples

Basics

The program generates various ice lattice with proton disorder and without defect. The total dipole moment is always set to zero (except in the case you specify --depol option). The minimal structure (with --rep 1 1 1 option) is not always the unit cell of the lattice because it is difficult to deal with the hydrogen bond network topology of tiny lattice under periodic boundary condition. Note that the generated structure is not optimal according to the potential energy.

GenIce is a modular program; it reads a unit cell data from a lattice plugin defined in the lattices folder, put water and guest molecules using a molecule plugin defined in the molecules/ folder, and output in various formats using a format plugin defined in the formats/ folder. You can write your plugins to extend GenIce. Some plugins also accept options.

Clathrate hydrates

For clathrate hydrates, you can prepare the lattice with cages partially occupied by various guest molecules.

Although only a few kinds of guest molecules are preset, you can easily prepare new guest molecules as a module. Here is an example of the ethylene oxide molecule.

import numpy as np
import genice2.molecules

class Molecule(genice2.molecules.Molecule):
    def __init__(self):
        # United-atom EO model with a dummy site
        LOC = 0.1436 # nm
        LCC = 0.1472 # nm

        Y = (LOC**2 - (LCC/2)**2)**0.5

        self.sites = np.array([[ 0.,    0., 0. ],
                               [-LCC/2, Y,  0. ],
                               [+LCC/2, Y,  0. ],])

        mass = np.array([16,14,14])
        # center of mass
        CoM = mass @ self.sites / np.sum(mass)
        self.sites -= CoM

        self.atoms_  = ["O","C","C"]
        self.labels_ = ["Oe","Ce","Ce"]
        self.name_   = "EO"

Write the code in eo.py. Make a folder named molecules in the current working directory and put it in.

Note: multiple occupancy is not implemented. If it is required, make a module of a virtual molecule that contains multiple molecules.

Doping ions

Small ions may replace the host molecules. In that case, you can use -a and -c options to replace the specified water molecules with anions and cations.

The following example replaces the 0th water molecule (in the replicated lattice) with Na cation and 1st water molecule with Cl anion. The hydrogen bonds around the ions are organized appropriately.

genice2 CS2 --depol=optimal -c 0=Na -a 1=Cl > CS2.gro

Note 1: The numbers of cations and anions must be the same. Otherwise, the ice rule is never satisfied and the program does not stop.

Note 2: The option --depol=optimal is also required because it is impossible to completely depolarize the structure containing ions.

Note 3: Protonic defects (H3O+ and OH-) are not yet implemented.

Semiclathrate hydrates

Placement of a tetrabutylammonium ion (testing)

Let us assume that the id of the water molecule to be replaced by nitrogen of the TBA as zero. Place the nitrogen as a cation and also replace the water 2 by the counter-ion Br.

genice2 HS1 -c 0=N -a 2=Br --depol=optimal > HS1.gro

Then you will see the following info.

INFO   Hints:
INFO     Cage types: ['12', '14', '15']
INFO     Cage type 12: {0, 1, 2, 3, 4, 5}
INFO     Cage type 14: {8, 9, 6, 7}
INFO     Cage type 15: {10, 11, 12, 13}
...
INFO Stage7: Arrange guest atoms.
INFO     Cages adjacent to dopant 2: {0, 9, 2, 13}
INFO     Cages adjacent to dopant 0: {0, 9, 2, 7}

It indicates that the nitrogen is surrounded by cages with ids 0, 9, 2, and 7. Types for these cages can also be found in the info. Then, we put the Bu- group (minus does not mean ions) in these cages adjacent to dopant 0.

genice2 HS1 -c 0=N -a 2=Br -H 0=Bu-:0 -H 9=Bu-:0 -H 2=Bu-:0 -H 7=Bu-:0 --depol=optimal > HS1.gro

Here the option -H specifies the group by -H (cage id)=(group name):(root), and the root is the nitrogen that is specified by -c (cation) option.

Placement of TBAB in the lattice module

Under preparation

It is more convenient if the lattice of the semiclathrate hydrate contains molecular ions in the appropriate locations in advance. Here we explain the way to make the special module for semclathrates.

Output formats

Name Application extension water solute HB remarks
cif, cif2 CIF .cif Atomic positions Atomic positions none Experimental
g, gromacs Gromacs .gro Atomic positions Atomic positions none Default format.
m, mdview MDView .mdv Atomic positions Atomic positions auto
mdv_au MDView .mdv Atomic positions Atomic positions auto In atomic unit.
o, openscad OpenSCAD .scad Center of mass none o See tests/art/openscad for usage.
povray Povray .pov Atomic positions Atomic Positions o
towhee TowHee .coords(?) Atomic positions Atomic positions none
xyz XYZ .xyz Atomic positions Atomic positions none Experimental
exyz extended XYZ .xyz Atomic positions Atomic positions none Extended XYZ format defined in Open Babel
exyz2 extended XYZ .xyz Atomic positions Atomic positions none Extended XYZ format defined in QUIP
y, yaplot Yaplot .yap Atomic positions Atomic positions o It renders molecular configurations and the HB network.
e, euler Euler angles .nx3a Rigid rotor none none
q, quaternion Quaternions .nx4a Rigid rotor none none
d, digraph Digraph .ngph none none o
graph Graph .ngph none none o Experimental.
c, com CenterOfMass .ar3a Center of mass none none
r, rcom Relative CoM .ar3r Center of mass none none In fractional coordinate system.
p, python, reshape Python module .py Center of mass none none Under development.
_ringstat Ring phase statistics Statistical test suite 1: Check the appearance frequencies of the ring phases as a test for the intermediate-range disorder.
rings Yaplot .yap center of mass none o It renders HB rings.
_KG Kirkwood G(r) Statistical test suite 2: Calculate G(r) for checking long-range disorder in molecular orientations.

By installing the genice2-mdanalysis package separately, you can generate files in many formats for a large number of molecular dynamics package softwares. E.g.

% pip install genice2-mdanalysis
% genice2 1c -f 'mdanalysis[1c.pdb]'
% genice2 1h -f 'mdanalysis[1h.xtc]'

All the supported file types are listed in the MDAnalysis web page.

You can prepare your file formats. Create a folder named formats in the current working directory and put the plugins in it.

Internally, there are seven stages to generate an ice structure.

  1. Cell repetition.
  2. Random graph generation and replication.
  3. Apply ice rule.
  4. Depolarize.
  5. Determine orientations of the water molecules.
  6. Place atoms in water molecules.
  7. Place atoms in guests.

In the format plugin, you define the hook functions that are invoked after processing each stage.

Ice structures

Symbol
Description
0, ice0 Metastable ice "0". [Russo 2014]
11, XI, ice11 A candidate for an antiferroelectric Ice XI #19. [Jackson 1997, Fan 2010]
115_2_114, 12_1_11, 144_2_7301, 151_2_4949650, 153_2_155471, 176_2_5256, 207_1_4435, 2_2_623457, ACO, CS4, DDR, IWV, LTA, MAR, NON, PCOD8007225, PCOD8036144, PCOD8204698, PCOD8301974, PCOD8321499, PCOD8324623, SGT, SOD, engel01, engel03, engel04, engel17, engel20, engel23, engel24, engel26, engel29, engel30, engel31, engel34, sVII Hypothetical zeolitic ice [Jeffrey 1984, Kosyakov 1999, Engel 2018, IZA Database]
11i Sixteen candidates for Ice XI. [Hirsch 2004]
12, XII, ice12 Metastable high-pressure ice XII. [Lobban 1998, Koza 2000]
13, XIII, ice13 Ice XIII, a hydrogen-ordered counterpart of ice V. [Salzmann 2006]
16, CS2, MTN, XVI, ice16, sII Ultralow-density Ice XVI. [Jeffrey 1984, Kosyakov 1999, Sikiric 2010, Falenty 2014, IZA Database]
17, XVII, ice17 Ultralow-density Ice XVII. [Smirnov 2013, Rosso 2016, Strobel 2016]
1c, Ic, ice1c Cubic type of ice I. [Vos 1993]
1h, Ih, ice1h Most popular Ice I (hexagonal)
2, II, ice2 Hydrogen-ordered ice II. [Kamb 1964, Londono 1988, Kamb 2003]
2D3 Trilayer honeycomb ice.
2d, ice2d, ice2rect A hydrogen-disordered counterpart of ice II. [Nakamura 2015]
3, III, ice3 Ice III. [Petrenko 1999]
4, IV, ice4 Ice IV. [Avogadro]
4R Orthogonalized ice IV. [Avogadro]
5, V, ice5 Monoclinic ice V (testing).
5R Ice V with orthogonal unit cell. (testing)
6, VI, ice6 Conventional high-pressure ice VI. [Petrenko 1999]
6h Half lattice of ice VI.
7, VII, ice7 Conventional high-pressure ice VII.
8, VIII, ice8 Ice VIII, a hydrogen-ordered counterpart of ice VII. [Kuhs 1998]
9, IX, ice9 Ice IX, a hydrogen-ordered counterpart of ice III. [Londono 1993]
A, iceA Hypothetical ice A. [Baez 1998]
A15, Struct33 Cubic Structure I of clathrate hydrate. [Sikiric 2010]
B, iceB Hypothetical ice B. [Baez 1998]
BSV, engel05 Hypothetical zeolitic ice of the gyroid structure. [Engel 2018, IZA Database]
C14, C15, C36, FK6layers, FK9layers, HS2, Hcomp, Struct01, Struct03, Struct04, Struct05, Struct06, Struct07, Struct08, Struct09, Struct10, Struct11, Struct12, Struct13, Struct14, Struct15, Struct16, Struct17, Struct18, Struct19, Struct20, Struct21, Struct22, Struct23, Struct24, Struct25, Struct26, Struct27, Struct28, Struct29, Struct30, Struct31, Struct32, Struct34, Struct35, Struct36, Struct37, Struct38, Struct39, Struct40, Struct41, Struct42, Struct43, Struct44, Struct45, Struct46, Struct47, Struct48, Struct49, Struct50, Struct51, Struct52, Struct53, Struct54, Struct55, Struct56, Struct57, Struct58, Struct59, Struct60, Struct61, Struct62, Struct63, Struct64, Struct65, Struct66, Struct67, Struct68, Struct69, Struct70, Struct71, Struct72, Struct73, Struct74, Struct75, Struct76, Struct77, Struct78, Struct79, Struct80, Struct81, Struct82, Struct83, Struct84, Z, delta, mu, psigma, sV, sigma, zra-d A space fullerene. [Sikiric 2010]
CRN1, CRN2, CRN3 A continuous random network of Sillium. [Mousseau 2001]
CS1, MEP, sI Clathrate hydrates sI. [Frank 1959, Jeffrey 1984, Kosyakov 1999, IZA Database]
DOH, HS3, sH Clathrate type H.
EMT Hypothetical ice with a large cavity. [Liu 2019, IZA Database]
FAU Hypothetical ice at negative pressure ice 'sIV'. [Huang 2017, IZA Database]
RHO Hypothetical ice at negative pressure ice 'sIII'. [Huang 2016, IZA Database]
Struct02 A space fullerene. (I phase?) [Sikiric 2010]
T Hypothetical clathrate type T. [Sikiric 2010, Karttunen 2011]
XIc-a A candidate for the proton-ordered counterpart of ice Ic. The structure 'a' in Figure 1. [Geiger 2014]
bilayer A Bilayer Honeycomb Ice Phase in Hydrophobic Nanopores. [Koga 1997]
c0te Filled ice C0 by Teeratchanan (Hydrogen-disordered.) (Positions of guests are supplied.) [Teeratchanan 2015]
c1te Hydrogen-ordered hydrogen hydrate C1 by Teeratchanan. (Positions of guests are supplied.) [Teeratchanan 2015]
c2te Filled ice C2 (cubic ice) by Teeratchanan (Hydrogen disordered). (Positions of guests are supplied.) [Teeratchanan 2015]
eleven Ice XI w/ stacking faults.
i Hypothetical ice "i". [Fennell 2005]
ice1hte Filled ice Ih by Teeratchanan (Hydrogen disordered). (Positions of guests are supplied.) [Teeratchanan 2015]
iceR Hypothetical ice R. [Maynard-Casely 2010, Mochizuki 2014]
iceT Hypothetical ice T. [Hirata 2017]
iceT2 Hypothetical ice T2. [Yagasaki 2018]
one Ice I w/ stacking disorder.
oprism Hydrogen-ordered ice nanotubes. [Koga 2001]
sTprime Filled ice sT'. [Smirnov 2013]
xFAU Aeroice xFAU. [Matsui 2017]
xdtc A porous ice with cylindrical channels. [Matsumoto 2021]
1h_unit, HS1, TS1, dtc, ice1h_unit, sIII, sIV (Undocumented)

Ice names with double quotations are not experimentally verified.

You can prepare your own ice structures. Create a folder named lattices in the current working directory and put the plugins in it.

cif2ice is a tool to retrieve a cif file of zeolite from IZA structure database and prepare a lattice module in the path above.

Note: Different names are given in different nomenclature.

CH/FI CH ice FK Zeo Foam
sI CS1 - A15 MEP Weaire-Phelan
sII CS2 16 C15 MTN
sIII TS1 - sigma -
sIV HS1 - Z -
sV HS2 - * -
sVII CS4 - * SOD Kelvin
sH HS3 - * DOH
C0 - 17 * -
C1 - 2 * -
C2 - 1c * -

FI: Filled ices; CH: Clathrate hydrates; FK:Frank-Kasper duals; Zeo: Zeolites; Foam: foam crystals (Weaire 1994).

-: No correspondence; *: Non-FK types.

Please ask vitroid@gmail.com to add new ice structures.

Water models

A water model can be chosen with --water option.

symbol type
3site, tip3p A typical 3-site model.
4site, tip4p A typical 4-site model. [Jorgensen 1983, Jorgensen 1985]
5site, tip5p A typical 5-site model.
6site, NvdE A 6-site water model. [Nada 2003]
7site A seven-site water model. [Zhao 2019]
physical_water Physical model of water; Oxygen atom is on the lattice point. [Jorgensen, Chandrasekhar, Madura, Impey, Klein, J Chem Phys, 79, 926 (1983).]
ice, spce (Undocumented)

Guest molecules

symbol type
H2 Hydrogen molecule. [https://www.britannica.com/science/hydrogen]
ch4 An all-atom methane model.
et A united-atom ethane model.
me A united-atom methane model.
mol Loader for MOL files (generated by MolView.org), e.g. mol[THF.mol].
thf An all-atom tetrahydrofuran (THF) model.
uathf A united-atom five-site tetrahydrofuran (THF) model.
co2, empty, g12, g14, g15, g16, one, uathf6 (Undocumented)

You can prepare your own guest molecules. Create a folder named molecules in the current working directory and put the plugins in it.

Extra plugins

Some extra plugins are available via python package index using pip command.

For example, you can install RDF plugin by the following command,

% pip install genice2-rdf

And use it as an output format to get the radial distribution functions.

% genice2 TS1 -f _RDF > TS1.rdf.txt

Output and analysis plugins

Analysis plugin is a kind of output plugin (specified with -f option).

pip name GenIce2 option Description output format requirements
genice2-cage -f _cage Detect cages and quasi-polyhedra (vitrites). text, json, gromacs cycless
genice2-rdf -f _RDF Radial distribution functions. text
genice2-svg -f svg
-f png
2D graphics in SVG format.
... in PNG format.
SVG
PNG
svgwrite
genice2-twist -f twist Calculate the twist order parameter (and visualize) [Matsumoto 2019] text (@BTWC)
SVG
PNG
yaplot
twist-op, genice2-svg
genice2-mdanalysis -f mdanalysis Output the atoms in various file formats that are served by MDAnalysis. text, binary mdanalysis

Input plugins

Input plugins (a.k.a. lattice plugins) construct a crystal structure on demand.

pip name GenIce2 usage Description requirements
genice2-cif genice2 cif[ITT.cif]
genice2 zeolite[ITT]
Read a local CIF file as an ice structure.
Read a structure from Zeolite DB.
cif2ice

New in GenIce2.1

GenIce2-MDAnalysis integration is now available. Try

% pip install genice2-mdanalysis
% genice2 1h -r 4 4 4 -f "mdanalysis[1h.pdb]"

to generate a PDB file.

Changes from GenIce1

Novel algorithm to make a structure obeying the ice rules in Stage 3.

Faster, faster, faster.

Combinations of the new algorithm and other improvements in coding, the processing time of GenIce2 is about five times faster than that of GenIce1.

Core algorithm is separated.

The core part of the new algorithm is separated as the TileCycles package.

Colaboratory-ready!

Now GenIce2 works on the Google Colaboratory!

New ices

Many new ice structures are added.

Integration with MDAnalysis

GenIce2 is now integrated with MDAnalysis.

References

Algorithms and how to cite them.

The algorithms to make a depolarized hydrogen-disordered ice are explained in these papers:

M. Matsumoto, T. Yagasaki, and H. Tanaka,"GenIce: Hydrogen-Disordered Ice Generator", J. Comput. Chem. 39, 61-64 (2017). DOI: 10.1002/jcc.25077

@article{Matsumoto:2017bk,
    author = {Matsumoto, Masakazu and Yagasaki, Takuma and Tanaka, Hideki},
    title = {GenIce: Hydrogen-Disordered Ice Generator},
    journal = {Journal of Computational Chemistry},
    volume = {39},
    pages = {61-64},
    year = {2017}
}

M. Matsumoto, T. Yagasaki, and H. Tanaka, “GenIce-core: Efficient algorithm for generation of hydrogen-disordered ice structures.”, J. Chem. Phys. 160, 094101 (2024). DOI:10.1063/5.0198056

@article{Matsumoto:2024,
    author = {Matsumoto, Masakazu and Yagasaki, Takuma and Tanaka, Hideki},
    title = {GenIce-core: Efficient algorithm for generation of hydrogen-disordered ice structures},
    journal = {Journal of Chemical Physics},
    volume = {160},
    pages = {094101},
    year = {2024}
}

How to contribute

GenIce has been available as open source software on GitHub(https://github.com/vitroid/GenIce) since 2015. Feedback, suggestions for improvements and enhancements, bug fixes, etc. are sincerely welcome. Developers and test users are also welcome. If you have any ice that is publicly available but not included in GenIce, please let us know.