RAT banner

Reflectivity Algorithms Toolbox (RAT) is a toolbox for analysing neutron reflectivity data at multiple contrasts. It has been designed as the calculation engine for the upcoming RasCAL-2, which will supersede the reflectivity software RasCAL.

It is designed to be flexible, allowing analysis using traditional layer models, but also using user-defined custom models, which can be parameterised by the user however they wish (either as an array of layers, or a continuous SLD profile). It is also incredibly fast; the core algorithm code is native C++, created from the MATLAB source code using MATLAB Coder.

By separating the GUI from the toolbox, users can create and run a full analysis from a script, which can be written in either our MATLAB or Python API. This means that the reflectivity analysis can be integrated alongside other analysis tools written in MATLAB or Python, and this analysis script can be provided alongside publications to ensure reproducible data.

RAT contains a number of improvements over legacy RasCAL, including:

Getting started with RAT

Follow these guides to get started:

  • Installation: Learn how to install RAT.

  • User Guide: Learn the core principles of RAT with code snippets.

  • Examples: Jump into some practical examples.

Go deeper into RAT

Learn more by diving into the RAT reference:

Get more help

The easiest way to get help with the project is to start discussions or open an issue on Github.