Installation
HierarchicalEOM.jl
To install HierarchicalEOM.jl, run the following commands inside Julia's interactive session (also known as REPL):
using Pkg
Pkg.add("HierarchicalEOM")Alternatively, this can also be done in Julia's Pkg REPL by pressing the key ] in the REPL to use the package mode, and then type the following command:
(1.9) pkg> add HierarchicalEOMMore information about Julia's package manager can be found at Pkg.jl.
HierarchicalEOM.jl requires Julia 1.9 or higher (we dropped Julia 1.8 since ver.1.12.1)
To load the package and check the version information, use the command:
julia> using HierarchicalEOM
julia> HierarchicalEOM.versioninfo()Other Useful Packages
In order to get a better experience and take full advantage of HierarchicalEOM, we recommend to install the following external packages:
QuantumToolbox.jl
QuantumToolbox is a cutting-edge Julia package designed for quantum physics simulations, closely emulating the popular Python QuTiP package. It provides many useful functions to create arbitrary quantum states and operators which can be combined in all the expected ways. It uniquely combines the simplicity and power of Julia with advanced features like GPU acceleration and distributed computing, making simulation of quantum systems more accessible and efficient.
The inputs in HierarchicalEOM should be child-type of the standard Base.AbstractVector (for vector-type quantum states) and Base.AbstractMatrix (for matrix-type quantum operators). Users can still construct the vectors or matrices by standard method and take it as the input of HierarchicalEOM. For the users who constructs the quantum objects by QuantumToolbox package, the standard type of vectors or matrices are stored in the .data field of the objects, i.e., op.data (where op is a QuantumToolbox-type object). Thus, users should take it as the inputs of HierarchicalEOM for objects in QuantumToolbox package.
HierarchicalEOM.jl provides an extension to support QuantumToolbox-type object, but this feature requires Julia 1.9+ and HierarchicalEOM 1.4+. See here for more details.
QuantumOptics.jl
QuantumOptics framework provides many useful functions to create arbitrary quantum states and operators which can be combined in all the expected ways. Constructing arbitrary Hamiltonians and specifying initial states is also straightforward.
The inputs in HierarchicalEOM should be child-type of the standard Base.AbstractVector (for vector-type quantum states) and Base.AbstractMatrix (for matrix-type quantum operators). Users can still construct the vectors or matrices by standard method and take it as the input of HierarchicalEOM. For the users who constructs the quantum objects by QuantumOptics package, the standard type of vectors or matrices are stored in the .data field of the objects, i.e., op.data (where op is a QuantumOptics-type object). Thus, users should take it as the inputs of HierarchicalEOM for objects in QuantumOptics package.
HierarchicalEOM.jl provides an extension to support QuantumOptics-type object, but this feature requires Julia 1.9+ and HierarchicalEOM 0.3+. See here for more details.
DifferentialEquations.jl
DifferentialEquations is needed to provide the low-level ODE solvers especially for solving time evolution. For low dependency usage, users can use OrdinaryDiffEq.jl instead.
LinearSolve.jl
LinearSolve is a unified interface for the linear solving packages of Julia. It interfaces with other packages of the Julia ecosystem to make it easier to test alternative solver packages and pass small types to control algorithm swapping. It is needed to provide the solvers especially for solving stationary state and spectra for both bosonic and fermionic systems.
JLD2.jl
JLD2 saves and loads Julia data structures in a format comprising a subset of HDF5. Because the size of matrix in HierarchicalEOM is usually super large and leads to long time calculation, we support the functionality for saving and loading the HierarchicalEOM-type objects into files by JLD2 >= 0.4.23.
PyPlot.jl
PyPlot.jl provides a Julia interface to the Matplotlib plotting library from Python, and specifically to the matplotlib.pyplot module.