MAE715-Atomistic Modeling of Materials
(Parte 1 de 7)
QUANTUM ESPRESSO: a modular and open-source software project for quantum simulations of materials
Paolo Giannozzi,1,2 Stefano Baroni,1,3 Nicola Bonini,4 Matteo Calandra,5 Roberto Car,6 Carlo Cavazzoni,7,8 Davide Ceresoli,4 Guido L. Chiarotti,9 Matteo Cococcioni,10 Ismaila Dabo,1 Andrea Dal Corso,1,3 Stefano Fabris,1,3 Guido Fratesi,12 Stefano de Gironcoli,1,3 Ralph Gebauer,1,13 Uwe Gerstmann,14 Christos Gougoussis,5 Anton Kokalj,1,15 Michele Lazzeri,5 Layla Martin-Samos,1 Nicola Marzari,1,3 Francesco Mauri,5 Riccardo Mazzarello,16 Stefano Paolini,3,9 Alfredo Pasquarello,17 Lorenzo Paulatto,1,3 Carlo Sbraccia,1‡ Sandro Scandolo,1,13 Gabriele Sclauzero,1,3 Ari P. Seitsonen,5 Alexander Smogunov,13 Paolo Umari,1 Renata M. Wentzcovitch,18,19
1CNR-INFM Democritos National Simulation Center, 34100 Trieste, Italy 2Dipartimento di Fisica, Università degli Studi di Udine, via delle Scienze 208, 33100 Udine, Italy 3SISSA – Scuola Internazionale Superiore di Studi Avanzati, via Beirut 2-4, 34151 Trieste Grignano, Italy 4Department of Materials Science and Engineering, Massachusetts Institute of Technology, Cambridge, MA 02139 USA 5Institut de Minéralogie et de Physique des Milieux Condensés, Université Pierre et Marie Curie, CNRS, IPGP, 140 rue de Lourmel, 75015 Paris, France 6Department of Chemistry, Princeton University, Princeton NJ 08544, USA 7CINECA National Supercomputing Center, Casalecchio di Reno, 40033 Bologna, Italy 8CNR-INFM S3 Research Center, 41100 Modena, Italy 9SPIN s.r.l. via del Follatoio 12, 34148 Trieste, Italy 10Department of Chemical Engineering and Materials Science, University of Minnesota, 151 Amundson Hall, 421 Washington Avenue SE, Minneapolis MN 55455, USA 11Université Paris-Est, CERMICS, Projet Micmac ENPC-INRIA, 6-8 avenue Blaise Pascal, 77455 Marne-la-Vallée Cedex 2, France 12Dipartimento di Scienza dei Materiali, Università degli Studi di Milano-Bicocca, via Cozzi 53, 20125 Milano, Italy 13The Abdus Salam International Centre for Theoretical Physics, Strada Costiera 1, 34151 Trieste Grignano, Italy 14Theoretische Physik, Universität Paderborn, D-33098 Paderborn, Germany 15Jožef Stefan Institute, Jamova 39, SI-1000 Ljubljana, Slovenia 16Computational Science, Department of Chemistry and Applied Biosciences, ETH Zurich, USI Campus, via Giuseppe Buffi 13, CH-6900 Lugano, Switzerland 17Ecole Polytechnique Fédérale de Lausanne (EPFL), Institute of Theoretical Physics, and Institut Romand de Recherche Numérique en Physique des Matériaux (IRRMA), CH-1015 Lausanne, Switzerland
‡ Present address: Constellation Energy Commodities Group 7th Floor, 61 Aldwich, London, WC2B 4AE, United Kingdom arXiv:0906.2569v2 [cond-mat.mtrl-sci] 26 Jul 2009
QUANTUM ESPRESSO 2
18Department of Chemical Engineering and Materials Science, University of Minnesota, 151 Amundson Hall, 421 Washington Avenue SE, Minneapolis MN 55455, USA 19Minnesota Supercomputing Institute for Advanced Computational Research, University of Minnesota, Minneapolis MN 55455, USA
Abstract. QUANTUM ESPRESSO is an integrated suite of computer codes for electronicstructure calculations and materials modeling, based on density-functional theory, plane waves, and pseudopotentials (norm-conserving, ultrasoft, and projector-augmented wave). QUANTUM ESPRESSO stands for opEn Source Package for Research in Electronic Structure, Simulation, and Optimization. It is freely available to researchers around the world under the terms of the GNU General Public License. QUANTUM ESPRESSO builds upon newlyrestructured electronic-structure codes that have been developed and tested by some of the original authors of novel electronic-structure algorithms and applied in the last twenty years by some of the leading materials modeling groups worldwide. Innovation and efficiency are still its main focus, with special attention paid to massively-parallel architectures, and a great effort being devoted to user friendliness. QUANTUM ESPRESSO is evolving towards a distribution of independent and inter-operable codes in the spirit of an open-source project, where researchers active in the field of electronic-structure calculations are encouraged to participate in the project by contributing their own codes or by implementing their own ideas into existing codes.
QUANTUM ESPRESSO 3 1. Introduction
The combination of methodological and algorithmic innovations and ever-increasing computer power is delivering a simulation revolution in materials modeling, starting from the nanoscale up to bulk materials and devices . Electronic-structure simulations based on density-functional theory (DFT) [2, 3, 4] have been instrumental to this revolution, and their application has now spread outside a restricted core of researchers in condensed-matter theory and quantum chemistry, involving a vast community of end users with very diverse scientific backgrounds and research interests. Sustaining this revolution and extending its beneficial effects to the many fields of science and technology that can capitalize on it represents a multifold challenge. In our view it is also a most urgent, fascinating and fruitful endeavor, able to deliver new forms for scientific exploration and discovery, where a very complex infrastructure—made of software rather than hardware—can be made available to any researcher, and whose capabilities continue to increase thanks to the methodological innovations and computing power scalability alluded to above.
Over the past few decades, innovation in materials simulation and modeling has resulted from the concerted efforts of many individuals and groups worldwide, often of small size. Their success has been made possible by a combination of competences, ranging from the ability to address meaningful and challenging problems, to a rigorous insight into theoretical methods, ending with a marked sensibility to matters of numerical accuracy and algorithmic efficiency. The readiness to implement new algorithms that utilize novel ideas requires total control over the software being used–for this reason, the physics community has long relied on in-house computer codes to develop and implement new ideas and algorithms. Transitioning these development codes to production tools is nevertheless essential, both to extensively validate new methods and to speed up their acceptance by the scientific community. At the same time, the dissemination of codes has to be substantial, to justify the learning efforts of PhD students and young postdocs who would soon be confronted with the necessity of deploying their competences in different research groups. In order to sustain innovation in numerical simulation, we believe there should be little, if any, distinction between development and production codes; computer codes should be easy to maintain, to understand by different generations of young researchers, to modify, and extend; they should be easy to use by the layman, as well as general and flexible enough to be enticing for a vast and diverse community of end users. One easily understands that such conflicting requirements can only be tempered, if anything, within organized and modular software projects.
Software modularity also comes as a necessity when complex problems in complex materials need to be tackled with an array of different methods and techniques. Multiscale approaches, in particular, strive to combine methods with different accuracy and scope to describe different parts of a complex system, or phenomena occurring at different time and/or length scales. Such approaches will require software packages that can perform different kinds of computations on different aspects of the same problem and/or different portions of the same system, and that allow for interoperability or joint usage of the different modules.
QUANTUM ESPRESSO 4
Different packages should at the very least share the same input/output data formats; ideally they should also share a number of mathematical and application libraries, as well as the internal representation of some of the data structures on which they operate. Individual researchers or research groups find it increasingly difficult to meet all these requirements and to continue to develop and maintain in-house software project of increasing complexity. Thus, different and possibly collaborative solutions should be sought.
A successful example comes from the software for simulations in quantum chemistry, that has often (but not always) evolved towards commercialization: the development and maintenance of most well-known packages is devolved to non-profit [5, 6, 7, 8] or commercial [9, 10, 1, 12] companies. The software is released for a fee under some proprietary license that may impose several restrictions to the availability of sources (computer code in a highlevel language) and to what can be done with the software. This model has worked well, and is also used by some of the leading development groups in the condensed-matter electronicstructure community [13, 14], while some proprietary projects allow for some free academic usage of their products [15, 16, 17, 18, 19, 14]. A commercial endeavor also brings the distinctive advantage of a professional approach to software development, maintenance, documentation, and support.
We believe however that a more interesting and fruitful alternative can be pursued, and one that is closer to the spirit of science and scientific endeavor, modeled on the experience of the open-source software community. Under this model, a large community of users has full access to the source code and the development material, under the coordination of a smaller group of core developers. In the long term, and in the absence of entrenched monopolies, this strategy could be more effective in providing good software solutions and in nurturing a community engaged in providing those solutions, as compared to the proprietary software strategy. In the case of software for scientific usage, such an approach has the additional, and by no means minor, advantage to be in line with the tradition and best practice of science, that require reproducibility of other people’s results, and where collaboration is no less important than competition.
In this paper we will shortly describe our answer to the above-mentioned problems, as embodied in our QUANTUM ESPRESSO project (indeed, ESPRESSO stands for opEn Source Package for Research in Electronic Structure, Simulation, and Optimization). First, in Sec. 2, we describe the guiding lines of our effort. In Sec. 3, we give an overview of the current capabilities of QUANTUM ESPRESSO. In Sec. 4, we provide a short description of each software component presently distributed within QUANTUM ESPRESSO. In Sec. 5 we give an overview of the parallelization strategies followed and implemented in QUANTUM ESPRESSO. Finally, Sec. 6 describes current developments and offers a perspective outlook. The Appendix sections discuss some of the more specific technical details of the algorithms used, that have not been documented elsewhere.
QUANTUM ESPRESSO 5 2. The QUANTUM ESPRESSO project
QUANTUM ESPRESSO is an integrated suite of computer codes for electronic-structure calculations and materials modeling based on density-functional theory, plane waves basis sets and pseudopotentials to represent electron-ion interactions. QUANTUM ESPRESSO is free, open-source software distributed under the terms of the GNU General Public License (GPL) .
The two main goals of this project are to foster methodological innovation in the field of electronic-structure simulations and to provide a wide and diverse community of end users with highly efficient, robust, and user-friendly software implementing the most recent innovations in this field. Other open-source projects [21, 2, 23, 24, 25] exist, besides QUANTUM ESPRESSO, that address electronic-structure calculations and various materials simulation techniques based on them. Unlike some of these projects, QUANTUM ESPRESSO does not aim at providing a single monolithic code able to perform several different tasks by specifying different input data to a same executable. Our general philosophy is rather that of an open distribution, i.e. an integrated suite of codes designed to be interoperable, much in the spirit of a Linux distribution, and thus built around a number of core components designed and maintained by a small group of core developers, plus a number of auxiliary/complementary codes designed, implemented, and maintained by members of a wider community of users. The distribution can even be redundant, with different applications addressing the same problem in different ways; at the end, the sole requirements that QUANTUM ESPRESSO components must fulfill are that: i) they are distributed under the same GPL license agreement  as the other QUANTUM ESPRESSO components; i) they are fully interoperable with the other components. Of course, they need to be scientifically sound, verified and validated. External contributors are encouraged to join the QUANTUM ESPRESSO project, if they wish, while maintaining their own individual distribution and advertisement mode for their software (for instance, by maintaining individual web sites with their own brand names ). To facilitate this, a web service called qe-forge , described in the next subsection, has been recently put in place.
Interoperability of different components within QUANTUM ESPRESSO is granted by the use of common formats for the input, output, and work files. In addition, external contributors are encouraged, but not by any means forced, to use the many numerical and application libraries on which the core components are built. Of course, this general philosophy must be seen more as an objective to which a very complex software project tends, rather than a starting point.
One of the main concerns that motivated the birth of the QUANTUM ESPRESSO project is high performance, both in serial and in parallel execution. High serial performance across different architectures is achieved by the systematic use of standardized mathematical libraries (BLAS, LAPACK , and FFTW ) for which highly optimized implementations exist on many platforms; when proprietary optimizations of these libraries are not available, the user can compile the library sources distributed with QUANTUM ESPRESSO. Optimal performance in parallel execution is achieved through the design of several parallelization
QUANTUM ESPRESSO 6 levels, using sophisticated communication algorithms, whose implementation often does not need to concern the developer, being embedded and concealed in appropriate software layers. As a result the performance of the key engines, PWscf (Sec. 4.1) and CP (Sec. 4.2) may scale on massively parallel computers up to thousands of processors.
The distribution is organized into a basic set of modules, libraries, installation utilities, plus a number of directories, each containing one or more executables, performing specific tasks. The communications between the different executables take place via data files. We think that this kind of approach lowers the learning barrier for those who wish to contribute to the project. The codes distributed with QUANTUM ESPRESSO, including many auxiliary codes for the post-processing of the data generated by the simulations, are easy to install and to use. The GNU configure and make utilities ensure a straightforward installation on many different machines. Applications are run through text input files based on Fortran namelists, that require the users to specify only an essential but small subset of the many control variables available; a specialized graphical user interface (GUI) that is provided with the distribution facilitates this task for most component programs. It is foreseen that in the near future the design of special APIs (Application Programming Interfaces) will make it easier to glue different components of the distribution together and with external applications, as well as to interface them to other, custom-tailored, GUIs and/or command interpreters.
(Parte 1 de 7)