Developing of Scientific Software Applications in Python. I. Transformation of Hubbard Hamiltonian into the Matrix and its Diagonalization
Herok Łukasz 1, Szczęśniak Radosław 1,2, Durajski Artur 2*
1 Institute of Physics, Jan Długosz University
Al. Armii Krajowej 13/15, 42-200 Częstochowa, Poland2 Institute of Physics, Częstochowa University of Technology
Al. Armii Krajowej 19, 42-200 Częstochowa, Poland
*E-mail: adurajski@wip.pcz.pl
Received:
Received: 28 April 2015; revised: 06 September 2015; accepted: 07 September 2015; published online: 06 November 2015
DOI: 10.12921/cmst.2015.21.04.002
Abstract:
In order to perform larger scale physics research in the area of superconductivity, we have developed an application that can transform the Hubbard Hamiltonian into a matrix and diagonalize it to find the selected model’s energy spectrum. For that purpose we have used the Python language and its wide ecosystem. This paper proves that selected tools are capable of creating scientific applications in a general sense. After a short introduction into the physics problem and the designed algorithm we will present the computer science problems and their solutions in creating usual scientific programs, in particular: performance and parallelization issues, storage of input data and the results, bottlenecks detections, as well as optimization and testing. The most interesting examples of the developing cycle will be described to give a prepared solution for implementing the other scientific software.
Key words:
References:
[1] T.E. Oliphant, Python for Scientific Computing, Computing in
Science & Engineering 9, 10-20 (2007).
[2] D.M. Beazley, P.S. Lomdahl, Extensible Message Passing
Application Development and Debugging with Python, Proceedings
11th International Parallel Processing Symposium,
650-655 (1997).
[3] J. Spałek, Wst˛ep do fizyki materii skondensowanej, Wydawnictwo
Naukowe PWN, Warszawa 2015.
[4] H. Fangohr, Python for Computational Science and Engineering,
Faculty of Engineering and the Environment University
of Southampton, Southampton 2014.
[5] Python Software Foundation, Python Documentation,
https://docs.python.org, 2015.
[6] D.M. Beazley, Scientific Computing with Python, Astronomical
Data Analysis Software and Systems IX ASP Conference
Series 216, San Francisco 2000.
[7] D.M. Beazley, P.S. Lomdahl, Building Flexible Large-Scale
Scientific Computing Applications with Scripting Languages,
8th SIAM Conference on Parallel Processing for Scientific
Computing, Minnesota 1997.
[8] X. Cai, H. P. Langtangen, H. Moe, On the Performance of
the Python Programming Language for Serial and Parallel
Scientific Computations, Scientific Programming 13, 31-56
(2005).
[9] R.B. Lehoucq, D.C. Sorensen, C.Yang, ARPACK Users’
Guide: Solution of Large-Scale Eigenvalue Problems with
Implicitly Restarted Arnoldi Methods, University of Leeds,
1997.
[10] S. Behnel, R. Bradshaw, C. Citro, L. Dalcin, D. S. Seljebotn,
K. Smith, Cython: The Best of Both Worlds, Computing in
Science and Engineering 13, 31-39 (2011).
[11] A. S. Szalay, J. A. Blakeley, Gray’s laws: database-centric
computing in science, [in:] T. Hey (ed.), S. Tansley (ed.), K.
Tolle (ed.), The Fourth Paradigm: Data-Intensive Scientific
Discovery, Redmond, p. 5-11, 2009.
[12] P. Buneman, Why Don’t Scientists Use Databases?, Microsoft
PowerPoint Presentation to National e-Science Centre, (2002).
[13] A. Noreen, K. Olaussen, A Python Class for Higher-Dimensional
Schroedinger Equations, arXiv:1503.04607
[physics.comp-ph], (2015).
[14] M.R B. Kristensen, B. Vinter, Numerical Python for scalable
architectures, Proceedings of the Fourth Conference on Partitioned
Global Address Space Programming Model, New York,
art. 15 2010.
[15] J.K. Nilsen, X. Cai, B. Høyland, H. P. Langtangen, Simplifying
the parallelization of scientific codes by a function-centric
approach in Python, Computational Science & Discovery 3,
(2010).
In order to perform larger scale physics research in the area of superconductivity, we have developed an application that can transform the Hubbard Hamiltonian into a matrix and diagonalize it to find the selected model’s energy spectrum. For that purpose we have used the Python language and its wide ecosystem. This paper proves that selected tools are capable of creating scientific applications in a general sense. After a short introduction into the physics problem and the designed algorithm we will present the computer science problems and their solutions in creating usual scientific programs, in particular: performance and parallelization issues, storage of input data and the results, bottlenecks detections, as well as optimization and testing. The most interesting examples of the developing cycle will be described to give a prepared solution for implementing the other scientific software.
Key words:
References:
[1] T.E. Oliphant, Python for Scientific Computing, Computing in
Science & Engineering 9, 10-20 (2007).
[2] D.M. Beazley, P.S. Lomdahl, Extensible Message Passing
Application Development and Debugging with Python, Proceedings
11th International Parallel Processing Symposium,
650-655 (1997).
[3] J. Spałek, Wst˛ep do fizyki materii skondensowanej, Wydawnictwo
Naukowe PWN, Warszawa 2015.
[4] H. Fangohr, Python for Computational Science and Engineering,
Faculty of Engineering and the Environment University
of Southampton, Southampton 2014.
[5] Python Software Foundation, Python Documentation,
https://docs.python.org, 2015.
[6] D.M. Beazley, Scientific Computing with Python, Astronomical
Data Analysis Software and Systems IX ASP Conference
Series 216, San Francisco 2000.
[7] D.M. Beazley, P.S. Lomdahl, Building Flexible Large-Scale
Scientific Computing Applications with Scripting Languages,
8th SIAM Conference on Parallel Processing for Scientific
Computing, Minnesota 1997.
[8] X. Cai, H. P. Langtangen, H. Moe, On the Performance of
the Python Programming Language for Serial and Parallel
Scientific Computations, Scientific Programming 13, 31-56
(2005).
[9] R.B. Lehoucq, D.C. Sorensen, C.Yang, ARPACK Users’
Guide: Solution of Large-Scale Eigenvalue Problems with
Implicitly Restarted Arnoldi Methods, University of Leeds,
1997.
[10] S. Behnel, R. Bradshaw, C. Citro, L. Dalcin, D. S. Seljebotn,
K. Smith, Cython: The Best of Both Worlds, Computing in
Science and Engineering 13, 31-39 (2011).
[11] A. S. Szalay, J. A. Blakeley, Gray’s laws: database-centric
computing in science, [in:] T. Hey (ed.), S. Tansley (ed.), K.
Tolle (ed.), The Fourth Paradigm: Data-Intensive Scientific
Discovery, Redmond, p. 5-11, 2009.
[12] P. Buneman, Why Don’t Scientists Use Databases?, Microsoft
PowerPoint Presentation to National e-Science Centre, (2002).
[13] A. Noreen, K. Olaussen, A Python Class for Higher-Dimensional
Schroedinger Equations, arXiv:1503.04607
[physics.comp-ph], (2015).
[14] M.R B. Kristensen, B. Vinter, Numerical Python for scalable
architectures, Proceedings of the Fourth Conference on Partitioned
Global Address Space Programming Model, New York,
art. 15 2010.
[15] J.K. Nilsen, X. Cai, B. Høyland, H. P. Langtangen, Simplifying
the parallelization of scientific codes by a function-centric
approach in Python, Computational Science & Discovery 3,
(2010).