Multi-Scale Infrastructure for Chemistry and Aerosols
MUSICA is a collection of modeling software and tools that allow for robust modeling of chemistry in Earth's atmosphere.
At present the project encompasses these core components
-
- A photolysis rate calculator
-
- Model Independent Chemical Module
-
- Community Aerosol and Radiation Model for Atmospheres (integration in development)
-
- The standardized format to describe atmospheric chemistry
These components are used to drive the MUSICA software ecosystem. This is a snapshot of how MUSICA can be used with different models.
MUSICA provides interfaces for multiple programming languages. Choose the installation method that best fits your needs:
Most scientific users may prefer our python interface. It can be installed with pip:
pip install musicaFor detailed Python installation instructions, usage examples, and development information, see the Python README.
The JavaScript interface uses WebAssembly to run MUSICA components. This interface is most for tools developed for web browsers and only supports the C++ components of MUSICA. It can be installed from npm
npm install @ncar/musicaFor detailed JavaScript installation instructions, usage examples, and development information, see the JavaScript README.
The Fortran interface is designed for integration with Fortran-based atmospheric models. You can install this from spack
spack install musicaFor detailed Fortran installation instructions, usage examples, and development information, see the Fortran README.
For C++ development or building from source with full control over options:
Minimum required packages:
- cmake (>= 3.21)
- pkg-config
- netcdf
- netcdf-fortran
- blas (only needed when building CARMA,
MUSICA_ENABLE_CARMA=ON, which is the default) - lapack (only needed when building CARMA,
MUSICA_ENABLE_CARMA=ON, which is the default)
git clone https://github.com/NCAR/musica.git
cd musica
mkdir build
cd build
ccmake ..
make
make installMUSICA automatically downloads and builds additional dependencies (pybind11, googletest, MICM, TUV-x, Mechanism Configuration, CARMA) using CMake's FetchContent. If you have these packages already installed where CMake can find them, they will be used instead of being downloaded.
- Full Documentation - Complete API reference, tutorials, and guides
- Interactive Tutorials - Try MUSICA in your browser via Binder
The names "MUSICAv0" and "MUSICAv1" refer to configurations of CESM/CAM-chem with regional refinement.
These configurations do not currently use the musica library in this repository.
The MUSICA Wiki and the available grids are for these CESM configurations only.
Introduced in Pull Request #124, it is possible for developers to specify which versions of various dependencies should be used. These options are currently limited to those dependencies managed via FetchContent. This change allows for more easily testing musica against changes committed in different repositories and branches. The environmental variables introduced are outlined in the following table.
| Musica Dependency | Repository | Branch, Tag or Hash |
|---|---|---|
| Google Test | GOOGLETEST_GIT_REPOSITORY | GOOGLETEST_GIT_TAG |
| MICM | MICM_GIT_REPOSITORY | MICM_GIT_TAG |
| TUV-X | TUVX_GIT_REPOSITORY | TUVX_GIT_TAG |
| PyBind11 | PYBIND11_GIT_REPOSITORY | PYBIND11_GIT_TAG |
| Mechanism Configuration | MECH_CONFIG_GIT_REPOSITORY | MECH_CONFIG_GIT_TAG |
The following examples assume the working directory is a
build/directory inside themusicasource directory.
Specifying a different version of tuv-x, to ensure a change won't break anything.
$ cmake .. \
-DTUVX_GIT_REPOSITORY="https://github.com/WardF/tuv-x.git" \
-DTUVX_GIT_TAG=test-fix
Specifying a specific version of tuv-x by has, but using the official repository.
$ cmake .. \
-DTUVX_GIT_TAG=a6b2c4d8745
We welcome contributions from the community! Please see our Contributing Guide for information on how to get involved.
For a complete list of contributors and authors, see AUTHORS.md.
MUSICA can be cited in at least two ways:
-
Cite the foundational paper that defines the vision of the MUSICA software:
- Pfister et al., 2020, Bulletin of the American Meteorological Society
- Use the following BibTeX entry:
@Article { acom.software.musica-vision, author = "Gabriele G. Pfister and Sebastian D. Eastham and Avelino F. Arellano and Bernard Aumont and Kelley C. Barsanti and Mary C. Barth and Andrew Conley and Nicholas A. Davis and Louisa K. Emmons and Jerome D. Fast and Arlene M. Fiore and Benjamin Gaubert and Steve Goldhaber and Claire Granier and Georg A. Grell and Marc Guevara and Daven K. Henze and Alma Hodzic and Xiaohong Liu and Daniel R. Marsh and John J. Orlando and John M. C. Plane and Lorenzo M. Polvani and Karen H. Rosenlof and Allison L. Steiner and Daniel J. Jacob and Guy P. Brasseur", title = "The Multi-Scale Infrastructure for Chemistry and Aerosols (MUSICA)", journal = "Bulletin of the American Meteorological Society", year = "2020", publisher = "American Meteorological Society", address = "Boston MA, USA", volume = "101", number = "10", doi = "10.1175/BAMS-D-19-0331.1", pages= "E1743 - E1760", url = "https://journals.ametsoc.org/view/journals/bams/101/10/bamsD190331.xml" }
-
Cite the MUSICA software with the Zenodo DOI:
- 10.5281/zenodo.7458559 refers to all versions. Zenodo also gives a DOI for each release.