Project

aims

0.0
No commit activity in last 3 years
No release in over 3 years
Support for generation and parsing of input and output files for FHI-AIMS DFT package
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0
 Project Readme

What is the Aims Gem?¶ ↑

The Aims gem is a ruby interface to the FHI-Aims ab-initio molecular simulation package published by the Fritz-Haber Institute [aimsclub.fhi-berlin.mpg.de/]. It provides a set of tools for parsing and generating the input and output files for AIMS.

The aims gem is written by Joshua Shapiro and release under the MIT license.

Copyright © Joshua Shapiro 2012

Why should I use the Aims Gem?¶ ↑

If you like Ruby, and you like AIMS, then this gem provides you with a pure Ruby object-oriented interface to AIMS. You can use this library to:

  • Simplify the generation of complex geometries

    • Bulk and common surface geometries of ZincBlende and Wurtzite are predefined.

  • Automate the generation of geometry and control files

  • Parse the output of Aims into ruby objects for analysis

  • Summarize the output of AIMS using simple scripts that come with the gem

  • Whatever else you can imagine..

Installation¶ ↑

To use this gem, you will need to have an installation of ruby. If you own a mac or a linux machine, then you already have ruby. If you have a windows machine, then you need to install ruby. The recommended way to install Ruby on windows (as of June 2012) is via rubyinstaller.org .

Once you have ruby, then just invoke the following from a terminal window.

gem install aims

Usage ¶ ↑

Using the Aims GEM to generate geometry.in files¶ ↑

The following code can be used interactively in an irb ruby interpreter, or can be invoked in a ruby script.

Example 1: Generate a primitive unit cell of Silicon¶ ↑

require 'aims'
include Aims

# Define the lattice constant
lattice_const = 5.43

# Define the basis
a1 = Atom.new(0,0,0, "Si")
a2 = Atom.new(lattice_const/4, lattice_const/4, lattice_const/4, "Si")

# Define the primitive vectors
v1 = [lattice_const/2, lattice_const/2, 0]
v2 = [lattice_const/2, 0, lattice_const/2]
v3 = [0, lattice_const/2, lattice_const/2]

# Define the unit cell
uc = Geometry.new([a1, a2], [v1, v2, v3])

# Output the unit cell
puts uc.format_geometry_in

Example 2: Shortcut for generating a primitive unit cell of Zinc-Blende¶ ↑

require 'aims'
include Aims

zb = ZincBlende.new("Ga", "As", 5.65)

# Get the bulk geometry
puts zb.get_bulk.format_geometry_in

And here is how you get a (100) surface with 7 layers and 20 angstrom of vacuum

layers = 7
vacuum = 20
puts zb.get_001_surface(layers, vacuum)

And here is how you can constrain the bottom three layers

constrain = 3
puts zb.get_001_surface(layers, vacuum, constrain)

Scripts that come with the Aims GEM¶ ↑

There are currently two scripts that come with the GEM

aims_output.rb¶ ↑

Quickly output the total energy, and timing information from the calculation to make sure everything went smoothly.

Don’t use this as a replacement for actually looking at the output of Aims.

usage: aims_output.rb [options] file1 [file2 ...]
    -s, --step [N]                   Output information for relaxation step.
                                     Specify an integer, 'first', 'last', or 'all'
                                     Default is 'all'
        --debug                      Debug output
        --geometry-delta             Display change from input geometry to final geometry
    -c, --self-consistency           Output self-consistency information
    -f                               Output max force component for each geometry relaxation step
    -t                               Output timings

aims_summary.rb¶ ↑

Display a one-line summary for a list of calculations in tabular form. Useful for copying and pasting into a spreadsheet.

usage: aims_summary.rb file1 [file2] ...