Go to file
Marek Nečada a66dd24f89 Cython evaluation of "normal" and Ewald-summed SSWF 2022-06-22 12:33:48 +03:00
amos Quit Fortran dependencies, using own f2c'd version of amos. 2020-04-10 23:19:18 +03:00
apps/transop-ewald transop_ewald.c continue parsing 2019-06-20 06:56:54 +03:00
besseltransforms Mathematica bessel transforms 2018-03-28 11:52:50 +03:00
camos@19e7ae82e7 More multiplatform build of camos 2020-04-11 00:48:37 +03:00
ci Add bc to CI common prerequisities (required to run examples) 2022-06-21 09:54:24 +03:00
cmake Initial version info in the C library 2022-06-21 06:25:22 +03:00
examples Custom python T-matrix generator test. 2021-08-23 08:39:27 +03:00
faddeeva CMakeLists for Faddeeva 2020-05-19 15:52:08 +03:00
lepaper Orbit figure draft 2019-08-02 10:01:22 +03:00
misc finiterect-constant-driving more metadata output 2022-06-22 12:33:48 +03:00
notes WIP documentation on phase/normalisation implementation. 2022-06-22 12:33:48 +03:00
oldtests Start modifying the tests structure. 2019-08-17 13:57:24 +03:00
qpms Cython evaluation of "normal" and Ewald-summed SSWF 2022-06-22 12:33:48 +03:00
tests Ewald summation consistency test for lattice basis fields. 2022-06-22 12:33:48 +03:00
.drone.yml Disable "hard" examples in CI 2022-06-21 15:13:20 +03:00
.gitignore Update gitignore 2020-07-08 15:58:42 +03:00
.gitmodules Trustworthier source for zbessel submodule 2022-06-16 07:41:32 +03:00
BUGS.rst Remove bugs of removed code from BUGS.rst. 2022-06-22 12:33:48 +03:00
CLIUTILS.md Docs: Add overview of CLI utilities; optimisation TODO 2020-07-02 22:49:12 +03:00
CMakeLists.txt Initial version info in the C library 2022-06-21 06:25:22 +03:00
COPYING.md Add license 2020-06-23 15:23:20 +03:00
Doxyfile List of public mirrors 2022-06-10 12:43:16 +03:00
MIRRORS.md List of public mirrors 2022-06-10 12:43:16 +03:00
README.Triton.md README update, include to Doxyfile. 2019-06-11 17:28:15 +03:00
README.md Initial CI workflow for Drone 2022-06-16 02:25:17 +03:00
TODO.md Some features to enable ScatteringSystem reconstruction 2020-07-03 23:04:53 +03:00
farfield.png Update README, remove obsolete periodic lattice tutorial 2020-06-26 22:40:00 +03:00
finite_systems.md Update README, remove obsolete periodic lattice tutorial 2020-06-26 22:40:00 +03:00
setup.cfg Balíčkování 2016-03-27 12:56:54 +03:00
setup.py Don't import qpms_p in __init__, remove scipy from install dependencies 2022-06-07 06:10:24 +03:00
version.cmake version.cpp -> qpms_version.c 2019-06-17 17:28:43 +03:00

README.md

Build Status

QPMS README

QPMS (standing for QPMS Photonic Multiple Scattering) is a toolkit for frequency-domain simulations of photonic systems consisting of compact objects (particles) inside a homogeneous medium. Scattering properties of the individual particles are described by their T-matrices (which can be obtained using one of the built-in generators or e.g. with the scuff-tmatrix tool from the SCUFF-EM suite).

QPMS handles the multiple scattering of electromagnetic radiation between the particles. The system can consist either of a finite number of particles or an infinite number of periodically arranged lattices (with finite number of particles in a single unit cell).

Features

Finite systems

  • Computing multipole excitations and fields scattered from nanoparticle clusters illuminated by plane, spherical or cylindrical (TODO) waves.
  • Finding eigenmodes (optical resonances).
  • Calculating cross sections.
  • Reducing numerical complexity of the computations by exploiting symmetries of the cluster (decomposition to irreducible representations).

Infinite systems (lattices)

  • 2D-periodic systems with arbitrary unit cell geometry supported. (TODO 1D and 3D.)
  • Computing multipole excitations and fields scattered from nanoparticle
  • Finding eigenmodes and calculating dispersion relations.
  • Calculation of the scattered fields.
  • Calculation of total transmission and reflection properties (TODO).
  • Reducing numerical complexity of the computations by exploiting symmetries of the lattice (decomposition to irreducible representations) (in development).

Getting the code

The codebase is available at the main upstream public repository https://repo.or.cz/qpms.git or any of the maintained mirrors. Just clone the repository with git and proceed to the installation instructions below.

Installation

The package depends on several python modules, a BLAS/LAPACK library with the respective C bindings (incl. the lapacke.h and cblas.h headers; OpenBLAS does have it all and is recommended) and GSL (>= 2.0). The python module dependencies should be installed automatically when running the installation script. If you have a recent enough OS, you can get GSL easily from the repositories; on Debian and derivatives, just run apt-get install libgsl-dev under root. Alternatively, you can get the source and compile it yourself.

You also need a fresh enough version of cmake.

QPMS uses a C version of the Amos library for calculating Bessel function from a submodule. Before proceeding with running cmake, the submodules need to be downloaded first (in the QPMS source root directory):

  git submodule init
  git submodule update

After GSL is installed and submodules updated, you can install qpms to your local python library using

  cmake -DCMAKE_INSTALL_PREFIX=${YOUR_PREFIX} .
  make install
  python3 setup.py install --user

Above, replace ${YOUR_PREFIX} with the path to where you want to install the shared library; you will also need to make sure that the linker can find it; on Linux, this means the path ${YOUR_PREFIX}/lib is included in your LIBRARY_PATH and LD_LIBRARY_PATH environment variables. The same applies to the GSL and OpenBLAS dependencies: they must be installed where the installation scripts and linker can find them (setting the C_INCLUDE_PATH environment variable might be necessary as well).

Special care might need to be taken when installing QPMS in cluster environments. Specific installation instructions for Aalto University's Triton cluster can be found in a separate document.

Instructions for installation on Android-based devices are in another document.

Documentation

QPMS documentation is a work in progress. Most of the newer code is documented using doxygen comments. Documentation generated for the upstream version is hosted on the QPMS homepage https://qpms.necada.org.

To build the documentation yourself, just run doxygen in the QPMS source root directory; the documentation will then be found in docs/html/index.html.

Of course, the prerequisite of this is having doxygen installed. If you don't, you will probably find it easily in your OS's repositories. On Debian and derivatives, simply run apt-get install doxygen under root.

Tutorials

See also the examples directory in the source repository.

Command line utilities

Acknowledgments

This software has been developed in the Quantum Dynamics research group, Aalto University, Finland. If you use the code in your work, please cite M. Nečada and P. Törmä, Multiple-scattering T-matrix simulations for nanophotonics: symmetries and periodic lattices, arXiv: 2006.12968 (2020) in your publications, presentations, and similar.

Please also have a look at other publications by the group (google scholar Päivi Törmä), they may be useful for your work as well.

Bug reports

If you believe that some parts of QPMS behave incorrectly, please mail a bug report to marek@necada.org. To ensure that your message is not considered spam, please start the subject line with QPMS.

If you were able to fix a bug yourself, please include the patch as well, see below.

Contributions

Contributions to QPMS are welcome, be it bug fixes, improvements to the documentation, code quality, or new features.

You can send patches prepared using the git format-patch tool to marek@necada.org.

If you plan to contribute with major changes to the codebase, it is recommended to discuss that first (see the contact information below).

Contact & discussion

You can contact the main author e.g. via e-mail or Telegram.

You are also warmly welcome to the QPMS user chat in Telegram!