McStas logo McStas - A neutron ray-trace simulation package ILL; PSI; ESS Niels Bohr Institute DTU Physics NEXMAP

McStas
site 2

About McStas
 Conditions of use
 Authors/Contacts
 Project funding

Download
 Components
 Other Downloads (share)

Mailing list

Search web/mailinglist

Documentation
 Wiki (GitHub)
 McStas manual
 Publications

Links

Report bugs (GitHub)

Code-repository (GitHub)


McStas - A neutron ray-trace simulation package

McStas is a general tool for simulating neutron scattering instruments and experiments. It is actively supported by DTU Physics, NBI KU, ESS, PSI and ILL

Simulated scattering from a hollow-cylinder vanadium sample.

The plot shows the intensity of scattered neutrons (red is highest intensity). The sample is at the center of the sphere with the neutron beam coming from the left. Clearly seen is the shadowing effect of the sample causing a lower intensity opposite the beam. Also seen is the effect of the non-symmetric geometry of the sample, causing lower intensity directly above and to the side of the sample.



Recent news


Migrating from McStas 2.x to 3.x? - Use the wiki-based guides

May 16th, 2024: (experimental) previews of the forthcoming 3.5-release

Dear all,

If you want a sneak preview at the forthcoming 3.5-release, we recommend you to try either

  • Our conda-forge packages
    (NB: The Windows version of the package does not include MCPL and NCrystal yet)
  • A new set of conda-based macOS app bundles
    (Based on conda-forge and should auto-download the newest conda-package plus dependencies)
  • Corresponding Debian packages, Windows/MinGW package and macOS/Intel package are built on a nightly basis via GitHub action "mcstas-autobuild" see e.g. this latest one
    (The packages are available in the "artifacts", download may require being logged in on GitHub. Somewhat confusingly, the Windows build is enclosed in the "ubuntu" artifact.)

Among the hightlights are:

  1. New default-CFLAGS
    (Gives improved simulation performance of ~ 30-40% when using gcc and/or clang on Unix platforms at the cost of 5-10% longer compile time. -
    Thanks to Thomas Kittelmann for help debugging a slowdown found when using the built-in compilers on conda :-) )
  2. Tighter integration with McStasScript
    (mcstas-pygen-driven button in mcgui directly spawns JupyterLab with a generated notebook)
  3. McStasScript is automatically included and configured on mac and Windows builds
  4. We have started organising the instrument-examples in a folder-structure, allowing to distribute "more than just the instrument-file" as an example.
    (Case-specific datafiles or geometry-files, c-code snippets, python scripts or McStasScript notebooks welcome - we still want new comps to arrive in contrib)
  5. New GISANS_sample.comp contribution from Henrich Frielinghaus, allows to simulate selected samples for Grazing Incidence SANS.
  6. New File.comp contribution from Greg Tucker, allows to use metadata blocks to store input-files for components
    (e.g. for a small OFF file or other datafile - then visible alongside instr in your editor.)
  7. ... and we are working on freshening up certain aspects of the 3D-visualisation... ;-)
    (New visualisation is not yet included in the above-mentioned packages...)

Do you have new component- or instrument-developments you would like included in next release?
- Then NOW is a good time to send them. :-) We prefer of you open a PR on GitHub but of course email-based contributions are also welcome. :-)

Finally, if you know anyone running McXtrace most of the above should also work for them. And going forward, releases of McStas and McXtrace should come in pairs with the same versioning.


Previous news items: 2023, 2022, 2021,2020,2019, 2018, 2017, 2016, 2015, 2014, 2013, 2012, 2011, 2010, 2009, 2008, 2007, 2006, 2005, 2004, 2003, 2002, 2001, 2000, 1999, 1998.


Last Modified: Thursday, 16-May-2024 15:56:02 CEST
Search website mailinglist archive GitHub repos