125 Commits

Author SHA1 Message Date
bac6202a73 Update .gitea/workflows/deploy-pages.yml
Some checks failed
Build and Deploy Documentation / build-and-deploy (push) Failing after 17s
change action trigger to default branch name
2025-10-13 15:16:12 +02:00
b5447aef32 Update .gitea/workflows/deploy-pages.yml
changed build image
2025-10-13 15:13:06 +02:00
1e9b82f1c2 add TDirectory option to any2many. 2025-10-03 15:42:44 +02:00
fbfce99790 better handling of values=n/a when dumping the header info. 2025-10-01 12:36:01 +02:00
32b49e7ac8 fixed char* comparison bug. 2025-10-01 09:38:17 +02:00
df7b8433e1 adopted PRunDataHandler::ReadRootFile such that it can handle TDirectory in addition to the deprecated TFolder. 2025-09-30 14:32:47 +02:00
10117abeff dump_header can now handle TMusrRoot with TFolder as well as TDirectory. 2025-09-30 12:30:45 +02:00
675ed39739 update of the in-source MusrRoot docu. 2025-09-29 16:41:17 +02:00
7f911cd3ab make musrRootValidation TDirectory compatible. 2025-09-29 14:28:53 +02:00
288c4c644b updated the docu and removed unused DrawHeader. 2025-09-29 12:45:24 +02:00
ea646e012b increase the MusrRoot version to 2.0. 2025-09-29 12:43:21 +02:00
d8d1eb1838 added necessary FOURIER block. 2025-09-29 11:43:30 +02:00
4917e5c7ae added the reader part for MusrRoot if written with TDirectory rather than TFolder. 2025-09-29 10:47:58 +02:00
7e28402e25 start implementing TDirectory infrastructure. 2025-09-28 16:45:49 +02:00
db71346ebb Update .gitea/workflows/deploy-pages.yml
added graphiz for the collaboration diagrams
2025-09-17 14:03:50 +02:00
4fbd678a88 split argv parsing between root (un)related parts. 2025-09-15 13:25:21 +02:00
376b4f59ba add the errno information onto the IPC, in case of a failure. 2025-09-07 18:15:12 +02:00
a61a09bddd added musredit.dox in the doc directory. 2025-09-02 09:14:41 +02:00
475bb6a9f7 changed copy path for pages. 2025-09-02 09:10:35 +02:00
a6153a0eb7 add first technical docu pages pipeline. 2025-09-02 09:07:00 +02:00
7405a95c6e removed qmake leftovers. Only cmake is used for the future. Reorganized the technical docu, for better gitea-pages integration. 2025-09-02 08:55:00 +02:00
ed6e392a53 prevent crash if no tab is present. 2025-08-19 18:09:29 +02:00
ef4c6d75e5 make sure that index states in proper range for PRunAsymmetryRRF. 2025-08-05 10:30:41 +02:00
392a0b089d added more histo length versus fgb, lgb checks. 2025-07-11 13:05:49 +02:00
06a509a420 improved reload of msr-files in musredit after a msr2data command. 2025-07-07 10:02:14 +02:00
2e951d92f1 error feed fStep rather than fPosError for expected chisq. Tweaked the param rounding for expected chisq. 2025-07-04 16:29:33 +02:00
d9016d82a8 better exp estimate for precision. 2025-07-04 08:31:52 +02:00
25bcdd25e5 add err==0.0 handling for rounding. 2025-07-03 10:22:11 +02:00
781a2e7dbd also apply the parameter rounding onto the per run block estimate. 2025-07-03 09:50:48 +02:00
1aa7e6941f improved rounding handling to get a more consistent expected chisq after fitting compared to pure chisq estimate of musrfit. Essentially get rid of rounding issues. 2025-07-03 09:38:34 +02:00
7491a2c331 now all error messages from musrview can be sent to PMsgBox. 2025-06-29 09:12:11 +02:00
832a74e0b5 added a feature which brings up a error message box, if there was any issue with the msr-file when starting musrview from musredit. 2025-06-29 09:04:45 +02:00
0b1c9e53c6 (i) make most internal checking functions in the msr handler private. (ii) improved checking of real Fourier for consistency. 2025-06-23 16:02:07 +02:00
18bf65a231 changed theory functionc abbriviation 'if' to 'ifld'. 2025-06-10 13:23:03 +02:00
0cde84d756 updated of the offline docu. 2025-06-09 09:10:49 +02:00
0943f1f061 increase libPMusr version to 1.5.0. 2025-06-08 10:58:40 +02:00
769a828a76 new version 1.9.9. Adopted ChangeLog and CMakeLists.txt. 2025-06-08 10:48:12 +02:00
ecec59c8a3 1st full Gauss/Lorentz LF. Still room for optimization, and further testing. 2025-06-06 10:21:09 +02:00
66af890157 add new functions to musredit select. 2025-06-05 11:19:48 +02:00
eb98c9727c add simple F-mu-F to the standard theory functions. 2025-06-05 10:41:12 +02:00
079baa3edf start adding more standard theory functions. Not all ready yet. 2025-06-04 17:39:02 +02:00
7df47a05f3 create src dir if not present. Needed for git-revision.h 2025-06-03 12:58:00 +02:00
15c5b02c8b more docu. 2025-05-28 13:48:57 +02:00
37f099542a stripped CMakeLists.txt to the bare minimum. 2025-05-28 13:48:05 +02:00
c2fb166d3b add necessary docu for the Gaussian Lorentzian approach. 2025-05-28 12:47:20 +02:00
e8806c3e72 changed the integral approximation approach for Gaussian/Lorentzian. 2025-05-28 12:46:37 +02:00
91a45cad90 added ZF, LF geometry, dynamic approximation width/hopp << 1. 2025-05-27 15:59:58 +02:00
d1f025a8c2 improved GL integration. 2025-05-27 15:59:08 +02:00
e525abe614 simplify git-revision.h generation. 2025-05-19 13:29:54 +02:00
005b33c379 added missing MACOSX_BUNDLE_GUI_IDENTIFIER for mupp. 2025-05-14 18:10:51 +02:00
3bcc382679 allow to define Tmax from the cmd line. 2025-05-13 16:08:23 +02:00
249d6ff97c add missing header. 2025-05-12 20:25:40 +02:00
69ab03d5ae first LGKT_LF. Might need to slightly improve Simpson. 2025-05-12 16:36:37 +02:00
819d209863 proper class for GKT LF. 2025-05-12 10:58:53 +02:00
bcc1597e30 add LF Gaussian/Lorentzian testing code. 2025-05-09 16:02:04 +02:00
9fa90c24fb start populating nfs4 path rather than afs in the musrfit_startup.xml. 2025-05-06 15:33:13 +02:00
236a702d36 needed to add an additional header (stdbool.h, libCuba) to make clang happy. 2025-05-03 15:13:26 +02:00
09f9782a31 comment outdated typedef in libCuba. 2025-05-02 19:18:43 +02:00
f99f71a8db slight improvement on mud.h needed that it doesn't crash on macos15.4 m3pro. 2025-04-09 17:11:14 +02:00
6e60013037 updated mud.h (thanks to Donald Arseneau). Makes modern compiler happy again. 2025-04-08 17:00:04 +02:00
e38fa47961 add skeleton for MusrRoot which will handle TDirectoryFile rather than TFolder. 2025-04-04 18:37:42 +02:00
764cdf4e51 start implementing TDirectoryFile instead of TFolder, since TFolder is depricated. First I added the necessary parts on the validator. The read/write are still missing. 2025-04-04 16:58:57 +02:00
e5ff0fa743 switched from raw to QScopedPointer pointer in mupp.cpp. 2025-04-01 14:10:59 +02:00
e26fa4eea2 removed my quick and dirty fix. It doesn't work for all compilers. Reported bug to triumf and wait for a fix. 2025-03-31 07:54:25 +02:00
5648757389 back ported some qt6 recent file handling. 2025-03-30 18:14:04 +02:00
Andreas Suter
c3b4c7c3b1 improved recent file handling for macos. 2025-03-30 17:09:04 +02:00
e233c860d1 slight improvement in handling of the recent msr-files. 2025-03-30 15:30:46 +02:00
c230bfb1bc updated the icon switching by adding the missing View2Dat. 2025-03-29 22:36:48 +01:00
5119b1cd13 fixed typo and added necessary update for the theme flags. 2025-03-29 21:48:23 +01:00
d937324885 improved dark theme handling on mupp for qt5. 2025-03-29 20:54:03 +01:00
f7e5c53879 improved dark theme handling on mupp for qt6. 2025-03-29 20:17:28 +01:00
3796925e93 needed to adopt mud.h to make it gcc15.0.1 ready. 2025-03-26 17:05:16 +01:00
d5343a0073 activate the status bar. 2025-03-25 15:35:10 +01:00
bb99482461 add a user interface option to export data from a msr-file view (single- or multiple files) - qt6. 2025-03-24 20:28:57 +01:00
f0869935d1 add a user interface option to export data from a msr-file view (single- or multiple files). 2025-03-24 20:10:01 +01:00
0f95551200 add necessary increment for unique cropped name for PSI-BIN. 2025-03-19 16:24:56 +01:00
b8ce741534 make sure that for PSI-BIN export the 4 char detector names are unique. 2025-03-19 09:45:16 +01:00
4b6654ca2a add title to PRawRunDataSet. 2025-03-19 09:44:13 +01:00
38d4ec1806 read 'Sample Orientation' from ROOT file, since it might be needed by any2many. 2025-03-18 12:51:40 +01:00
4231d26604 make sure that the 'selected' object is present. 2025-02-24 20:22:20 +01:00
a28650f017 this is a workaround which should prevent that the key event is executed if a text/latex is written into the canvas. 2025-02-17 17:53:39 +01:00
9a23c4f241 fix of a copy/paste error. 2025-02-15 10:41:02 +01:00
5f7f79e46d header of exported data adopted for easier read in with pandas. 2025-02-14 09:06:55 +01:00
4a20d805dd updated the copyright info. 2025-01-30 11:15:42 +01:00
10cfe3f863 Merge branch 'root6' of https://git.psi.ch/nemu/musrfit into root6 2025-01-29 08:05:29 +01:00
0828d1b8d4 proper handling of comments and descriptions in the RUN block. 2025-01-29 08:04:48 +01:00
75785d2c0e add switch to enable/disable HDF4 support for NeXus. 2025-01-28 21:40:58 +01:00
e4b84b12df make sure that 'ASCII', 'DAT', and 'DB' is rejected from musrFT. 2025-01-27 18:00:32 +01:00
124a31386c add a new tag PMUSR_UNSUPPORTED_FEATURE 2025-01-27 17:58:42 +01:00
ebdb0feb7f path-run-name in RUN block of the msr-file can now handle spaces. 2025-01-18 13:35:08 +01:00
e67d92fc05 Merged in mnstrategy (pull request #19)
Explicit passing of MnStrategy during minimizer initialization

Approved-by: Suter Andreas
2025-01-10 10:00:30 +00:00
ead1674b13 Explicit passing of MnStrategy during minimizer initialization
This patch fixes compilation errors that arise with recent ROOT versions (e.g., 6.34.02),
which require a ROOT::Minuit2::MnStrategy object to be passed when initializing the
ROOT::Minuit2::MnX (X = Migrad, Simplex, Minimize) minimizers (i.e., instead of the integer
representing the "strategy").
2025-01-09 11:38:33 -08:00
fd22884ce8 slightly re-ordered the default files for mupp in the open dialog. 2024-12-16 07:41:24 +01:00
20dd08fbef changed default ROOT color kGreen to kGreen+2. 2024-12-14 14:54:17 +01:00
3e66760c26 adopted for custom button handling qt5. 2024-12-11 14:06:32 +01:00
d6bcdf52b8 adopted for custom button handling. 2024-12-11 13:58:11 +01:00
30bd2b2876 added missing enum tag. 2024-12-11 09:36:57 +01:00
9f8f89db6d make the theme handling in musredit more flexible. At the same time adopted some part to more modern c++. 2024-12-11 09:25:28 +01:00
458913ca31 update of the ChangeLog 2024-12-03 18:13:02 +01:00
5c3accc6ed added jump to block feature. 2024-12-02 20:05:50 +01:00
6f8b0a2341 center edit widget for find. This gives a better user experience. 2024-12-02 17:06:02 +01:00
4febdb42b4 make sure that for non-muSR data errors are not = 0. Will set it to 1, and issue a warning. This prevents chisq to crash. 2024-10-14 12:22:25 +02:00
ae95a5dc1c implemented unary operator for metaData in functions. 2024-10-11 16:34:49 +02:00
c3f531e0d5 fixed a bug for out-of-repo build to generate git-info. 2024-10-11 08:19:54 +02:00
0b61130e28 adopted OpenMP handling for libZFRelaxation. 2024-09-23 09:41:20 +02:00
d1cd63dcb0 fixed a bug in the mupp gui refresh of a collection. 2024-09-21 13:02:31 +02:00
7838901fbe make sure that the run template number has at least 4 digits before proceeding. 2024-09-17 16:27:04 +02:00
00b012d0dd Merge https://bitbucket.org/muonspin/musrfit into root6 2024-09-12 09:29:03 +02:00
d2984d8923 Merged in avg (pull request #18)
fix batch mode averaged output

Approved-by: Andreas Suter
2024-09-12 07:28:15 +00:00
58889614e5 fix batch mode averaged output
closes issue #63
2024-09-10 13:52:30 -07:00
c9fc373862 improved dat-file reading for mupp. 2024-07-02 09:26:44 +02:00
ebefcf7af9 updated the docu. 2024-06-24 09:44:07 +02:00
64d3b6192b added the option to write the content of the MINUIT2.OUTPUT ascii file as yaml. This extends the previous commit from Ryan M.L. McFadden. 2024-06-18 11:16:15 +02:00
6bcb26f9d5 Merge branch 'root6' of https://bitbucket.org/muonspin/musrfit into root6 2024-06-18 08:19:01 +02:00
6b865efd3b Merged in ignore (pull request #17)
ignore all files generated from an in-repo build

Approved-by: Andreas Suter
2024-06-18 06:18:56 +00:00
caccfb175a Merged in yaml (pull request #16)
write the fit results to an easy-to-read/parse yaml file

Approved-by: Andreas Suter
2024-06-18 06:18:31 +00:00
1845b5c176 Merged in segfault (pull request #15)
fix segfault

Approved-by: Andreas Suter
2024-06-18 06:18:14 +00:00
8821112927 ignore all files generated from an in-repo build 2024-06-17 13:07:06 -03:00
833171c712 write the fit results to an easy-to-read/parse yaml file
This patch adds routines for writing a comprehensive set of fit results (i.e., parameter values, parabolic errors, asymmetric errors, covariances, correlation coefficients, etc.) for an individual `.msr` file to an easy-to-read/parse `.yaml` file.

The main motivation for the code addition is to provide users with easy access to the fit's covariance matrix without the need for "extra" manual effort (e.g., parsing the contents of `MINUIT2.OUTPUT` or `MINUIT2.root`). The other fit quantities are also included for completeness.

Reading/accessing the output is trivial using, for example, the PyYAML Python library (https://github.com/yaml/pyyaml):

```python
import yaml

with open("2125_tf_histo.yaml", "r") as fh:
	results = yaml.load(fh, Loader=yaml.SafeLoader)

cov = results["covariance"]["Field_1"]["Sigma_1"]
```

Note: the naming conventions chosen for the blocks in the `.yaml` output closely follow those used by the iminuit Python library (https://github.com/scikit-hep/iminuit).
2024-06-17 12:51:04 -03:00
61749b91c4 fix segfault
This patch provides a memory-safe alternative to the changes introduced in commit 418adfde67, which causes a segfault when the "batch mode" flag is required (i.e., for ascii/graphic export).

Note: the program name (i.e., argv[0]) has been added the list arguments passed to ROOT's TApplication. This ensures that the TApplication name matches that of the program (see 542b98b2cc/core/base/src/TApplication.cxx (L179-L180)).
2024-06-17 10:52:14 -03:00
3d92e2eefb add CPU info to the configure process. 2024-06-09 17:45:02 +02:00
b71dce9291 remove more accidently added file. 2024-06-08 16:39:57 +02:00
1aa4ce0a99 remove accidentely added file. 2024-06-08 16:36:54 +02:00
425ed02e22 update of the docu. 2024-06-08 09:23:36 +02:00
a36abfc461 updated version info, due to the macOS OpenMP support. 2024-06-08 09:17:05 +02:00
457 changed files with 18546 additions and 25300 deletions

BIN
.DS_Store vendored

Binary file not shown.

View File

@@ -0,0 +1,44 @@
name: Build and Deploy Documentation
on:
push:
branches:
- root6
workflow_dispatch:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
container:
image: gitea.psi.ch/images/alpine-jupyterbook
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install system dependencies
run: |
apk add doxygen graphviz
- name: Build musrfit-tech-docu
run: |
cd doc
mkdir technical
doxygen musrfit_dox.cfg
doxygen musredit_qt5_dox.cfg
doxygen mupp_qt5_dox.cfg
- name: Configure Git
run: |
git config --global user.name "Gitea Actions"
git config --global user.email "actions@gitea.local"
- name: Push to gitea-pages branch
run: |
git checkout --orphan gitea-pages
git reset --hard
cp -r ./doc/technical/html/* .
git add .
git commit -m "Deploy site"
git push -f https://${{secrets.GITHUB_TOKEN}}@gitea.psi.ch/${{ github.repository }}.git gitea-pages

2
.gitignore vendored Normal file
View File

@@ -0,0 +1,2 @@
# ignore all files generated from an in-repo build
build/

View File

@@ -1,7 +1,7 @@
# - musrfit
cmake_minimum_required(VERSION 3.17)
project(musrfit VERSION 1.9.3 LANGUAGES C CXX)
project(musrfit VERSION 1.9.9 LANGUAGES C CXX)
#--- musrfit specific options -------------------------------------------------
option(nexus "build optional NeXus support. Needed for ISIS" OFF)
@@ -200,8 +200,10 @@ endif (qt_based_tools)
#--- if NeXus check also for HDF4, HDF5, and MXML -----------------------------
if (nexus)
find_package(HDF5 COMPONENTS CXX REQUIRED )
find_package(HDF4 REQUIRED)
find_package(HDF5 COMPONENTS CXX REQUIRED)
if (HAVE_HDF4)
find_package(HDF4 REQUIRED)
endif (HAVE_HDF4)
find_package(NEXUS REQUIRED)
add_definitions(-DPNEXUS_ENABLED)
endif (nexus)
@@ -222,6 +224,19 @@ else ()
set(IS_GIT_REPO 0)
endif ()
#--- start create git-revision.h ----------------------------------------------
if (IS_GIT_REPO)
execute_process(COMMAND sh ${CMAKE_SOURCE_DIR}/src/git_revision.sh)
set(HAVE_GIT_REV_H "-DHAVE_GIT_REV_H")
set(GIT_REV_H "git-revision.h")
else (IS_GIT_REPO)
set(HAVE_GIT_REV_H "")
set(GIT_REV_H "")
endif (IS_GIT_REPO)
#--- end create git-revision.h ------------------------------------------------
#--- rpath related things -----------------------------------------------------
# use, i.e. don't skip the full RPATH for the build tree
set(CMAKE_SKIP_BUILD_RPATH FALSE)
@@ -249,6 +264,8 @@ set(CMAKE_INSTALL_RPATH "${rpath}")
add_subdirectory(src)
#--- write summary of the installation
cmake_host_system_information(RESULT PROCESSOR QUERY PROCESSOR_DESCRIPTION)
message("")
message("|-----------------------------------------------------------------------|")
message("| |")
@@ -256,8 +273,9 @@ message("| Summary
message("| |")
message("|-----------------------------------------------------------------------|")
message("")
message(" System: ${CMAKE_HOST_SYSTEM_NAME} ${CMAKE_SYSTEM_PROCESSOR} - ${CMAKE_HOST_SYSTEM_VERSION}")
message(" -------")
message(" System: ${CMAKE_HOST_SYSTEM_NAME} ${CMAKE_SYSTEM_PROCESSOR} - ${CMAKE_HOST_SYSTEM_VERSION}")
message(" Processor: ${PROCESSOR} (${CMAKE_SYSTEM_PROCESSOR})")
message(" ----------")
message("")
message(" musrfit Version: ${musrfit_VERSION}")
message(" ----------------")
@@ -283,7 +301,11 @@ endif (OpenMP_FOUND)
if (nexus)
message("")
message(" HDF4 found in ${HDF4_INCLUDE_DIRS}")
if (HAVE_HDF4)
message(" HDF4 found in ${HDF4_INCLUDE_DIRS}")
else (HAVE_HDF4)
message(" HDF4 not present.")
endif (HAVE_HDF4)
message(" HDF5 found in ${HDF5_INCLUDE_DIRS}, Version: ${HDF5_VERSION}")
message(" NeXus found in ${NEXUS_INCLUDE_DIR}, Version: ${NEXUS_VERSION_STRING}")
endif (nexus)

View File

@@ -12,6 +12,37 @@ or
https://bitbucket.org/muonspin/musrfit/commits/all
Release of V1.9.9, 2025/06/08
=============================
add THEORY functions for local Gaussian / global Lorentzian, and a simple F-mu-F function.
Release of V1.9.8, 2025/03/24
=============================
add a user interface option to export data from a msr-file view (single- or multiple files).
Release of V1.9.7, 2025/01/18
=============================
allow spaces in RUN block path-filename
Release of V1.9.6, 2024/12/02
=============================
added jump to block feature in musredit.
Release of V1.9.5, 2024/06/24
=============================
yaml export of ALL fit-parameters, as initiated by R.M.L. McFadden.
Release of V1.9.4, 2024/06/08
=============================
enable OpenMP for macOS.
Release of V1.9.3, 2024/04/19
=============================

View File

@@ -1,30 +0,0 @@
# configure_musrfit_version_file.cmake.in:
set(SRC_DIR "@CMAKE_SOURCE_DIR@")
set(BIN_DIR "@CMAKE_CURRENT_BINARY_DIR@")
# Set variables
set(CMAKE_INSTALL_PREFIX "@CMAKE_INSTALL_PREFIX@")
set(MUSRFIT_VERSION "@MUSRFIT_VERSION@")
# Get the current working branch
execute_process(
COMMAND git rev-parse --abbrev-ref HEAD
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
OUTPUT_VARIABLE GIT_BRANCH
OUTPUT_STRIP_TRAILING_WHITESPACE
)
# Get the latest abbreviated commit hash of the working branch
execute_process(
COMMAND git log -1 --pretty="%h, %ci"
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
OUTPUT_VARIABLE GIT_CURRENT_SHA1
OUTPUT_STRIP_TRAILING_WHITESPACE
)
configure_file(
${SRC_DIR}/cmake/git-revision.h.in
${BIN_DIR}/git-revision.h
@ONLY
)
# EOF

BIN
doc/.DS_Store vendored

Binary file not shown.

BIN
doc/examples/.DS_Store vendored

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2021 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -15,9 +15,6 @@ asymmetry 3
simplExpo 4 (rate)
TFieldCos 1 2 (phase frequency)
###############################################################
#FUNCTIONS
###############################################################
RUN data/lem08_his_2279 MUE4 PSI ROOT-NPP (name beamline institute data-file-format)
fittype 0 (single histogram fit)
@@ -39,6 +36,14 @@ MINIMIZE
MINOS
SAVE
###############################################################
FOURIER
units Gauss # units either 'Gauss', 'Tesla', 'MHz', or 'Mc/s'
fourier_power 10
apodization STRONG # NONE, WEAK, MEDIUM, STRONG
plot POWER # REAL, IMAG, REAL_AND_IMAG, POWER, PHASE, PHASE_OPT_REAL
dc-corrected true
###############################################################
PLOT 0 (single histo plot)
runs 1

View File

@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 28c8d31b3d0d7429fcebb7bd0074bdd3
# This file records the configuration used when building these files. When it is not found, a full rebuild will be done.
config: a49a5e0b750ed752f738f66d3ddeadd4
tags: 645f666f9bcd5a90fca523b33c5a78b7

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 68 KiB

View File

@@ -0,0 +1,259 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="22"
height="22"
viewBox="0 0 22.000001 22"
id="svg2"
version="1.1"
inkscape:version="1.0.2 (e86c870879, 2021-01-15)"
sodipodi:docname="musrview2dat-plain.svg">
<defs
id="defs4">
<marker
inkscape:stockid="Arrow1Sstart"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Sstart"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path8245"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#da4453;stroke-width:1pt;stroke-opacity:1;fill:#da4453;fill-opacity:1"
transform="scale(0.2) translate(6,0)" />
</marker>
<marker
inkscape:stockid="Arrow2Mstart"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow2Mstart"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path8257"
style="fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round;stroke:#da4453;stroke-opacity:1;fill:#da4453;fill-opacity:1"
d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
transform="scale(0.6) translate(0,0)" />
</marker>
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0.0"
refX="0.0"
id="Arrow1Lend"
style="overflow:visible;"
inkscape:isstock="true">
<path
id="path8236"
d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
style="fill-rule:evenodd;stroke:#da4453;stroke-width:1pt;stroke-opacity:1;fill:#000000;fill-opacity:1"
transform="scale(0.8) rotate(180) translate(12.5,0)" />
</marker>
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="38.863636"
inkscape:cx="11"
inkscape:cy="11"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
units="pt"
inkscape:window-width="2560"
inkscape:window-height="1376"
inkscape:window-x="0"
inkscape:window-y="27"
inkscape:window-maximized="1"
inkscape:snap-grids="true"
showguides="true"
borderlayer="true"
inkscape:showpageshadow="false"
inkscape:document-rotation="0">
<inkscape:grid
type="xygrid"
id="grid5486" />
</sodipodi:namedview>
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1030.3622)">
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.935414;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 8.471,1031.8299 v 7"
id="path8054"
inkscape:connector-curvature="0" />
<g
id="g16411"
transform="translate(-1.9999996,0)">
<path
inkscape:connector-curvature="0"
id="path8035-5"
d="m 8.5000005,1043.3622 0,8"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000012;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<path
sodipodi:open="true"
d="m 10.000001,1043.8622 a 2.594672,3.5000203 0 0 1 2.594672,3.5 2.594672,3.5000203 0 0 1 -2.594672,3.5"
sodipodi:end="1.5707963"
sodipodi:start="4.712389"
sodipodi:ry="3.5000203"
sodipodi:rx="2.594672"
sodipodi:cy="1047.3622"
sodipodi:cx="10.000001"
sodipodi:type="arc"
id="path16389"
style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.99996012;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<path
inkscape:connector-curvature="0"
id="path16394"
d="m 8,1043.8622 2,0"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
<path
inkscape:transform-center-y="-3.7031618"
inkscape:transform-center-x="-1.5617682"
inkscape:connector-curvature="0"
id="path16394-8"
d="m 8.0000005,1050.8622 1.9999995,0"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
</g>
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.911555;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 18.500001,1044.3384 v 6.6474"
id="path8054-0-0"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.935;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 16.4165,1043.8617 h 4.166666"
id="path8071-1"
inkscape:connector-curvature="0" />
<g
id="g16558"
transform="matrix(0.8331761,0,0,1,2.2916816,0)">
<path
inkscape:connector-curvature="0"
id="path16442"
d="m 11.002838,1050.8557 2.99716,-6.9869"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1.09554851px;stroke-linecap:round;stroke-linejoin:bevel;stroke-opacity:1" />
<path
inkscape:connector-curvature="0"
id="path16444"
d="m 13.999998,1043.8688 2.997161,6.9869"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1.09554851px;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1" />
</g>
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 12,1049.3622 4,0"
id="path16450"
inkscape:connector-curvature="0" />
<path
style="fill:#4d4d4d;fill-opacity:1;fill-rule:evenodd;stroke:#4d4d4d;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 1.0000001,1049.8622 3.0000002,0"
id="path16452-9"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#4d4d4d;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 1.0000001,1041.8622 5.0000001,0"
id="path16452-4-1"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#4d4d4d;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 1.0000001,1043.8622 3.0000004,0"
id="path16452-4-7"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#4d4d4d;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 1.0000001,1045.8622 2.0000001,0"
id="path16452-4-8"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#4d4d4d;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 1.0000001,1047.8622 3.0000004,0"
id="path16452-4-89"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#da4453;stroke-width:1.00000012;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 12.353554,1040.1551 2,2 2.000001,-2"
id="path16535"
inkscape:connector-curvature="0" />
<g
id="g1261"
transform="translate(-2,-0.0478)">
<path
inkscape:connector-curvature="0"
id="path16442-7"
d="m 8.4971623,1031.91 -2.497162,6.9869"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:round;stroke-linejoin:bevel;stroke-opacity:1" />
<path
inkscape:connector-curvature="0"
id="path16444-4"
d="M 6.0000003,1038.8969 3.5028374,1031.91"
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1" />
</g>
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.935414;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 10.967707,1031.8299 v 7"
id="path8054-6"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.935;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 14,1031.7617 H 11"
id="path8054-6-8"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.935;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 14,1038.8617 H 11"
id="path8054-6-8-7"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.919364;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="M 14,1034.8617 H 11.0995"
id="path8054-6-8-7-2"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.900712;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 15.908054,1031.7306 1.0766,7.2162"
id="path8054-2"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.900712;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 21,1031.7626 -1.0766,7.2162"
id="path8054-2-7"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.901;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 18.39969,1035.6617 -1.30419,3.3269"
id="path8054-2-7-0"
inkscape:connector-curvature="0" />
<path
style="fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:0.901;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
d="m 18.4995,1035.6617 1.30419,3.3269"
id="path8054-2-7-0-5"
inkscape:connector-curvature="0" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 11 KiB

View File

@@ -0,0 +1,123 @@
/* Compatability shim for jQuery and underscores.js.
*
* Copyright Sphinx contributors
* Released under the two clause BSD licence
*/
/**
* small helper function to urldecode strings
*
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/decodeURIComponent#Decoding_query_parameters_from_a_URL
*/
jQuery.urldecode = function(x) {
if (!x) {
return x
}
return decodeURIComponent(x.replace(/\+/g, ' '));
};
/**
* small helper function to urlencode strings
*/
jQuery.urlencode = encodeURIComponent;
/**
* This function returns the parsed url parameters of the
* current request. Multiple values per key are supported,
* it will always return arrays of strings for the value parts.
*/
jQuery.getQueryParameters = function(s) {
if (typeof s === 'undefined')
s = document.location.search;
var parts = s.substr(s.indexOf('?') + 1).split('&');
var result = {};
for (var i = 0; i < parts.length; i++) {
var tmp = parts[i].split('=', 2);
var key = jQuery.urldecode(tmp[0]);
var value = jQuery.urldecode(tmp[1]);
if (key in result)
result[key].push(value);
else
result[key] = [value];
}
return result;
};
/**
* highlight a given string on a jquery object by wrapping it in
* span elements with the given class name.
*/
jQuery.fn.highlightText = function(text, className) {
function highlight(node, addItems) {
if (node.nodeType === 3) {
var val = node.nodeValue;
var pos = val.toLowerCase().indexOf(text);
if (pos >= 0 &&
!jQuery(node.parentNode).hasClass(className) &&
!jQuery(node.parentNode).hasClass("nohighlight")) {
var span;
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.className = className;
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
document.createTextNode(val.substr(pos + text.length)),
node.nextSibling));
node.nodeValue = val.substr(0, pos);
if (isInSVG) {
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
var bbox = node.parentElement.getBBox();
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute('class', className);
addItems.push({
"parent": node.parentNode,
"target": rect});
}
}
}
else if (!jQuery(node).is("button, select, textarea")) {
jQuery.each(node.childNodes, function() {
highlight(this, addItems);
});
}
}
var addItems = [];
var result = this.each(function() {
highlight(this, addItems);
});
for (var i = 0; i < addItems.length; ++i) {
jQuery(addItems[i].parent).before(addItems[i].target);
}
return result;
};
/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];
return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 673 B

View File

@@ -1,12 +1,5 @@
/*
* basic.css
* ~~~~~~~~~
*
* Sphinx stylesheet -- basic theme.
*
* :copyright: Copyright 2007-2018 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
/* -- main layout ----------------------------------------------------------- */
@@ -15,6 +8,12 @@ div.clearer {
clear: both;
}
div.section::after {
display: block;
content: '';
clear: left;
}
/* -- relbar ---------------------------------------------------------------- */
div.related {
@@ -81,6 +80,10 @@ div.sphinxsidebar input {
font-size: 1em;
}
div.sphinxsidebar #searchbox form.search {
overflow: hidden;
}
div.sphinxsidebar #searchbox input[type="text"] {
float: left;
width: 80%;
@@ -105,22 +108,18 @@ img {
/* -- search page ----------------------------------------------------------- */
ul.search {
margin: 10px 0 0 20px;
padding: 0;
margin-top: 10px;
}
ul.search li {
padding: 5px 0 5px 20px;
background-image: url(file.png);
background-repeat: no-repeat;
background-position: 0 7px;
padding: 5px 0;
}
ul.search li a {
font-weight: bold;
}
ul.search li div.context {
ul.search li p.context {
color: #888;
margin: 2px 0 0 30px;
text-align: left;
@@ -212,7 +211,7 @@ table.modindextable td {
/* -- general body styles --------------------------------------------------- */
div.body {
min-width: 450px;
min-width: 360px;
max-width: 800px;
}
@@ -227,6 +226,10 @@ a.headerlink {
visibility: hidden;
}
a:visited {
color: #551A8B;
}
h1:hover > a.headerlink,
h2:hover > a.headerlink,
h3:hover > a.headerlink,
@@ -257,19 +260,25 @@ p.rubric {
font-weight: bold;
}
img.align-left, .figure.align-left, object.align-left {
img.align-left, figure.align-left, .figure.align-left, object.align-left {
clear: left;
float: left;
margin-right: 1em;
}
img.align-right, .figure.align-right, object.align-right {
img.align-right, figure.align-right, .figure.align-right, object.align-right {
clear: right;
float: right;
margin-left: 1em;
}
img.align-center, .figure.align-center, object.align-center {
img.align-center, figure.align-center, .figure.align-center, object.align-center {
display: block;
margin-left: auto;
margin-right: auto;
}
img.align-default, figure.align-default, .figure.align-default {
display: block;
margin-left: auto;
margin-right: auto;
@@ -283,30 +292,45 @@ img.align-center, .figure.align-center, object.align-center {
text-align: center;
}
.align-default {
text-align: center;
}
.align-right {
text-align: right;
}
/* -- sidebars -------------------------------------------------------------- */
div.sidebar {
div.sidebar,
aside.sidebar {
margin: 0 0 0.5em 1em;
border: 1px solid #ddb;
padding: 7px 7px 0 7px;
padding: 7px;
background-color: #ffe;
width: 40%;
float: right;
clear: right;
overflow-x: auto;
}
p.sidebar-title {
font-weight: bold;
}
nav.contents,
aside.topic,
div.admonition, div.topic, blockquote {
clear: left;
}
/* -- topics ---------------------------------------------------------------- */
nav.contents,
aside.topic,
div.topic {
border: 1px solid #ccc;
padding: 7px 7px 0 7px;
padding: 7px;
margin: 10px 0 10px 0;
}
@@ -328,10 +352,6 @@ div.admonition dt {
font-weight: bold;
}
div.admonition dl {
margin-bottom: 0;
}
p.admonition-title {
margin: 0px 10px 5px 0px;
font-weight: bold;
@@ -342,9 +362,34 @@ div.body p.centered {
margin-top: 25px;
}
/* -- content of sidebars/topics/admonitions -------------------------------- */
div.sidebar > :last-child,
aside.sidebar > :last-child,
nav.contents > :last-child,
aside.topic > :last-child,
div.topic > :last-child,
div.admonition > :last-child {
margin-bottom: 0;
}
div.sidebar::after,
aside.sidebar::after,
nav.contents::after,
aside.topic::after,
div.topic::after,
div.admonition::after,
blockquote::after {
display: block;
content: '';
clear: both;
}
/* -- tables ---------------------------------------------------------------- */
table.docutils {
margin-top: 10px;
margin-bottom: 10px;
border: 0;
border-collapse: collapse;
}
@@ -354,6 +399,11 @@ table.align-center {
margin-right: auto;
}
table.align-default {
margin-left: auto;
margin-right: auto;
}
table caption span.caption-number {
font-style: italic;
}
@@ -369,10 +419,6 @@ table.docutils td, table.docutils th {
border-bottom: 1px solid #aaa;
}
table.footnote td, table.footnote th {
border: 0 !important;
}
th {
text-align: left;
padding-right: 5px;
@@ -387,22 +433,34 @@ table.citation td {
border-bottom: none;
}
th > :first-child,
td > :first-child {
margin-top: 0px;
}
th > :last-child,
td > :last-child {
margin-bottom: 0px;
}
/* -- figures --------------------------------------------------------------- */
div.figure {
div.figure, figure {
margin: 0.5em;
padding: 0.5em;
}
div.figure p.caption {
div.figure p.caption, figcaption {
padding: 0.3em;
}
div.figure p.caption span.caption-number {
div.figure p.caption span.caption-number,
figcaption span.caption-number {
font-style: italic;
}
div.figure p.caption span.caption-text {
div.figure p.caption span.caption-text,
figcaption span.caption-text {
}
/* -- field list styles ----------------------------------------------------- */
@@ -427,6 +485,74 @@ table.field-list td, table.field-list th {
hyphens: manual;
}
/* -- hlist styles ---------------------------------------------------------- */
table.hlist {
margin: 1em 0;
}
table.hlist td {
vertical-align: top;
}
/* -- object description styles --------------------------------------------- */
.sig {
font-family: 'Consolas', 'Menlo', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', monospace;
}
.sig-name, code.descname {
background-color: transparent;
font-weight: bold;
}
.sig-name {
font-size: 1.1em;
}
code.descname {
font-size: 1.2em;
}
.sig-prename, code.descclassname {
background-color: transparent;
}
.optional {
font-size: 1.3em;
}
.sig-paren {
font-size: larger;
}
.sig-param.n {
font-style: italic;
}
/* C++ specific styling */
.sig-inline.c-texpr,
.sig-inline.cpp-texpr {
font-family: unset;
}
.sig.c .k, .sig.c .kt,
.sig.cpp .k, .sig.cpp .kt {
color: #0033B3;
}
.sig.c .m,
.sig.cpp .m {
color: #1750EB;
}
.sig.c .s, .sig.c .sc,
.sig.cpp .s, .sig.cpp .sc {
color: #067D17;
}
/* -- other body styles ----------------------------------------------------- */
ol.arabic {
@@ -449,11 +575,81 @@ ol.upperroman {
list-style: upper-roman;
}
:not(li) > ol > li:first-child > :first-child,
:not(li) > ul > li:first-child > :first-child {
margin-top: 0px;
}
:not(li) > ol > li:last-child > :last-child,
:not(li) > ul > li:last-child > :last-child {
margin-bottom: 0px;
}
ol.simple ol p,
ol.simple ul p,
ul.simple ol p,
ul.simple ul p {
margin-top: 0;
}
ol.simple > li:not(:first-child) > p,
ul.simple > li:not(:first-child) > p {
margin-top: 0;
}
ol.simple p,
ul.simple p {
margin-bottom: 0;
}
aside.footnote > span,
div.citation > span {
float: left;
}
aside.footnote > span:last-of-type,
div.citation > span:last-of-type {
padding-right: 0.5em;
}
aside.footnote > p {
margin-left: 2em;
}
div.citation > p {
margin-left: 4em;
}
aside.footnote > p:last-of-type,
div.citation > p:last-of-type {
margin-bottom: 0em;
}
aside.footnote > p:last-of-type:after,
div.citation > p:last-of-type:after {
content: "";
clear: both;
}
dl.field-list {
display: grid;
grid-template-columns: fit-content(30%) auto;
}
dl.field-list > dt {
font-weight: bold;
word-break: break-word;
padding-left: 0.5em;
padding-right: 5px;
}
dl.field-list > dd {
padding-left: 0.5em;
margin-top: 0em;
margin-left: 0em;
margin-bottom: 0em;
}
dl {
margin-bottom: 15px;
}
dd p {
dd > :first-child {
margin-top: 0px;
}
@@ -467,6 +663,21 @@ dd {
margin-left: 30px;
}
.sig dd {
margin-top: 0px;
margin-bottom: 0px;
}
.sig dl {
margin-top: 0px;
margin-bottom: 0px;
}
dl > dd:last-child,
dl > dd:last-child > :last-child {
margin-bottom: 0;
}
dt:target, span.highlighted {
background-color: #fbe54e;
}
@@ -480,14 +691,6 @@ dl.glossary dt {
font-size: 1.1em;
}
.optional {
font-size: 1.3em;
}
.sig-paren {
font-size: larger;
}
.versionmodified {
font-style: italic;
}
@@ -526,11 +729,26 @@ dl.glossary dt {
font-style: oblique;
}
.classifier:before {
font-style: normal;
margin: 0 0.5em;
content: ":";
display: inline-block;
}
abbr, acronym {
border-bottom: dotted 1px;
cursor: help;
}
.translated {
background-color: rgba(207, 255, 207, 0.2)
}
.untranslated {
background-color: rgba(255, 207, 207, 0.2)
}
/* -- code displays --------------------------------------------------------- */
pre {
@@ -538,29 +756,69 @@ pre {
overflow-y: hidden; /* fixes display issues on Chrome browsers */
}
pre, div[class*="highlight-"] {
clear: both;
}
span.pre {
-moz-hyphens: none;
-ms-hyphens: none;
-webkit-hyphens: none;
hyphens: none;
white-space: nowrap;
}
div[class*="highlight-"] {
margin: 1em 0;
}
td.linenos pre {
padding: 5px 0px;
border: 0;
background-color: transparent;
color: #aaa;
}
table.highlighttable {
margin-left: 0.5em;
display: block;
}
table.highlighttable tbody {
display: block;
}
table.highlighttable tr {
display: flex;
}
table.highlighttable td {
padding: 0 0.5em 0 0.5em;
margin: 0;
padding: 0;
}
table.highlighttable td.linenos {
padding-right: 0.5em;
}
table.highlighttable td.code {
flex: 1;
overflow: hidden;
}
.highlight .hll {
display: block;
}
div.highlight pre,
table.highlighttable pre {
margin: 0;
}
div.code-block-caption + div {
margin-top: 0;
}
div.code-block-caption {
margin-top: 1em;
padding: 2px 5px;
font-size: small;
}
@@ -569,8 +827,14 @@ div.code-block-caption code {
background-color: transparent;
}
div.code-block-caption + div > div.highlight > pre {
margin-top: 0;
table.highlighttable td.linenos,
span.linenos,
div.highlight span.gp { /* gp: Generic.Prompt */
user-select: none;
-webkit-user-select: text; /* Safari fallback only */
-webkit-user-select: none; /* Chrome/Safari */
-moz-user-select: none; /* Firefox */
-ms-user-select: none; /* IE10+ */
}
div.code-block-caption span.caption-number {
@@ -582,21 +846,7 @@ div.code-block-caption span.caption-text {
}
div.literal-block-wrapper {
padding: 1em 1em 0;
}
div.literal-block-wrapper div.highlight {
margin: 0;
}
code.descname {
background-color: transparent;
font-weight: bold;
font-size: 1.2em;
}
code.descclassname {
background-color: transparent;
margin: 1em 0;
}
code.xref, a code {
@@ -637,8 +887,7 @@ span.eqno {
}
span.eqno a.headerlink {
position: relative;
left: 0px;
position: absolute;
z-index: 1;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 756 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 829 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 641 B

View File

@@ -1 +1 @@
.fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:before,.clearfix:after{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-weight:normal;font-style:normal;src:url("../fonts/fontawesome-webfont.eot");src:url("../fonts/fontawesome-webfont.eot?#iefix") format("embedded-opentype"),url("../fonts/fontawesome-webfont.woff") format("woff"),url("../fonts/fontawesome-webfont.ttf") format("truetype"),url("../fonts/fontawesome-webfont.svg#FontAwesome") format("svg")}.fa:before{display:inline-block;font-family:FontAwesome;font-style:normal;font-weight:normal;line-height:1;text-decoration:inherit}a .fa{display:inline-block;text-decoration:inherit}li .fa{display:inline-block}li .fa-large:before,li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-0.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before,ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before{content:""}.icon-book:before{content:""}.fa-caret-down:before{content:""}.icon-caret-down:before{content:""}.fa-caret-up:before{content:""}.icon-caret-up:before{content:""}.fa-caret-left:before{content:""}.icon-caret-left:before{content:""}.fa-caret-right:before{content:""}.icon-caret-right:before{content:""}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:"Lato","proxima-nova","Helvetica Neue",Arial,sans-serif;z-index:400}.rst-versions a{color:#2980B9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27AE60;*zoom:1}.rst-versions .rst-current-version:before,.rst-versions .rst-current-version:after{display:table;content:""}.rst-versions .rst-current-version:after{clear:both}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book{float:left}.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#E74C3C;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#F1C40F;color:#000}.rst-versions.shift-up{height:auto;max-height:100%}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:gray;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:solid 1px #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px}.rst-versions.rst-badge .icon-book{float:none}.rst-versions.rst-badge .fa-book{float:none}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book{float:left}.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge .rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width: 768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}
.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:local("FontAwesome"),url('/.sysassets/fonts/fontawesome/fontawesome-webfont.ttf') format("truetype")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions .rst-other-versions .rtd-current-item{font-weight:700}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}#flyout-search-form{padding:6px}

File diff suppressed because one or more lines are too long

View File

@@ -1,313 +1,149 @@
/*
* doctools.js
* ~~~~~~~~~~~
*
* Sphinx JavaScript utilities for all documentation.
*
* :copyright: Copyright 2007-2018 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
* Base JavaScript utilities for all Sphinx HTML documentation.
*/
"use strict";
/**
* select a different prefix for underscore
*/
$u = _.noConflict();
const BLACKLISTED_KEY_CONTROL_ELEMENTS = new Set([
"TEXTAREA",
"INPUT",
"SELECT",
"BUTTON",
]);
/**
* make the code below compatible with browsers without
* an installed firebug like debugger
if (!window.console || !console.firebug) {
var names = ["log", "debug", "info", "warn", "error", "assert", "dir",
"dirxml", "group", "groupEnd", "time", "timeEnd", "count", "trace",
"profile", "profileEnd"];
window.console = {};
for (var i = 0; i < names.length; ++i)
window.console[names[i]] = function() {};
}
*/
/**
* small helper function to urldecode strings
*/
jQuery.urldecode = function(x) {
return decodeURIComponent(x).replace(/\+/g, ' ');
};
/**
* small helper function to urlencode strings
*/
jQuery.urlencode = encodeURIComponent;
/**
* This function returns the parsed url parameters of the
* current request. Multiple values per key are supported,
* it will always return arrays of strings for the value parts.
*/
jQuery.getQueryParameters = function(s) {
if (typeof s === 'undefined')
s = document.location.search;
var parts = s.substr(s.indexOf('?') + 1).split('&');
var result = {};
for (var i = 0; i < parts.length; i++) {
var tmp = parts[i].split('=', 2);
var key = jQuery.urldecode(tmp[0]);
var value = jQuery.urldecode(tmp[1]);
if (key in result)
result[key].push(value);
else
result[key] = [value];
const _ready = (callback) => {
if (document.readyState !== "loading") {
callback();
} else {
document.addEventListener("DOMContentLoaded", callback);
}
return result;
};
/**
* highlight a given string on a jquery object by wrapping it in
* span elements with the given class name.
*/
jQuery.fn.highlightText = function(text, className) {
function highlight(node, addItems) {
if (node.nodeType === 3) {
var val = node.nodeValue;
var pos = val.toLowerCase().indexOf(text);
if (pos >= 0 &&
!jQuery(node.parentNode).hasClass(className) &&
!jQuery(node.parentNode).hasClass("nohighlight")) {
var span;
var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.className = className;
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
node.parentNode.insertBefore(span, node.parentNode.insertBefore(
document.createTextNode(val.substr(pos + text.length)),
node.nextSibling));
node.nodeValue = val.substr(0, pos);
if (isInSVG) {
var bbox = span.getBBox();
var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute('class', className);
var parentOfText = node.parentNode.parentNode;
addItems.push({
"parent": node.parentNode,
"target": rect});
}
}
}
else if (!jQuery(node).is("button, select, textarea")) {
jQuery.each(node.childNodes, function() {
highlight(this, addItems);
});
}
}
var addItems = [];
var result = this.each(function() {
highlight(this, addItems);
});
for (var i = 0; i < addItems.length; ++i) {
jQuery(addItems[i].parent).before(addItems[i].target);
}
return result;
};
/*
* backward compatibility for jQuery.browser
* This will be supported until firefox bug is fixed.
*/
if (!jQuery.browser) {
jQuery.uaMatch = function(ua) {
ua = ua.toLowerCase();
var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
/(webkit)[ \/]([\w.]+)/.exec(ua) ||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
/(msie) ([\w.]+)/.exec(ua) ||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
[];
return {
browser: match[ 1 ] || "",
version: match[ 2 ] || "0"
};
};
jQuery.browser = {};
jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
}
/**
* Small JavaScript module for the documentation.
*/
var Documentation = {
init : function() {
this.fixFirefoxAnchorBug();
this.highlightSearchWords();
this.initIndexTable();
const Documentation = {
init: () => {
Documentation.initDomainIndexTable();
Documentation.initOnKeyListeners();
},
/**
* i18n support
*/
TRANSLATIONS : {},
PLURAL_EXPR : function(n) { return n === 1 ? 0 : 1; },
LOCALE : 'unknown',
TRANSLATIONS: {},
PLURAL_EXPR: (n) => (n === 1 ? 0 : 1),
LOCALE: "unknown",
// gettext and ngettext don't access this so that the functions
// can safely bound to a different name (_ = Documentation.gettext)
gettext : function(string) {
var translated = Documentation.TRANSLATIONS[string];
if (typeof translated === 'undefined')
return string;
return (typeof translated === 'string') ? translated : translated[0];
gettext: (string) => {
const translated = Documentation.TRANSLATIONS[string];
switch (typeof translated) {
case "undefined":
return string; // no translation
case "string":
return translated; // translation exists
default:
return translated[0]; // (singular, plural) translation tuple exists
}
},
ngettext : function(singular, plural, n) {
var translated = Documentation.TRANSLATIONS[singular];
if (typeof translated === 'undefined')
return (n == 1) ? singular : plural;
return translated[Documentation.PLURALEXPR(n)];
ngettext: (singular, plural, n) => {
const translated = Documentation.TRANSLATIONS[singular];
if (typeof translated !== "undefined")
return translated[Documentation.PLURAL_EXPR(n)];
return n === 1 ? singular : plural;
},
addTranslations : function(catalog) {
for (var key in catalog.messages)
this.TRANSLATIONS[key] = catalog.messages[key];
this.PLURAL_EXPR = new Function('n', 'return +(' + catalog.plural_expr + ')');
this.LOCALE = catalog.locale;
addTranslations: (catalog) => {
Object.assign(Documentation.TRANSLATIONS, catalog.messages);
Documentation.PLURAL_EXPR = new Function(
"n",
`return (${catalog.plural_expr})`
);
Documentation.LOCALE = catalog.locale;
},
/**
* add context elements like header anchor links
* helper function to focus on search bar
*/
addContextElements : function() {
$('div[id] > :header:first').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this headline')).
appendTo(this);
});
$('dt[id]').each(function() {
$('<a class="headerlink">\u00B6</a>').
attr('href', '#' + this.id).
attr('title', _('Permalink to this definition')).
appendTo(this);
});
focusSearchBar: () => {
document.querySelectorAll("input[name=q]")[0]?.focus();
},
/**
* workaround a firefox stupidity
* see: https://bugzilla.mozilla.org/show_bug.cgi?id=645075
* Initialise the domain index toggle buttons
*/
fixFirefoxAnchorBug : function() {
if (document.location.hash && $.browser.mozilla)
window.setTimeout(function() {
document.location.href += '';
}, 10);
},
/**
* highlight the search words provided in the url in the text
*/
highlightSearchWords : function() {
var params = $.getQueryParameters();
var terms = (params.highlight) ? params.highlight[0].split(/\s+/) : [];
if (terms.length) {
var body = $('div.body');
if (!body.length) {
body = $('body');
initDomainIndexTable: () => {
const toggler = (el) => {
const idNumber = el.id.substr(7);
const toggledRows = document.querySelectorAll(`tr.cg-${idNumber}`);
if (el.src.substr(-9) === "minus.png") {
el.src = `${el.src.substr(0, el.src.length - 9)}plus.png`;
toggledRows.forEach((el) => (el.style.display = "none"));
} else {
el.src = `${el.src.substr(0, el.src.length - 8)}minus.png`;
toggledRows.forEach((el) => (el.style.display = ""));
}
window.setTimeout(function() {
$.each(terms, function() {
body.highlightText(this.toLowerCase(), 'highlighted');
});
}, 10);
$('<p class="highlight-link"><a href="javascript:Documentation.' +
'hideSearchWords()">' + _('Hide Search Matches') + '</a></p>')
.appendTo($('#searchbox'));
}
};
const togglerElements = document.querySelectorAll("img.toggler");
togglerElements.forEach((el) =>
el.addEventListener("click", (event) => toggler(event.currentTarget))
);
togglerElements.forEach((el) => (el.style.display = ""));
if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) togglerElements.forEach(toggler);
},
/**
* init the domain index toggle buttons
*/
initIndexTable : function() {
var togglers = $('img.toggler').click(function() {
var src = $(this).attr('src');
var idnum = $(this).attr('id').substr(7);
$('tr.cg-' + idnum).toggle();
if (src.substr(-9) === 'minus.png')
$(this).attr('src', src.substr(0, src.length-9) + 'plus.png');
else
$(this).attr('src', src.substr(0, src.length-8) + 'minus.png');
}).css('display', '');
if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) {
togglers.click();
}
},
initOnKeyListeners: () => {
// only install a listener if it is really needed
if (
!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS &&
!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS
)
return;
/**
* helper function to hide the search marks again
*/
hideSearchWords : function() {
$('#searchbox .highlight-link').fadeOut(300);
$('span.highlighted').removeClass('highlighted');
},
document.addEventListener("keydown", (event) => {
// bail for input elements
if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return;
// bail with special keys
if (event.altKey || event.ctrlKey || event.metaKey) return;
/**
* make the url absolute
*/
makeURL : function(relativeURL) {
return DOCUMENTATION_OPTIONS.URL_ROOT + '/' + relativeURL;
},
if (!event.shiftKey) {
switch (event.key) {
case "ArrowLeft":
if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break;
/**
* get the current relative url
*/
getCurrentURL : function() {
var path = document.location.pathname;
var parts = path.split(/\//);
$.each(DOCUMENTATION_OPTIONS.URL_ROOT.split(/\//), function() {
if (this === '..')
parts.pop();
});
var url = parts.join('/');
return path.substring(url.lastIndexOf('/') + 1, path.length - 1);
},
initOnKeyListeners: function() {
$(document).keyup(function(event) {
var activeElementType = document.activeElement.tagName;
// don't navigate when in search box or textarea
if (activeElementType !== 'TEXTAREA' && activeElementType !== 'INPUT' && activeElementType !== 'SELECT') {
switch (event.keyCode) {
case 37: // left
var prevHref = $('link[rel="prev"]').prop('href');
if (prevHref) {
window.location.href = prevHref;
return false;
const prevLink = document.querySelector('link[rel="prev"]');
if (prevLink && prevLink.href) {
window.location.href = prevLink.href;
event.preventDefault();
}
case 39: // right
var nextHref = $('link[rel="next"]').prop('href');
if (nextHref) {
window.location.href = nextHref;
return false;
break;
case "ArrowRight":
if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break;
const nextLink = document.querySelector('link[rel="next"]');
if (nextLink && nextLink.href) {
window.location.href = nextLink.href;
event.preventDefault();
}
break;
}
}
// some keyboard layouts may need Shift to get /
switch (event.key) {
case "/":
if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) break;
Documentation.focusSearchBar();
event.preventDefault();
}
});
}
},
};
// quick alias for translations
_ = Documentation.gettext;
const _ = Documentation.gettext;
$(document).ready(function() {
Documentation.init();
});
_ready(Documentation.init);

View File

@@ -1,9 +1,13 @@
var DOCUMENTATION_OPTIONS = {
URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
VERSION: '1.9.3',
LANGUAGE: 'None',
const DOCUMENTATION_OPTIONS = {
VERSION: '1.9.9',
LANGUAGE: 'en',
COLLAPSE_INDEX: false,
BUILDER: 'html',
FILE_SUFFIX: '.html',
LINK_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
SOURCELINK_SUFFIX: '.txt',
NAVIGATION_WITH_KEYS: false,
SHOW_SEARCH_SUMMARY: true,
ENABLE_SEARCH_SHORTCUTS: true,
};

Binary file not shown.

Before

Width:  |  Height:  |  Size: 222 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 202 B

Binary file not shown.

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 434 KiB

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1 @@
!function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=4)}({4:function(e,t,r){}});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,228 @@
const themeFlyoutDisplay = "hidden";
const themeVersionSelector = true;
const themeLanguageSelector = true;
if (themeFlyoutDisplay === "attached") {
function renderLanguages(config) {
if (!config.projects.translations.length) {
return "";
}
// Insert the current language to the options on the selector
let languages = config.projects.translations.concat(config.projects.current);
languages = languages.sort((a, b) => a.language.name.localeCompare(b.language.name));
const languagesHTML = `
<dl>
<dt>Languages</dt>
${languages
.map(
(translation) => `
<dd ${translation.slug == config.projects.current.slug ? 'class="rtd-current-item"' : ""}>
<a href="${translation.urls.documentation}">${translation.language.code}</a>
</dd>
`,
)
.join("\n")}
</dl>
`;
return languagesHTML;
}
function renderVersions(config) {
if (!config.versions.active.length) {
return "";
}
const versionsHTML = `
<dl>
<dt>Versions</dt>
${config.versions.active
.map(
(version) => `
<dd ${version.slug === config.versions.current.slug ? 'class="rtd-current-item"' : ""}>
<a href="${version.urls.documentation}">${version.slug}</a>
</dd>
`,
)
.join("\n")}
</dl>
`;
return versionsHTML;
}
function renderDownloads(config) {
if (!Object.keys(config.versions.current.downloads).length) {
return "";
}
const downloadsNameDisplay = {
pdf: "PDF",
epub: "Epub",
htmlzip: "HTML",
};
const downloadsHTML = `
<dl>
<dt>Downloads</dt>
${Object.entries(config.versions.current.downloads)
.map(
([name, url]) => `
<dd>
<a href="${url}">${downloadsNameDisplay[name]}</a>
</dd>
`,
)
.join("\n")}
</dl>
`;
return downloadsHTML;
}
document.addEventListener("readthedocs-addons-data-ready", function (event) {
const config = event.detail.data();
const flyout = `
<div class="rst-versions" data-toggle="rst-versions" role="note">
<span class="rst-current-version" data-toggle="rst-current-version">
<span class="fa fa-book"> Read the Docs</span>
v: ${config.versions.current.slug}
<span class="fa fa-caret-down"></span>
</span>
<div class="rst-other-versions">
<div class="injected">
${renderLanguages(config)}
${renderVersions(config)}
${renderDownloads(config)}
<dl>
<dt>On Read the Docs</dt>
<dd>
<a href="${config.projects.current.urls.home}">Project Home</a>
</dd>
<dd>
<a href="${config.projects.current.urls.builds}">Builds</a>
</dd>
<dd>
<a href="${config.projects.current.urls.downloads}">Downloads</a>
</dd>
</dl>
<dl>
<dt>Search</dt>
<dd>
<form id="flyout-search-form">
<input
class="wy-form"
type="text"
name="q"
aria-label="Search docs"
placeholder="Search docs"
/>
</form>
</dd>
</dl>
<hr />
<small>
<span>Hosted by <a href="https://about.readthedocs.org/?utm_source=&utm_content=flyout">Read the Docs</a></span>
</small>
</div>
</div>
`;
// Inject the generated flyout into the body HTML element.
document.body.insertAdjacentHTML("beforeend", flyout);
// Trigger the Read the Docs Addons Search modal when clicking on the "Search docs" input from inside the flyout.
document
.querySelector("#flyout-search-form")
.addEventListener("focusin", () => {
const event = new CustomEvent("readthedocs-search-show");
document.dispatchEvent(event);
});
})
}
if (themeLanguageSelector || themeVersionSelector) {
function onSelectorSwitch(event) {
const option = event.target.selectedIndex;
const item = event.target.options[option];
window.location.href = item.dataset.url;
}
document.addEventListener("readthedocs-addons-data-ready", function (event) {
const config = event.detail.data();
const versionSwitch = document.querySelector(
"div.switch-menus > div.version-switch",
);
if (themeVersionSelector) {
let versions = config.versions.active;
if (config.versions.current.hidden || config.versions.current.type === "external") {
versions.unshift(config.versions.current);
}
const versionSelect = `
<select>
${versions
.map(
(version) => `
<option
value="${version.slug}"
${config.versions.current.slug === version.slug ? 'selected="selected"' : ""}
data-url="${version.urls.documentation}">
${version.slug}
</option>`,
)
.join("\n")}
</select>
`;
versionSwitch.innerHTML = versionSelect;
versionSwitch.firstElementChild.addEventListener("change", onSelectorSwitch);
}
const languageSwitch = document.querySelector(
"div.switch-menus > div.language-switch",
);
if (themeLanguageSelector) {
if (config.projects.translations.length) {
// Add the current language to the options on the selector
let languages = config.projects.translations.concat(
config.projects.current,
);
languages = languages.sort((a, b) =>
a.language.name.localeCompare(b.language.name),
);
const languageSelect = `
<select>
${languages
.map(
(language) => `
<option
value="${language.language.code}"
${config.projects.current.slug === language.slug ? 'selected="selected"' : ""}
data-url="${language.urls.documentation}">
${language.language.name}
</option>`,
)
.join("\n")}
</select>
`;
languageSwitch.innerHTML = languageSelect;
languageSwitch.firstElementChild.addEventListener("change", onSelectorSwitch);
}
else {
languageSwitch.remove();
}
}
});
}
document.addEventListener("readthedocs-addons-data-ready", function (event) {
// Trigger the Read the Docs Addons Search modal when clicking on "Search docs" input from the topnav.
document
.querySelector("[role='search'] input")
.addEventListener("focusin", () => {
const event = new CustomEvent("readthedocs-search-show");
document.dispatchEvent(event);
});
});

View File

@@ -0,0 +1,192 @@
/*
* This script contains the language-specific data used by searchtools.js,
* namely the list of stopwords, stemmer, scorer and splitter.
*/
var stopwords = ["a", "and", "are", "as", "at", "be", "but", "by", "for", "if", "in", "into", "is", "it", "near", "no", "not", "of", "on", "or", "such", "that", "the", "their", "then", "there", "these", "they", "this", "to", "was", "will", "with"];
/* Non-minified version is copied as a separate JS file, if available */
/**
* Porter Stemmer
*/
var Stemmer = function() {
var step2list = {
ational: 'ate',
tional: 'tion',
enci: 'ence',
anci: 'ance',
izer: 'ize',
bli: 'ble',
alli: 'al',
entli: 'ent',
eli: 'e',
ousli: 'ous',
ization: 'ize',
ation: 'ate',
ator: 'ate',
alism: 'al',
iveness: 'ive',
fulness: 'ful',
ousness: 'ous',
aliti: 'al',
iviti: 'ive',
biliti: 'ble',
logi: 'log'
};
var step3list = {
icate: 'ic',
ative: '',
alize: 'al',
iciti: 'ic',
ical: 'ic',
ful: '',
ness: ''
};
var c = "[^aeiou]"; // consonant
var v = "[aeiouy]"; // vowel
var C = c + "[^aeiouy]*"; // consonant sequence
var V = v + "[aeiou]*"; // vowel sequence
var mgr0 = "^(" + C + ")?" + V + C; // [C]VC... is m>0
var meq1 = "^(" + C + ")?" + V + C + "(" + V + ")?$"; // [C]VC[V] is m=1
var mgr1 = "^(" + C + ")?" + V + C + V + C; // [C]VCVC... is m>1
var s_v = "^(" + C + ")?" + v; // vowel in stem
this.stemWord = function (w) {
var stem;
var suffix;
var firstch;
var origword = w;
if (w.length < 3)
return w;
var re;
var re2;
var re3;
var re4;
firstch = w.substr(0,1);
if (firstch == "y")
w = firstch.toUpperCase() + w.substr(1);
// Step 1a
re = /^(.+?)(ss|i)es$/;
re2 = /^(.+?)([^s])s$/;
if (re.test(w))
w = w.replace(re,"$1$2");
else if (re2.test(w))
w = w.replace(re2,"$1$2");
// Step 1b
re = /^(.+?)eed$/;
re2 = /^(.+?)(ed|ing)$/;
if (re.test(w)) {
var fp = re.exec(w);
re = new RegExp(mgr0);
if (re.test(fp[1])) {
re = /.$/;
w = w.replace(re,"");
}
}
else if (re2.test(w)) {
var fp = re2.exec(w);
stem = fp[1];
re2 = new RegExp(s_v);
if (re2.test(stem)) {
w = stem;
re2 = /(at|bl|iz)$/;
re3 = new RegExp("([^aeiouylsz])\\1$");
re4 = new RegExp("^" + C + v + "[^aeiouwxy]$");
if (re2.test(w))
w = w + "e";
else if (re3.test(w)) {
re = /.$/;
w = w.replace(re,"");
}
else if (re4.test(w))
w = w + "e";
}
}
// Step 1c
re = /^(.+?)y$/;
if (re.test(w)) {
var fp = re.exec(w);
stem = fp[1];
re = new RegExp(s_v);
if (re.test(stem))
w = stem + "i";
}
// Step 2
re = /^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/;
if (re.test(w)) {
var fp = re.exec(w);
stem = fp[1];
suffix = fp[2];
re = new RegExp(mgr0);
if (re.test(stem))
w = stem + step2list[suffix];
}
// Step 3
re = /^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/;
if (re.test(w)) {
var fp = re.exec(w);
stem = fp[1];
suffix = fp[2];
re = new RegExp(mgr0);
if (re.test(stem))
w = stem + step3list[suffix];
}
// Step 4
re = /^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/;
re2 = /^(.+?)(s|t)(ion)$/;
if (re.test(w)) {
var fp = re.exec(w);
stem = fp[1];
re = new RegExp(mgr1);
if (re.test(stem))
w = stem;
}
else if (re2.test(w)) {
var fp = re2.exec(w);
stem = fp[1] + fp[2];
re2 = new RegExp(mgr1);
if (re2.test(stem))
w = stem;
}
// Step 5
re = /^(.+?)e$/;
if (re.test(w)) {
var fp = re.exec(w);
stem = fp[1];
re = new RegExp(mgr1);
re2 = new RegExp(meq1);
re3 = new RegExp("^" + C + v + "[^aeiouwxy]$");
if (re.test(stem) || (re2.test(stem) && !(re3.test(stem))))
w = stem;
}
re = /ll$/;
re2 = new RegExp(mgr1);
if (re.test(w) && re2.test(w)) {
re = /.$/;
w = w.replace(re,"");
}
// and turn initial Y back to y
if (firstch == "y")
w = firstch.toLowerCase() + w.substr(1);
return w;
}
}

View File

@@ -1,5 +1,10 @@
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight { background: #eeffcc; }
.highlight { background: #eeffcc; }
.highlight .c { color: #408090; font-style: italic } /* Comment */
.highlight .err { border: 1px solid #FF0000 } /* Error */
.highlight .k { color: #007020; font-weight: bold } /* Keyword */
@@ -12,6 +17,7 @@
.highlight .cs { color: #408090; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #A00000 } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.highlight .gr { color: #FF0000 } /* Generic.Error */
.highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */
.highlight .gi { color: #00A000 } /* Generic.Inserted */

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,154 @@
/* Highlighting utilities for Sphinx HTML documentation. */
"use strict";
const SPHINX_HIGHLIGHT_ENABLED = true
/**
* highlight a given string on a node by wrapping it in
* span elements with the given class name.
*/
const _highlight = (node, addItems, text, className) => {
if (node.nodeType === Node.TEXT_NODE) {
const val = node.nodeValue;
const parent = node.parentNode;
const pos = val.toLowerCase().indexOf(text);
if (
pos >= 0 &&
!parent.classList.contains(className) &&
!parent.classList.contains("nohighlight")
) {
let span;
const closestNode = parent.closest("body, svg, foreignObject");
const isInSVG = closestNode && closestNode.matches("svg");
if (isInSVG) {
span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
} else {
span = document.createElement("span");
span.classList.add(className);
}
span.appendChild(document.createTextNode(val.substr(pos, text.length)));
const rest = document.createTextNode(val.substr(pos + text.length));
parent.insertBefore(
span,
parent.insertBefore(
rest,
node.nextSibling
)
);
node.nodeValue = val.substr(0, pos);
/* There may be more occurrences of search term in this node. So call this
* function recursively on the remaining fragment.
*/
_highlight(rest, addItems, text, className);
if (isInSVG) {
const rect = document.createElementNS(
"http://www.w3.org/2000/svg",
"rect"
);
const bbox = parent.getBBox();
rect.x.baseVal.value = bbox.x;
rect.y.baseVal.value = bbox.y;
rect.width.baseVal.value = bbox.width;
rect.height.baseVal.value = bbox.height;
rect.setAttribute("class", className);
addItems.push({ parent: parent, target: rect });
}
}
} else if (node.matches && !node.matches("button, select, textarea")) {
node.childNodes.forEach((el) => _highlight(el, addItems, text, className));
}
};
const _highlightText = (thisNode, text, className) => {
let addItems = [];
_highlight(thisNode, addItems, text, className);
addItems.forEach((obj) =>
obj.parent.insertAdjacentElement("beforebegin", obj.target)
);
};
/**
* Small JavaScript module for the documentation.
*/
const SphinxHighlight = {
/**
* highlight the search words provided in localstorage in the text
*/
highlightSearchWords: () => {
if (!SPHINX_HIGHLIGHT_ENABLED) return; // bail if no highlight
// get and clear terms from localstorage
const url = new URL(window.location);
const highlight =
localStorage.getItem("sphinx_highlight_terms")
|| url.searchParams.get("highlight")
|| "";
localStorage.removeItem("sphinx_highlight_terms")
url.searchParams.delete("highlight");
window.history.replaceState({}, "", url);
// get individual terms from highlight string
const terms = highlight.toLowerCase().split(/\s+/).filter(x => x);
if (terms.length === 0) return; // nothing to do
// There should never be more than one element matching "div.body"
const divBody = document.querySelectorAll("div.body");
const body = divBody.length ? divBody[0] : document.querySelector("body");
window.setTimeout(() => {
terms.forEach((term) => _highlightText(body, term, "highlighted"));
}, 10);
const searchBox = document.getElementById("searchbox");
if (searchBox === null) return;
searchBox.appendChild(
document
.createRange()
.createContextualFragment(
'<p class="highlight-link">' +
'<a href="javascript:SphinxHighlight.hideSearchWords()">' +
_("Hide Search Matches") +
"</a></p>"
)
);
},
/**
* helper function to hide the search marks again
*/
hideSearchWords: () => {
document
.querySelectorAll("#searchbox .highlight-link")
.forEach((el) => el.remove());
document
.querySelectorAll("span.highlighted")
.forEach((el) => el.classList.remove("highlighted"));
localStorage.removeItem("sphinx_highlight_terms")
},
initEscapeListener: () => {
// only install a listener if it is really needed
if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) return;
document.addEventListener("keydown", (event) => {
// bail for input elements
if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return;
// bail with special keys
if (event.shiftKey || event.altKey || event.ctrlKey || event.metaKey) return;
if (DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS && (event.key === "Escape")) {
SphinxHighlight.hideSearchWords();
event.preventDefault();
}
});
},
};
_ready(() => {
/* Do not call highlightSearchWords() when we are on the search page.
* It will highlight words from the *previous* search query.
*/
if (typeof Search === "undefined") SphinxHighlight.highlightSearchWords();
SphinxHighlight.initEscapeListener();
});

View File

@@ -1,999 +0,0 @@
// Underscore.js 1.3.1
// (c) 2009-2012 Jeremy Ashkenas, DocumentCloud Inc.
// Underscore is freely distributable under the MIT license.
// Portions of Underscore are inspired or borrowed from Prototype,
// Oliver Steele's Functional, and John Resig's Micro-Templating.
// For all details and documentation:
// http://documentcloud.github.com/underscore
(function() {
// Baseline setup
// --------------
// Establish the root object, `window` in the browser, or `global` on the server.
var root = this;
// Save the previous value of the `_` variable.
var previousUnderscore = root._;
// Establish the object that gets returned to break out of a loop iteration.
var breaker = {};
// Save bytes in the minified (but not gzipped) version:
var ArrayProto = Array.prototype, ObjProto = Object.prototype, FuncProto = Function.prototype;
// Create quick reference variables for speed access to core prototypes.
var slice = ArrayProto.slice,
unshift = ArrayProto.unshift,
toString = ObjProto.toString,
hasOwnProperty = ObjProto.hasOwnProperty;
// All **ECMAScript 5** native function implementations that we hope to use
// are declared here.
var
nativeForEach = ArrayProto.forEach,
nativeMap = ArrayProto.map,
nativeReduce = ArrayProto.reduce,
nativeReduceRight = ArrayProto.reduceRight,
nativeFilter = ArrayProto.filter,
nativeEvery = ArrayProto.every,
nativeSome = ArrayProto.some,
nativeIndexOf = ArrayProto.indexOf,
nativeLastIndexOf = ArrayProto.lastIndexOf,
nativeIsArray = Array.isArray,
nativeKeys = Object.keys,
nativeBind = FuncProto.bind;
// Create a safe reference to the Underscore object for use below.
var _ = function(obj) { return new wrapper(obj); };
// Export the Underscore object for **Node.js**, with
// backwards-compatibility for the old `require()` API. If we're in
// the browser, add `_` as a global object via a string identifier,
// for Closure Compiler "advanced" mode.
if (typeof exports !== 'undefined') {
if (typeof module !== 'undefined' && module.exports) {
exports = module.exports = _;
}
exports._ = _;
} else {
root['_'] = _;
}
// Current version.
_.VERSION = '1.3.1';
// Collection Functions
// --------------------
// The cornerstone, an `each` implementation, aka `forEach`.
// Handles objects with the built-in `forEach`, arrays, and raw objects.
// Delegates to **ECMAScript 5**'s native `forEach` if available.
var each = _.each = _.forEach = function(obj, iterator, context) {
if (obj == null) return;
if (nativeForEach && obj.forEach === nativeForEach) {
obj.forEach(iterator, context);
} else if (obj.length === +obj.length) {
for (var i = 0, l = obj.length; i < l; i++) {
if (i in obj && iterator.call(context, obj[i], i, obj) === breaker) return;
}
} else {
for (var key in obj) {
if (_.has(obj, key)) {
if (iterator.call(context, obj[key], key, obj) === breaker) return;
}
}
}
};
// Return the results of applying the iterator to each element.
// Delegates to **ECMAScript 5**'s native `map` if available.
_.map = _.collect = function(obj, iterator, context) {
var results = [];
if (obj == null) return results;
if (nativeMap && obj.map === nativeMap) return obj.map(iterator, context);
each(obj, function(value, index, list) {
results[results.length] = iterator.call(context, value, index, list);
});
if (obj.length === +obj.length) results.length = obj.length;
return results;
};
// **Reduce** builds up a single result from a list of values, aka `inject`,
// or `foldl`. Delegates to **ECMAScript 5**'s native `reduce` if available.
_.reduce = _.foldl = _.inject = function(obj, iterator, memo, context) {
var initial = arguments.length > 2;
if (obj == null) obj = [];
if (nativeReduce && obj.reduce === nativeReduce) {
if (context) iterator = _.bind(iterator, context);
return initial ? obj.reduce(iterator, memo) : obj.reduce(iterator);
}
each(obj, function(value, index, list) {
if (!initial) {
memo = value;
initial = true;
} else {
memo = iterator.call(context, memo, value, index, list);
}
});
if (!initial) throw new TypeError('Reduce of empty array with no initial value');
return memo;
};
// The right-associative version of reduce, also known as `foldr`.
// Delegates to **ECMAScript 5**'s native `reduceRight` if available.
_.reduceRight = _.foldr = function(obj, iterator, memo, context) {
var initial = arguments.length > 2;
if (obj == null) obj = [];
if (nativeReduceRight && obj.reduceRight === nativeReduceRight) {
if (context) iterator = _.bind(iterator, context);
return initial ? obj.reduceRight(iterator, memo) : obj.reduceRight(iterator);
}
var reversed = _.toArray(obj).reverse();
if (context && !initial) iterator = _.bind(iterator, context);
return initial ? _.reduce(reversed, iterator, memo, context) : _.reduce(reversed, iterator);
};
// Return the first value which passes a truth test. Aliased as `detect`.
_.find = _.detect = function(obj, iterator, context) {
var result;
any(obj, function(value, index, list) {
if (iterator.call(context, value, index, list)) {
result = value;
return true;
}
});
return result;
};
// Return all the elements that pass a truth test.
// Delegates to **ECMAScript 5**'s native `filter` if available.
// Aliased as `select`.
_.filter = _.select = function(obj, iterator, context) {
var results = [];
if (obj == null) return results;
if (nativeFilter && obj.filter === nativeFilter) return obj.filter(iterator, context);
each(obj, function(value, index, list) {
if (iterator.call(context, value, index, list)) results[results.length] = value;
});
return results;
};
// Return all the elements for which a truth test fails.
_.reject = function(obj, iterator, context) {
var results = [];
if (obj == null) return results;
each(obj, function(value, index, list) {
if (!iterator.call(context, value, index, list)) results[results.length] = value;
});
return results;
};
// Determine whether all of the elements match a truth test.
// Delegates to **ECMAScript 5**'s native `every` if available.
// Aliased as `all`.
_.every = _.all = function(obj, iterator, context) {
var result = true;
if (obj == null) return result;
if (nativeEvery && obj.every === nativeEvery) return obj.every(iterator, context);
each(obj, function(value, index, list) {
if (!(result = result && iterator.call(context, value, index, list))) return breaker;
});
return result;
};
// Determine if at least one element in the object matches a truth test.
// Delegates to **ECMAScript 5**'s native `some` if available.
// Aliased as `any`.
var any = _.some = _.any = function(obj, iterator, context) {
iterator || (iterator = _.identity);
var result = false;
if (obj == null) return result;
if (nativeSome && obj.some === nativeSome) return obj.some(iterator, context);
each(obj, function(value, index, list) {
if (result || (result = iterator.call(context, value, index, list))) return breaker;
});
return !!result;
};
// Determine if a given value is included in the array or object using `===`.
// Aliased as `contains`.
_.include = _.contains = function(obj, target) {
var found = false;
if (obj == null) return found;
if (nativeIndexOf && obj.indexOf === nativeIndexOf) return obj.indexOf(target) != -1;
found = any(obj, function(value) {
return value === target;
});
return found;
};
// Invoke a method (with arguments) on every item in a collection.
_.invoke = function(obj, method) {
var args = slice.call(arguments, 2);
return _.map(obj, function(value) {
return (_.isFunction(method) ? method || value : value[method]).apply(value, args);
});
};
// Convenience version of a common use case of `map`: fetching a property.
_.pluck = function(obj, key) {
return _.map(obj, function(value){ return value[key]; });
};
// Return the maximum element or (element-based computation).
_.max = function(obj, iterator, context) {
if (!iterator && _.isArray(obj)) return Math.max.apply(Math, obj);
if (!iterator && _.isEmpty(obj)) return -Infinity;
var result = {computed : -Infinity};
each(obj, function(value, index, list) {
var computed = iterator ? iterator.call(context, value, index, list) : value;
computed >= result.computed && (result = {value : value, computed : computed});
});
return result.value;
};
// Return the minimum element (or element-based computation).
_.min = function(obj, iterator, context) {
if (!iterator && _.isArray(obj)) return Math.min.apply(Math, obj);
if (!iterator && _.isEmpty(obj)) return Infinity;
var result = {computed : Infinity};
each(obj, function(value, index, list) {
var computed = iterator ? iterator.call(context, value, index, list) : value;
computed < result.computed && (result = {value : value, computed : computed});
});
return result.value;
};
// Shuffle an array.
_.shuffle = function(obj) {
var shuffled = [], rand;
each(obj, function(value, index, list) {
if (index == 0) {
shuffled[0] = value;
} else {
rand = Math.floor(Math.random() * (index + 1));
shuffled[index] = shuffled[rand];
shuffled[rand] = value;
}
});
return shuffled;
};
// Sort the object's values by a criterion produced by an iterator.
_.sortBy = function(obj, iterator, context) {
return _.pluck(_.map(obj, function(value, index, list) {
return {
value : value,
criteria : iterator.call(context, value, index, list)
};
}).sort(function(left, right) {
var a = left.criteria, b = right.criteria;
return a < b ? -1 : a > b ? 1 : 0;
}), 'value');
};
// Groups the object's values by a criterion. Pass either a string attribute
// to group by, or a function that returns the criterion.
_.groupBy = function(obj, val) {
var result = {};
var iterator = _.isFunction(val) ? val : function(obj) { return obj[val]; };
each(obj, function(value, index) {
var key = iterator(value, index);
(result[key] || (result[key] = [])).push(value);
});
return result;
};
// Use a comparator function to figure out at what index an object should
// be inserted so as to maintain order. Uses binary search.
_.sortedIndex = function(array, obj, iterator) {
iterator || (iterator = _.identity);
var low = 0, high = array.length;
while (low < high) {
var mid = (low + high) >> 1;
iterator(array[mid]) < iterator(obj) ? low = mid + 1 : high = mid;
}
return low;
};
// Safely convert anything iterable into a real, live array.
_.toArray = function(iterable) {
if (!iterable) return [];
if (iterable.toArray) return iterable.toArray();
if (_.isArray(iterable)) return slice.call(iterable);
if (_.isArguments(iterable)) return slice.call(iterable);
return _.values(iterable);
};
// Return the number of elements in an object.
_.size = function(obj) {
return _.toArray(obj).length;
};
// Array Functions
// ---------------
// Get the first element of an array. Passing **n** will return the first N
// values in the array. Aliased as `head`. The **guard** check allows it to work
// with `_.map`.
_.first = _.head = function(array, n, guard) {
return (n != null) && !guard ? slice.call(array, 0, n) : array[0];
};
// Returns everything but the last entry of the array. Especcialy useful on
// the arguments object. Passing **n** will return all the values in
// the array, excluding the last N. The **guard** check allows it to work with
// `_.map`.
_.initial = function(array, n, guard) {
return slice.call(array, 0, array.length - ((n == null) || guard ? 1 : n));
};
// Get the last element of an array. Passing **n** will return the last N
// values in the array. The **guard** check allows it to work with `_.map`.
_.last = function(array, n, guard) {
if ((n != null) && !guard) {
return slice.call(array, Math.max(array.length - n, 0));
} else {
return array[array.length - 1];
}
};
// Returns everything but the first entry of the array. Aliased as `tail`.
// Especially useful on the arguments object. Passing an **index** will return
// the rest of the values in the array from that index onward. The **guard**
// check allows it to work with `_.map`.
_.rest = _.tail = function(array, index, guard) {
return slice.call(array, (index == null) || guard ? 1 : index);
};
// Trim out all falsy values from an array.
_.compact = function(array) {
return _.filter(array, function(value){ return !!value; });
};
// Return a completely flattened version of an array.
_.flatten = function(array, shallow) {
return _.reduce(array, function(memo, value) {
if (_.isArray(value)) return memo.concat(shallow ? value : _.flatten(value));
memo[memo.length] = value;
return memo;
}, []);
};
// Return a version of the array that does not contain the specified value(s).
_.without = function(array) {
return _.difference(array, slice.call(arguments, 1));
};
// Produce a duplicate-free version of the array. If the array has already
// been sorted, you have the option of using a faster algorithm.
// Aliased as `unique`.
_.uniq = _.unique = function(array, isSorted, iterator) {
var initial = iterator ? _.map(array, iterator) : array;
var result = [];
_.reduce(initial, function(memo, el, i) {
if (0 == i || (isSorted === true ? _.last(memo) != el : !_.include(memo, el))) {
memo[memo.length] = el;
result[result.length] = array[i];
}
return memo;
}, []);
return result;
};
// Produce an array that contains the union: each distinct element from all of
// the passed-in arrays.
_.union = function() {
return _.uniq(_.flatten(arguments, true));
};
// Produce an array that contains every item shared between all the
// passed-in arrays. (Aliased as "intersect" for back-compat.)
_.intersection = _.intersect = function(array) {
var rest = slice.call(arguments, 1);
return _.filter(_.uniq(array), function(item) {
return _.every(rest, function(other) {
return _.indexOf(other, item) >= 0;
});
});
};
// Take the difference between one array and a number of other arrays.
// Only the elements present in just the first array will remain.
_.difference = function(array) {
var rest = _.flatten(slice.call(arguments, 1));
return _.filter(array, function(value){ return !_.include(rest, value); });
};
// Zip together multiple lists into a single array -- elements that share
// an index go together.
_.zip = function() {
var args = slice.call(arguments);
var length = _.max(_.pluck(args, 'length'));
var results = new Array(length);
for (var i = 0; i < length; i++) results[i] = _.pluck(args, "" + i);
return results;
};
// If the browser doesn't supply us with indexOf (I'm looking at you, **MSIE**),
// we need this function. Return the position of the first occurrence of an
// item in an array, or -1 if the item is not included in the array.
// Delegates to **ECMAScript 5**'s native `indexOf` if available.
// If the array is large and already in sort order, pass `true`
// for **isSorted** to use binary search.
_.indexOf = function(array, item, isSorted) {
if (array == null) return -1;
var i, l;
if (isSorted) {
i = _.sortedIndex(array, item);
return array[i] === item ? i : -1;
}
if (nativeIndexOf && array.indexOf === nativeIndexOf) return array.indexOf(item);
for (i = 0, l = array.length; i < l; i++) if (i in array && array[i] === item) return i;
return -1;
};
// Delegates to **ECMAScript 5**'s native `lastIndexOf` if available.
_.lastIndexOf = function(array, item) {
if (array == null) return -1;
if (nativeLastIndexOf && array.lastIndexOf === nativeLastIndexOf) return array.lastIndexOf(item);
var i = array.length;
while (i--) if (i in array && array[i] === item) return i;
return -1;
};
// Generate an integer Array containing an arithmetic progression. A port of
// the native Python `range()` function. See
// [the Python documentation](http://docs.python.org/library/functions.html#range).
_.range = function(start, stop, step) {
if (arguments.length <= 1) {
stop = start || 0;
start = 0;
}
step = arguments[2] || 1;
var len = Math.max(Math.ceil((stop - start) / step), 0);
var idx = 0;
var range = new Array(len);
while(idx < len) {
range[idx++] = start;
start += step;
}
return range;
};
// Function (ahem) Functions
// ------------------
// Reusable constructor function for prototype setting.
var ctor = function(){};
// Create a function bound to a given object (assigning `this`, and arguments,
// optionally). Binding with arguments is also known as `curry`.
// Delegates to **ECMAScript 5**'s native `Function.bind` if available.
// We check for `func.bind` first, to fail fast when `func` is undefined.
_.bind = function bind(func, context) {
var bound, args;
if (func.bind === nativeBind && nativeBind) return nativeBind.apply(func, slice.call(arguments, 1));
if (!_.isFunction(func)) throw new TypeError;
args = slice.call(arguments, 2);
return bound = function() {
if (!(this instanceof bound)) return func.apply(context, args.concat(slice.call(arguments)));
ctor.prototype = func.prototype;
var self = new ctor;
var result = func.apply(self, args.concat(slice.call(arguments)));
if (Object(result) === result) return result;
return self;
};
};
// Bind all of an object's methods to that object. Useful for ensuring that
// all callbacks defined on an object belong to it.
_.bindAll = function(obj) {
var funcs = slice.call(arguments, 1);
if (funcs.length == 0) funcs = _.functions(obj);
each(funcs, function(f) { obj[f] = _.bind(obj[f], obj); });
return obj;
};
// Memoize an expensive function by storing its results.
_.memoize = function(func, hasher) {
var memo = {};
hasher || (hasher = _.identity);
return function() {
var key = hasher.apply(this, arguments);
return _.has(memo, key) ? memo[key] : (memo[key] = func.apply(this, arguments));
};
};
// Delays a function for the given number of milliseconds, and then calls
// it with the arguments supplied.
_.delay = function(func, wait) {
var args = slice.call(arguments, 2);
return setTimeout(function(){ return func.apply(func, args); }, wait);
};
// Defers a function, scheduling it to run after the current call stack has
// cleared.
_.defer = function(func) {
return _.delay.apply(_, [func, 1].concat(slice.call(arguments, 1)));
};
// Returns a function, that, when invoked, will only be triggered at most once
// during a given window of time.
_.throttle = function(func, wait) {
var context, args, timeout, throttling, more;
var whenDone = _.debounce(function(){ more = throttling = false; }, wait);
return function() {
context = this; args = arguments;
var later = function() {
timeout = null;
if (more) func.apply(context, args);
whenDone();
};
if (!timeout) timeout = setTimeout(later, wait);
if (throttling) {
more = true;
} else {
func.apply(context, args);
}
whenDone();
throttling = true;
};
};
// Returns a function, that, as long as it continues to be invoked, will not
// be triggered. The function will be called after it stops being called for
// N milliseconds.
_.debounce = function(func, wait) {
var timeout;
return function() {
var context = this, args = arguments;
var later = function() {
timeout = null;
func.apply(context, args);
};
clearTimeout(timeout);
timeout = setTimeout(later, wait);
};
};
// Returns a function that will be executed at most one time, no matter how
// often you call it. Useful for lazy initialization.
_.once = function(func) {
var ran = false, memo;
return function() {
if (ran) return memo;
ran = true;
return memo = func.apply(this, arguments);
};
};
// Returns the first function passed as an argument to the second,
// allowing you to adjust arguments, run code before and after, and
// conditionally execute the original function.
_.wrap = function(func, wrapper) {
return function() {
var args = [func].concat(slice.call(arguments, 0));
return wrapper.apply(this, args);
};
};
// Returns a function that is the composition of a list of functions, each
// consuming the return value of the function that follows.
_.compose = function() {
var funcs = arguments;
return function() {
var args = arguments;
for (var i = funcs.length - 1; i >= 0; i--) {
args = [funcs[i].apply(this, args)];
}
return args[0];
};
};
// Returns a function that will only be executed after being called N times.
_.after = function(times, func) {
if (times <= 0) return func();
return function() {
if (--times < 1) { return func.apply(this, arguments); }
};
};
// Object Functions
// ----------------
// Retrieve the names of an object's properties.
// Delegates to **ECMAScript 5**'s native `Object.keys`
_.keys = nativeKeys || function(obj) {
if (obj !== Object(obj)) throw new TypeError('Invalid object');
var keys = [];
for (var key in obj) if (_.has(obj, key)) keys[keys.length] = key;
return keys;
};
// Retrieve the values of an object's properties.
_.values = function(obj) {
return _.map(obj, _.identity);
};
// Return a sorted list of the function names available on the object.
// Aliased as `methods`
_.functions = _.methods = function(obj) {
var names = [];
for (var key in obj) {
if (_.isFunction(obj[key])) names.push(key);
}
return names.sort();
};
// Extend a given object with all the properties in passed-in object(s).
_.extend = function(obj) {
each(slice.call(arguments, 1), function(source) {
for (var prop in source) {
obj[prop] = source[prop];
}
});
return obj;
};
// Fill in a given object with default properties.
_.defaults = function(obj) {
each(slice.call(arguments, 1), function(source) {
for (var prop in source) {
if (obj[prop] == null) obj[prop] = source[prop];
}
});
return obj;
};
// Create a (shallow-cloned) duplicate of an object.
_.clone = function(obj) {
if (!_.isObject(obj)) return obj;
return _.isArray(obj) ? obj.slice() : _.extend({}, obj);
};
// Invokes interceptor with the obj, and then returns obj.
// The primary purpose of this method is to "tap into" a method chain, in
// order to perform operations on intermediate results within the chain.
_.tap = function(obj, interceptor) {
interceptor(obj);
return obj;
};
// Internal recursive comparison function.
function eq(a, b, stack) {
// Identical objects are equal. `0 === -0`, but they aren't identical.
// See the Harmony `egal` proposal: http://wiki.ecmascript.org/doku.php?id=harmony:egal.
if (a === b) return a !== 0 || 1 / a == 1 / b;
// A strict comparison is necessary because `null == undefined`.
if (a == null || b == null) return a === b;
// Unwrap any wrapped objects.
if (a._chain) a = a._wrapped;
if (b._chain) b = b._wrapped;
// Invoke a custom `isEqual` method if one is provided.
if (a.isEqual && _.isFunction(a.isEqual)) return a.isEqual(b);
if (b.isEqual && _.isFunction(b.isEqual)) return b.isEqual(a);
// Compare `[[Class]]` names.
var className = toString.call(a);
if (className != toString.call(b)) return false;
switch (className) {
// Strings, numbers, dates, and booleans are compared by value.
case '[object String]':
// Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is
// equivalent to `new String("5")`.
return a == String(b);
case '[object Number]':
// `NaN`s are equivalent, but non-reflexive. An `egal` comparison is performed for
// other numeric values.
return a != +a ? b != +b : (a == 0 ? 1 / a == 1 / b : a == +b);
case '[object Date]':
case '[object Boolean]':
// Coerce dates and booleans to numeric primitive values. Dates are compared by their
// millisecond representations. Note that invalid dates with millisecond representations
// of `NaN` are not equivalent.
return +a == +b;
// RegExps are compared by their source patterns and flags.
case '[object RegExp]':
return a.source == b.source &&
a.global == b.global &&
a.multiline == b.multiline &&
a.ignoreCase == b.ignoreCase;
}
if (typeof a != 'object' || typeof b != 'object') return false;
// Assume equality for cyclic structures. The algorithm for detecting cyclic
// structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`.
var length = stack.length;
while (length--) {
// Linear search. Performance is inversely proportional to the number of
// unique nested structures.
if (stack[length] == a) return true;
}
// Add the first object to the stack of traversed objects.
stack.push(a);
var size = 0, result = true;
// Recursively compare objects and arrays.
if (className == '[object Array]') {
// Compare array lengths to determine if a deep comparison is necessary.
size = a.length;
result = size == b.length;
if (result) {
// Deep compare the contents, ignoring non-numeric properties.
while (size--) {
// Ensure commutative equality for sparse arrays.
if (!(result = size in a == size in b && eq(a[size], b[size], stack))) break;
}
}
} else {
// Objects with different constructors are not equivalent.
if ('constructor' in a != 'constructor' in b || a.constructor != b.constructor) return false;
// Deep compare objects.
for (var key in a) {
if (_.has(a, key)) {
// Count the expected number of properties.
size++;
// Deep compare each member.
if (!(result = _.has(b, key) && eq(a[key], b[key], stack))) break;
}
}
// Ensure that both objects contain the same number of properties.
if (result) {
for (key in b) {
if (_.has(b, key) && !(size--)) break;
}
result = !size;
}
}
// Remove the first object from the stack of traversed objects.
stack.pop();
return result;
}
// Perform a deep comparison to check if two objects are equal.
_.isEqual = function(a, b) {
return eq(a, b, []);
};
// Is a given array, string, or object empty?
// An "empty" object has no enumerable own-properties.
_.isEmpty = function(obj) {
if (_.isArray(obj) || _.isString(obj)) return obj.length === 0;
for (var key in obj) if (_.has(obj, key)) return false;
return true;
};
// Is a given value a DOM element?
_.isElement = function(obj) {
return !!(obj && obj.nodeType == 1);
};
// Is a given value an array?
// Delegates to ECMA5's native Array.isArray
_.isArray = nativeIsArray || function(obj) {
return toString.call(obj) == '[object Array]';
};
// Is a given variable an object?
_.isObject = function(obj) {
return obj === Object(obj);
};
// Is a given variable an arguments object?
_.isArguments = function(obj) {
return toString.call(obj) == '[object Arguments]';
};
if (!_.isArguments(arguments)) {
_.isArguments = function(obj) {
return !!(obj && _.has(obj, 'callee'));
};
}
// Is a given value a function?
_.isFunction = function(obj) {
return toString.call(obj) == '[object Function]';
};
// Is a given value a string?
_.isString = function(obj) {
return toString.call(obj) == '[object String]';
};
// Is a given value a number?
_.isNumber = function(obj) {
return toString.call(obj) == '[object Number]';
};
// Is the given value `NaN`?
_.isNaN = function(obj) {
// `NaN` is the only value for which `===` is not reflexive.
return obj !== obj;
};
// Is a given value a boolean?
_.isBoolean = function(obj) {
return obj === true || obj === false || toString.call(obj) == '[object Boolean]';
};
// Is a given value a date?
_.isDate = function(obj) {
return toString.call(obj) == '[object Date]';
};
// Is the given value a regular expression?
_.isRegExp = function(obj) {
return toString.call(obj) == '[object RegExp]';
};
// Is a given value equal to null?
_.isNull = function(obj) {
return obj === null;
};
// Is a given variable undefined?
_.isUndefined = function(obj) {
return obj === void 0;
};
// Has own property?
_.has = function(obj, key) {
return hasOwnProperty.call(obj, key);
};
// Utility Functions
// -----------------
// Run Underscore.js in *noConflict* mode, returning the `_` variable to its
// previous owner. Returns a reference to the Underscore object.
_.noConflict = function() {
root._ = previousUnderscore;
return this;
};
// Keep the identity function around for default iterators.
_.identity = function(value) {
return value;
};
// Run a function **n** times.
_.times = function (n, iterator, context) {
for (var i = 0; i < n; i++) iterator.call(context, i);
};
// Escape a string for HTML interpolation.
_.escape = function(string) {
return (''+string).replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/"/g, '&quot;').replace(/'/g, '&#x27;').replace(/\//g,'&#x2F;');
};
// Add your own custom functions to the Underscore object, ensuring that
// they're correctly added to the OOP wrapper as well.
_.mixin = function(obj) {
each(_.functions(obj), function(name){
addToWrapper(name, _[name] = obj[name]);
});
};
// Generate a unique integer id (unique within the entire client session).
// Useful for temporary DOM ids.
var idCounter = 0;
_.uniqueId = function(prefix) {
var id = idCounter++;
return prefix ? prefix + id : id;
};
// By default, Underscore uses ERB-style template delimiters, change the
// following template settings to use alternative delimiters.
_.templateSettings = {
evaluate : /<%([\s\S]+?)%>/g,
interpolate : /<%=([\s\S]+?)%>/g,
escape : /<%-([\s\S]+?)%>/g
};
// When customizing `templateSettings`, if you don't want to define an
// interpolation, evaluation or escaping regex, we need one that is
// guaranteed not to match.
var noMatch = /.^/;
// Within an interpolation, evaluation, or escaping, remove HTML escaping
// that had been previously added.
var unescape = function(code) {
return code.replace(/\\\\/g, '\\').replace(/\\'/g, "'");
};
// JavaScript micro-templating, similar to John Resig's implementation.
// Underscore templating handles arbitrary delimiters, preserves whitespace,
// and correctly escapes quotes within interpolated code.
_.template = function(str, data) {
var c = _.templateSettings;
var tmpl = 'var __p=[],print=function(){__p.push.apply(__p,arguments);};' +
'with(obj||{}){__p.push(\'' +
str.replace(/\\/g, '\\\\')
.replace(/'/g, "\\'")
.replace(c.escape || noMatch, function(match, code) {
return "',_.escape(" + unescape(code) + "),'";
})
.replace(c.interpolate || noMatch, function(match, code) {
return "'," + unescape(code) + ",'";
})
.replace(c.evaluate || noMatch, function(match, code) {
return "');" + unescape(code).replace(/[\r\n\t]/g, ' ') + ";__p.push('";
})
.replace(/\r/g, '\\r')
.replace(/\n/g, '\\n')
.replace(/\t/g, '\\t')
+ "');}return __p.join('');";
var func = new Function('obj', '_', tmpl);
if (data) return func(data, _);
return function(data) {
return func.call(this, data, _);
};
};
// Add a "chain" function, which will delegate to the wrapper.
_.chain = function(obj) {
return _(obj).chain();
};
// The OOP Wrapper
// ---------------
// If Underscore is called as a function, it returns a wrapped object that
// can be used OO-style. This wrapper holds altered versions of all the
// underscore functions. Wrapped objects may be chained.
var wrapper = function(obj) { this._wrapped = obj; };
// Expose `wrapper.prototype` as `_.prototype`
_.prototype = wrapper.prototype;
// Helper function to continue chaining intermediate results.
var result = function(obj, chain) {
return chain ? _(obj).chain() : obj;
};
// A method to easily add functions to the OOP wrapper.
var addToWrapper = function(name, func) {
wrapper.prototype[name] = function() {
var args = slice.call(arguments);
unshift.call(args, this._wrapped);
return result(func.apply(_, args), this._chain);
};
};
// Add all of the Underscore functions to the wrapper object.
_.mixin(_);
// Add all mutator Array functions to the wrapper.
each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) {
var method = ArrayProto[name];
wrapper.prototype[name] = function() {
var wrapped = this._wrapped;
method.apply(wrapped, arguments);
var length = wrapped.length;
if ((name == 'shift' || name == 'splice') && length === 0) delete wrapped[0];
return result(wrapped, this._chain);
};
});
// Add all accessor Array functions to the wrapper.
each(['concat', 'join', 'slice'], function(name) {
var method = ArrayProto[name];
wrapper.prototype[name] = function() {
return result(method.apply(this._wrapped, arguments), this._chain);
};
});
// Start chaining a wrapped Underscore object.
wrapper.prototype.chain = function() {
this._chain = true;
return this;
};
// Extracts the result from a wrapped and chained object.
wrapper.prototype.value = function() {
return this._wrapped;
};
}).call(this);

View File

@@ -1,31 +0,0 @@
// Underscore.js 1.3.1
// (c) 2009-2012 Jeremy Ashkenas, DocumentCloud Inc.
// Underscore is freely distributable under the MIT license.
// Portions of Underscore are inspired or borrowed from Prototype,
// Oliver Steele's Functional, and John Resig's Micro-Templating.
// For all details and documentation:
// http://documentcloud.github.com/underscore
(function(){function q(a,c,d){if(a===c)return a!==0||1/a==1/c;if(a==null||c==null)return a===c;if(a._chain)a=a._wrapped;if(c._chain)c=c._wrapped;if(a.isEqual&&b.isFunction(a.isEqual))return a.isEqual(c);if(c.isEqual&&b.isFunction(c.isEqual))return c.isEqual(a);var e=l.call(a);if(e!=l.call(c))return false;switch(e){case "[object String]":return a==String(c);case "[object Number]":return a!=+a?c!=+c:a==0?1/a==1/c:a==+c;case "[object Date]":case "[object Boolean]":return+a==+c;case "[object RegExp]":return a.source==
c.source&&a.global==c.global&&a.multiline==c.multiline&&a.ignoreCase==c.ignoreCase}if(typeof a!="object"||typeof c!="object")return false;for(var f=d.length;f--;)if(d[f]==a)return true;d.push(a);var f=0,g=true;if(e=="[object Array]"){if(f=a.length,g=f==c.length)for(;f--;)if(!(g=f in a==f in c&&q(a[f],c[f],d)))break}else{if("constructor"in a!="constructor"in c||a.constructor!=c.constructor)return false;for(var h in a)if(b.has(a,h)&&(f++,!(g=b.has(c,h)&&q(a[h],c[h],d))))break;if(g){for(h in c)if(b.has(c,
h)&&!f--)break;g=!f}}d.pop();return g}var r=this,G=r._,n={},k=Array.prototype,o=Object.prototype,i=k.slice,H=k.unshift,l=o.toString,I=o.hasOwnProperty,w=k.forEach,x=k.map,y=k.reduce,z=k.reduceRight,A=k.filter,B=k.every,C=k.some,p=k.indexOf,D=k.lastIndexOf,o=Array.isArray,J=Object.keys,s=Function.prototype.bind,b=function(a){return new m(a)};if(typeof exports!=="undefined"){if(typeof module!=="undefined"&&module.exports)exports=module.exports=b;exports._=b}else r._=b;b.VERSION="1.3.1";var j=b.each=
b.forEach=function(a,c,d){if(a!=null)if(w&&a.forEach===w)a.forEach(c,d);else if(a.length===+a.length)for(var e=0,f=a.length;e<f;e++){if(e in a&&c.call(d,a[e],e,a)===n)break}else for(e in a)if(b.has(a,e)&&c.call(d,a[e],e,a)===n)break};b.map=b.collect=function(a,c,b){var e=[];if(a==null)return e;if(x&&a.map===x)return a.map(c,b);j(a,function(a,g,h){e[e.length]=c.call(b,a,g,h)});if(a.length===+a.length)e.length=a.length;return e};b.reduce=b.foldl=b.inject=function(a,c,d,e){var f=arguments.length>2;a==
null&&(a=[]);if(y&&a.reduce===y)return e&&(c=b.bind(c,e)),f?a.reduce(c,d):a.reduce(c);j(a,function(a,b,i){f?d=c.call(e,d,a,b,i):(d=a,f=true)});if(!f)throw new TypeError("Reduce of empty array with no initial value");return d};b.reduceRight=b.foldr=function(a,c,d,e){var f=arguments.length>2;a==null&&(a=[]);if(z&&a.reduceRight===z)return e&&(c=b.bind(c,e)),f?a.reduceRight(c,d):a.reduceRight(c);var g=b.toArray(a).reverse();e&&!f&&(c=b.bind(c,e));return f?b.reduce(g,c,d,e):b.reduce(g,c)};b.find=b.detect=
function(a,c,b){var e;E(a,function(a,g,h){if(c.call(b,a,g,h))return e=a,true});return e};b.filter=b.select=function(a,c,b){var e=[];if(a==null)return e;if(A&&a.filter===A)return a.filter(c,b);j(a,function(a,g,h){c.call(b,a,g,h)&&(e[e.length]=a)});return e};b.reject=function(a,c,b){var e=[];if(a==null)return e;j(a,function(a,g,h){c.call(b,a,g,h)||(e[e.length]=a)});return e};b.every=b.all=function(a,c,b){var e=true;if(a==null)return e;if(B&&a.every===B)return a.every(c,b);j(a,function(a,g,h){if(!(e=
e&&c.call(b,a,g,h)))return n});return e};var E=b.some=b.any=function(a,c,d){c||(c=b.identity);var e=false;if(a==null)return e;if(C&&a.some===C)return a.some(c,d);j(a,function(a,b,h){if(e||(e=c.call(d,a,b,h)))return n});return!!e};b.include=b.contains=function(a,c){var b=false;if(a==null)return b;return p&&a.indexOf===p?a.indexOf(c)!=-1:b=E(a,function(a){return a===c})};b.invoke=function(a,c){var d=i.call(arguments,2);return b.map(a,function(a){return(b.isFunction(c)?c||a:a[c]).apply(a,d)})};b.pluck=
function(a,c){return b.map(a,function(a){return a[c]})};b.max=function(a,c,d){if(!c&&b.isArray(a))return Math.max.apply(Math,a);if(!c&&b.isEmpty(a))return-Infinity;var e={computed:-Infinity};j(a,function(a,b,h){b=c?c.call(d,a,b,h):a;b>=e.computed&&(e={value:a,computed:b})});return e.value};b.min=function(a,c,d){if(!c&&b.isArray(a))return Math.min.apply(Math,a);if(!c&&b.isEmpty(a))return Infinity;var e={computed:Infinity};j(a,function(a,b,h){b=c?c.call(d,a,b,h):a;b<e.computed&&(e={value:a,computed:b})});
return e.value};b.shuffle=function(a){var b=[],d;j(a,function(a,f){f==0?b[0]=a:(d=Math.floor(Math.random()*(f+1)),b[f]=b[d],b[d]=a)});return b};b.sortBy=function(a,c,d){return b.pluck(b.map(a,function(a,b,g){return{value:a,criteria:c.call(d,a,b,g)}}).sort(function(a,b){var c=a.criteria,d=b.criteria;return c<d?-1:c>d?1:0}),"value")};b.groupBy=function(a,c){var d={},e=b.isFunction(c)?c:function(a){return a[c]};j(a,function(a,b){var c=e(a,b);(d[c]||(d[c]=[])).push(a)});return d};b.sortedIndex=function(a,
c,d){d||(d=b.identity);for(var e=0,f=a.length;e<f;){var g=e+f>>1;d(a[g])<d(c)?e=g+1:f=g}return e};b.toArray=function(a){return!a?[]:a.toArray?a.toArray():b.isArray(a)?i.call(a):b.isArguments(a)?i.call(a):b.values(a)};b.size=function(a){return b.toArray(a).length};b.first=b.head=function(a,b,d){return b!=null&&!d?i.call(a,0,b):a[0]};b.initial=function(a,b,d){return i.call(a,0,a.length-(b==null||d?1:b))};b.last=function(a,b,d){return b!=null&&!d?i.call(a,Math.max(a.length-b,0)):a[a.length-1]};b.rest=
b.tail=function(a,b,d){return i.call(a,b==null||d?1:b)};b.compact=function(a){return b.filter(a,function(a){return!!a})};b.flatten=function(a,c){return b.reduce(a,function(a,e){if(b.isArray(e))return a.concat(c?e:b.flatten(e));a[a.length]=e;return a},[])};b.without=function(a){return b.difference(a,i.call(arguments,1))};b.uniq=b.unique=function(a,c,d){var d=d?b.map(a,d):a,e=[];b.reduce(d,function(d,g,h){if(0==h||(c===true?b.last(d)!=g:!b.include(d,g)))d[d.length]=g,e[e.length]=a[h];return d},[]);
return e};b.union=function(){return b.uniq(b.flatten(arguments,true))};b.intersection=b.intersect=function(a){var c=i.call(arguments,1);return b.filter(b.uniq(a),function(a){return b.every(c,function(c){return b.indexOf(c,a)>=0})})};b.difference=function(a){var c=b.flatten(i.call(arguments,1));return b.filter(a,function(a){return!b.include(c,a)})};b.zip=function(){for(var a=i.call(arguments),c=b.max(b.pluck(a,"length")),d=Array(c),e=0;e<c;e++)d[e]=b.pluck(a,""+e);return d};b.indexOf=function(a,c,
d){if(a==null)return-1;var e;if(d)return d=b.sortedIndex(a,c),a[d]===c?d:-1;if(p&&a.indexOf===p)return a.indexOf(c);for(d=0,e=a.length;d<e;d++)if(d in a&&a[d]===c)return d;return-1};b.lastIndexOf=function(a,b){if(a==null)return-1;if(D&&a.lastIndexOf===D)return a.lastIndexOf(b);for(var d=a.length;d--;)if(d in a&&a[d]===b)return d;return-1};b.range=function(a,b,d){arguments.length<=1&&(b=a||0,a=0);for(var d=arguments[2]||1,e=Math.max(Math.ceil((b-a)/d),0),f=0,g=Array(e);f<e;)g[f++]=a,a+=d;return g};
var F=function(){};b.bind=function(a,c){var d,e;if(a.bind===s&&s)return s.apply(a,i.call(arguments,1));if(!b.isFunction(a))throw new TypeError;e=i.call(arguments,2);return d=function(){if(!(this instanceof d))return a.apply(c,e.concat(i.call(arguments)));F.prototype=a.prototype;var b=new F,g=a.apply(b,e.concat(i.call(arguments)));return Object(g)===g?g:b}};b.bindAll=function(a){var c=i.call(arguments,1);c.length==0&&(c=b.functions(a));j(c,function(c){a[c]=b.bind(a[c],a)});return a};b.memoize=function(a,
c){var d={};c||(c=b.identity);return function(){var e=c.apply(this,arguments);return b.has(d,e)?d[e]:d[e]=a.apply(this,arguments)}};b.delay=function(a,b){var d=i.call(arguments,2);return setTimeout(function(){return a.apply(a,d)},b)};b.defer=function(a){return b.delay.apply(b,[a,1].concat(i.call(arguments,1)))};b.throttle=function(a,c){var d,e,f,g,h,i=b.debounce(function(){h=g=false},c);return function(){d=this;e=arguments;var b;f||(f=setTimeout(function(){f=null;h&&a.apply(d,e);i()},c));g?h=true:
a.apply(d,e);i();g=true}};b.debounce=function(a,b){var d;return function(){var e=this,f=arguments;clearTimeout(d);d=setTimeout(function(){d=null;a.apply(e,f)},b)}};b.once=function(a){var b=false,d;return function(){if(b)return d;b=true;return d=a.apply(this,arguments)}};b.wrap=function(a,b){return function(){var d=[a].concat(i.call(arguments,0));return b.apply(this,d)}};b.compose=function(){var a=arguments;return function(){for(var b=arguments,d=a.length-1;d>=0;d--)b=[a[d].apply(this,b)];return b[0]}};
b.after=function(a,b){return a<=0?b():function(){if(--a<1)return b.apply(this,arguments)}};b.keys=J||function(a){if(a!==Object(a))throw new TypeError("Invalid object");var c=[],d;for(d in a)b.has(a,d)&&(c[c.length]=d);return c};b.values=function(a){return b.map(a,b.identity)};b.functions=b.methods=function(a){var c=[],d;for(d in a)b.isFunction(a[d])&&c.push(d);return c.sort()};b.extend=function(a){j(i.call(arguments,1),function(b){for(var d in b)a[d]=b[d]});return a};b.defaults=function(a){j(i.call(arguments,
1),function(b){for(var d in b)a[d]==null&&(a[d]=b[d])});return a};b.clone=function(a){return!b.isObject(a)?a:b.isArray(a)?a.slice():b.extend({},a)};b.tap=function(a,b){b(a);return a};b.isEqual=function(a,b){return q(a,b,[])};b.isEmpty=function(a){if(b.isArray(a)||b.isString(a))return a.length===0;for(var c in a)if(b.has(a,c))return false;return true};b.isElement=function(a){return!!(a&&a.nodeType==1)};b.isArray=o||function(a){return l.call(a)=="[object Array]"};b.isObject=function(a){return a===Object(a)};
b.isArguments=function(a){return l.call(a)=="[object Arguments]"};if(!b.isArguments(arguments))b.isArguments=function(a){return!(!a||!b.has(a,"callee"))};b.isFunction=function(a){return l.call(a)=="[object Function]"};b.isString=function(a){return l.call(a)=="[object String]"};b.isNumber=function(a){return l.call(a)=="[object Number]"};b.isNaN=function(a){return a!==a};b.isBoolean=function(a){return a===true||a===false||l.call(a)=="[object Boolean]"};b.isDate=function(a){return l.call(a)=="[object Date]"};
b.isRegExp=function(a){return l.call(a)=="[object RegExp]"};b.isNull=function(a){return a===null};b.isUndefined=function(a){return a===void 0};b.has=function(a,b){return I.call(a,b)};b.noConflict=function(){r._=G;return this};b.identity=function(a){return a};b.times=function(a,b,d){for(var e=0;e<a;e++)b.call(d,e)};b.escape=function(a){return(""+a).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;").replace(/\//g,"&#x2F;")};b.mixin=function(a){j(b.functions(a),
function(c){K(c,b[c]=a[c])})};var L=0;b.uniqueId=function(a){var b=L++;return a?a+b:b};b.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var t=/.^/,u=function(a){return a.replace(/\\\\/g,"\\").replace(/\\'/g,"'")};b.template=function(a,c){var d=b.templateSettings,d="var __p=[],print=function(){__p.push.apply(__p,arguments);};with(obj||{}){__p.push('"+a.replace(/\\/g,"\\\\").replace(/'/g,"\\'").replace(d.escape||t,function(a,b){return"',_.escape("+
u(b)+"),'"}).replace(d.interpolate||t,function(a,b){return"',"+u(b)+",'"}).replace(d.evaluate||t,function(a,b){return"');"+u(b).replace(/[\r\n\t]/g," ")+";__p.push('"}).replace(/\r/g,"\\r").replace(/\n/g,"\\n").replace(/\t/g,"\\t")+"');}return __p.join('');",e=new Function("obj","_",d);return c?e(c,b):function(a){return e.call(this,a,b)}};b.chain=function(a){return b(a).chain()};var m=function(a){this._wrapped=a};b.prototype=m.prototype;var v=function(a,c){return c?b(a).chain():a},K=function(a,c){m.prototype[a]=
function(){var a=i.call(arguments);H.call(a,this._wrapped);return v(c.apply(b,a),this._chain)}};b.mixin(b);j("pop,push,reverse,shift,sort,splice,unshift".split(","),function(a){var b=k[a];m.prototype[a]=function(){var d=this._wrapped;b.apply(d,arguments);var e=d.length;(a=="shift"||a=="splice")&&e===0&&delete d[0];return v(d,this._chain)}});j(["concat","join","slice"],function(a){var b=k[a];m.prototype[a]=function(){return v(b.apply(this._wrapped,arguments),this._chain)}});m.prototype.chain=function(){this._chain=
true;return this};m.prototype.value=function(){return this._wrapped}}).call(this);

Binary file not shown.

Before

Width:  |  Height:  |  Size: 214 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 203 B

View File

@@ -1,808 +0,0 @@
/*
* websupport.js
* ~~~~~~~~~~~~~
*
* sphinx.websupport utilities for all documentation.
*
* :copyright: Copyright 2007-2018 by the Sphinx team, see AUTHORS.
* :license: BSD, see LICENSE for details.
*
*/
(function($) {
$.fn.autogrow = function() {
return this.each(function() {
var textarea = this;
$.fn.autogrow.resize(textarea);
$(textarea)
.focus(function() {
textarea.interval = setInterval(function() {
$.fn.autogrow.resize(textarea);
}, 500);
})
.blur(function() {
clearInterval(textarea.interval);
});
});
};
$.fn.autogrow.resize = function(textarea) {
var lineHeight = parseInt($(textarea).css('line-height'), 10);
var lines = textarea.value.split('\n');
var columns = textarea.cols;
var lineCount = 0;
$.each(lines, function() {
lineCount += Math.ceil(this.length / columns) || 1;
});
var height = lineHeight * (lineCount + 1);
$(textarea).css('height', height);
};
})(jQuery);
(function($) {
var comp, by;
function init() {
initEvents();
initComparator();
}
function initEvents() {
$(document).on("click", 'a.comment-close', function(event) {
event.preventDefault();
hide($(this).attr('id').substring(2));
});
$(document).on("click", 'a.vote', function(event) {
event.preventDefault();
handleVote($(this));
});
$(document).on("click", 'a.reply', function(event) {
event.preventDefault();
openReply($(this).attr('id').substring(2));
});
$(document).on("click", 'a.close-reply', function(event) {
event.preventDefault();
closeReply($(this).attr('id').substring(2));
});
$(document).on("click", 'a.sort-option', function(event) {
event.preventDefault();
handleReSort($(this));
});
$(document).on("click", 'a.show-proposal', function(event) {
event.preventDefault();
showProposal($(this).attr('id').substring(2));
});
$(document).on("click", 'a.hide-proposal', function(event) {
event.preventDefault();
hideProposal($(this).attr('id').substring(2));
});
$(document).on("click", 'a.show-propose-change', function(event) {
event.preventDefault();
showProposeChange($(this).attr('id').substring(2));
});
$(document).on("click", 'a.hide-propose-change', function(event) {
event.preventDefault();
hideProposeChange($(this).attr('id').substring(2));
});
$(document).on("click", 'a.accept-comment', function(event) {
event.preventDefault();
acceptComment($(this).attr('id').substring(2));
});
$(document).on("click", 'a.delete-comment', function(event) {
event.preventDefault();
deleteComment($(this).attr('id').substring(2));
});
$(document).on("click", 'a.comment-markup', function(event) {
event.preventDefault();
toggleCommentMarkupBox($(this).attr('id').substring(2));
});
}
/**
* Set comp, which is a comparator function used for sorting and
* inserting comments into the list.
*/
function setComparator() {
// If the first three letters are "asc", sort in ascending order
// and remove the prefix.
if (by.substring(0,3) == 'asc') {
var i = by.substring(3);
comp = function(a, b) { return a[i] - b[i]; };
} else {
// Otherwise sort in descending order.
comp = function(a, b) { return b[by] - a[by]; };
}
// Reset link styles and format the selected sort option.
$('a.sel').attr('href', '#').removeClass('sel');
$('a.by' + by).removeAttr('href').addClass('sel');
}
/**
* Create a comp function. If the user has preferences stored in
* the sortBy cookie, use those, otherwise use the default.
*/
function initComparator() {
by = 'rating'; // Default to sort by rating.
// If the sortBy cookie is set, use that instead.
if (document.cookie.length > 0) {
var start = document.cookie.indexOf('sortBy=');
if (start != -1) {
start = start + 7;
var end = document.cookie.indexOf(";", start);
if (end == -1) {
end = document.cookie.length;
by = unescape(document.cookie.substring(start, end));
}
}
}
setComparator();
}
/**
* Show a comment div.
*/
function show(id) {
$('#ao' + id).hide();
$('#ah' + id).show();
var context = $.extend({id: id}, opts);
var popup = $(renderTemplate(popupTemplate, context)).hide();
popup.find('textarea[name="proposal"]').hide();
popup.find('a.by' + by).addClass('sel');
var form = popup.find('#cf' + id);
form.submit(function(event) {
event.preventDefault();
addComment(form);
});
$('#s' + id).after(popup);
popup.slideDown('fast', function() {
getComments(id);
});
}
/**
* Hide a comment div.
*/
function hide(id) {
$('#ah' + id).hide();
$('#ao' + id).show();
var div = $('#sc' + id);
div.slideUp('fast', function() {
div.remove();
});
}
/**
* Perform an ajax request to get comments for a node
* and insert the comments into the comments tree.
*/
function getComments(id) {
$.ajax({
type: 'GET',
url: opts.getCommentsURL,
data: {node: id},
success: function(data, textStatus, request) {
var ul = $('#cl' + id);
var speed = 100;
$('#cf' + id)
.find('textarea[name="proposal"]')
.data('source', data.source);
if (data.comments.length === 0) {
ul.html('<li>No comments yet.</li>');
ul.data('empty', true);
} else {
// If there are comments, sort them and put them in the list.
var comments = sortComments(data.comments);
speed = data.comments.length * 100;
appendComments(comments, ul);
ul.data('empty', false);
}
$('#cn' + id).slideUp(speed + 200);
ul.slideDown(speed);
},
error: function(request, textStatus, error) {
showError('Oops, there was a problem retrieving the comments.');
},
dataType: 'json'
});
}
/**
* Add a comment via ajax and insert the comment into the comment tree.
*/
function addComment(form) {
var node_id = form.find('input[name="node"]').val();
var parent_id = form.find('input[name="parent"]').val();
var text = form.find('textarea[name="comment"]').val();
var proposal = form.find('textarea[name="proposal"]').val();
if (text == '') {
showError('Please enter a comment.');
return;
}
// Disable the form that is being submitted.
form.find('textarea,input').attr('disabled', 'disabled');
// Send the comment to the server.
$.ajax({
type: "POST",
url: opts.addCommentURL,
dataType: 'json',
data: {
node: node_id,
parent: parent_id,
text: text,
proposal: proposal
},
success: function(data, textStatus, error) {
// Reset the form.
if (node_id) {
hideProposeChange(node_id);
}
form.find('textarea')
.val('')
.add(form.find('input'))
.removeAttr('disabled');
var ul = $('#cl' + (node_id || parent_id));
if (ul.data('empty')) {
$(ul).empty();
ul.data('empty', false);
}
insertComment(data.comment);
var ao = $('#ao' + node_id);
ao.find('img').attr({'src': opts.commentBrightImage});
if (node_id) {
// if this was a "root" comment, remove the commenting box
// (the user can get it back by reopening the comment popup)
$('#ca' + node_id).slideUp();
}
},
error: function(request, textStatus, error) {
form.find('textarea,input').removeAttr('disabled');
showError('Oops, there was a problem adding the comment.');
}
});
}
/**
* Recursively append comments to the main comment list and children
* lists, creating the comment tree.
*/
function appendComments(comments, ul) {
$.each(comments, function() {
var div = createCommentDiv(this);
ul.append($(document.createElement('li')).html(div));
appendComments(this.children, div.find('ul.comment-children'));
// To avoid stagnating data, don't store the comments children in data.
this.children = null;
div.data('comment', this);
});
}
/**
* After adding a new comment, it must be inserted in the correct
* location in the comment tree.
*/
function insertComment(comment) {
var div = createCommentDiv(comment);
// To avoid stagnating data, don't store the comments children in data.
comment.children = null;
div.data('comment', comment);
var ul = $('#cl' + (comment.node || comment.parent));
var siblings = getChildren(ul);
var li = $(document.createElement('li'));
li.hide();
// Determine where in the parents children list to insert this comment.
for(var i=0; i < siblings.length; i++) {
if (comp(comment, siblings[i]) <= 0) {
$('#cd' + siblings[i].id)
.parent()
.before(li.html(div));
li.slideDown('fast');
return;
}
}
// If we get here, this comment rates lower than all the others,
// or it is the only comment in the list.
ul.append(li.html(div));
li.slideDown('fast');
}
function acceptComment(id) {
$.ajax({
type: 'POST',
url: opts.acceptCommentURL,
data: {id: id},
success: function(data, textStatus, request) {
$('#cm' + id).fadeOut('fast');
$('#cd' + id).removeClass('moderate');
},
error: function(request, textStatus, error) {
showError('Oops, there was a problem accepting the comment.');
}
});
}
function deleteComment(id) {
$.ajax({
type: 'POST',
url: opts.deleteCommentURL,
data: {id: id},
success: function(data, textStatus, request) {
var div = $('#cd' + id);
if (data == 'delete') {
// Moderator mode: remove the comment and all children immediately
div.slideUp('fast', function() {
div.remove();
});
return;
}
// User mode: only mark the comment as deleted
div
.find('span.user-id:first')
.text('[deleted]').end()
.find('div.comment-text:first')
.text('[deleted]').end()
.find('#cm' + id + ', #dc' + id + ', #ac' + id + ', #rc' + id +
', #sp' + id + ', #hp' + id + ', #cr' + id + ', #rl' + id)
.remove();
var comment = div.data('comment');
comment.username = '[deleted]';
comment.text = '[deleted]';
div.data('comment', comment);
},
error: function(request, textStatus, error) {
showError('Oops, there was a problem deleting the comment.');
}
});
}
function showProposal(id) {
$('#sp' + id).hide();
$('#hp' + id).show();
$('#pr' + id).slideDown('fast');
}
function hideProposal(id) {
$('#hp' + id).hide();
$('#sp' + id).show();
$('#pr' + id).slideUp('fast');
}
function showProposeChange(id) {
$('#pc' + id).hide();
$('#hc' + id).show();
var textarea = $('#pt' + id);
textarea.val(textarea.data('source'));
$.fn.autogrow.resize(textarea[0]);
textarea.slideDown('fast');
}
function hideProposeChange(id) {
$('#hc' + id).hide();
$('#pc' + id).show();
var textarea = $('#pt' + id);
textarea.val('').removeAttr('disabled');
textarea.slideUp('fast');
}
function toggleCommentMarkupBox(id) {
$('#mb' + id).toggle();
}
/** Handle when the user clicks on a sort by link. */
function handleReSort(link) {
var classes = link.attr('class').split(/\s+/);
for (var i=0; i<classes.length; i++) {
if (classes[i] != 'sort-option') {
by = classes[i].substring(2);
}
}
setComparator();
// Save/update the sortBy cookie.
var expiration = new Date();
expiration.setDate(expiration.getDate() + 365);
document.cookie= 'sortBy=' + escape(by) +
';expires=' + expiration.toUTCString();
$('ul.comment-ul').each(function(index, ul) {
var comments = getChildren($(ul), true);
comments = sortComments(comments);
appendComments(comments, $(ul).empty());
});
}
/**
* Function to process a vote when a user clicks an arrow.
*/
function handleVote(link) {
if (!opts.voting) {
showError("You'll need to login to vote.");
return;
}
var id = link.attr('id');
if (!id) {
// Didn't click on one of the voting arrows.
return;
}
// If it is an unvote, the new vote value is 0,
// Otherwise it's 1 for an upvote, or -1 for a downvote.
var value = 0;
if (id.charAt(1) != 'u') {
value = id.charAt(0) == 'u' ? 1 : -1;
}
// The data to be sent to the server.
var d = {
comment_id: id.substring(2),
value: value
};
// Swap the vote and unvote links.
link.hide();
$('#' + id.charAt(0) + (id.charAt(1) == 'u' ? 'v' : 'u') + d.comment_id)
.show();
// The div the comment is displayed in.
var div = $('div#cd' + d.comment_id);
var data = div.data('comment');
// If this is not an unvote, and the other vote arrow has
// already been pressed, unpress it.
if ((d.value !== 0) && (data.vote === d.value * -1)) {
$('#' + (d.value == 1 ? 'd' : 'u') + 'u' + d.comment_id).hide();
$('#' + (d.value == 1 ? 'd' : 'u') + 'v' + d.comment_id).show();
}
// Update the comments rating in the local data.
data.rating += (data.vote === 0) ? d.value : (d.value - data.vote);
data.vote = d.value;
div.data('comment', data);
// Change the rating text.
div.find('.rating:first')
.text(data.rating + ' point' + (data.rating == 1 ? '' : 's'));
// Send the vote information to the server.
$.ajax({
type: "POST",
url: opts.processVoteURL,
data: d,
error: function(request, textStatus, error) {
showError('Oops, there was a problem casting that vote.');
}
});
}
/**
* Open a reply form used to reply to an existing comment.
*/
function openReply(id) {
// Swap out the reply link for the hide link
$('#rl' + id).hide();
$('#cr' + id).show();
// Add the reply li to the children ul.
var div = $(renderTemplate(replyTemplate, {id: id})).hide();
$('#cl' + id)
.prepend(div)
// Setup the submit handler for the reply form.
.find('#rf' + id)
.submit(function(event) {
event.preventDefault();
addComment($('#rf' + id));
closeReply(id);
})
.find('input[type=button]')
.click(function() {
closeReply(id);
});
div.slideDown('fast', function() {
$('#rf' + id).find('textarea').focus();
});
}
/**
* Close the reply form opened with openReply.
*/
function closeReply(id) {
// Remove the reply div from the DOM.
$('#rd' + id).slideUp('fast', function() {
$(this).remove();
});
// Swap out the hide link for the reply link
$('#cr' + id).hide();
$('#rl' + id).show();
}
/**
* Recursively sort a tree of comments using the comp comparator.
*/
function sortComments(comments) {
comments.sort(comp);
$.each(comments, function() {
this.children = sortComments(this.children);
});
return comments;
}
/**
* Get the children comments from a ul. If recursive is true,
* recursively include childrens' children.
*/
function getChildren(ul, recursive) {
var children = [];
ul.children().children("[id^='cd']")
.each(function() {
var comment = $(this).data('comment');
if (recursive)
comment.children = getChildren($(this).find('#cl' + comment.id), true);
children.push(comment);
});
return children;
}
/** Create a div to display a comment in. */
function createCommentDiv(comment) {
if (!comment.displayed && !opts.moderator) {
return $('<div class="moderate">Thank you! Your comment will show up '
+ 'once it is has been approved by a moderator.</div>');
}
// Prettify the comment rating.
comment.pretty_rating = comment.rating + ' point' +
(comment.rating == 1 ? '' : 's');
// Make a class (for displaying not yet moderated comments differently)
comment.css_class = comment.displayed ? '' : ' moderate';
// Create a div for this comment.
var context = $.extend({}, opts, comment);
var div = $(renderTemplate(commentTemplate, context));
// If the user has voted on this comment, highlight the correct arrow.
if (comment.vote) {
var direction = (comment.vote == 1) ? 'u' : 'd';
div.find('#' + direction + 'v' + comment.id).hide();
div.find('#' + direction + 'u' + comment.id).show();
}
if (opts.moderator || comment.text != '[deleted]') {
div.find('a.reply').show();
if (comment.proposal_diff)
div.find('#sp' + comment.id).show();
if (opts.moderator && !comment.displayed)
div.find('#cm' + comment.id).show();
if (opts.moderator || (opts.username == comment.username))
div.find('#dc' + comment.id).show();
}
return div;
}
/**
* A simple template renderer. Placeholders such as <%id%> are replaced
* by context['id'] with items being escaped. Placeholders such as <#id#>
* are not escaped.
*/
function renderTemplate(template, context) {
var esc = $(document.createElement('div'));
function handle(ph, escape) {
var cur = context;
$.each(ph.split('.'), function() {
cur = cur[this];
});
return escape ? esc.text(cur || "").html() : cur;
}
return template.replace(/<([%#])([\w\.]*)\1>/g, function() {
return handle(arguments[2], arguments[1] == '%' ? true : false);
});
}
/** Flash an error message briefly. */
function showError(message) {
$(document.createElement('div')).attr({'class': 'popup-error'})
.append($(document.createElement('div'))
.attr({'class': 'error-message'}).text(message))
.appendTo('body')
.fadeIn("slow")
.delay(2000)
.fadeOut("slow");
}
/** Add a link the user uses to open the comments popup. */
$.fn.comment = function() {
return this.each(function() {
var id = $(this).attr('id').substring(1);
var count = COMMENT_METADATA[id];
var title = count + ' comment' + (count == 1 ? '' : 's');
var image = count > 0 ? opts.commentBrightImage : opts.commentImage;
var addcls = count == 0 ? ' nocomment' : '';
$(this)
.append(
$(document.createElement('a')).attr({
href: '#',
'class': 'sphinx-comment-open' + addcls,
id: 'ao' + id
})
.append($(document.createElement('img')).attr({
src: image,
alt: 'comment',
title: title
}))
.click(function(event) {
event.preventDefault();
show($(this).attr('id').substring(2));
})
)
.append(
$(document.createElement('a')).attr({
href: '#',
'class': 'sphinx-comment-close hidden',
id: 'ah' + id
})
.append($(document.createElement('img')).attr({
src: opts.closeCommentImage,
alt: 'close',
title: 'close'
}))
.click(function(event) {
event.preventDefault();
hide($(this).attr('id').substring(2));
})
);
});
};
var opts = {
processVoteURL: '/_process_vote',
addCommentURL: '/_add_comment',
getCommentsURL: '/_get_comments',
acceptCommentURL: '/_accept_comment',
deleteCommentURL: '/_delete_comment',
commentImage: '/static/_static/comment.png',
closeCommentImage: '/static/_static/comment-close.png',
loadingImage: '/static/_static/ajax-loader.gif',
commentBrightImage: '/static/_static/comment-bright.png',
upArrow: '/static/_static/up.png',
downArrow: '/static/_static/down.png',
upArrowPressed: '/static/_static/up-pressed.png',
downArrowPressed: '/static/_static/down-pressed.png',
voting: false,
moderator: false
};
if (typeof COMMENT_OPTIONS != "undefined") {
opts = jQuery.extend(opts, COMMENT_OPTIONS);
}
var popupTemplate = '\
<div class="sphinx-comments" id="sc<%id%>">\
<p class="sort-options">\
Sort by:\
<a href="#" class="sort-option byrating">best rated</a>\
<a href="#" class="sort-option byascage">newest</a>\
<a href="#" class="sort-option byage">oldest</a>\
</p>\
<div class="comment-header">Comments</div>\
<div class="comment-loading" id="cn<%id%>">\
loading comments... <img src="<%loadingImage%>" alt="" /></div>\
<ul id="cl<%id%>" class="comment-ul"></ul>\
<div id="ca<%id%>">\
<p class="add-a-comment">Add a comment\
(<a href="#" class="comment-markup" id="ab<%id%>">markup</a>):</p>\
<div class="comment-markup-box" id="mb<%id%>">\
reStructured text markup: <i>*emph*</i>, <b>**strong**</b>, \
<code>``code``</code>, \
code blocks: <code>::</code> and an indented block after blank line</div>\
<form method="post" id="cf<%id%>" class="comment-form" action="">\
<textarea name="comment" cols="80"></textarea>\
<p class="propose-button">\
<a href="#" id="pc<%id%>" class="show-propose-change">\
Propose a change &#9657;\
</a>\
<a href="#" id="hc<%id%>" class="hide-propose-change">\
Propose a change &#9663;\
</a>\
</p>\
<textarea name="proposal" id="pt<%id%>" cols="80"\
spellcheck="false"></textarea>\
<input type="submit" value="Add comment" />\
<input type="hidden" name="node" value="<%id%>" />\
<input type="hidden" name="parent" value="" />\
</form>\
</div>\
</div>';
var commentTemplate = '\
<div id="cd<%id%>" class="sphinx-comment<%css_class%>">\
<div class="vote">\
<div class="arrow">\
<a href="#" id="uv<%id%>" class="vote" title="vote up">\
<img src="<%upArrow%>" />\
</a>\
<a href="#" id="uu<%id%>" class="un vote" title="vote up">\
<img src="<%upArrowPressed%>" />\
</a>\
</div>\
<div class="arrow">\
<a href="#" id="dv<%id%>" class="vote" title="vote down">\
<img src="<%downArrow%>" id="da<%id%>" />\
</a>\
<a href="#" id="du<%id%>" class="un vote" title="vote down">\
<img src="<%downArrowPressed%>" />\
</a>\
</div>\
</div>\
<div class="comment-content">\
<p class="tagline comment">\
<span class="user-id"><%username%></span>\
<span class="rating"><%pretty_rating%></span>\
<span class="delta"><%time.delta%></span>\
</p>\
<div class="comment-text comment"><#text#></div>\
<p class="comment-opts comment">\
<a href="#" class="reply hidden" id="rl<%id%>">reply &#9657;</a>\
<a href="#" class="close-reply" id="cr<%id%>">reply &#9663;</a>\
<a href="#" id="sp<%id%>" class="show-proposal">proposal &#9657;</a>\
<a href="#" id="hp<%id%>" class="hide-proposal">proposal &#9663;</a>\
<a href="#" id="dc<%id%>" class="delete-comment hidden">delete</a>\
<span id="cm<%id%>" class="moderation hidden">\
<a href="#" id="ac<%id%>" class="accept-comment">accept</a>\
</span>\
</p>\
<pre class="proposal" id="pr<%id%>">\
<#proposal_diff#>\
</pre>\
<ul class="comment-children" id="cl<%id%>"></ul>\
</div>\
<div class="clearleft"></div>\
</div>\
</div>';
var replyTemplate = '\
<li>\
<div class="reply-div" id="rd<%id%>">\
<form id="rf<%id%>">\
<textarea name="comment" cols="80"></textarea>\
<input type="submit" value="Add reply" />\
<input type="button" value="Cancel" />\
<input type="hidden" name="parent" value="<%id%>" />\
<input type="hidden" name="node" value="" />\
</form>\
</div>\
</li>';
$(document).ready(function() {
init();
});
})(jQuery);
$(document).ready(function() {
// add comment anchors for all paragraphs that are commentable
$('.sphinx-has-comment').comment();
// highlight search words in search results
$("div.context").each(function() {
var params = $.getQueryParameters();
var terms = (params.q) ? params.q[0].split(/\s+/) : [];
var result = $(this);
$.each(terms, function() {
result.highlightText(this.toLowerCase(), 'highlighted');
});
});
// directly open comment window if requested
var anchor = document.location.hash;
if (anchor.substring(0, 9) == '#comment-') {
$('#ao' + anchor.substring(9)).click();
document.location.hash = '#s' + anchor.substring(9);
}
});

View File

@@ -1,90 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Acknowledgements &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Acknowledgements &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Bugtracking" href="bugtracking.html" />
<link rel="prev" title="MusrRoot - an Extensible Open File Format for μSR" href="musr-root.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -102,148 +61,73 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Acknowledgements</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Acknowledgements</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/acknowledgement.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="acknowledgements">
<span id="acknowledgment"></span><span id="index-0"></span><h1>Acknowledgements<a class="headerlink" href="#acknowledgements" title="Permalink to this headline"></a></h1>
<dl class="docutils">
<dt><strong>Bastian M. Wojek</strong></dt>
<dd>I am very much indebted to BMW for his rigorous testing of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>, his many useful suggestions, contributions, and for the
largest part of the user manual of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> which makes it accessible to a broader audience! Many thanks Bastian!</dd>
<dt><strong>Uldis Locans</strong></dt>
<dd>I am very much indebted to Uldis work on <a class="reference internal" href="setup-dks.html#setup-dks"><span class="std std-ref">DKS</span></a> enabling the GPU support for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>. His kind, calm, and
extremely competent way to deal with his projects as well as to deal with the chaos of physicists way to think is admirable. Many thanks Uldis!</dd>
<dt><strong>Zaher Salman</strong></dt>
<dd>Thanks for his beta-NMR and web-interface contributions to <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>!</dd>
<dt><strong>Robert Scheuermann</strong></dt>
<dd>Thanks for his constant contructive input on <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>!</dd>
<section id="acknowledgements">
<span id="acknowledgment"></span><span id="index-0"></span><h1>Acknowledgements<a class="headerlink" href="#acknowledgements" title="Link to this heading"></a></h1>
<dl class="simple">
<dt><strong>Bastian M. Wojek</strong></dt><dd><p>I am very much indebted to BMW for his rigorous testing of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>, his many useful suggestions, contributions, and for the
largest part of the user manual of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> which makes it accessible to a broader audience! Many thanks Bastian!</p>
</dd>
<dt><strong>Uldis Locans</strong></dt><dd><p>I am very much indebted to Uldis work on <a class="reference internal" href="setup-dks.html#setup-dks"><span class="std std-ref">DKS</span></a> enabling the GPU support for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>. His kind, calm, and
extremely competent way to deal with his projects as well as to deal with the chaos of physicists way to think is admirable. Many thanks Uldis!</p>
</dd>
<dt><strong>Zaher Salman</strong></dt><dd><p>Thanks for his beta-NMR and web-interface contributions to <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>!</p>
</dd>
<dt><strong>Robert Scheuermann</strong></dt><dd><p>Thanks for his constant contructive input on <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>!</p>
</dd>
</dl>
</div>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="bugtracking.html" class="btn btn-neutral float-right" title="Bugtracking" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="musr-root.html" class="btn btn-neutral" title="MusrRoot - an Extensible Open File Format for μSR" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="musr-root.html" class="btn btn-neutral float-left" title="MusrRoot - an Extensible Open File Format for μSR" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="bugtracking.html" class="btn btn-neutral float-right" title="Bugtracking" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>any2many - a Universal μSR-file-format converter &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>any2many - a Universal μSR-file-format converter &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Short description and references to the supported file-formats" href="file-formats.html" />
<link rel="prev" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" href="msr2data.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -102,138 +61,63 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>any2many - a Universal μSR-file-format converter</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">any2many - a Universal μSR-file-format converter</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/any2many.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="any2many-a-universal-mgrsr-file-format-converter">
<span id="index-0"></span><h1>any2many - a Universal μSR-file-format converter<a class="headerlink" href="#any2many-a-universal-mgrsr-file-format-converter" title="Permalink to this headline"></a></h1>
<section id="any2many-a-universal-mgrsr-file-format-converter">
<span id="index-0"></span><h1>any2many - a Universal μSR-file-format converter<a class="headerlink" href="#any2many-a-universal-mgrsr-file-format-converter" title="Link to this heading"></a></h1>
<p><code class="docutils literal notranslate"><span class="pre">any2many</span></code> allows to convert most μSR-file-formats from one to the other.
For a detailed description see <a class="reference internal" href="user-manual.html#any2many"><span class="std std-ref">here</span></a>.</p>
</div>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="file-formats.html" class="btn btn-neutral float-right" title="Short description and references to the supported file-formats" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="msr2data.html" class="btn btn-neutral" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="msr2data.html" class="btn btn-neutral float-left" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="file-formats.html" class="btn btn-neutral float-right" title="Short description and references to the supported file-formats" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,89 +1,48 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Bugtracking &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Bugtracking &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="prev" title="Acknowledgements" href="acknowledgement.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -101,137 +60,63 @@
<li class="toctree-l1 current"><a class="current reference internal" href="#">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Bugtracking</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Bugtracking</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/bugtracking.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="bugtracking">
<span id="index-0"></span><span id="id1"></span><h1>Bugtracking<a class="headerlink" href="#bugtracking" title="Permalink to this headline"></a></h1>
<section id="bugtracking">
<span id="index-0"></span><span id="id1"></span><h1>Bugtracking<a class="headerlink" href="#bugtracking" title="Link to this heading"></a></h1>
<p>For reporting bugs or requesting new features and improvements please use
the <a class="reference external" href="https://bitbucket.org/muonspin/musrfit/issues">bitbucket-repo</a> (preferred)
or send an e-mail to A. Suter at PSI.</p>
</div>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="acknowledgement.html" class="btn btn-neutral" title="Acknowledgements" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="acknowledgement.html" class="btn btn-neutral float-left" title="Acknowledgements" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>How to Cite musrfit? &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>How to Cite musrfit? &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Tutorial for musrfit" href="tutorial.html" />
<link rel="prev" title="Welcome to the musrfit documentation!" href="index.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1 current"><a class="current reference internal" href="#">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -102,150 +61,75 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/cite.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="how-to-cite-musrfit">
<span id="cite"></span><span id="index-0"></span><h1>How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?<a class="headerlink" href="#how-to-cite-musrfit" title="Permalink to this headline"></a></h1>
<section id="how-to-cite-musrfit">
<span id="cite"></span><span id="index-0"></span><h1>How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?<a class="headerlink" href="#how-to-cite-musrfit" title="Link to this heading"></a></h1>
<p>Since quite some effort is going into the development and maintenance of the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> package, you should at least acknowledge it in your publication if you have used it to analyze your data. Even better of course is to cite it properly by the reference given beneath</p>
<blockquote>
<div><ul class="simple">
<li>A. Suter, B.M. Wojek, “Musrfit: A Free Platform-Independent Framework for μSR Data Analysis”, Physics Procedia <strong>30</strong>, 69 (2012). <a class="reference external" href="http://dx.doi.org/10.1016/j.phpro.2012.04.042">http://dx.doi.org/10.1016/j.phpro.2012.04.042</a></li>
<li><p>A. Suter, B.M. Wojek, “Musrfit: A Free Platform-Independent Framework for μSR Data Analysis”, Physics Procedia <strong>30</strong>, 69 (2012). <a class="reference external" href="http://dx.doi.org/10.1016/j.phpro.2012.04.042">http://dx.doi.org/10.1016/j.phpro.2012.04.042</a></p></li>
</ul>
</div></blockquote>
<p>The GPU high speed <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> version is utilizing <code class="docutils literal notranslate"><span class="pre">DKS</span></code>. In case you are using this version, please also add the following citations</p>
<blockquote>
<div><ul class="simple">
<li>A. Adelmann, U. Locans, A. Suter, “The Dynamic Kernel Scheduler—Part 1”, Computer Physics Communications <strong>207</strong>, 83 (2016). <a class="reference external" href="https://doi.org/10.1016/j.cpc.2016.05.013">https://doi.org/10.1016/j.cpc.2016.05.013</a></li>
<li>U. Locans, <em>et al.</em>, “Real-time computation of parameter fitting and image reconstruction using graphical processing units”, Computer Physics Communications <strong>215</strong>, 71 (2017). <a class="reference external" href="https://doi.org/10.1016/j.cpc.2017.02.007">https://doi.org/10.1016/j.cpc.2017.02.007</a></li>
<li>U.Locans and A.Suter, “Musrfit Real Time Parameter Fitting Using GPUs”, JPS Conf. Proc. <em>21</em>, 011051 (2018). <a class="reference external" href="http://dx.doi.org/10.7566/JPSCP.21.011051">http://dx.doi.org/10.7566/JPSCP.21.011051</a></li>
<li><p>A. Adelmann, U. Locans, A. Suter, “The Dynamic Kernel Scheduler—Part 1”, Computer Physics Communications <strong>207</strong>, 83 (2016). <a class="reference external" href="https://doi.org/10.1016/j.cpc.2016.05.013">https://doi.org/10.1016/j.cpc.2016.05.013</a></p></li>
<li><p>U. Locans, <em>et al.</em>, “Real-time computation of parameter fitting and image reconstruction using graphical processing units”, Computer Physics Communications <strong>215</strong>, 71 (2017). <a class="reference external" href="https://doi.org/10.1016/j.cpc.2017.02.007">https://doi.org/10.1016/j.cpc.2017.02.007</a></p></li>
<li><p>U.Locans and A.Suter, “Musrfit Real Time Parameter Fitting Using GPUs”, JPS Conf. Proc. <em>21</em>, 011051 (2018). <a class="reference external" href="http://dx.doi.org/10.7566/JPSCP.21.011051">http://dx.doi.org/10.7566/JPSCP.21.011051</a></p></li>
</ul>
</div></blockquote>
</div>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="tutorial.html" class="btn btn-neutral float-right" title="Tutorial for musrfit" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="index.html" class="btn btn-neutral" title="Welcome to the musrfit documentation!" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="index.html" class="btn btn-neutral float-left" title="Welcome to the musrfit documentation!" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="tutorial.html" class="btn btn-neutral float-right" title="Tutorial for musrfit" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,50 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Short description and references to the supported file-formats &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Short description and references to the supported file-formats &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script async="async" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="MusrRoot - an Extensible Open File Format for μSR" href="musr-root.html" />
<link rel="prev" title="any2many - a Universal μSR-file-format converter" href="any2many.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -114,85 +74,47 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Short description and references to the supported file-formats</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Short description and references to the supported file-formats</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/file-formats.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="short-description-and-references-to-the-supported-file-formats">
<span id="file-formats"></span><span id="index-0"></span><h1>Short description and references to the supported file-formats<a class="headerlink" href="#short-description-and-references-to-the-supported-file-formats" title="Permalink to this headline"></a></h1>
<section id="short-description-and-references-to-the-supported-file-formats">
<span id="file-formats"></span><span id="index-0"></span><h1>Short description and references to the supported file-formats<a class="headerlink" href="#short-description-and-references-to-the-supported-file-formats" title="Link to this heading"></a></h1>
<p>Currently the following μSR and non-μSR file formats are supported (in alphabetic order):</p>
<ul class="simple">
<li>ascii (non-μSR): <a class="reference internal" href="#ascii-file-format"><span class="std std-ref">ASCII file format for non-uSR</span></a></li>
<li>db (non-μSR): <a class="reference internal" href="#db-file-format"><span class="std std-ref">DB (triumf)</span></a></li>
<li>dat (non-μSR): <a class="reference internal" href="#dat-file-format"><span class="std std-ref">DAT: CSV like data file</span></a></li>
<li>mdu (μSR): <a class="reference internal" href="#mdu-file-format"><span class="std std-ref">MDU file format (PSI)</span></a></li>
<li>mud (μSR): <a class="reference internal" href="#mud-file-format"><span class="std std-ref">MUon Data access file format (TRIUMF)</span></a></li>
<li>musr-root (μSR): <a class="reference internal" href="musr-root.html#musrroot"><span class="std std-ref">MusrRoot - an Extensible Open File Format for uSR</span></a></li>
<li>nexus (μSR): used to read NeXus files from ISIS (HDF4 and HDF5): <a class="reference internal" href="#nexus-file-format"><span class="std std-ref">NeXus</span></a></li>
<li>psi-bin (μSR): <a class="reference internal" href="#psi-bin-file-format"><span class="std std-ref">PSI-BIN file format (PSI)</span></a></li>
<li>root (μSR): specific version for LEM before 2012 <a class="reference internal" href="#root-file-format"><span class="std std-ref">LEM ROOT file format</span></a></li>
<li>wkm (μSR): special ascii file format used in the past by the TU Braunschweig (outdated): <a class="reference internal" href="#wkm-file-format"><span class="std std-ref">WKM</span></a></li>
<li><p>ascii (non-μSR): <a class="reference internal" href="#ascii-file-format"><span class="std std-ref">ASCII file format for non-uSR</span></a></p></li>
<li><p>db (non-μSR): <a class="reference internal" href="#db-file-format"><span class="std std-ref">DB (triumf)</span></a></p></li>
<li><p>dat (non-μSR): <a class="reference internal" href="#dat-file-format"><span class="std std-ref">DAT: CSV like data file</span></a></p></li>
<li><p>mdu (μSR): <a class="reference internal" href="#mdu-file-format"><span class="std std-ref">MDU file format (PSI)</span></a></p></li>
<li><p>mud (μSR): <a class="reference internal" href="#mud-file-format"><span class="std std-ref">MUon Data access file format (TRIUMF)</span></a></p></li>
<li><p>musr-root (μSR): <a class="reference internal" href="musr-root.html#musrroot"><span class="std std-ref">MusrRoot - an Extensible Open File Format for uSR</span></a></p></li>
<li><p>nexus (μSR): used to read NeXus files from ISIS (HDF4 and HDF5): <a class="reference internal" href="#nexus-file-format"><span class="std std-ref">NeXus</span></a></p></li>
<li><p>psi-bin (μSR): <a class="reference internal" href="#psi-bin-file-format"><span class="std std-ref">PSI-BIN file format (PSI)</span></a></p></li>
<li><p>root (μSR): specific version for LEM before 2012 <a class="reference internal" href="#root-file-format"><span class="std std-ref">LEM ROOT file format</span></a></p></li>
<li><p>wkm (μSR): special ascii file format used in the past by the TU Braunschweig (outdated): <a class="reference internal" href="#wkm-file-format"><span class="std std-ref">WKM</span></a></p></li>
</ul>
<div class="section" id="ascii-file-format-for-non-mgrsr">
<span id="ascii-file-format"></span><span id="index-1"></span><h2>ASCII file format for non-μSR<a class="headerlink" href="#ascii-file-format-for-non-mgrsr" title="Permalink to this headline"></a></h2>
<section id="ascii-file-format-for-non-mgrsr">
<span id="ascii-file-format"></span><span id="index-1"></span><h2>ASCII file format for non-μSR<a class="headerlink" href="#ascii-file-format-for-non-mgrsr" title="Link to this heading"></a></h2>
<p>This for instance can be used to fit <span class="math notranslate nohighlight">\(1/\lambda^2 ~ \mathrm{vs} ~ T\)</span> to study gap properties of superconductors.
Details about the gap-intergrals can be found in the memo <em>GapIntegrals.pdf</em> which can be found in the source code of musrfit
under &lt;musrfit-home-dir&gt;/src/external/libGapIntegrals.</p>
@@ -258,9 +180,9 @@ If no error in y is present, the weighting in the fit will be equal.</p>
<span class="mf">4.30518</span><span class="p">,</span> <span class="mf">1.35139</span><span class="p">,</span> <span class="mf">0.08</span>
</pre></div>
</div>
</div>
<div class="section" id="db-file-format-for-non-mgrsr">
<span id="db-file-format"></span><span id="index-2"></span><h2>DB file format for non-μSR<a class="headerlink" href="#db-file-format-for-non-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="db-file-format-for-non-mgrsr">
<span id="db-file-format"></span><span id="index-2"></span><h2>DB file format for non-μSR<a class="headerlink" href="#db-file-format-for-non-mgrsr" title="Link to this heading"></a></h2>
<p>The DB file format is an <em>archaic</em> ascii file format from TRIUMF which is intended to be used to collect parameter summaries of various runs, which can be read directly by <a class="reference internal" href="mupp.html#mupp"><span class="std std-ref">mupp</span></a>.</p>
<p>The DB file is organized in a couple of tags defining various properties, followed by the parameter data with its errors.
Tags and is content are always separated by an empty line.
@@ -287,7 +209,7 @@ Unlike the other tags, here the list of names follow directly after the <strong>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">DATA</span> <span class="n">dataT</span> <span class="n">dataB</span> <span class="n">dataE</span> <span class="n">dataTr</span> <span class="o">...</span>
</pre></div>
</div>
<p>Next there will be a line with the tag <strong>\-e</strong>, followed by</p>
<p>Next there will be a line with the tag <strong>\\-e</strong>, followed by</p>
<p>The parameters are afterwards listed as</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">param</span><span class="o">-</span><span class="n">name</span> <span class="o">=</span> <span class="n">val</span><span class="p">,</span> <span class="n">pos</span><span class="o">-</span><span class="n">err</span><span class="p">,</span> <span class="n">neg</span><span class="o">-</span><span class="n">err</span><span class="p">,</span>\
</pre></div>
@@ -392,9 +314,9 @@ This might look like this (be aware of the comma!):</p>
<span class="o">&gt;&gt;</span> <span class="n">here</span> <span class="n">many</span> <span class="n">more</span> <span class="n">run</span> <span class="n">data</span> <span class="n">would</span> <span class="n">follow</span> <span class="o">...</span>
</pre></div>
</div>
</div>
<div class="section" id="dat-csv-like-file-format-for-non-mgrsr">
<span id="dat-file-format"></span><span id="index-3"></span><h2>DAT: CSV like file format for non-μSR<a class="headerlink" href="#dat-csv-like-file-format-for-non-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="dat-csv-like-file-format-for-non-mgrsr">
<span id="dat-file-format"></span><span id="index-3"></span><h2>DAT: CSV like file format for non-μSR<a class="headerlink" href="#dat-csv-like-file-format-for-non-mgrsr" title="Link to this heading"></a></h2>
<p>This is typically used when exporting the parameter data from <strong>msr2data</strong> to be used in <strong>mupp</strong>, gnuplot, origin, or whatever parameter plotter you might use.
The first line defines the parameter tags separated by spaces or tabs. If errors are available there are labeled be the ending <em>Err</em>.
This is followed by the parameter values and its errors if present. A fill example looks like this:</p>
@@ -403,29 +325,29 @@ This is followed by the parameter values and its errors if present. A fill examp
<span class="mi">200</span> <span class="mf">0.009</span> <span class="mf">99.49</span> <span class="mf">2.11668</span> <span class="mf">10.001</span> <span class="o">-</span><span class="mf">0.008</span> <span class="o">-</span><span class="mf">0.008</span> <span class="o">-</span><span class="mi">10</span> <span class="mf">0.1732</span> <span class="mf">0.0012</span> <span class="mf">0.0012</span> <span class="mf">0.0096</span> <span class="mf">0.0025</span> <span class="mf">0.0026</span> <span class="mf">28.88</span> <span class="mf">0.57</span> <span class="mf">0.57</span> <span class="mf">101.231</span> <span class="mf">0.03</span> <span class="mf">0.03</span> <span class="mi">0</span> <span class="mi">0</span> <span class="mi">0</span> <span class="mf">219.86</span> <span class="mf">0.27</span> <span class="mf">0.27</span> <span class="mf">2.749</span> <span class="mf">0.033</span> <span class="mf">0.033</span> <span class="o">-</span><span class="mf">88.87</span> <span class="mf">0.71</span> <span class="mf">0.71</span> <span class="mf">211.47</span> <span class="mf">0.26</span> <span class="mf">0.26</span> <span class="mf">2.791</span> <span class="mf">0.032</span> <span class="mf">0.032</span> <span class="o">-</span><span class="mf">178.48</span> <span class="mf">0.72</span> <span class="mf">0.71</span> <span class="mf">0.9678</span> <span class="mf">0.0017</span> <span class="mf">0.0017</span> <span class="mf">2.969</span> <span class="mf">0.033</span> <span class="mf">0.033</span> <span class="mf">90.94</span> <span class="mf">0.73</span> <span class="mf">0.73</span> <span class="mf">0.9608</span> <span class="mf">0.0017</span> <span class="mf">0.0017</span> <span class="mf">2.653</span> <span class="mf">0.032</span> <span class="mf">0.032</span> <span class="mf">20182.5</span> <span class="mi">20361</span> <span class="mf">0.991233</span> <span class="mi">11401</span>
</pre></div>
</div>
</div>
<div class="section" id="mdu-file-format-psi-for-mgrsr">
<span id="mdu-file-format"></span><span id="index-4"></span><h2>MDU file format (psi) for μSR<a class="headerlink" href="#mdu-file-format-psi-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="mdu-file-format-psi-for-mgrsr">
<span id="mdu-file-format"></span><span id="index-4"></span><h2>MDU file format (psi) for μSR<a class="headerlink" href="#mdu-file-format-psi-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details about the PSI-BIN/MDU file format from PSI see <a class="reference external" href="http://lmu.web.psi.ch/docu/manuals/bulk_manuals/software/Class_MuSR_PSI/index.html">Class_MuSR_PSI</a></p>
</div>
<div class="section" id="mud-file-format-triumf-for-mgrsr">
<span id="mud-file-format"></span><span id="index-5"></span><h2>MUD file format (triumf) for μSR<a class="headerlink" href="#mud-file-format-triumf-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="mud-file-format-triumf-for-mgrsr">
<span id="mud-file-format"></span><span id="index-5"></span><h2>MUD file format (triumf) for μSR<a class="headerlink" href="#mud-file-format-triumf-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details about the MUD file format from triumf see <a class="reference external" href="https://cmms.triumf.ca/mud/">MUon Data access</a> .</p>
</div>
<div class="section" id="musrroot-file-format-psi-for-mgrsr">
<span id="musr-root-file-format"></span><h2>MusrRoot file format (PSI) for μSR<a class="headerlink" href="#musrroot-file-format-psi-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="musrroot-file-format-psi-for-mgrsr">
<span id="musr-root-file-format"></span><h2>MusrRoot file format (PSI) for μSR<a class="headerlink" href="#musrroot-file-format-psi-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details see <a class="reference internal" href="musr-root.html#musrroot"><span class="std std-ref">MusrRoot - an Extensible Open File Format for uSR</span></a>.</p>
</div>
<div class="section" id="nexus-file-format-isis-for-mgrsr">
<span id="nexus-file-format"></span><span id="index-6"></span><h2>NeXus file format (isis) for μSR<a class="headerlink" href="#nexus-file-format-isis-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="nexus-file-format-isis-for-mgrsr">
<span id="nexus-file-format"></span><span id="index-6"></span><h2>NeXus file format (isis) for μSR<a class="headerlink" href="#nexus-file-format-isis-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details about the NeXus file format from ISIS (UK) see <a class="reference external" href="https://doi.org/10.1016/S0921-4526(02)01613-7">The application of the NeXus data format to ISIS muon data</a> . For a detailed list of available meta information and data see <a class="reference external" href="https://www.isis.stfc.ac.uk/Pages/nexus-definition-v27924.pdf">NeXus Instrument Definitions for ISIS muon Data</a> .</p>
</div>
<div class="section" id="psi-bin-file-format-psi-for-mgrsr">
<span id="psi-bin-file-format"></span><span id="index-7"></span><h2>PSI-BIN file format (psi) for μSR<a class="headerlink" href="#psi-bin-file-format-psi-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="psi-bin-file-format-psi-for-mgrsr">
<span id="psi-bin-file-format"></span><span id="index-7"></span><h2>PSI-BIN file format (psi) for μSR<a class="headerlink" href="#psi-bin-file-format-psi-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details about the PSI-BIN/MDU file format from PSI see <a class="reference external" href="http://lmu.web.psi.ch/docu/manuals/bulk_manuals/software/Class_MuSR_PSI/index.html">Class_MuSR_PSI</a>.</p>
</div>
<div class="section" id="root-file-format-psi-lem-before-2012-for-mgrsr">
<span id="root-file-format"></span><span id="index-8"></span><h2>ROOT file format (psi/lem before 2012) for μSR<a class="headerlink" href="#root-file-format-psi-lem-before-2012-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="root-file-format-psi-lem-before-2012-for-mgrsr">
<span id="root-file-format"></span><span id="index-8"></span><h2>ROOT file format (psi/lem before 2012) for μSR<a class="headerlink" href="#root-file-format-psi-lem-before-2012-for-mgrsr" title="Link to this heading"></a></h2>
<p>For details about the API of ROOT files can be here: <a class="reference external" href="https://root.cern/manual/root_files/">ROOT files</a>.
The structure of the ROOT files (LEM, before 2012) looks like this:</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">ROOT</span><span class="o">-</span><span class="n">file</span> <span class="o">--|</span>
@@ -457,9 +379,9 @@ The structure of the ROOT files (LEM, before 2012) looks like this:</p>
<p>The detectors (20, 21, 22, and 23) are the detectors (Left, Top, Right, Bottom). These are post-pileup-corrected (PPC) histograms.</p>
<p>The <code class="docutils literal notranslate"><span class="pre">SCAnaModule</span></code> contains various <strong>TF1H</strong> objects of slow control data of the run.</p>
<p>The <code class="docutils literal notranslate"><span class="pre">RunSummary</span></code> is essentially an ascii dump, with summary information of the run.</p>
</div>
<div class="section" id="wkm-file-format-for-mgrsr">
<span id="wkm-file-format"></span><span id="index-9"></span><h2>WKM file format for μSR<a class="headerlink" href="#wkm-file-format-for-mgrsr" title="Permalink to this headline"></a></h2>
</section>
<section id="wkm-file-format-for-mgrsr">
<span id="wkm-file-format"></span><span id="index-9"></span><h2>WKM file format for μSR<a class="headerlink" href="#wkm-file-format-for-mgrsr" title="Link to this heading"></a></h2>
<p>WKM is an obsolete ascii file format, originally introduced by people from the TU Braunschweig.
It starts with a header which shows like this:</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="o">-</span> <span class="n">WKM</span> <span class="n">data</span> <span class="n">file</span> <span class="n">converted</span> <span class="k">with</span> <span class="n">any2many</span>
@@ -479,73 +401,36 @@ It starts with a header which shows like this:</p>
<p>The header ends with an empty line.</p>
<p>The data are stored as following: there are always 10 bin-counts per line.
Between detectors, there will be an empty line.</p>
</div>
</div>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="musr-root.html" class="btn btn-neutral float-right" title="MusrRoot - an Extensible Open File Format for μSR" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="any2many.html" class="btn btn-neutral" title="any2many - a Universal μSR-file-format converter" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="any2many.html" class="btn btn-neutral float-left" title="any2many - a Universal μSR-file-format converter" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="musr-root.html" class="btn btn-neutral float-right" title="MusrRoot - an Extensible Open File Format for μSR" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,89 +1,46 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Index &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Index &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="#" />
<link rel="search" title="Search" href="search.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul>
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -101,66 +58,29 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Index</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Index</li>
<li class="wy-breadcrumbs-aside">
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<h1 id="index">Index</h1>
@@ -743,59 +663,28 @@
</div>
</div>
<footer>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 09, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,89 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Welcome to the musrfit documentation! &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Welcome to the musrfit documentation! &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script async="async" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="How to Cite musrfit?" href="cite.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="#" class="icon icon-home"> musrfit
<a href="#" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul>
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -101,70 +61,32 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="#">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="#">Docs</a> &raquo;</li>
<li>Welcome to the musrfit documentation!</li>
<li><a href="#" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Welcome to the musrfit documentation!</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/index.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="welcome-to-the-musrfit-documentation">
<h1>Welcome to the musrfit documentation!<a class="headerlink" href="#welcome-to-the-musrfit-documentation" title="Permalink to this headline"></a></h1>
<section id="welcome-to-the-musrfit-documentation">
<h1>Welcome to the musrfit documentation!<a class="headerlink" href="#welcome-to-the-musrfit-documentation" title="Link to this heading"></a></h1>
<div class="toctree-wrapper compound">
<ul>
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
@@ -178,13 +100,13 @@
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#available-executables-configuration-files-and-their-basic-usage">Available Executables, Configuration Files and their Basic Usage</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#description-of-the-msr-file-format">Description of the msr File Format</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#fit-types">Fit Types</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#id38">User Functions</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#id47">User Functions</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-manual.html#technical-description-of-the-musrfit-framework">Technical Description of the musrfit framework</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="user-libs.html">Documentation of user libs (user functions)</a><ul>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#meissner-profiles-vortex-lattice-related-functions-bmw-libs">Meissner-Profiles / Vortex-Lattice related functions (BMW libs)</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#supeconducting-gap-integrals-to-calculate-vs">Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span></a></li>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#supeconducting-gap-integrals-to-calculate-1-lambda-2-vs-t">Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span></a></li>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#nonlocal-superconductivity-related-meissner-screening-functions-as-libs">Nonlocal superconductivity related Meissner screening functions (AS libs)</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#depth-resolved-information-as-libs">Depth resolved information (AS libs)</a></li>
<li class="toctree-l2"><a class="reference internal" href="user-libs.html#functions-to-analyze-bgr-nmr-data-bnmr-libs">Functions to analyze β-NMR data (BNMR libs)</a></li>
@@ -257,77 +179,41 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
<div class="section" id="indices-and-tables">
<h1>Indices and tables<a class="headerlink" href="#indices-and-tables" title="Permalink to this headline"></a></h1>
</section>
<section id="indices-and-tables">
<h1>Indices and tables<a class="headerlink" href="#indices-and-tables" title="Link to this heading"></a></h1>
<ul class="simple">
<li><a class="reference internal" href="genindex.html"><span class="std std-ref">Index</span></a></li>
<li><a class="reference internal" href="search.html"><span class="std std-ref">Search Page</span></a></li>
<li><p><a class="reference internal" href="genindex.html"><span class="std std-ref">Index</span></a></p></li>
<li><p><a class="reference internal" href="search.html"><span class="std std-ref">Search Page</span></a></p></li>
</ul>
</div>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="cite.html" class="btn btn-neutral float-right" title="How to Cite musrfit?" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="cite.html" class="btn btn-neutral float-right" title="How to Cite musrfit?" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 09, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,50 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>msr2data - A Program for Automatically Processing Multiple musrfit msr Files &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>msr2data - A Program for Automatically Processing Multiple musrfit msr Files &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script async="async" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="any2many - a Universal μSR-file-format converter" href="any2many.html" />
<link rel="prev" title="mupp - μSR Parameter Plotter" href="mupp.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -117,130 +77,91 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>msr2data - A Program for Automatically Processing Multiple <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> msr Files</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">msr2data - A Program for Automatically Processing Multiple <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> msr Files</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/msr2data.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="msr2data-a-program-for-automatically-processing-multiple-musrfit-msr-files">
<span id="msr2data"></span><span id="index-0"></span><h1>msr2data - A Program for Automatically Processing Multiple <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> msr Files<a class="headerlink" href="#msr2data-a-program-for-automatically-processing-multiple-musrfit-msr-files" title="Permalink to this headline"></a></h1>
<section id="msr2data-a-program-for-automatically-processing-multiple-musrfit-msr-files">
<span id="msr2data"></span><span id="index-0"></span><h1>msr2data - A Program for Automatically Processing Multiple <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> msr Files<a class="headerlink" href="#msr2data-a-program-for-automatically-processing-multiple-musrfit-msr-files" title="Link to this heading"></a></h1>
<p><code class="docutils literal notranslate"><span class="pre">msr2data</span></code> (originally written by B. M. Wojek) is a program implemented in <code class="docutils literal notranslate"><span class="pre">C++</span></code>. Its purpose is
to process multiple msr files (input files for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>) with the same parameters and summarize the fitting
results either in a <em>TRIUMF DB</em> <a class="footnote-reference" href="#f1" id="id1">[1]</a> or a <em>column ASCII</em> file. This allows essentially to</p>
results either in a <em>TRIUMF DB</em> <a class="footnote-reference brackets" href="#f1" id="id1" role="doc-noteref"><span class="fn-bracket">[</span>1<span class="fn-bracket">]</span></a> or a <em>column ASCII</em> file. This allows essentially to</p>
<ol class="arabic simple">
<li>Collect the fit parameters.</li>
<li>Generate <em>new</em> input msr files based on old ones.</li>
<li><p>Collect the fit parameters.</p></li>
<li><p>Generate <em>new</em> input msr files based on old ones.</p></li>
</ol>
<table class="docutils footnote" frame="void" id="f1" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id1">[1]</a></td><td>For an abridged description of this format see <a class="reference external" href="http://musr.org/xyfit/dbformat.html">here</a>. The DB files
<aside class="footnote-list brackets">
<aside class="footnote brackets" id="f1" role="doc-footnote">
<span class="label"><span class="fn-bracket">[</span><a role="doc-backlink" href="#id1">1</a><span class="fn-bracket">]</span></span>
<p>For an abridged description of this format see <a class="reference external" href="http://musr.org/xyfit/dbformat.html">here</a>. The DB files
produced by <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> can be viewed for instance with <a class="reference internal" href="mupp.html#mupp"><span class="std std-ref">mupp</span></a> or μView <a class="reference external" href="http://musr.org/muview/">see here</a>, however,
they are not completely backward-compatible to the original <code class="docutils literal notranslate"><span class="pre">db</span> <span class="pre">language</span></code> since the parameter names can be longer than five or
six characters! In order to establish this backward compatibility (if needed) the user has to ensure the correct length of the
parameter names in the msr files!</td></tr>
</tbody>
</table>
<div class="section" id="basic-types-of-usage">
<span id="msr2data-basic-usage"></span><h2>Basic Types of Usage<a class="headerlink" href="#basic-types-of-usage" title="Permalink to this headline"></a></h2>
parameter names in the msr files!</p>
</aside>
</aside>
<section id="basic-types-of-usage">
<span id="msr2data-basic-usage"></span><h2>Basic Types of Usage<a class="headerlink" href="#basic-types-of-usage" title="Link to this heading"></a></h2>
<p>Apart from numerous <a class="reference internal" href="#msr2data-opt-param"><span class="std std-ref">optional parameters</span></a> that might be set, in principle there are four different ways of calling <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>.
These differ in how the list of runs which should be processed is supplied:</p>
<dl class="docutils">
<dt><strong>msr2data &lt;run&gt; &lt;extension&gt; [optional parameters]</strong></dt>
<dd>A single run number.</dd>
<dt><strong>msr2data &lt;firstRunNo&gt; &lt;lastRunNo&gt; &lt;extension&gt; [optional parameters]</strong></dt>
<dd>An interval of run numbers is specified through the first and the last run number. The condition <code class="docutils literal notranslate"><span class="pre">&lt;firstRunNo&gt;</span></code> &lt; <code class="docutils literal notranslate"><span class="pre">&lt;lastRunNo&gt;</span></code> is not necessary.</dd>
<dt><strong>msr2data [ &lt;runList&gt; ] &lt;extension&gt; [optional parameters]</strong></dt>
<dd><p class="first">Where <code class="docutils literal notranslate"><span class="pre">&lt;runList&gt;</span></code> is one or a combination of the following:</p>
<ol class="last arabic simple">
<li><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;,</span> <span class="pre">&lt;run1&gt;,</span> <span class="pre">&lt;run2&gt;,</span> <span class="pre">...</span> <span class="pre">&lt;runN&gt;</span></code> : run numbers, <em>e.g.</em> 123 124,</li>
<li><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;-&lt;runN&gt;</span></code> : a range, <em>e.g.</em> 123-125 -&gt; 123 124 125,</li>
<li><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;:&lt;runN&gt;:&lt;step&gt;</span></code> : a sequence, <em>e.g.</em> 123:127:2 -&gt; 123 125 127. <code class="docutils literal notranslate"><span class="pre">&lt;step&gt;</span></code> has to be a positive integer.</li>
<li>A <code class="docutils literal notranslate"><span class="pre">&lt;runList&gt;</span></code> can also combine (1)-(3), <em>e.g.</em> 123 128-130 133, etc.</li>
<dl class="simple">
<dt><strong>msr2data &lt;run&gt; &lt;extension&gt; [optional parameters]</strong></dt><dd><p>A single run number.</p>
</dd>
<dt><strong>msr2data &lt;firstRunNo&gt; &lt;lastRunNo&gt; &lt;extension&gt; [optional parameters]</strong></dt><dd><p>An interval of run numbers is specified through the first and the last run number. The condition <code class="docutils literal notranslate"><span class="pre">&lt;firstRunNo&gt;</span></code> &lt; <code class="docutils literal notranslate"><span class="pre">&lt;lastRunNo&gt;</span></code> is not necessary.</p>
</dd>
<dt><strong>msr2data [ &lt;runList&gt; ] &lt;extension&gt; [optional parameters]</strong></dt><dd><p>Where <code class="docutils literal notranslate"><span class="pre">&lt;runList&gt;</span></code> is one or a combination of the following:</p>
<ol class="arabic simple">
<li><p><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;,</span> <span class="pre">&lt;run1&gt;,</span> <span class="pre">&lt;run2&gt;,</span> <span class="pre">...</span> <span class="pre">&lt;runN&gt;</span></code> : run numbers, <em>e.g.</em> 123 124,</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;-&lt;runN&gt;</span></code> : a range, <em>e.g.</em> 123-125 -&gt; 123 124 125,</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">&lt;run0&gt;:&lt;runN&gt;:&lt;step&gt;</span></code> : a sequence, <em>e.g.</em> 123:127:2 -&gt; 123 125 127. <code class="docutils literal notranslate"><span class="pre">&lt;step&gt;</span></code> has to be a positive integer.</p></li>
<li><p>A <code class="docutils literal notranslate"><span class="pre">&lt;runList&gt;</span></code> can also combine (1)-(3), <em>e.g.</em> 123 128-130 133, etc.</p></li>
</ol>
</dd>
<dt><strong>msr2data &lt;runListFileName&gt; &lt;extension&gt; [optional parameters]</strong></dt>
<dd>An ASCII file containing a list of run numbers and optional external parameters is passed to <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>. For the structure of the ASCII file
see <a class="reference internal" href="#run-list-file-structure"><span class="std std-ref">below</span></a>.</dd>
<dt><strong>msr2data &lt;runListFileName&gt; &lt;extension&gt; [optional parameters]</strong></dt><dd><p>An ASCII file containing a list of run numbers and optional external parameters is passed to <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>. For the structure of the ASCII file
see <a class="reference internal" href="#run-list-file-structure"><span class="std std-ref">below</span></a>.</p>
</dd>
</dl>
<p>All four basic types of calling <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> contain the <em>mandatory</em> file-name <code class="docutils literal notranslate"><span class="pre">&lt;extension&gt;</span></code> passed right after the list of runs. The meaning of
this <code class="docutils literal notranslate"><span class="pre">&lt;extension&gt;</span></code> should become clear after giving examples for all four cases:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8472</span> _tf_h13
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8472</span><span class="w"> </span>_tf_h13
</pre></div>
</div>
<p>generates the DB file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> (can be changed by using the -o option) from <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code>.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8472</span> <span class="m">8474</span> _tf_h13
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8472</span><span class="w"> </span><span class="m">8474</span><span class="w"> </span>_tf_h13
</pre></div>
</div>
<p>generates the DB file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> (can be changed by using the -o option) from <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8473_tf_h13.msr</span></code>, and <code class="docutils literal notranslate"><span class="pre">8474_tf_h13.msr</span></code>.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="o">[</span><span class="m">8472</span> <span class="m">8470</span><span class="o">]</span> _tf_h13
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="o">[</span><span class="m">8472</span><span class="w"> </span><span class="m">8470</span><span class="o">]</span><span class="w"> </span>_tf_h13
</pre></div>
</div>
<p>generates the DB file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> (can be changed by using the -o option) from <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code> and <code class="docutils literal notranslate"><span class="pre">8470_tf_h13.msr</span></code>.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="o">[</span><span class="m">8470</span>:8474:2<span class="o">]</span> _tf_h13
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="o">[</span><span class="m">8470</span>:8474:2<span class="o">]</span><span class="w"> </span>_tf_h13
</pre></div>
</div>
<p>generates the DB file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> (can be changed by using the -o option) from <code class="docutils literal notranslate"><span class="pre">8470_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code>, and <code class="docutils literal notranslate"><span class="pre">8474_tf_h13.msr</span></code>.</p>
<div class="section" id="run-list-file-structure">
<span id="id2"></span><h3>Run List File Structure<a class="headerlink" href="#run-list-file-structure" title="Permalink to this headline"></a></h3>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data run.list _tf_h13
<section id="run-list-file-structure">
<span id="id2"></span><h3>Run List File Structure<a class="headerlink" href="#run-list-file-structure" title="Link to this heading"></a></h3>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span>run.list<span class="w"> </span>_tf_h13
</pre></div>
</div>
<p>generates the DB file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> (can be changed by using the -o option) from all runs listed in the ASCII file <code class="docutils literal notranslate"><span class="pre">run.list</span></code> in the working directory.
@@ -258,118 +179,116 @@ In this file it is also possible to include <em>external</em> parameters which s
<p>It is allowed to add comments (with a preceding #) or empty lines to the run-list file.</p>
<p>The following should be mentioned together with the above examples:</p>
<ul>
<li><p class="first">The output files in the examples above are only newly created if they did <em>not</em> exist before invoking <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>.
If the files were already present the msr file data would be appended!</p>
</li>
<li><p class="first">If the files have been newly created, also the DB file header is written. If the files were present before, only
<li><p>The output files in the examples above are only newly created if they did <em>not</em> exist before invoking <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>.
If the files were already present the msr file data would be appended!</p></li>
<li><p>If the files have been newly created, also the DB file header is written. If the files were present before, only
the data blocks are appended. The output of the header can either be forced or completely suppressed with the <code class="docutils literal notranslate"><span class="pre">header</span></code>
and <code class="docutils literal notranslate"><span class="pre">noheader</span></code> options as shall be seen later.</p>
</li>
<li><p class="first">If the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> output files do not have an <code class="docutils literal notranslate"><span class="pre">&lt;extension&gt;</span></code> as specified above like <code class="docutils literal notranslate"><span class="pre">8472.msr</span></code> one has to call <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> like in the following example:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8472</span> <span class="m">8460</span> <span class="s2">&quot;&quot;</span>
and <code class="docutils literal notranslate"><span class="pre">noheader</span></code> options as shall be seen later.</p></li>
<li><p>If the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> output files do not have an <code class="docutils literal notranslate"><span class="pre">&lt;extension&gt;</span></code> as specified above like <code class="docutils literal notranslate"><span class="pre">8472.msr</span></code> one has to call <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> like in the following example:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8472</span><span class="w"> </span><span class="m">8460</span><span class="w"> </span><span class="s2">&quot;&quot;</span>
</pre></div>
</div>
</li>
</ul>
</div>
</div>
<div class="section" id="optional-parameters">
<span id="msr2data-opt-param"></span><h2>Optional Parameters<a class="headerlink" href="#optional-parameters" title="Permalink to this headline"></a></h2>
</section>
</section>
<section id="optional-parameters">
<span id="msr2data-opt-param"></span><h2>Optional Parameters<a class="headerlink" href="#optional-parameters" title="Link to this heading"></a></h2>
<p>As mentioned already above there are some optional parameters which change the behavior of <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> and can be passed in any order. Here is a complete list:</p>
<dl class="docutils">
<dt><strong>data</strong></dt>
<dd>The output file format is changed to a simple column ASCII file (default output file name: out.dat).</dd>
<dt><strong>new</strong></dt>
<dd>An existing output file is deleted before new information is written to it.</dd>
<dt><strong>header</strong></dt>
<dd>Force the output of the file header even if the output file was present before.</dd>
<dt><strong>noheader</strong></dt>
<dd>The output of the file header is suppressed—also if the output file is newly created.
<dl class="simple">
<dt><strong>data</strong></dt><dd><p>The output file format is changed to a simple column ASCII file (default output file name: out.dat).</p>
</dd>
<dt><strong>new</strong></dt><dd><p>An existing output file is deleted before new information is written to it.</p>
</dd>
<dt><strong>header</strong></dt><dd><p>Force the output of the file header even if the output file was present before.</p>
</dd>
<dt><strong>noheader</strong></dt><dd><p>The output of the file header is suppressed—also if the output file is newly created.
If either both or none of the header options are given, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> writes the file header only to new files
and it solely appends the data blocks to an existing output file assuming that the header is present already.</dd>
<dt><strong>nosummary</strong></dt>
<dd>There will be no attempt to read additional information like the temperature or the applied magnetic field from
the data files even if these information were present there.</dd>
<dt><strong>paramList &lt;param&gt;</strong></dt>
<dd>option used to select the parameters which shall be exported. <code class="docutils literal notranslate"><span class="pre">&lt;param&gt;</span></code> is a list of parameter numbers to be exported.
and it solely appends the data blocks to an existing output file assuming that the header is present already.</p>
</dd>
<dt><strong>nosummary</strong></dt><dd><p>There will be no attempt to read additional information like the temperature or the applied magnetic field from
the data files even if these information were present there.</p>
</dd>
<dt><strong>paramList &lt;param&gt;</strong></dt><dd><p>option used to select the parameters which shall be exported. <code class="docutils literal notranslate"><span class="pre">&lt;param&gt;</span></code> is a list of parameter numbers to be exported.
Allowed lists are: <code class="docutils literal notranslate"><span class="pre">&lt;startNo&gt;-&lt;endNo&gt;</span></code>, <em>e.g.</em> <code class="docutils literal notranslate"><span class="pre">1-16</span></code> will export parameters 1 to 16. Space separated numbers, <em>e.g.:</em> <code class="docutils literal notranslate"><span class="pre">1</span> <span class="pre">3</span> <span class="pre">5</span></code>.
A combination of both is possible, <em>e.g.</em> <code class="docutils literal notranslate"><span class="pre">1-16</span> <span class="pre">19</span> <span class="pre">31</span> <span class="pre">62</span></code>, and so on.</dd>
<dt><strong>-o&lt;outputFileName&gt;, -o &lt;outputFileName&gt;</strong></dt>
<dd>The processed data will be written to the file <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> instead of the default <code class="docutils literal notranslate"><span class="pre">out.db</span></code> or <code class="docutils literal notranslate"><span class="pre">out.dat</span></code>.
If <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> is equal to none (case-insensitive) the parameter data are not appended to any output file.</dd>
<dt><strong>fit</strong></dt>
<dd>Additionally to the final data collection <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will invoke <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> to fit the specified runs.
All msr files are assumed to be present, none is newly generated!</dd>
<dt><strong>fit-&lt;template&gt;[!]</strong></dt>
<dd>Additionally to the final data collection <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will generate msr files for the runs specified in the list
A combination of both is possible, <em>e.g.</em> <code class="docutils literal notranslate"><span class="pre">1-16</span> <span class="pre">19</span> <span class="pre">31</span> <span class="pre">62</span></code>, and so on.</p>
</dd>
<dt><strong>-o&lt;outputFileName&gt;, -o &lt;outputFileName&gt;</strong></dt><dd><p>The processed data will be written to the file <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> instead of the default <code class="docutils literal notranslate"><span class="pre">out.db</span></code> or <code class="docutils literal notranslate"><span class="pre">out.dat</span></code>.
If <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> is equal to none (case-insensitive) the parameter data are not appended to any output file.</p>
</dd>
<dt><strong>fit</strong></dt><dd><p>Additionally to the final data collection <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will invoke <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> to fit the specified runs.
All msr files are assumed to be present, none is newly generated!</p>
</dd>
<dt><strong>fit-&lt;template&gt;[!]</strong></dt><dd><p>Additionally to the final data collection <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will generate msr files for the runs specified in the list
of runs and invoke <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">musrfit</span></a> for performing fits of the data. As template for the first run the file
<code class="docutils literal notranslate"><span class="pre">&lt;template&gt;&lt;extension&gt;.msr</span></code> (or if not available: <code class="docutils literal notranslate"><span class="pre">&lt;template&gt;&lt;extension&gt;.mlog</span></code>) is used; the subsequent input
files will be created using the msr output of the last processed runs (“chain fit”). However, if for all runs only
the given template should be used one has to append an exclamation mark (<strong>!</strong>) to the <code class="docutils literal notranslate"><span class="pre">&lt;template&gt;</span></code>.</dd>
<dt><strong>msr-&lt;template&gt;</strong></dt>
<dd>The same as <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;[!]</span></code>, <em>without</em> calling <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> and the final data collection, <em>i.e.</em> only the msr files for the given runs are generated.</dd>
<dt><strong>-k</strong></dt>
<dd>If specified together with the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span></code> option, the <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">- -keep-mn2-output</span></a> option is passed to <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>.
In the case no fits should be done, this option is ignored.</dd>
<dt><strong>-t</strong></dt>
<dd>In case this option is given additionally to the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span> <span class="pre">option</span></code>, <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> is called with
the <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">- -title-from-data-file</span></a> option. If no fitting is done, this option is ignored.</dd>
the given template should be used one has to append an exclamation mark (<strong>!</strong>) to the <code class="docutils literal notranslate"><span class="pre">&lt;template&gt;</span></code>.</p>
</dd>
<dt><strong>msr-&lt;template&gt;</strong></dt><dd><p>The same as <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;[!]</span></code>, <em>without</em> calling <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> and the final data collection, <em>i.e.</em> only the msr files for the given runs are generated.</p>
</dd>
<dt><strong>-k</strong></dt><dd><p>If specified together with the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span></code> option, the <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">- -keep-mn2-output</span></a> option is passed to <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>.
In the case no fits should be done, this option is ignored.</p>
</dd>
<dt><strong>-t</strong></dt><dd><p>In case this option is given additionally to the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span> <span class="pre">option</span></code>, <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> is called with
the <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">- -title-from-data-file</span></a> option. If no fitting is done, this option is ignored.</p>
</dd>
</dl>
<p><strong>Examples:</strong></p>
<p>In order to illustrate the usage of these parameters a few examples with explanations are given below:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8400</span> <span class="m">8460</span> _tf_h13 -oABC.db fit-8472
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8400</span><span class="w"> </span><span class="m">8460</span><span class="w"> </span>_tf_h13<span class="w"> </span>-oABC.db<span class="w"> </span>fit-8472
</pre></div>
</div>
<p>Using <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code> as first template, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> generates subsequent msr input files <code class="docutils literal notranslate"><span class="pre">8400_tf_h13.msr</span></code> through <code class="docutils literal notranslate"><span class="pre">8460_tf_h13.msr</span></code>,
calls <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> to perform a fit of these files and collects the results of the fits together with the DB header in the new file <code class="docutils literal notranslate"><span class="pre">ABC.db</span></code>.
Additionally, some information about external parameters like the temperature will be passed to <code class="docutils literal notranslate"><span class="pre">ABC.db</span></code> if it is present in the data files.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="o">[</span><span class="m">8500</span> <span class="m">8502</span>-8504 <span class="m">8507</span><span class="o">]</span> _zf fit-8472 noheader nosummary -o DEF.db
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="o">[</span><span class="m">8500</span><span class="w"> </span><span class="m">8502</span>-8504<span class="w"> </span><span class="m">8507</span><span class="o">]</span><span class="w"> </span>_zf<span class="w"> </span>fit-8472<span class="w"> </span>noheader<span class="w"> </span>nosummary<span class="w"> </span>-o<span class="w"> </span>DEF.db
</pre></div>
</div>
<p>Using <code class="docutils literal notranslate"><span class="pre">8472_zf.msr</span></code> as first template, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> generates subsequent msr input files <code class="docutils literal notranslate"><span class="pre">8500_zf.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8502_zf.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8503_zf.msr</span></code>,
<code class="docutils literal notranslate"><span class="pre">8504_zf.msr</span></code>, and <code class="docutils literal notranslate"><span class="pre">8507_zf.msr</span></code>, calls <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> to perform a fit of these files and collects the results of the fits in the file <code class="docutils literal notranslate"><span class="pre">DEF.db</span></code>
<em>without</em> writing the DB file header or attempting to read additional information from the data files.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8595</span> <span class="m">8585</span> <span class="s2">&quot;&quot;</span> noheader fit-8472! -oGHI.dat data nosummary -k
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8595</span><span class="w"> </span><span class="m">8585</span><span class="w"> </span><span class="s2">&quot;&quot;</span><span class="w"> </span>noheader<span class="w"> </span>fit-8472!<span class="w"> </span>-oGHI.dat<span class="w"> </span>data<span class="w"> </span>nosummary<span class="w"> </span>-k
</pre></div>
</div>
<p>Using <code class="docutils literal notranslate"><span class="pre">8472.msr</span></code> as template for all runs, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> generates the msr input files <code class="docutils literal notranslate"><span class="pre">8595.msr</span></code> through <code class="docutils literal notranslate"><span class="pre">8585.msr</span></code>, calls <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> with
the option <code class="docutils literal notranslate"><span class="pre">--keep-mn2-ouput</span></code> to perform a fit of these files and collects the results of the fits in the column-structured ASCII file <code class="docutils literal notranslate"><span class="pre">GHI.dat</span></code>
<em>without</em> writing any file header or attempting to read additional information from the data files.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8472</span> <span class="m">8475</span> <span class="s2">&quot;&quot;</span> fit -o none
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8472</span><span class="w"> </span><span class="m">8475</span><span class="w"> </span><span class="s2">&quot;&quot;</span><span class="w"> </span>fit<span class="w"> </span>-o<span class="w"> </span>none
</pre></div>
</div>
<p>Take the <em>given</em> msr files <code class="docutils literal notranslate"><span class="pre">8472.msr</span></code> through <code class="docutils literal notranslate"><span class="pre">8475.msr</span></code> and call <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> <em>without</em> finally summarizing the results.</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8472</span> <span class="m">8475</span> _tf_h13 msr-8471!
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8472</span><span class="w"> </span><span class="m">8475</span><span class="w"> </span>_tf_h13<span class="w"> </span>msr-8471!
</pre></div>
</div>
<p>Using <code class="docutils literal notranslate"><span class="pre">8471_tf_h13.msr</span></code> as template for all runs, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> generates the msr input files <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code> through <code class="docutils literal notranslate"><span class="pre">8475_tf_h13.msr</span></code>.
<em>No fitting will be performed and no DB or ASCII output will be generated!</em></p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="o">[</span><span class="m">8472</span> <span class="m">8475</span>-8479<span class="o">]</span> _tf_h13 paramList <span class="m">1</span>-16 data -o bestData.dat
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="o">[</span><span class="m">8472</span><span class="w"> </span><span class="m">8475</span>-8479<span class="o">]</span><span class="w"> </span>_tf_h13<span class="w"> </span>paramList<span class="w"> </span><span class="m">1</span>-16<span class="w"> </span>data<span class="w"> </span>-o<span class="w"> </span>bestData.dat
</pre></div>
</div>
<p>Will collect the parameters 1 to 16 from the msr-files <code class="docutils literal notranslate"><span class="pre">8472_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8475_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8476_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8477_tf_h13.msr</span></code>, <code class="docutils literal notranslate"><span class="pre">8478_tf_h13.msr</span></code>,
and <code class="docutils literal notranslate"><span class="pre">8479_tf_h13.msr</span></code> and write these parameters into a column like output file <code class="docutils literal notranslate"><span class="pre">bestData.dat</span></code>.</p>
</div>
<div class="section" id="the-global-mode">
<span id="index-1"></span><h2>The Global Mode<a class="headerlink" href="#the-global-mode" title="Permalink to this headline"></a></h2>
</section>
<section id="the-global-mode">
<span id="index-1"></span><h2>The Global Mode<a class="headerlink" href="#the-global-mode" title="Link to this heading"></a></h2>
<p>Apart from all the options described <a class="reference internal" href="#msr2data-opt-param"><span class="std std-ref">above</span></a> there is another program option: <strong>global</strong>.
This option changes the general behavior of <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> in that way that instead of processing one msr file for each
run it combines all specified runs in <em>one single msr file</em> with the possibility to define common parameters for all
runs as well as run-specific parameters. When writing the obtained parameters to a DB file or a column-structured
ASCII file that single msr file is read and the parameters valid for each run are extracted. The global option can be
used in conjunction with any of the described invocations of <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> and together with all options stated <a class="reference internal" href="#msr2data-opt-param"><span class="std std-ref">above</span></a>.</p>
<div class="section" id="file-generation">
<h3>File Generation<a class="headerlink" href="#file-generation" title="Permalink to this headline"></a></h3>
<section id="file-generation">
<h3>File Generation<a class="headerlink" href="#file-generation" title="Link to this heading"></a></h3>
<p>The general idea of this mode is to generate a global msr file on the basis of a working single-run msr file. For this
purpose a single-run template containing information about common and run-specific parameters should be created. These
parameters are identified through their parameter names:</p>
<dl class="docutils">
<dt><strong>run-specific parameters</strong></dt>
<dd>these parameters are tagged with the current run number in the format <code class="docutils literal notranslate"><span class="pre">%0Xu</span></code>, <em>i.e.</em> <code class="docutils literal notranslate"><span class="pre">X</span></code> digits with leading zeros,
<dl class="simple">
<dt><strong>run-specific parameters</strong></dt><dd><p>these parameters are tagged with the current run number in the format <code class="docutils literal notranslate"><span class="pre">%0Xu</span></code>, <em>i.e.</em> <code class="docutils literal notranslate"><span class="pre">X</span></code> digits with leading zeros,
at the end of the parameter name, <em>e.g.</em> for a 4-digit-formatted run number <code class="docutils literal notranslate"><span class="pre">alpha0123</span></code> if the run number was 123 or
for a 8-digit-formatted run number <code class="docutils literal notranslate"><span class="pre">alpha00123456</span></code> if the run number was 123456. <code class="docutils literal notranslate"><span class="pre">X</span></code> has to be at least 4.</dd>
<dt><strong>common parameters</strong></dt>
<dd>all parameters that are not run specific</dd>
for a 8-digit-formatted run number <code class="docutils literal notranslate"><span class="pre">alpha00123456</span></code> if the run number was 123456. <code class="docutils literal notranslate"><span class="pre">X</span></code> has to be at least 4.</p>
</dd>
<dt><strong>common parameters</strong></dt><dd><p>all parameters that are not run specific</p>
</dd>
</dl>
<p>The <a class="reference internal" href="user-manual.html#msr-fitparameter-block"><span class="std std-ref">FITPARAMETER block</span></a> of an exemplary template file <code class="docutils literal notranslate"><span class="pre">8472_example.msr</span></code> could therefore look like:</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">FITPARAMETER</span>
@@ -385,7 +304,7 @@ for a 8-digit-formatted run number <code class="docutils literal notranslate"><s
<a class="reference internal" href="user-manual.html#msr-functions-block"><span class="std std-ref">FUNCTIONS</span></a> blocks. If however, those parameters are met, <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will try to substitute them by mapped parameters
and add them accordingly to the map contained in each <a class="reference internal" href="user-manual.html#msr-run-block"><span class="std std-ref">RUN block</span></a>.</p>
<p>When <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> is called to generate a global msr file, <em>e.g.</em></p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8471</span> <span class="m">8470</span> _example msr-8472 global
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8471</span><span class="w"> </span><span class="m">8470</span><span class="w"> </span>_example<span class="w"> </span>msr-8472<span class="w"> </span>global
</pre></div>
</div>
<p>a new msr file <code class="docutils literal notranslate"><span class="pre">8471+global_example.msr</span></code> is created. As can be seen in the example, the name of the global msr file always starts with the
@@ -414,35 +333,35 @@ followed by copies of the parameters specific to each run (in the specified orde
created — for each run as many as found for the template run.</p>
<p>During this reorganization all the affected parameter occurrences are changed accordingly!</p>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Please be aware of the fact that comments in the template msr file are <em>not</em> propagated to the newly generated global msr file!</p>
<p class="admonition-title">Note</p>
<p>Please be aware of the fact that comments in the template msr file are <em>not</em> propagated to the newly generated global msr file!</p>
</div>
</div>
<div class="section" id="parameter-extraction">
<span id="index-2"></span><h3>Parameter Extraction<a class="headerlink" href="#parameter-extraction" title="Permalink to this headline"></a></h3>
</section>
<section id="parameter-extraction">
<span id="index-2"></span><h3>Parameter Extraction<a class="headerlink" href="#parameter-extraction" title="Link to this heading"></a></h3>
<p>After fitting some model to the specified data the fit parameters can be extracted from the global msr file to a DB or column-structured ASCII file;
as usual this includes also parameters stored in the run data files or externally specified parameters given in a <a class="reference internal" href="#run-list-file-structure"><span class="std std-ref">run-list file</span></a>.
In order to reach this goal the global msr file has to obey certain rules:</p>
<ul class="simple">
<li>The order of the parameters has to match the one described above, meaning the common parameters are listed first followed by
<li><p>The order of the parameters has to match the one described above, meaning the common parameters are listed first followed by
the same number of parameters specific to each run tagged by the according run numbers at the end of the parameter names and
having the same order as the specified list of runs.</li>
<li>The RUN blocks have to be ordered according to the list of runs to be processed.</li>
having the same order as the specified list of runs.</p></li>
<li><p>The RUN blocks have to be ordered according to the list of runs to be processed.</p></li>
</ul>
<p>Following these rules which is achieved most easily by generating the global msr file using <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> as shown above the parameters can be extracted <em>e.g.</em> like</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8471</span> <span class="m">8470</span> _example global data -o globalFit.dat
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8471</span><span class="w"> </span><span class="m">8470</span><span class="w"> </span>_example<span class="w"> </span>global<span class="w"> </span>data<span class="w"> </span>-o<span class="w"> </span>globalFit.dat
</pre></div>
</div>
<p>This will read in the file <code class="docutils literal notranslate"><span class="pre">8471+global_example.msr</span></code>, extract for each run all relevant parameters from the msr file as well as
from the according data files (if available) and append all of them in columns to the ASCII file <code class="docutils literal notranslate"><span class="pre">globalFit.dat</span></code>.</p>
</div>
<div class="section" id="the-extended-global-mode">
<span id="index-3"></span><h3>The Extended Global Mode<a class="headerlink" href="#the-extended-global-mode" title="Permalink to this headline"></a></h3>
</section>
<section id="the-extended-global-mode">
<span id="index-3"></span><h3>The Extended Global Mode<a class="headerlink" href="#the-extended-global-mode" title="Link to this heading"></a></h3>
<p>If a new global input file is generated, it is also possible to do an automatic pre-analysis for each single run using the specified template first;
afterwards the run-specific parameters of these single-run msr files are collected into the global msr file. In special cases this might be useful
to obtain a better set of starting values for the parameters, however, in most cases it will not replace the “manual review” of the generated global
input file. The option is activated by choosing the keyword <strong>global+</strong>. For example</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8471</span> <span class="m">8470</span> _example global+ msr-8472
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8471</span><span class="w"> </span><span class="m">8470</span><span class="w"> </span>_example<span class="w"> </span>global+<span class="w"> </span>msr-8472
</pre></div>
</div>
<p>Here, <code class="docutils literal notranslate"><span class="pre">8472_example.msr</span></code> is first used as template to generate the file <code class="docutils literal notranslate"><span class="pre">8471-OneRunFit_example.msr</span></code>, then <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> is called for it, the result
@@ -452,115 +371,79 @@ produced — including the fit results of the <code class="docutils literal notr
explained before). The <strong>+[!]</strong> extension will be ignored, if no new global input file is generated.
The single run msr files are <em>not</em> deleted at the moment. The information contained in them might be useful for some people. Of course the data can also
be collected by <code class="docutils literal notranslate"><span class="pre">msr2data</span></code>. <em>E.g.</em> in order to produce a DB file <code class="docutils literal notranslate"><span class="pre">OneRunFits.db</span></code> one could call</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">8471</span> <span class="m">8470</span> -OneRunFit_example -o OneRunFits.db
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">8471</span><span class="w"> </span><span class="m">8470</span><span class="w"> </span>-OneRunFit_example<span class="w"> </span>-o<span class="w"> </span>OneRunFits.db
</pre></div>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Please be aware that the program in this mode <em>always</em> generates new single-run msr files and <em>always</em> calls <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> for them. In case there are
<p class="admonition-title">Note</p>
<p>Please be aware that the program in this mode <em>always</em> generates new single-run msr files and <em>always</em> calls <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> for them. In case there are
already single-run fits present, these cannot be used in conjunction with this option. The program on purpose behaves in this way in order to ensure
the file integrity and correct parameter order within these files.</p>
</div>
</div>
</div>
<div class="section" id="known-limitations">
<h2>Known Limitations<a class="headerlink" href="#known-limitations" title="Permalink to this headline"></a></h2>
</section>
</section>
<section id="known-limitations">
<h2>Known Limitations<a class="headerlink" href="#known-limitations" title="Link to this heading"></a></h2>
<ul class="simple">
<li>The indexing run number of the msr file has to be at the begin of every filename.</li>
<li>Within the data file name the <code class="docutils literal notranslate"><span class="pre">RUN#</span></code> has the format <code class="docutils literal notranslate"><span class="pre">%0Xu</span></code>, <em>i.e.</em> <code class="docutils literal notranslate"><span class="pre">X</span></code> digits with leading zeros, and has to be the rightmost number given in this
format in the file name. <code class="docutils literal notranslate"><span class="pre">X</span></code> has to be at least 4. The highest treatable run number is <span class="math notranslate nohighlight">\(2^{32}-1 = 4294967295\)</span>.</li>
<li>In order to keep <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> working properly the msr files should only contain <em>one</em> STATISTIC block at the end of the file and <em>one</em> FITPARAMETER block
right after the TITLE — <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> itself allows to have more creative msr files…</li>
<li>The msr-file generation from a template takes only care of runs given on the <em>first</em> line of a <code class="docutils literal notranslate"><span class="pre">RUN</span> <span class="pre">block</span></code>. <a class="reference internal" href="user-manual.html#msr-addrun"><span class="std std-ref">ADDRUN</span></a> statements are simply
<li><p>The indexing run number of the msr file has to be at the begin of every filename.</p></li>
<li><p>Within the data file name the <code class="docutils literal notranslate"><span class="pre">RUN#</span></code> has the format <code class="docutils literal notranslate"><span class="pre">%0Xu</span></code>, <em>i.e.</em> <code class="docutils literal notranslate"><span class="pre">X</span></code> digits with leading zeros, and has to be the rightmost number given in this
format in the file name. <code class="docutils literal notranslate"><span class="pre">X</span></code> has to be at least 4. The highest treatable run number is <span class="math notranslate nohighlight">\(2^{32}-1 = 4294967295\)</span>.</p></li>
<li><p>In order to keep <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> working properly the msr files should only contain <em>one</em> STATISTIC block at the end of the file and <em>one</em> FITPARAMETER block
right after the TITLE — <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> itself allows to have more creative msr files…</p></li>
<li><p>The msr-file generation from a template takes only care of runs given on the <em>first</em> line of a <code class="docutils literal notranslate"><span class="pre">RUN</span> <span class="pre">block</span></code>. <a class="reference internal" href="user-manual.html#msr-addrun"><span class="std std-ref">ADDRUN</span></a> statements are simply
copied! Since this is most probably <em>not</em> what one likes to do, it is suggested <em>not</em> to use the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span></code> and <code class="docutils literal notranslate"><span class="pre">msr-&lt;template&gt;</span></code> options if
ADDRUN statements were present in the template file.</li>
<li><code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will write only up to two successive empty lines in newly generated msr files. In case more subsequent empty lines are encountered in a template file,
these are not copied! Actually, this measure is not a limitation but has been introduced to keep the msr files in a reasonable shape.</li>
ADDRUN statements were present in the template file.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">msr2data</span></code> will write only up to two successive empty lines in newly generated msr files. In case more subsequent empty lines are encountered in a template file,
these are not copied! Actually, this measure is not a limitation but has been introduced to keep the msr files in a reasonable shape.</p></li>
</ul>
</div>
<div class="section" id="the-graphical-user-interface-for-msr2data-provided-by-musredit">
<h2>The Graphical User Interface for msr2data Provided by musredit<a class="headerlink" href="#the-graphical-user-interface-for-msr2data-provided-by-musredit" title="Permalink to this headline"></a></h2>
</section>
<section id="the-graphical-user-interface-for-msr2data-provided-by-musredit">
<h2>The Graphical User Interface for msr2data Provided by musredit<a class="headerlink" href="#the-graphical-user-interface-for-msr2data-provided-by-musredit" title="Link to this heading"></a></h2>
<p><a class="reference internal" href="musredit.html#musredit-sec"><span class="std std-ref">musredit</span></a>, designed especially for the manipulation of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> msr files and graphical front ends to <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>, offer an almost
self-explanatory graphical user interface to <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> depicted below:</p>
<img alt="_images/msr2data-GUI.svg" src="_images/msr2data-GUI.svg" /><ol class="arabic simple">
<li>and 2. Choose one of the ways to specify your list of runs as described under <a class="reference internal" href="#msr2data-basic-usage"><span class="std std-ref">basic usage</span></a>.</li>
<img alt="_images/msr2data-GUI.svg" src="_images/msr2data-GUI.svg" />
<ol class="arabic simple">
<li><p>and 2. Choose one of the ways to specify your list of runs as described under <a class="reference internal" href="#msr2data-basic-usage"><span class="std std-ref">basic usage</span></a>.</p></li>
</ol>
<ol class="arabic simple" start="3">
<li>Give the file extension here, <em>e.g.</em> <code class="docutils literal notranslate"><span class="pre">_zf</span></code> for files like <code class="docutils literal notranslate"><span class="pre">8472_zf.msr</span></code>. If the files do not have an extension this
field stays empty. <code class="docutils literal notranslate"><span class="pre">musredit</span></code> takes care of passing the “” to <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> as mentioned above.</li>
<li>Activates the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span></code> option if <code class="docutils literal notranslate"><span class="pre">&lt;template&gt;</span></code> is entered. In case the option <code class="docutils literal notranslate"><span class="pre">Chain</span> <span class="pre">Fit</span></code> is <em>not</em> set the
<li><p>Give the file extension here, <em>e.g.</em> <code class="docutils literal notranslate"><span class="pre">_zf</span></code> for files like <code class="docutils literal notranslate"><span class="pre">8472_zf.msr</span></code>. If the files do not have an extension this
field stays empty. <code class="docutils literal notranslate"><span class="pre">musredit</span></code> takes care of passing the “” to <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> as mentioned above.</p></li>
<li><p>Activates the <code class="docutils literal notranslate"><span class="pre">fit-&lt;template&gt;</span></code> option if <code class="docutils literal notranslate"><span class="pre">&lt;template&gt;</span></code> is entered. In case the option <code class="docutils literal notranslate"><span class="pre">Chain</span> <span class="pre">Fit</span></code> is <em>not</em> set the
given template will be used for the input-file generation for all runs to be fitted — otherwise the output of the first
fit serves as template for the second and so on. The template field stays empty if <em>no</em> fits should be performed!</li>
<li>Activates the <code class="docutils literal notranslate"><span class="pre">-o</span> <span class="pre">&lt;outputFileName&gt;</span></code> option if <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> is entered. If nothing is entered the default output file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> or <code class="docutils literal notranslate"><span class="pre">out.dat</span></code> is used.</li>
fit serves as template for the second and so on. The template field stays empty if <em>no</em> fits should be performed!</p></li>
<li><p>Activates the <code class="docutils literal notranslate"><span class="pre">-o</span> <span class="pre">&lt;outputFileName&gt;</span></code> option if <code class="docutils literal notranslate"><span class="pre">&lt;outputFileName&gt;</span></code> is entered. If nothing is entered the default output file <code class="docutils literal notranslate"><span class="pre">out.db</span></code> or <code class="docutils literal notranslate"><span class="pre">out.dat</span></code> is used.</p></li>
</ol>
<p>The options tags correspond essentially to the description in <a class="reference internal" href="#msr2data-opt-param"><span class="std std-ref">optional parameters</span></a>.</p>
</div>
</div>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="any2many.html" class="btn btn-neutral float-right" title="any2many - a Universal μSR-file-format converter" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="mupp.html" class="btn btn-neutral" title="mupp - μSR Parameter Plotter" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="mupp.html" class="btn btn-neutral float-left" title="mupp - μSR Parameter Plotter" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="any2many.html" class="btn btn-neutral float-right" title="any2many - a Universal μSR-file-format converter" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>mupp - μSR Parameter Plotter &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>mupp - μSR Parameter Plotter &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" href="msr2data.html" />
<link rel="prev" title="musredit: the GUI Based Interface to musrfit" href="musredit.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -110,70 +69,32 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>mupp - μSR Parameter Plotter</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">mupp - μSR Parameter Plotter</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/mupp.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="mupp-mgrsr-parameter-plotter">
<span id="mupp"></span><span id="index-0"></span><h1>mupp - μSR Parameter Plotter<a class="headerlink" href="#mupp-mgrsr-parameter-plotter" title="Permalink to this headline"></a></h1>
<section id="mupp-mgrsr-parameter-plotter">
<span id="mupp"></span><span id="index-0"></span><h1>mupp - μSR Parameter Plotter<a class="headerlink" href="#mupp-mgrsr-parameter-plotter" title="Link to this heading"></a></h1>
<p><code class="docutils literal notranslate"><span class="pre">mupp</span></code> is a little helper program which allows to quickly plot a collection of msr-file parameters,
as for instance generated by <a class="reference internal" href="msr2data.html#msr2data"><span class="std std-ref">msr2data</span></a>. It can handle <code class="docutils literal notranslate"><span class="pre">db</span></code>- and <code class="docutils literal notranslate"><span class="pre">dat</span></code>-files.
Also a collection of <code class="docutils literal notranslate"><span class="pre">msr</span></code>-files can be invoked. <code class="docutils literal notranslate"><span class="pre">mupp</span></code> is heavily inspired by μView (see
@@ -184,64 +105,54 @@ The <code class="docutils literal notranslate"><span class="pre">mupp</span></co
A run is analyzed by a number of parameters (defined in the msr-files), and complemented by
additional physical parameters as the temperature, magnetic field, implantation energy, etc.
Hence parameters can be seen as vectors and can be plot against each other.</p>
<div class="section" id="the-graphical-user-interface">
<span id="index-1"></span><h2>The Graphical User Interface<a class="headerlink" href="#the-graphical-user-interface" title="Permalink to this headline"></a></h2>
<section id="the-graphical-user-interface">
<span id="index-1"></span><h2>The Graphical User Interface<a class="headerlink" href="#the-graphical-user-interface" title="Link to this heading"></a></h2>
<p>A typical setting could look like this</p>
<img alt="_images/mupp-gui-0.svg" src="_images/mupp-gui-0.svg" /><ol class="arabic">
<li><p class="first">shows the list of loaded collections. A collection is defined as <code class="docutils literal notranslate"><span class="pre">db</span></code>- or <code class="docutils literal notranslate"><span class="pre">dat</span></code>-file (typically the
<img alt="_images/mupp-gui-0.svg" src="_images/mupp-gui-0.svg" />
<ol class="arabic">
<li><p>shows the list of loaded collections. A collection is defined as <code class="docutils literal notranslate"><span class="pre">db</span></code>- or <code class="docutils literal notranslate"><span class="pre">dat</span></code>-file (typically the
output from <a class="reference internal" href="msr2data.html#msr2data"><span class="std std-ref">msr2data</span></a>). If you call the open-dialog and select a collection of
<code class="docutils literal notranslate"><span class="pre">msr</span></code>-files, <code class="docutils literal notranslate"><span class="pre">mupp</span></code> will call <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> and tries to generate a collection on-the-fly.</p>
</li>
<li><p class="first">in this list, the data-tags of the currently selected collection is presented. The data-tags can be
<code class="docutils literal notranslate"><span class="pre">msr</span></code>-files, <code class="docutils literal notranslate"><span class="pre">mupp</span></code> will call <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> and tries to generate a collection on-the-fly.</p></li>
<li><p>in this list, the data-tags of the currently selected collection is presented. The data-tags can be
directly dragged over to the <code class="docutils literal notranslate"><span class="pre">x</span></code>- and <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis list. Another way is to select the data-tag
wished and click <code class="docutils literal notranslate"><span class="pre">add</span> <span class="pre">X</span></code> to add the selected data-tag to the <code class="docutils literal notranslate"><span class="pre">x</span></code>-axis list. Analogous it is done
for the <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">x</span></code>-axis list. The labels are followed by <code class="docutils literal notranslate"><span class="pre">(-X-)</span></code> where the number <code class="docutils literal notranslate"><span class="pre">X</span></code> corresponds to the
selection it corresponds to. The numbering of the collection is as given in the collection list.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">y</span></code>-axis list. The labels are followed by <code class="docutils literal notranslate"><span class="pre">(-X-)</span></code> where the number <code class="docutils literal notranslate"><span class="pre">X</span></code> corresponds to the
selection it corresponds to. The numbering of the collection is as given in the collection list.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">add</span> <span class="pre">X</span></code> allows to add the currently selected data-tag to the <code class="docutils literal notranslate"><span class="pre">x</span></code>-axis list.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">add</span> <span class="pre">Y</span></code> allows to add the currently selected data-tag to the <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis list.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">remove</span> <span class="pre">X</span></code> will remove the selected <code class="docutils literal notranslate"><span class="pre">x</span></code>-axis tag.</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">remove</span> <span class="pre">Y</span></code> will remove the selected <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis tag.</p>
</li>
<li><p class="first">Often one would like to compare trends of different settings. In the above example each collections
for the <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">x</span></code>-axis list. The labels are followed by <code class="docutils literal notranslate"><span class="pre">(-X-)</span></code> where the number <code class="docutils literal notranslate"><span class="pre">X</span></code> corresponds to the
selection it corresponds to. The numbering of the collection is as given in the collection list.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">y</span></code>-axis list. The labels are followed by <code class="docutils literal notranslate"><span class="pre">(-X-)</span></code> where the number <code class="docutils literal notranslate"><span class="pre">X</span></code> corresponds to the
selection it corresponds to. The numbering of the collection is as given in the collection list.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">add</span> <span class="pre">X</span></code> allows to add the currently selected data-tag to the <code class="docutils literal notranslate"><span class="pre">x</span></code>-axis list.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">add</span> <span class="pre">Y</span></code> allows to add the currently selected data-tag to the <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis list.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">remove</span> <span class="pre">X</span></code> will remove the selected <code class="docutils literal notranslate"><span class="pre">x</span></code>-axis tag.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">remove</span> <span class="pre">Y</span></code> will remove the selected <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis tag.</p></li>
<li><p>Often one would like to compare trends of different settings. In the above example each collections
holds an energy scans for a given temperature. Each collection is measured at a different temperature.
Now, instead of adding <code class="docutils literal notranslate"><span class="pre">x</span></code>- and <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis tags for each collection, you can do the following:
you add <code class="docutils literal notranslate"><span class="pre">x</span></code>- and <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis data-tags for the first collection. Afterwards you select all the other
collections of interest and click on <code class="docutils literal notranslate"><span class="pre">Add</span> <span class="pre">Ditto</span></code>. <code class="docutils literal notranslate"><span class="pre">mupp</span></code> will then add the corresponding
<code class="docutils literal notranslate"><span class="pre">x</span></code>- and <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis data-tags accordingly. This is less error prone and quicker!</p>
</li>
<li><p class="first">Clicking the <code class="docutils literal notranslate"><span class="pre">Plot</span></code> button will invoke <code class="docutils literal notranslate"><span class="pre">mupp_plot</span></code> (a <code class="docutils literal notranslate"><span class="pre">ROOT</span></code> based application) which will
<code class="docutils literal notranslate"><span class="pre">x</span></code>- and <code class="docutils literal notranslate"><span class="pre">y</span></code>-axis data-tags accordingly. This is less error prone and quicker!</p></li>
<li><p>Clicking the <code class="docutils literal notranslate"><span class="pre">Plot</span></code> button will invoke <code class="docutils literal notranslate"><span class="pre">mupp_plot</span></code> (a <code class="docutils literal notranslate"><span class="pre">ROOT</span></code> based application) which will
present the data, as shown here</p>
<a class="reference internal image-reference" href="_images/mupp-plot-0.svg"><img alt="_images/mupp-plot-0.svg" height="600px" src="_images/mupp-plot-0.svg" /></a>
<a class="reference internal image-reference" href="_images/mupp-plot-0.svg"><img alt="_images/mupp-plot-0.svg" src="_images/mupp-plot-0.svg" style="height: 600px;" />
</a>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">Remove</span> <span class="pre">Collection</span></code>: will remove the selected collection</p>
</li>
<li><p class="first"><code class="docutils literal notranslate"><span class="pre">Refresh</span> <span class="pre">Collection</span></code>: will reload the collection (<code class="docutils literal notranslate"><span class="pre">db</span></code>- or <code class="docutils literal notranslate"><span class="pre">dat</span></code>-file). This is often useful
during beamtime where the collection is growing run-by-run.</p>
</li>
<li><p class="first">Command history window.</p>
</li>
<li><p class="first">This is the script command line. Currently it allows to perform the tasks without mouse gambling.
<li><p><code class="docutils literal notranslate"><span class="pre">Remove</span> <span class="pre">Collection</span></code>: will remove the selected collection</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">Refresh</span> <span class="pre">Collection</span></code>: will reload the collection (<code class="docutils literal notranslate"><span class="pre">db</span></code>- or <code class="docutils literal notranslate"><span class="pre">dat</span></code>-file). This is often useful
during beamtime where the collection is growing run-by-run.</p></li>
<li><p>Command history window.</p></li>
<li><p>This is the script command line. Currently it allows to perform the tasks without mouse gambling.
In the future much more commands are planed. See the <code class="docutils literal notranslate"><span class="pre">Help</span> <span class="pre">/</span> <span class="pre">Cmd's</span></code> for the currently available
commands.</p>
</li>
commands.</p></li>
</ol>
<div class="section" id="define-variable-dialog">
<h3>Define Variable Dialog<a class="headerlink" href="#define-variable-dialog" title="Permalink to this headline"></a></h3>
<img alt="_images/mupp-add-var.svg" src="_images/mupp-add-var.svg" /><ol class="arabic simple">
<li>Variable text edit window.</li>
<li>Collection link window.</li>
<li>Shows the parameters of the selected collection.</li>
<li>Check if the variable/error variable from the edit window is valid.</li>
<li>Add the variable to the selected collection(s) if the parsing is successful.</li>
<section id="define-variable-dialog">
<h3>Define Variable Dialog<a class="headerlink" href="#define-variable-dialog" title="Link to this heading"></a></h3>
<img alt="_images/mupp-add-var.svg" src="_images/mupp-add-var.svg" />
<ol class="arabic simple">
<li><p>Variable text edit window.</p></li>
<li><p>Collection link window.</p></li>
<li><p>Shows the parameters of the selected collection.</p></li>
<li><p>Check if the variable/error variable from the edit window is valid.</p></li>
<li><p>Add the variable to the selected collection(s) if the parsing is successful.</p></li>
</ol>
<p>A variable defined here is a mathematical expression defined by parameters of loaded collections.
Since a parameter also has an associated error, also newly defined variables <strong>always</strong> need
@@ -249,48 +160,47 @@ to be defined together with a corresponding error variable. If the name of a var
as <code class="docutils literal notranslate"><span class="pre">SigmaSC_10</span></code> (see the above snapshot), the error variable need to be named as <code class="docutils literal notranslate"><span class="pre">SigmaSC_10Err</span></code>.</p>
<p>Currently the following mathematical functions are defined: <code class="docutils literal notranslate"><span class="pre">max</span></code>, <code class="docutils literal notranslate"><span class="pre">min</span></code>, <code class="docutils literal notranslate"><span class="pre">abs</span></code>, <code class="docutils literal notranslate"><span class="pre">sin</span></code>, <code class="docutils literal notranslate"><span class="pre">cos</span></code>,
<code class="docutils literal notranslate"><span class="pre">tan</span></code>, <code class="docutils literal notranslate"><span class="pre">exp</span></code>, <code class="docutils literal notranslate"><span class="pre">log</span></code>, <code class="docutils literal notranslate"><span class="pre">ln</span></code>, <code class="docutils literal notranslate"><span class="pre">pow</span></code>.</p>
</div>
</div>
<div class="section" id="the-scripting-interface">
<span id="index-2"></span><h2>The Scripting Interface<a class="headerlink" href="#the-scripting-interface" title="Permalink to this headline"></a></h2>
</section>
</section>
<section id="the-scripting-interface">
<span id="index-2"></span><h2>The Scripting Interface<a class="headerlink" href="#the-scripting-interface" title="Link to this heading"></a></h2>
<p><code class="docutils literal notranslate"><span class="pre">mupp</span></code> can also be operated in a scripting like manner. The use cases are plot updates during run time,
or web-based interaction which requests figures. A script is invoked by the command line option <code class="docutils literal notranslate"><span class="pre">-s</span></code> (see
<a class="reference internal" href="#mupp-usage"><span class="std std-ref">mupp command line summary</span></a>. Currently the following scripting commands are available:</p>
<dl class="docutils">
<dt><strong>loadPath &lt;dir&gt;</strong></dt>
<dd>set the load path to <code class="docutils literal notranslate"><span class="pre">&lt;dir&gt;</span></code>. Bash variables like $HOME are accepted. This is the path where to look for collection files (<code class="docutils literal notranslate"><span class="pre">db</span></code>- and <code class="docutils literal notranslate"><span class="pre">dat</span></code>-files).</dd>
<dt><strong>load &lt;coll&gt;</strong></dt>
<dd>will load the collection <code class="docutils literal notranslate"><span class="pre">&lt;coll&gt;</span></code>.</dd>
<dt><strong>selectAll</strong></dt>
<dd>will select all loaded collections. This means every plot of variable x/y will be carried out to <em>ALL</em> collections.</dd>
<dt><strong>select &lt;nn&gt;</strong></dt>
<dd>selects collection <code class="docutils literal notranslate"><span class="pre">&lt;nn&gt;</span></code>, where <code class="docutils literal notranslate"><span class="pre">&lt;nn&gt;</span></code> is either the <em>number</em> of the collections, or its <em>name</em>, <em>e.g.</em>
select YBCO-40nm-T5K-FC150mT-Escan.db.</dd>
<dt><strong>x &lt;label&gt;</strong></dt>
<dd>add <code class="docutils literal notranslate"><span class="pre">&lt;label&gt;</span></code> as a <em>x</em>-variable. Only <em>one</em> is allowed.</dd>
<dt><strong>y &lt;label(s)&gt;</strong></dt>
<dd>add <code class="docutils literal notranslate"><span class="pre">&lt;label(s)&gt;</span></code> as <em>y</em>-variable. <em>Multiple</em> labels are possible.</dd>
<dt><strong>norm</strong></dt>
<dd>this will normalize all the <em>y</em>-variables by their maximum.</dd>
<dt><strong>savePath &lt;dir&gt;</strong></dt>
<dd>set the save path to <code class="docutils literal notranslate"><span class="pre">&lt;dir&gt;</span></code>. The place where the macros, and/or the plot output will be saved.</dd>
<dt><strong>plot &lt;fln&gt;</strong></dt>
<dd>where <code class="docutils literal notranslate"><span class="pre">&lt;fln&gt;</span></code> is the file name with extension under which the plot should be saved.</dd>
<dt><strong>macro &lt;fln&gt;</strong></dt>
<dd>where <code class="docutils literal notranslate"><span class="pre">&lt;fln&gt;</span></code> is the file name under which the root macro should be saved.</dd>
<dt><strong>var &lt;var_name&gt; = &lt;expr&gt;</strong></dt>
<dd><p class="first">defines a variable.
<dl>
<dt><strong>loadPath &lt;dir&gt;</strong></dt><dd><p>set the load path to <code class="docutils literal notranslate"><span class="pre">&lt;dir&gt;</span></code>. Bash variables like $HOME are accepted. This is the path where to look for collection files (<code class="docutils literal notranslate"><span class="pre">db</span></code>- and <code class="docutils literal notranslate"><span class="pre">dat</span></code>-files).</p>
</dd>
<dt><strong>load &lt;coll&gt;</strong></dt><dd><p>will load the collection <code class="docutils literal notranslate"><span class="pre">&lt;coll&gt;</span></code>.</p>
</dd>
<dt><strong>selectAll</strong></dt><dd><p>will select all loaded collections. This means every plot of variable x/y will be carried out to <em>ALL</em> collections.</p>
</dd>
<dt><strong>select &lt;nn&gt;</strong></dt><dd><p>selects collection <code class="docutils literal notranslate"><span class="pre">&lt;nn&gt;</span></code>, where <code class="docutils literal notranslate"><span class="pre">&lt;nn&gt;</span></code> is either the <em>number</em> of the collections, or its <em>name</em>, <em>e.g.</em>
select YBCO-40nm-T5K-FC150mT-Escan.db.</p>
</dd>
<dt><strong>x &lt;label&gt;</strong></dt><dd><p>add <code class="docutils literal notranslate"><span class="pre">&lt;label&gt;</span></code> as a <em>x</em>-variable. Only <em>one</em> is allowed.</p>
</dd>
<dt><strong>y &lt;label(s)&gt;</strong></dt><dd><p>add <code class="docutils literal notranslate"><span class="pre">&lt;label(s)&gt;</span></code> as <em>y</em>-variable. <em>Multiple</em> labels are possible.</p>
</dd>
<dt><strong>norm</strong></dt><dd><p>this will normalize all the <em>y</em>-variables by their maximum.</p>
</dd>
<dt><strong>savePath &lt;dir&gt;</strong></dt><dd><p>set the save path to <code class="docutils literal notranslate"><span class="pre">&lt;dir&gt;</span></code>. The place where the macros, and/or the plot output will be saved.</p>
</dd>
<dt><strong>plot &lt;fln&gt;</strong></dt><dd><p>where <code class="docutils literal notranslate"><span class="pre">&lt;fln&gt;</span></code> is the file name with extension under which the plot should be saved.</p>
</dd>
<dt><strong>macro &lt;fln&gt;</strong></dt><dd><p>where <code class="docutils literal notranslate"><span class="pre">&lt;fln&gt;</span></code> is the file name under which the root macro should be saved.</p>
</dd>
<dt><strong>var &lt;var_name&gt; = &lt;expr&gt;</strong></dt><dd><p>defines a variable.
&lt;expr&gt; is a mathematical expression where collection variables are addressed
via the $, e.g. <code class="docutils literal notranslate"><span class="pre">dataT</span></code> is addressed by <code class="docutils literal notranslate"><span class="pre">$dataT</span></code>, etc. An example:</p>
<p><code class="docutils literal notranslate"><span class="pre">var</span> <span class="pre">invT</span> <span class="pre">=</span> <span class="pre">1000.0</span> <span class="pre">/</span> <span class="pre">$dataT</span></code></p>
<p>Each variable has to be accompanied by its error variable. An error variable
is defined by the <code class="docutils literal notranslate"><span class="pre">&lt;var_name&gt;</span></code> followed by <code class="docutils literal notranslate"><span class="pre">Err</span></code>
For the above example the error variable is</p>
<p class="last"><code class="docutils literal notranslate"><span class="pre">var</span> <span class="pre">invTErr</span> <span class="pre">=</span> <span class="pre">$invT</span> <span class="pre">*</span> <span class="pre">$dataTErr</span> <span class="pre">/</span> <span class="pre">$dataT</span></code></p>
<p><code class="docutils literal notranslate"><span class="pre">var</span> <span class="pre">invTErr</span> <span class="pre">=</span> <span class="pre">$invT</span> <span class="pre">*</span> <span class="pre">$dataTErr</span> <span class="pre">/</span> <span class="pre">$dataT</span></code></p>
</dd>
<dt><strong>col &lt;nn&gt; : &lt;var_name&gt;</strong></dt><dd><p>links &lt;var_name&gt; to the collection &lt;nn&gt;, where &lt;nn&gt; is the number of the
collection as defined by the order of load, starting with 0.</p>
</dd>
<dt><strong>col &lt;nn&gt; : &lt;var_name&gt;</strong></dt>
<dd>links &lt;var_name&gt; to the collection &lt;nn&gt;, where &lt;nn&gt; is the number of the
collection as defined by the order of load, starting with 0.</dd>
</dl>
<p>An example script file <code class="docutils literal notranslate"><span class="pre">sigmaSC-vs-temp.txt</span></code> might look like this:</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span># This is a comment
@@ -338,9 +248,9 @@ macro SigmaSCVsTemp.C
# end
</pre></div>
</div>
</div>
<div class="section" id="the-usage-summary">
<span id="mupp-usage"></span><span id="index-3"></span><h2>The Usage Summary<a class="headerlink" href="#the-usage-summary" title="Permalink to this headline"></a></h2>
</section>
<section id="the-usage-summary">
<span id="mupp-usage"></span><span id="index-3"></span><h2>The Usage Summary<a class="headerlink" href="#the-usage-summary" title="Link to this heading"></a></h2>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>usage: mupp [OPTIONS] [[--path &lt;fit-param-path&gt;] &lt;fit-param-file-names&gt;]
OPTIONS:
@@ -384,73 +294,36 @@ SCRIPT COMMANDS:
by the order of load, starting with 0.
</pre></div>
</div>
</div>
</div>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="msr2data.html" class="btn btn-neutral float-right" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="musredit.html" class="btn btn-neutral" title="musredit: the GUI Based Interface to musrfit" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="musredit.html" class="btn btn-neutral float-left" title="musredit: the GUI Based Interface to musrfit" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="msr2data.html" class="btn btn-neutral float-right" title="msr2data - A Program for Automatically Processing Multiple musrfit msr Files" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -1,88 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Search &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Search &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<script src="_static/searchtools.js"></script>
<script src="_static/language_data.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="#" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="#" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul>
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -100,71 +61,33 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Search</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Search</li>
<li class="wy-breadcrumbs-aside">
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<noscript>
<div id="fallback" class="admonition warning">
<p class="last">
Please activate JavaScript to enable the search
functionality.
Please activate JavaScript to enable the search functionality.
</p>
</div>
</noscript>
@@ -175,69 +98,37 @@
</div>
</div>
</div>
<footer>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 09, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/searchtools.js"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});
</script>
<script type="text/javascript">
<script>
jQuery(function() { Search.loadIndex("searchindex.js"); });
</script>
<script type="text/javascript" id="searchindexloader"></script>
<script id="searchindexloader"></script>

File diff suppressed because one or more lines are too long

View File

@@ -1,90 +1,49 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Setting up musrfit / DKS: High Speed Fitting with GPUs &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Setting up musrfit / DKS: High Speed Fitting with GPUs &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="musredit: the GUI Based Interface to musrfit" href="musredit.html" />
<link rel="prev" title="Setting up musrfit on Different Platforms" href="setup-standard.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -121,70 +80,32 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> / <code class="docutils literal notranslate"><span class="pre">DKS</span></code>: High Speed Fitting with GPUs</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Setting up <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> / <code class="docutils literal notranslate"><span class="pre">DKS</span></code>: High Speed Fitting with GPUs</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/setup-dks.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="setting-up-musrfit-dks-high-speed-fitting-with-gpu-s">
<span id="setup-dks"></span><span id="index-0"></span><h1>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> / <code class="docutils literal notranslate"><span class="pre">DKS</span></code>: High Speed Fitting with GPUs<a class="headerlink" href="#setting-up-musrfit-dks-high-speed-fitting-with-gpu-s" title="Permalink to this headline"></a></h1>
<section id="setting-up-musrfit-dks-high-speed-fitting-with-gpu-s">
<span id="setup-dks"></span><span id="index-0"></span><h1>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> / <code class="docutils literal notranslate"><span class="pre">DKS</span></code>: High Speed Fitting with GPUs<a class="headerlink" href="#setting-up-musrfit-dks-high-speed-fitting-with-gpu-s" title="Link to this heading"></a></h1>
<p>In the years 2016/2017 we explored ways to speed up current fitting frameworks, especially <code class="docutils literal notranslate"><span class="pre">musrfit.</span></code>
This allows now to analyze histogram sets of high field spectrometers like <code class="docutils literal notranslate"><span class="pre">HAL-9500</span></code> at PSI without
the <em>error-prone</em> RRF fitting (see U. Locans and A. Suter,
@@ -195,37 +116,37 @@ allows Apple macOS users to speed up their fitting code on the CPU. Currently it
to get <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> multi-threaded under macOS since Apple doesnt be default support <code class="docutils literal notranslate"><span class="pre">OpenMP</span></code>. <code class="docutils literal notranslate"><span class="pre">DKS</span></code>
enables <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> to utilize <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> instead which is present on macOS by default.</p>
<div class="admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">Before you run into the shop to buy a gamer graphic card or a Tesla card, make sure that you have an
<p class="admonition-title">Warning</p>
<p>Before you run into the shop to buy a gamer graphic card or a Tesla card, make sure that you have an
appropriate server with a sufficiently strong power supply!</p>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">However, the current <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> version doesnt yet support all theory functions on the GPU.
<p class="admonition-title">Note</p>
<p>However, the current <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> version doesnt yet support all theory functions on the GPU.
In case the theory function is not yet available for the GPU, <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> will fall back to the CPU implementation.</p>
</div>
<p>Conceptually the setup of <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> is as following:</p>
<ol class="arabic simple">
<li>install the latest hardware driver for your graphic card.</li>
<li>install the GPU SDK which enables number crunching (<code class="docutils literal notranslate"><span class="pre">CUDA</span></code> for NVIDIA, <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> for AMD)</li>
<li>install <code class="docutils literal notranslate"><span class="pre">DKS</span></code></li>
<li>install the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> version which is <code class="docutils literal notranslate"><span class="pre">DKS</span></code> ready</li>
<li><p>install the latest hardware driver for your graphic card.</p></li>
<li><p>install the GPU SDK which enables number crunching (<code class="docutils literal notranslate"><span class="pre">CUDA</span></code> for NVIDIA, <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> for AMD)</p></li>
<li><p>install <code class="docutils literal notranslate"><span class="pre">DKS</span></code></p></li>
<li><p>install the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> version which is <code class="docutils literal notranslate"><span class="pre">DKS</span></code> ready</p></li>
</ol>
<p>In the following the description for the installation of <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for the following systems will be discussed in some more detail:</p>
<ul class="simple">
<li>NVIDIA Tesla K40c</li>
<li>AMD Graphic Card (Radeon R9 390X)</li>
<li>macOS in order to get <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> support</li>
<li><p>NVIDIA Tesla K40c</p></li>
<li><p>AMD Graphic Card (Radeon R9 390X)</p></li>
<li><p>macOS in order to get <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> support</p></li>
</ul>
<p>The usage of <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> with GPU acceleration and <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> support is described in the
<a class="reference internal" href="user-manual.html#user-manual"><span class="std std-ref">User manual of the μSR data analysis software musrfit</span></a>. The additional
<code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> are found <a class="reference internal" href="user-manual.html#msr-commands-block-dks"><span class="std std-ref">here</span></a>.</p>
<div class="section" id="setting-up-musrfit-dks-for-a-tesla-k40c-nvidia">
<span id="index-1"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for a Tesla K40c (NVIDIA)<a class="headerlink" href="#setting-up-musrfit-dks-for-a-tesla-k40c-nvidia" title="Permalink to this headline"></a></h2>
<section id="setting-up-musrfit-dks-for-a-tesla-k40c-nvidia">
<span id="index-1"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for a Tesla K40c (NVIDIA)<a class="headerlink" href="#setting-up-musrfit-dks-for-a-tesla-k40c-nvidia" title="Link to this heading"></a></h2>
<p>It is assumed that the Tesla K40c is already physically installed on your system. For now I only
will discuss to set it up for a Linux based system. In order to check that your operating systems
see the card, enter the following command in the terminal:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ lspci <span class="p">|</span> grep NVIDIA
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>lspci<span class="w"> </span><span class="p">|</span><span class="w"> </span>grep<span class="w"> </span>NVIDIA
</pre></div>
</div>
<p>The response should look something like</p>
@@ -233,100 +154,100 @@ see the card, enter the following command in the terminal:</p>
</pre></div>
</div>
<p>which means that the OS physically recognizes your card.</p>
<div class="section" id="driver-installation-for-the-tesla-k40c">
<h3>Driver Installation for the Tesla K40c<a class="headerlink" href="#driver-installation-for-the-tesla-k40c" title="Permalink to this headline"></a></h3>
<section id="driver-installation-for-the-tesla-k40c">
<h3>Driver Installation for the Tesla K40c<a class="headerlink" href="#driver-installation-for-the-tesla-k40c" title="Link to this heading"></a></h3>
<p>Next, you will need to download and install the driver for your card. Select the proper operating system,
card, etc. from the <a class="reference external" href="http://www.nvidia.com/Download/index.aspx?lang=en-us">NVIDIA download center</a>. At PSI
we are running currently Red Hat Enterprise Linux 7.x (RHEL) for which we will get a <code class="docutils literal notranslate"><span class="pre">rpm</span></code> (something like
<code class="docutils literal notranslate"><span class="pre">nvidia-diag-driver-local-repo-rhel7-375.66-1.x86_64.rpm</span></code>). Install it and make sure there is no conflict
with the nouveau driver of the system.</p>
</div>
<div class="section" id="installation-of-cuda">
<span id="index-2"></span><h3>Installation of CUDA<a class="headerlink" href="#installation-of-cuda" title="Permalink to this headline"></a></h3>
</section>
<section id="installation-of-cuda">
<span id="index-2"></span><h3>Installation of CUDA<a class="headerlink" href="#installation-of-cuda" title="Link to this heading"></a></h3>
<p>Download the <a class="reference external" href="https://developer.nvidia.com/cuda-downloads">CUDA SDK</a> form NVIDIA for your system. Again,
for the RHEL 7.x this is an <code class="docutils literal notranslate"><span class="pre">rpm</span></code>. After the installation of the rpm you should reboot your machine.
Afterwards you are ready for the installation of <code class="docutils literal notranslate"><span class="pre">DKS</span></code>.</p>
</div>
<div class="section" id="installation-of-dks">
<span id="index-3"></span><h3>Installation of DKS<a class="headerlink" href="#installation-of-dks" title="Permalink to this headline"></a></h3>
</section>
<section id="installation-of-dks">
<span id="index-3"></span><h3>Installation of DKS<a class="headerlink" href="#installation-of-dks" title="Link to this heading"></a></h3>
<p>For the following list of commands the <code class="docutils literal notranslate"><span class="pre">'$'</span></code> will be given as the command prompt. <em>Do not enter it!</em>
Also some comments will be added starting with a <code class="docutils literal notranslate"><span class="pre">'#'</span></code> which can be omitted. They are only there to
explain what is going on. <code class="docutils literal notranslate"><span class="pre">DKS</span></code> stands for Dynamical Kernel Scheduler and provides a thin interface
allowing host applications to incorporate GPUs and other hardware accelerators.</p>
<p>Details can be found in the papers listed <a class="reference internal" href="cite.html#cite"><span class="std std-ref">here</span></a>, or on the <a class="reference external" href="https://gitlab.psi.ch/uldis_l/DKS/wikis/home">DKS wiki page</a>.</p>
<p>Details can be found in the papers listed <a class="reference internal" href="cite.html#cite"><span class="std std-ref">here</span></a>.</p>
<p>In brief the installation should be something like this:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="c1"># go to whatever directory you would like to clone/install DKS</span>
<span class="c1"># For macOS DKS will likely to got to $HOME/Applications to be consistent with the musrfit docu for macOS</span>
$ <span class="nb">cd</span> <span class="nv">$HOME</span>/Apps
$ git clone https://gitlab.psi.ch/uldis_l/DKS.git
$ <span class="nb">cd</span> DKS
$ mkdir build
$ <span class="nb">cd</span> build
$ cmake ../ -DENABLE_MUSR<span class="o">=</span><span class="m">1</span> -DCMAKE_INSTALL_PREFIX<span class="o">=</span>../exec
$ cmake --build ./ --clean-first
$ make install
$<span class="w"> </span><span class="nb">cd</span><span class="w"> </span><span class="nv">$HOME</span>/Apps
$<span class="w"> </span>git<span class="w"> </span>clone<span class="w"> </span>git://gitea.psi.ch:LMU/DKS.git
$<span class="w"> </span><span class="nb">cd</span><span class="w"> </span>DKS
$<span class="w"> </span>mkdir<span class="w"> </span>build
$<span class="w"> </span><span class="nb">cd</span><span class="w"> </span>build
$<span class="w"> </span>cmake<span class="w"> </span>../<span class="w"> </span>-DENABLE_MUSR<span class="o">=</span><span class="m">1</span><span class="w"> </span>-DCMAKE_INSTALL_PREFIX<span class="o">=</span>../exec
$<span class="w"> </span>cmake<span class="w"> </span>--build<span class="w"> </span>./<span class="w"> </span>--clean-first
$<span class="w"> </span>make<span class="w"> </span>install
</pre></div>
</div>
<p>Since <code class="docutils literal notranslate"><span class="pre">DKS</span></code> is installed in a non-standard path, a couple of additional small steps are required.
This will be different for Linux compared to macOS.</p>
<p>For <strong>Linux:</strong></p>
<p>add the <code class="docutils literal notranslate"><span class="pre">DKS</span></code> library path to <code class="docutils literal notranslate"><span class="pre">/etc/ld.so.conf.d/musrfit-x86_64.conf</span></code> and execute as super user</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ /sbin/ldconfig
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>/sbin/ldconfig
</pre></div>
</div>
<p>For <strong>macOS:</strong></p>
<p>add the <code class="docutils literal notranslate"><span class="pre">DKS</span></code> path to <code class="docutils literal notranslate"><span class="pre">$HOME/.profile</span></code>:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="nb">export</span> <span class="nv">DKS</span><span class="o">=</span><span class="nv">$HOME</span>/Applications/DKS/exec
<span class="nb">export</span> <span class="nv">LD_LIBRARY_PATH</span><span class="o">=</span><span class="nv">$DKS</span>/lib:<span class="nv">$LD_LIBRARY_PATH</span>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="nb">export</span><span class="w"> </span><span class="nv">DKS</span><span class="o">=</span><span class="nv">$HOME</span>/Applications/DKS/exec
<span class="nb">export</span><span class="w"> </span><span class="nv">LD_LIBRARY_PATH</span><span class="o">=</span><span class="nv">$DKS</span>/lib:<span class="nv">$LD_LIBRARY_PATH</span>
launchctl setenv DKS <span class="nv">$DKS</span>
launchctl setenv LD_LIBRARY_PATH <span class="nv">$LD_LIBRARY_PATH</span>
launchctl<span class="w"> </span>setenv<span class="w"> </span>DKS<span class="w"> </span><span class="nv">$DKS</span>
launchctl<span class="w"> </span>setenv<span class="w"> </span>LD_LIBRARY_PATH<span class="w"> </span><span class="nv">$LD_LIBRARY_PATH</span>
</pre></div>
</div>
</div>
<div class="section" id="installation-of-musrfit-for-dks">
<span id="musrfit-dks-install"></span><h3>Installation of musrfit for DKS<a class="headerlink" href="#installation-of-musrfit-for-dks" title="Permalink to this headline"></a></h3>
</section>
<section id="installation-of-musrfit-for-dks">
<span id="musrfit-dks-install"></span><h3>Installation of musrfit for DKS<a class="headerlink" href="#installation-of-musrfit-for-dks" title="Link to this heading"></a></h3>
<p>Most of the installation steps are the same as described for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> without GPU support.
Here only the differences are explained. First checkout <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>, then you will need to
switch the working branch which is done by</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ <span class="nb">cd</span> <span class="nv">$HOME</span>/Apps/musrfit
$ git checkout dks6
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span><span class="nb">cd</span><span class="w"> </span><span class="nv">$HOME</span>/Apps/musrfit
$<span class="w"> </span>git<span class="w"> </span>checkout<span class="w"> </span>dks6
</pre></div>
</div>
<div class="section" id="install-via-cmake">
<h4>Install via cmake<a class="headerlink" href="#install-via-cmake" title="Permalink to this headline"></a></h4>
<section id="install-via-cmake">
<h4>Install via cmake<a class="headerlink" href="#install-via-cmake" title="Link to this heading"></a></h4>
<p>There is on more configuration switch</p>
<dl class="docutils">
<dt><strong>-Ddks=&lt;value&gt;</strong></dt>
<dd>it allows to enable/disable <code class="docutils literal notranslate"><span class="pre">DKS</span></code> support. The default is <code class="docutils literal notranslate"><span class="pre">&lt;value&gt;=1</span></code>, <em>i.e.</em> enabled. To disable use <code class="docutils literal notranslate"><span class="pre">&lt;value&gt;=0</span></code>.</dd>
<dl class="simple">
<dt><strong>-Ddks=&lt;value&gt;</strong></dt><dd><p>it allows to enable/disable <code class="docutils literal notranslate"><span class="pre">DKS</span></code> support. The default is <code class="docutils literal notranslate"><span class="pre">&lt;value&gt;=1</span></code>, <em>i.e.</em> enabled. To disable use <code class="docutils literal notranslate"><span class="pre">&lt;value&gt;=0</span></code>.</p>
</dd>
</dl>
<p>For a typical setup on a RHEL or macOS system it could look like this</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ cmake ../ -DCMAKE_INSTALL_PREFIX<span class="o">=</span><span class="nv">$ROOTSYS</span> -DASlibs<span class="o">=</span><span class="m">1</span> -DBMWlibs<span class="o">=</span><span class="m">1</span> -Dnexus<span class="o">=</span><span class="m">1</span> -Ddks<span class="o">=</span><span class="m">1</span>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>cmake<span class="w"> </span>../<span class="w"> </span>-DCMAKE_INSTALL_PREFIX<span class="o">=</span><span class="nv">$ROOTSYS</span><span class="w"> </span>-DASlibs<span class="o">=</span><span class="m">1</span><span class="w"> </span>-DBMWlibs<span class="o">=</span><span class="m">1</span><span class="w"> </span>-Dnexus<span class="o">=</span><span class="m">1</span><span class="w"> </span>-Ddks<span class="o">=</span><span class="m">1</span>
</pre></div>
</div>
<p>After</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ cmake --build ./ --clean-first -- -j8
$ make install
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>cmake<span class="w"> </span>--build<span class="w"> </span>./<span class="w"> </span>--clean-first<span class="w"> </span>--<span class="w"> </span>-j8
$<span class="w"> </span>make<span class="w"> </span>install
</pre></div>
</div>
<p>and updating the shared library lookup table (<em>only</em> needed for Linux)</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ /sbin/ldconfig <span class="c1"># as superuser / root</span>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>/sbin/ldconfig<span class="w"> </span><span class="c1"># as superuser / root</span>
</pre></div>
</div>
<p>you are done with the setup.</p>
</div>
</div>
</div>
<div class="section" id="setting-up-musrfit-dks-for-a-amd-graphic-card-radeon-r9-390x">
<span id="index-4"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for a AMD Graphic Card (Radeon R9 390X)<a class="headerlink" href="#setting-up-musrfit-dks-for-a-amd-graphic-card-radeon-r9-390x" title="Permalink to this headline"></a></h2>
<div class="section" id="driver-installation-for-an-amd-graphic-card-e-g-radeon-r9-390x">
<h3>Driver Installation for an AMD Graphic Card, <em>e.g.</em> Radeon R9 390X<a class="headerlink" href="#driver-installation-for-an-amd-graphic-card-e-g-radeon-r9-390x" title="Permalink to this headline"></a></h3>
</section>
</section>
</section>
<section id="setting-up-musrfit-dks-for-a-amd-graphic-card-radeon-r9-390x">
<span id="index-4"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for a AMD Graphic Card (Radeon R9 390X)<a class="headerlink" href="#setting-up-musrfit-dks-for-a-amd-graphic-card-radeon-r9-390x" title="Link to this heading"></a></h2>
<section id="driver-installation-for-an-amd-graphic-card-e-g-radeon-r9-390x">
<h3>Driver Installation for an AMD Graphic Card, <em>e.g.</em> Radeon R9 390X<a class="headerlink" href="#driver-installation-for-an-amd-graphic-card-e-g-radeon-r9-390x" title="Link to this heading"></a></h3>
<p>This will depend slightly on the AMD Card and operating system. Here I will summaries how it was done
on a RHEL (Linux) system using a Radeon R9 390X.</p>
<p>It is assumed that the Radeon R9 390X is already physically installed on your system. For now I only
will discuss to set it up for a Linux based system. In order to check that your operating systems see
the card, enter the following command in the terminal:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ lspci <span class="p">|</span> grep AMD
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>lspci<span class="w"> </span><span class="p">|</span><span class="w"> </span>grep<span class="w"> </span>AMD
</pre></div>
</div>
<p>The response should look something like</p>
@@ -335,48 +256,48 @@ the card, enter the following command in the terminal:</p>
</div>
<p>which means that the OS physically recognizes your card.</p>
<p>For RHEL7.x the AMDGPU-PRO driver should be used. It can be downloaded from <a class="reference external" href="http://support.amd.com/en-us/kb-articles/Pages/AMDGPU-PRO-RedHat-Install.aspx">AMD</a>. Unpack the driver</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ tar -Jxvf amdgpu-pro-17.10-414273.tar.xz
$ <span class="nb">cd</span> amdgpu-pro-17.10-414273
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>tar<span class="w"> </span>-Jxvf<span class="w"> </span>amdgpu-pro-17.10-414273.tar.xz
$<span class="w"> </span><span class="nb">cd</span><span class="w"> </span>amdgpu-pro-17.10-414273
</pre></div>
</div>
<p>Install the driver as root</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ ./amdgpu-pro-install --compute -y
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>./amdgpu-pro-install<span class="w"> </span>--compute<span class="w"> </span>-y
</pre></div>
</div>
<p>Here I assume that the AMD graphic card is only used for computation. You need to add the following command
in order that the user <strong>blabla</strong> (change this to the appropriate user name) can access the GPU (otherwise
only root works):</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ /sbin/usermod -a -G video blabla
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>/sbin/usermod<span class="w"> </span>-a<span class="w"> </span>-G<span class="w"> </span>video<span class="w"> </span>blabla
</pre></div>
</div>
<p>Reboot the machine.</p>
</div>
<div class="section" id="amd-app-software-development-kit-sdk-to-enable-opencl-support">
<h3>AMD APP Software Development Kit (SDK) to enable <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> support<a class="headerlink" href="#amd-app-software-development-kit-sdk-to-enable-opencl-support" title="Permalink to this headline"></a></h3>
</section>
<section id="amd-app-software-development-kit-sdk-to-enable-opencl-support">
<h3>AMD APP Software Development Kit (SDK) to enable <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> support<a class="headerlink" href="#amd-app-software-development-kit-sdk-to-enable-opencl-support" title="Link to this heading"></a></h3>
<p>The AMD APP Software Development Kit (SDK) is a complete development platform created by AMD to allow you to
quickly and easily develop applications accelerated by AMD APP technology. The SDK provides samples, documentation,
and other materials to quickly get you started leveraging accelerated compute using <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> or <code class="docutils literal notranslate"><span class="pre">C++</span> <span class="pre">AMP</span></code> in your
<code class="docutils literal notranslate"><span class="pre">C/C++</span></code> applications.</p>
<p>Download the AMD APP SDK 3.0 from <a class="reference external" href="http://developer.amd.com/tools-and-sdks/opencl-zone/amd-accelerated-parallel-processing-app-sdk/">AMD-SDK</a>.</p>
<p>Extract the installer</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ tar -xvjf AMD-APP-SDKInstaller-v3.0.130.136-GA-linux64.tar.bz2
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>tar<span class="w"> </span>-xvjf<span class="w"> </span>AMD-APP-SDKInstaller-v3.0.130.136-GA-linux64.tar.bz2
</pre></div>
</div>
<p>Run the installer</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ ./AMD-APP-SDK-v3.0.130.136-GA-linux64.sh
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>./AMD-APP-SDK-v3.0.130.136-GA-linux64.sh
</pre></div>
</div>
<p>This will install the AMD APP SDK to <code class="docutils literal notranslate"><span class="pre">/opt/AMDAPPSDK-3.0/</span></code> where you can find the <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code> include
and library files, as well as documentation and sample code. The install guide for AMD OpenCL SDK can
be found at <a class="reference external" href="http://developer.amd.com/wordpress/media/2012/10/AMD_APP_SDK_InstallationNotes.pdf">AMD SDK Installation Notes</a>.</p>
</div>
<div class="section" id="installation-of-dks-and-musrfit">
<h3>Installation of DKS and musrfit<a class="headerlink" href="#installation-of-dks-and-musrfit" title="Permalink to this headline"></a></h3>
</section>
<section id="installation-of-dks-and-musrfit">
<h3>Installation of DKS and musrfit<a class="headerlink" href="#installation-of-dks-and-musrfit" title="Link to this heading"></a></h3>
<p>To install <code class="docutils literal notranslate"><span class="pre">DKS</span></code> and <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> follow the instructions <a class="reference internal" href="#musrfit-dks-install"><span class="std std-ref">above</span></a>.</p>
</div>
</div>
<div class="section" id="setting-up-musrfit-dks-for-macos-for-opencl-support">
<span id="index-5"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for macOS for OpenCL support<a class="headerlink" href="#setting-up-musrfit-dks-for-macos-for-opencl-support" title="Permalink to this headline"></a></h2>
</section>
</section>
<section id="setting-up-musrfit-dks-for-macos-for-opencl-support">
<span id="index-5"></span><h2>Setting up <code class="docutils literal notranslate"><span class="pre">musrfit/DKS</span></code> for macOS for OpenCL support<a class="headerlink" href="#setting-up-musrfit-dks-for-macos-for-opencl-support" title="Link to this heading"></a></h2>
<p>Since Apple is not providing an out-of-the-box <code class="docutils literal notranslate"><span class="pre">OpenMP</span></code> support on their macOS compiler framework (Xcode),
typically <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> is just running <em>single threaded</em>. Here <code class="docutils literal notranslate"><span class="pre">DKS</span></code> can help since it delivers <code class="docutils literal notranslate"><span class="pre">OpenCL</span></code>
support which is present on macOS. Hence, if you would like to run <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> multi-threaded the easiest
@@ -384,73 +305,36 @@ way is to use <code class="docutils literal notranslate"><span class="pre">DKS</
<p>Since there is no graphic card involved, you do not need any graphic card driver of additional SDK.
The only thing you need <code class="docutils literal notranslate"><span class="pre">DKS</span></code> and the proper <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> version.</p>
<p>The installation instruction for <code class="docutils literal notranslate"><span class="pre">DKS/musrfit</span></code> can be found <a class="reference internal" href="#musrfit-dks-install"><span class="std std-ref">here</span></a>.</p>
</div>
</div>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="musredit.html" class="btn btn-neutral float-right" title="musredit: the GUI Based Interface to musrfit" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="setup-standard.html" class="btn btn-neutral" title="Setting up musrfit on Different Platforms" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="setup-standard.html" class="btn btn-neutral float-left" title="Setting up musrfit on Different Platforms" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="musredit.html" class="btn btn-neutral float-right" title="musredit: the GUI Based Interface to musrfit" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

File diff suppressed because it is too large Load Diff

View File

@@ -1,90 +1,50 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tutorial for musrfit &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Tutorial for musrfit &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script async="async" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="User manual" href="user-manual.html" />
<link rel="prev" title="How to Cite musrfit?" href="cite.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="#">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a><ul>
@@ -114,72 +74,34 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/tutorial.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="tutorial-for-musrfit">
<span id="index-0"></span><h1>Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code><a class="headerlink" href="#tutorial-for-musrfit" title="Permalink to this headline"></a></h1>
<div class="section" id="single-histogram-fit-tutorial">
<h2>Single-histogram-fit tutorial<a class="headerlink" href="#single-histogram-fit-tutorial" title="Permalink to this headline"></a></h2>
<section id="tutorial-for-musrfit">
<span id="index-0"></span><h1>Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code><a class="headerlink" href="#tutorial-for-musrfit" title="Link to this heading"></a></h1>
<section id="single-histogram-fit-tutorial">
<h2>Single-histogram-fit tutorial<a class="headerlink" href="#single-histogram-fit-tutorial" title="Link to this heading"></a></h2>
<p>The μSR-data-analysis process using musrfit is based on so-called msr files. These files contain all
information needed for the analysis such as names of the data files, a theory function, fit and plot parameters,
and so on. It is the idea of this page to explain the basic use of an msr file and the different programs
@@ -194,8 +116,8 @@ with the source-code distribution in the sub-directory <code class="docutils lit
text editor. For convenience the editor <code class="docutils literal notranslate"><span class="pre">musredit</span></code> is provided which offer some msr-file-specific functionalities
and additionally serve as front ends to the underlying programs. In the following it is assumed that the file is
open within <code class="docutils literal notranslate"><span class="pre">musredit</span></code>.</p>
<div class="section" id="the-msr-file">
<h3>The msr file<a class="headerlink" href="#the-msr-file" title="Permalink to this headline"></a></h3>
<section id="the-msr-file">
<h3>The msr file<a class="headerlink" href="#the-msr-file" title="Link to this heading"></a></h3>
<p>The msr file itself is divided into different blocks; a full description of the format can be found <a class="reference internal" href="user-manual.html#msr-file-format"><span class="std std-ref">here</span></a>.
In the file <code class="docutils literal notranslate"><span class="pre">3110_tutorial.msr</span></code> these blocks are successively:</p>
<p><a class="reference internal" href="user-manual.html#msr-title-block"><span class="std std-ref">The title</span></a></p>
@@ -258,7 +180,7 @@ sample holder), each with an amplitude (parameters 10 and 13), a depolarization
</pre></div>
</div>
<p>The THEORY block is used to define a fit-parameter-dependent theory function used to model
the decay asymmetry. Different <a class="reference internal" href="user-manual.html#msr-theory-block"><span class="std std-ref">predefined</span></a> and <a class="reference internal" href="user-manual.html#id38"><span class="std std-ref">user-defined</span></a>
the decay asymmetry. Different <a class="reference internal" href="user-manual.html#msr-theory-block"><span class="std std-ref">predefined</span></a> and <a class="reference internal" href="user-manual.html#id41"><span class="std std-ref">user-defined</span></a>
functions can be combined here. Theory lines following each other are <em>multiplied</em> and the <strong>+</strong> sign
is used to add different (here: two) signal contributions. The numbers are the parameter numbers
according to the <code class="docutils literal notranslate"><span class="pre">FITPARAMETER</span> <span class="pre">block</span></code>. <code class="docutils literal notranslate"><span class="pre">map</span></code> and <code class="docutils literal notranslate"><span class="pre">fun</span></code> are used to refer to
@@ -418,13 +340,13 @@ date and time as well as the absolute and normalized values of <span class="math
number of degrees of freedom in the fit.
These information only have a meaning if the fitting procedure has been executed at
least once and the fit has converged!</p>
</div>
<div class="section" id="determine-t0-and-the-data-range-using-musrt0">
<h3>Determine t0 and the data range using musrt0<a class="headerlink" href="#determine-t0-and-the-data-range-using-musrt0" title="Permalink to this headline"></a></h3>
</section>
<section id="determine-t0-and-the-data-range-using-musrt0">
<h3>Determine t0 and the data range using musrt0<a class="headerlink" href="#determine-t0-and-the-data-range-using-musrt0" title="Link to this heading"></a></h3>
<p>Before the given model can be fitted to the data, the data ranges and time zeros of the different
<code class="docutils literal notranslate"><span class="pre">RUN</span> <span class="pre">blocks</span></code> have to be set correctly. This can be achieved using <a class="reference internal" href="user-manual.html#musrt0"><span class="std std-ref">musrt0</span></a>.
Starting this program by selecting the <code class="docutils literal notranslate"><span class="pre">musrt0</span></code> button in <code class="docutils literal notranslate"><span class="pre">musredit</span></code> or calling from a terminal</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ musrt0 3110_tutorial.msr
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>musrt0<span class="w"> </span>3110_tutorial.msr
</pre></div>
</div>
<p>opens an interactive window plotting the data of the first RUN block:</p>
@@ -441,38 +363,38 @@ when the cursor is found at a suitable location:</p>
This procedure is repeated until all ranges have been set correctly. When finished with the last histogram
the new t0 and data-range values will be written to the msr file. A full description of <code class="docutils literal notranslate"><span class="pre">musrt0</span></code> can be
found <a class="reference internal" href="user-manual.html#musrt0"><span class="std std-ref">here</span></a>.</p>
</div>
<div class="section" id="fit-the-model-to-the-data-using-musrfit">
<h3>Fit the model to the data using <code class="docutils literal notranslate"><span class="pre">musrfit</span></code><a class="headerlink" href="#fit-the-model-to-the-data-using-musrfit" title="Permalink to this headline"></a></h3>
</section>
<section id="fit-the-model-to-the-data-using-musrfit">
<h3>Fit the model to the data using <code class="docutils literal notranslate"><span class="pre">musrfit</span></code><a class="headerlink" href="#fit-the-model-to-the-data-using-musrfit" title="Link to this heading"></a></h3>
<p>Now that the basics of the msr file have been introduced and the necessary adjustments have been done one
can proceed with fitting the specified model to the data. This is done by selecting the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> icon
in <code class="docutils literal notranslate"><span class="pre">musredit</span></code> or calling from a terminal</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ musrfit 3110_tutorial.msr
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>musrfit<span class="w"> </span>3110_tutorial.msr
</pre></div>
</div>
<p>After the fitting procedure has finished the msr file is updated and contains the newly determined values
of the fit parameters.</p>
</div>
<div class="section" id="view-the-data-and-the-fit-using-musrview">
<h3>View the data and the fit using <code class="docutils literal notranslate"><span class="pre">musrview</span></code><a class="headerlink" href="#view-the-data-and-the-fit-using-musrview" title="Permalink to this headline"></a></h3>
</section>
<section id="view-the-data-and-the-fit-using-musrview">
<h3>View the data and the fit using <code class="docutils literal notranslate"><span class="pre">musrview</span></code><a class="headerlink" href="#view-the-data-and-the-fit-using-musrview" title="Link to this heading"></a></h3>
<p>The data and the corresponding fit can be visualized by choosing the <code class="docutils literal notranslate"><span class="pre">musrview</span></code> icon in <code class="docutils literal notranslate"><span class="pre">musredit</span></code> or
calling from a terminal</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ musrview 3110_tutorial.msr
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>musrview<span class="w"> </span>3110_tutorial.msr
</pre></div>
</div>
<p>This creates the windows according to the given PLOT blocks in the msr file:</p>
<img alt="_images/tutorial-musrview-1.png" src="_images/tutorial-musrview-1.png" />
<p>The basic features of <code class="docutils literal notranslate"><span class="pre">musrview</span></code> can be found in the <code class="docutils literal notranslate"><span class="pre">Musrfit</span> <span class="pre">menu</span></code>. They include:</p>
<ul class="simple">
<li>export the shown data and the model to an ASCII file with comma-separated values</li>
<li>presenting the difference between the shown data and the model (keyboard shortcut: <strong>d</strong>)</li>
<li>calculate and show the Fourier transform of the shown data (keyboard shortcut: <strong>f</strong>), <em>e.g.</em> for
the asymmetry of the “Up” and “Down” detectors:</li>
<li><p>export the shown data and the model to an ASCII file with comma-separated values</p></li>
<li><p>presenting the difference between the shown data and the model (keyboard shortcut: <strong>d</strong>)</p></li>
<li><p>calculate and show the Fourier transform of the shown data (keyboard shortcut: <strong>f</strong>), <em>e.g.</em> for
the asymmetry of the “Up” and “Down” detectors:</p></li>
</ul>
<img alt="_images/tutorial-musrview-FT.png" src="_images/tutorial-musrview-FT.png" />
</div>
<div class="section" id="process-multiple-msr-files-using-msr2data">
<h3>Process multiple msr files using <code class="docutils literal notranslate"><span class="pre">msr2data</span></code><a class="headerlink" href="#process-multiple-msr-files-using-msr2data" title="Permalink to this headline"></a></h3>
</section>
<section id="process-multiple-msr-files-using-msr2data">
<h3>Process multiple msr files using <code class="docutils literal notranslate"><span class="pre">msr2data</span></code><a class="headerlink" href="#process-multiple-msr-files-using-msr2data" title="Link to this heading"></a></h3>
<p>This short introduction is concluded by calling attention to the program <a class="reference internal" href="msr2data.html#msr2data"><span class="std std-ref">msr2data</span></a>.
As the name indicates the main purpose of this program is to extract the <code class="docutils literal notranslate"><span class="pre">FITPARAMETER</span></code> block
information from multiple msr files with the same structure and to summarize them in a single
@@ -487,89 +409,52 @@ and finally summarize the FITPARAMETER block information of all processed files
file <code class="docutils literal notranslate"><span class="pre">tutorial-T-dependence.dat</span></code> (simple columns). If further information on the temperature or the
applied field is available in the data files these will be included as well in the resulting ASCII file.
From the terminal this would be done as follows:</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$ msr2data <span class="m">3110</span> <span class="m">3114</span> _tutorial fit-3110 -o tutorial-T-dependence.dat data
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>$<span class="w"> </span>msr2data<span class="w"> </span><span class="m">3110</span><span class="w"> </span><span class="m">3114</span><span class="w"> </span>_tutorial<span class="w"> </span>fit-3110<span class="w"> </span>-o<span class="w"> </span>tutorial-T-dependence.dat<span class="w"> </span>data
</pre></div>
</div>
<p>To achieve the same in <code class="docutils literal notranslate"><span class="pre">musredit</span></code> (in this snapshot in the <em>dark theme</em>) one selects the <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> icon and fills the form accordingly:</p>
<img alt="_images/tutorial-musredit-msr2data.png" src="_images/tutorial-musredit-msr2data.png" />
</div>
<div class="section" id="further-reading">
<h3>Further reading<a class="headerlink" href="#further-reading" title="Permalink to this headline"></a></h3>
</section>
<section id="further-reading">
<h3>Further reading<a class="headerlink" href="#further-reading" title="Link to this heading"></a></h3>
<p>This page only summarizes the very basic features and options of the programs contained in the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> suite.
For a complete description please refer to the manuals of <a class="reference internal" href="user-manual.html#musrfit"><span class="std std-ref">musrfit</span></a> (including <a class="reference internal" href="user-manual.html#musrview"><span class="std std-ref">musrview</span></a>,
<a class="reference internal" href="user-manual.html#musrt0"><span class="std std-ref">musrt0</span></a>, and <a class="reference internal" href="user-manual.html#musrft"><span class="std std-ref">musrFT</span></a>), <a class="reference internal" href="mupp.html#mupp"><span class="std std-ref">mupp</span></a>, <a class="reference internal" href="musredit.html#musredit-sec"><span class="std std-ref">musredit</span></a>, and <a class="reference internal" href="msr2data.html#msr2data"><span class="std std-ref">msr2data</span></a>.</p>
</div>
</div>
<div class="section" id="asymmtery-fit-tutorial">
<h2>Asymmtery-fit tutorial<a class="headerlink" href="#asymmtery-fit-tutorial" title="Permalink to this headline"></a></h2>
</section>
</section>
<section id="asymmtery-fit-tutorial">
<h2>Asymmtery-fit tutorial<a class="headerlink" href="#asymmtery-fit-tutorial" title="Link to this heading"></a></h2>
<p>to be written yet.</p>
</div>
</div>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="user-manual.html" class="btn btn-neutral float-right" title="User manual" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="cite.html" class="btn btn-neutral" title="How to Cite musrfit?" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="cite.html" class="btn btn-neutral float-left" title="How to Cite musrfit?" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="user-manual.html" class="btn btn-neutral float-right" title="User manual" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

View File

@@ -1,90 +1,50 @@
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<html class="writer-html5" lang="en" data-content_root="./">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Documentation of user libs (user functions) &mdash; musrfit 1.9.3 documentation</title>
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Documentation of user libs (user functions) &mdash; musrfit 1.9.9 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/css/theme.css?v=7a5cd723" />
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<script src="_static/jquery.js?v=5d32c60e"></script>
<script src="_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
<script src="_static/documentation_options.js?v=4320943d"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script async="async" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
<script src="_static/js/theme.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="Setting up musrfit on Different Platforms" href="setup-standard.html" />
<link rel="prev" title="User manual" href="user-manual.html" />
<link href="_static/style.css" rel="stylesheet" type="text/css">
<script src="_static/js/modernizr.min.js"></script>
</head>
<body class="wy-body-for-nav">
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search">
<div class="wy-side-nav-search" >
<a href="index.html" class="icon icon-home"> musrfit
<a href="index.html" class="icon icon-home">
musrfit
</a>
<div class="version">
1.9
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="cite.html">How to Cite <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>?</a></li>
<li class="toctree-l1"><a class="reference internal" href="tutorial.html">Tutorial for <code class="docutils literal notranslate"><span class="pre">musrfit</span></code></a></li>
@@ -100,7 +60,7 @@
</li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="#supeconducting-gap-integrals-to-calculate-vs">Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span></a></li>
<li class="toctree-l2"><a class="reference internal" href="#supeconducting-gap-integrals-to-calculate-1-lambda-2-vs-t">Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span></a></li>
<li class="toctree-l2"><a class="reference internal" href="#nonlocal-superconductivity-related-meissner-screening-functions-as-libs">Nonlocal superconductivity related Meissner screening functions (AS libs)</a></li>
<li class="toctree-l2"><a class="reference internal" href="#depth-resolved-information-as-libs">Depth resolved information (AS libs)</a></li>
<li class="toctree-l2"><a class="reference internal" href="#functions-to-analyze-bgr-nmr-data-bnmr-libs">Functions to analyze β-NMR data (BNMR libs)</a><ul>
@@ -128,77 +88,39 @@
<li class="toctree-l1"><a class="reference internal" href="bugtracking.html">Bugtracking</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">musrfit</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<div role="navigation" aria-label="Page navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> &raquo;</li>
<li>Documentation of user libs (user functions)</li>
<li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
<li class="breadcrumb-item active">Documentation of user libs (user functions)</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/user-libs.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="documentation-of-user-libs-user-functions">
<span id="user-libs"></span><span id="index-0"></span><h1>Documentation of user libs (user functions)<a class="headerlink" href="#documentation-of-user-libs-user-functions" title="Permalink to this headline"></a></h1>
<div class="section" id="meissner-profiles-vortex-lattice-related-functions-bmw-libs">
<span id="bmw-libs"></span><span id="index-1"></span><h2>Meissner-Profiles / Vortex-Lattice related functions (BMW libs)<a class="headerlink" href="#meissner-profiles-vortex-lattice-related-functions-bmw-libs" title="Permalink to this headline"></a></h2>
<div class="section" id="libfitpofb">
<span id="index-2"></span><h3>libFitPofB<a class="headerlink" href="#libfitpofb" title="Permalink to this headline"></a></h3>
<div class="section" id="introduction">
<h4>Introduction<a class="headerlink" href="#introduction" title="Permalink to this headline"></a></h4>
<p><code class="docutils literal notranslate"><span class="pre">libFitPofB</span></code> is a collection of <code class="docutils literal notranslate"><span class="pre">C++</span></code> classes using the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> <a class="reference internal" href="user-manual.html#id38"><span class="std std-ref">user-functions</span></a>
<section id="documentation-of-user-libs-user-functions">
<span id="user-libs"></span><span id="index-0"></span><h1>Documentation of user libs (user functions)<a class="headerlink" href="#documentation-of-user-libs-user-functions" title="Link to this heading"></a></h1>
<section id="meissner-profiles-vortex-lattice-related-functions-bmw-libs">
<span id="bmw-libs"></span><span id="index-1"></span><h2>Meissner-Profiles / Vortex-Lattice related functions (BMW libs)<a class="headerlink" href="#meissner-profiles-vortex-lattice-related-functions-bmw-libs" title="Link to this heading"></a></h2>
<section id="libfitpofb">
<span id="index-2"></span><h3>libFitPofB<a class="headerlink" href="#libfitpofb" title="Link to this heading"></a></h3>
<section id="introduction">
<h4>Introduction<a class="headerlink" href="#introduction" title="Link to this heading"></a></h4>
<p><code class="docutils literal notranslate"><span class="pre">libFitPofB</span></code> is a collection of <code class="docutils literal notranslate"><span class="pre">C++</span></code> classes using the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> <a class="reference internal" href="user-manual.html#id41"><span class="std std-ref">user-functions</span></a>
interface in order to facilitate the usage in conjunction with <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>. The classes contained in this
library generally implement calculations of one-dimensional static magnetic field distributions
<span class="math notranslate nohighlight">\(p(B)\)</span> which lead to the muon-spin depolarization functions</p>
@@ -211,13 +133,13 @@ low-energy μSR (see <a class="reference external" href="https://www.psi.ch/smus
In the following the basic usage of the library in <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> is explained—the calculations by themselves are only
outlined. For further information please refer to the original literature and/or the source code of the implementation.</p>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">In order to supply certain information needed for the calculations but not suited to be stored in the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>
<p class="admonition-title">Note</p>
<p>In order to supply certain information needed for the calculations but not suited to be stored in the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>
msr files an <code class="docutils literal notranslate"><span class="pre">XML</span></code> configuration file in the working directory is used. For details, see below.</p>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">The implementations in this library heavily rely on <a class="reference external" href="http://fftw.org/">FFTW3</a>. In principle, it always checks what
<p class="admonition-title">Note</p>
<p>The implementations in this library heavily rely on <a class="reference external" href="http://fftw.org/">FFTW3</a>. In principle, it always checks what
is the best way to do efficient Fourier transforms for a given machine before the transforms are actually done. If
repeatedly Fourier transforms of the same (sizable) length should be done, it might be worth storing the once
obtained information in an external file and just load it the next time this information is needed
@@ -225,8 +147,8 @@ obtained information in an external file and just load it the next time this inf
file has to be specified in the <code class="docutils literal notranslate"><span class="pre">XML</span></code> file.</p>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">The model functions described in the following do generally <em>not behave nicely</em> in conjunction with <code class="docutils literal notranslate"><span class="pre">MINUIT</span></code>
<p class="admonition-title">Note</p>
<p>The model functions described in the following do generally <em>not behave nicely</em> in conjunction with <code class="docutils literal notranslate"><span class="pre">MINUIT</span></code>
function minimizations (or maximizations). The analysis process at the moment in most cases involves some
tedious trial-and-error procedure, where the displayed MINUIT information as always deserves attention.
This is especially true if small effects should be analyzed (<em>e.g.</em> small diamagnetic shifts in superconductors).
@@ -234,15 +156,15 @@ The parameter uncertainty in many cases has to be estimated independently. Due t
the use of the fit option of <code class="docutils literal notranslate"><span class="pre">msr2data</span></code> <em>cannot</em> be advised.</p>
</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">If these classes still prove useful and results obtained through them are part of scientific publications,
<p class="admonition-title">Note</p>
<p>If these classes still prove useful and results obtained through them are part of scientific publications,
an acknowledgment of the use of the library is appreciated.</p>
</div>
</div>
<div class="section" id="le-mgrsr">
<h4>LE-μSR<a class="headerlink" href="#le-mgrsr" title="Permalink to this headline"></a></h4>
<div class="section" id="one-dimensional-london-model-for-the-meissner-state-of-isotropic-superconductors">
<span id="index-3"></span><h5>One-dimensional London model for the Meissner state of isotropic superconductors<a class="headerlink" href="#one-dimensional-london-model-for-the-meissner-state-of-isotropic-superconductors" title="Permalink to this headline"></a></h5>
</section>
<section id="le-mgrsr">
<h4>LE-μSR<a class="headerlink" href="#le-mgrsr" title="Link to this heading"></a></h4>
<section id="one-dimensional-london-model-for-the-meissner-state-of-isotropic-superconductors">
<span id="index-3"></span><h5>One-dimensional London model for the Meissner state of isotropic superconductors<a class="headerlink" href="#one-dimensional-london-model-for-the-meissner-state-of-isotropic-superconductors" title="Link to this heading"></a></h5>
<p>The models for analyzing LE-μSR data assume the magnetic induction <span class="math notranslate nohighlight">\(B(z)\)</span> to vary only in the
dimension parallel to the momentum of the incident muons. In such a case the magnetic field distribution is given by</p>
<div class="math notranslate nohighlight">
@@ -267,11 +189,11 @@ of a <code class="docutils literal notranslate"><span class="pre">musrfit</span>
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</li>
<li>applied field (G)</li>
<li>thickness of the dead layer (nm)</li>
<li>magnetic field penetration depth (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</p></li>
<li><p>applied field (G)</p></li>
<li><p>thickness of the dead layer (nm)</p></li>
<li><p>magnetic field penetration depth (nm)</p></li>
</ol>
<p id="index-5"><strong>Superconducting thin film (one layer)</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TLondon1D1L</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span> <span class="mi">5</span> <span class="mi">6</span> <span class="p">[</span><span class="n">a</span> <span class="n">b</span><span class="p">]</span>
@@ -279,17 +201,17 @@ of a <code class="docutils literal notranslate"><span class="pre">musrfit</span>
</div>
<p>The mandatory parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</li>
<li>applied field (G)</li>
<li>thickness of the dead layer (nm)</li>
<li>thickness of the actually superconducting layer (nm)</li>
<li>magnetic field penetration depth (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</p></li>
<li><p>applied field (G)</p></li>
<li><p>thickness of the dead layer (nm)</p></li>
<li><p>thickness of the actually superconducting layer (nm)</p></li>
<li><p>magnetic field penetration depth (nm)</p></li>
</ol>
<p>The optional parameters are:</p>
<ol class="loweralpha simple">
<li>fraction f<sub>1</sub> of muons in the thin film contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</li>
<li>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</li>
<li><p>fraction f<sub>1</sub> of muons in the thin film contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</p></li>
</ol>
<p id="index-6"><strong>Superconducting thin-film bilayer heterostructure</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TLondon1D2L</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span> <span class="mi">5</span> <span class="mi">6</span> <span class="mi">7</span> <span class="mi">8</span> <span class="p">[</span><span class="n">a</span> <span class="n">b</span> <span class="n">c</span><span class="p">]</span>
@@ -297,20 +219,20 @@ of a <code class="docutils literal notranslate"><span class="pre">musrfit</span>
</div>
<p>The mandatory parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</li>
<li>applied field (G)</li>
<li>thickness of the dead layer (nm)</li>
<li>thickness of the actually superconducting first layer (nm)</li>
<li>thickness of the actually superconducting second layer (nm)</li>
<li>magnetic field penetration depth of the first layer (nm)</li>
<li>magnetic field penetration depth of the second layer (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</p></li>
<li><p>applied field (G)</p></li>
<li><p>thickness of the dead layer (nm)</p></li>
<li><p>thickness of the actually superconducting first layer (nm)</p></li>
<li><p>thickness of the actually superconducting second layer (nm)</p></li>
<li><p>magnetic field penetration depth of the first layer (nm)</p></li>
<li><p>magnetic field penetration depth of the second layer (nm)</p></li>
</ol>
<p>The optional parameters are:</p>
<ol class="loweralpha simple">
<li>fraction f<sub>1</sub> of muons in the dead and first layer contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</li>
<li>fraction f<sub>2</sub> of muons in the second layer contributing to the signal (0 ≤ f<sub>2</sub> ≤ 1)</li>
<li>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</li>
<li><p>fraction f<sub>1</sub> of muons in the dead and first layer contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>2</sub> of muons in the second layer contributing to the signal (0 ≤ f<sub>2</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</p></li>
</ol>
<p id="index-7"><strong>Superconducting thin-film trilayer heterostructure</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TLondon1D3L</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span> <span class="mi">5</span> <span class="mi">6</span> <span class="mi">7</span> <span class="mi">8</span> <span class="mi">9</span> <span class="mi">10</span> <span class="p">[</span><span class="n">a</span> <span class="n">b</span> <span class="n">c</span> <span class="n">d</span><span class="p">]</span>
@@ -318,30 +240,30 @@ of a <code class="docutils literal notranslate"><span class="pre">musrfit</span>
</div>
<p>The mandatory parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</li>
<li>applied field (G)</li>
<li>thickness of the dead layer (nm)</li>
<li>thickness of the actually superconducting first layer (nm)</li>
<li>thickness of the actually superconducting second layer (nm)</li>
<li>thickness of the actually superconducting third layer (nm)</li>
<li>magnetic field penetration depth of the first layer (nm)</li>
<li>magnetic field penetration depth of the second layer (nm)</li>
<li>magnetic field penetration depth of the third layer (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>muon implantation energy as specified in the <a class="reference internal" href="#bmwlibs-xml"><span class="std std-ref">XML startup</span></a> file (keV)</p></li>
<li><p>applied field (G)</p></li>
<li><p>thickness of the dead layer (nm)</p></li>
<li><p>thickness of the actually superconducting first layer (nm)</p></li>
<li><p>thickness of the actually superconducting second layer (nm)</p></li>
<li><p>thickness of the actually superconducting third layer (nm)</p></li>
<li><p>magnetic field penetration depth of the first layer (nm)</p></li>
<li><p>magnetic field penetration depth of the second layer (nm)</p></li>
<li><p>magnetic field penetration depth of the third layer (nm)</p></li>
</ol>
<p>The optional parameters are:</p>
<ol class="loweralpha simple">
<li>fraction f<sub>1</sub> of muons in the dead and first layer contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</li>
<li>fraction f<sub>2</sub> of muons in the second layer contributing to the signal (0 ≤ f<sub>2</sub> ≤ 1)</li>
<li>fraction f<sub>3</sub> of muons in the third layer contributing to the signal (0 ≤ f<sub>3</sub> ≤ 1)</li>
<li>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</li>
<li><p>fraction f<sub>1</sub> of muons in the dead and first layer contributing to the signal (0 ≤ f<sub>1</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>2</sub> of muons in the second layer contributing to the signal (0 ≤ f<sub>2</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>3</sub> of muons in the third layer contributing to the signal (0 ≤ f<sub>3</sub> ≤ 1)</p></li>
<li><p>fraction f<sub>s</sub> of muons in the substrate contributing to the signal (0 ≤ f<sub>s</sub> ≤ 1)</p></li>
</ol>
</div>
</div>
<div class="section" id="bulk-mgrsr">
<h4>Bulk μSR<a class="headerlink" href="#bulk-mgrsr" title="Permalink to this headline"></a></h4>
<div class="section" id="field-distributions-in-the-mixed-state-of-isotropic-superconductors">
<span id="index-8"></span><h5>Field distributions in the mixed state of isotropic superconductors<a class="headerlink" href="#field-distributions-in-the-mixed-state-of-isotropic-superconductors" title="Permalink to this headline"></a></h5>
</section>
</section>
<section id="bulk-mgrsr">
<h4>Bulk μSR<a class="headerlink" href="#bulk-mgrsr" title="Link to this heading"></a></h4>
<section id="field-distributions-in-the-mixed-state-of-isotropic-superconductors">
<span id="index-8"></span><h5>Field distributions in the mixed state of isotropic superconductors<a class="headerlink" href="#field-distributions-in-the-mixed-state-of-isotropic-superconductors" title="Link to this heading"></a></h5>
<p>When investigating superconductors in the mixed state by means of conventional μSR a
two-dimensional flux-line lattice is probed randomly by the muons. The spatial field
distributions within such an ordered lattice are modeled using the Fourier series</p>
@@ -375,10 +297,10 @@ The muon-spin depolarization functions finally are calculated using the followin
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>mean magnetic induction (G)</li>
<li>magnetic penetration depth (nm)</li>
<li>Ginzburg-Landau coherence length (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>mean magnetic induction (G)</p></li>
<li><p>magnetic penetration depth (nm)</p></li>
<li><p>Ginzburg-Landau coherence length (nm)</p></li>
</ol>
<p id="index-10"><strong>2D triangular vortex lattice, modified London model</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TBulkTriVortexML</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span>
@@ -386,10 +308,10 @@ The muon-spin depolarization functions finally are calculated using the followin
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>mean magnetic induction (G)</li>
<li>magnetic penetration depth (nm)</li>
<li>Ginzburg-Landau coherence length (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>mean magnetic induction (G)</p></li>
<li><p>magnetic penetration depth (nm)</p></li>
<li><p>Ginzburg-Landau coherence length (nm)</p></li>
</ol>
<p id="index-11"><strong>2D triangular vortex lattice, analytic Ginzburg-Landau model</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TBulkTriVortexAGL</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span>
@@ -397,10 +319,10 @@ The muon-spin depolarization functions finally are calculated using the followin
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>mean magnetic induction (G)</li>
<li>magnetic penetration depth (nm)</li>
<li>Ginzburg-Landau coherence length (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>mean magnetic induction (G)</p></li>
<li><p>magnetic penetration depth (nm)</p></li>
<li><p>Ginzburg-Landau coherence length (nm)</p></li>
</ol>
<p id="index-12"><strong>2D triangular vortex lattice, numerical Ginzburg-Landau model</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libFitPofB</span> <span class="n">TBulkTriVortexNGL</span> <span class="mi">1</span> <span class="mi">2</span> <span class="mi">3</span> <span class="mi">4</span>
@@ -408,14 +330,14 @@ The muon-spin depolarization functions finally are calculated using the followin
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>phase (deg)</li>
<li>mean magnetic induction (G)</li>
<li>magnetic penetration depth (nm)</li>
<li>Ginzburg-Landau coherence length (nm)</li>
<li><p>phase (deg)</p></li>
<li><p>mean magnetic induction (G)</p></li>
<li><p>magnetic penetration depth (nm)</p></li>
<li><p>Ginzburg-Landau coherence length (nm)</p></li>
</ol>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">In order to improve the convergence of <code class="docutils literal notranslate"><span class="pre">MIGRAD</span></code> it has proven useful to use the log-likelihood
<p class="admonition-title">Note</p>
<p>In order to improve the convergence of <code class="docutils literal notranslate"><span class="pre">MIGRAD</span></code> it has proven useful to use the log-likelihood
maximization instead of the <span class="math notranslate nohighlight">\(\chi^2\)</span> minimization routines and to choose sufficiently large
initial steps for the parameters. Calling <code class="docutils literal notranslate"><span class="pre">MINOS</span></code> in conjunction with these functions is futile.</p>
</div>
@@ -428,47 +350,44 @@ initial steps for the parameters. Calling <code class="docutils literal notransl
<span class="n">SAVE</span>
</pre></div>
</div>
</div>
</div>
<div class="section" id="the-xml-startup-file">
<span id="bmwlibs-xml"></span><span id="index-13"></span><h4>The XML startup file<a class="headerlink" href="#the-xml-startup-file" title="Permalink to this headline"></a></h4>
</section>
</section>
<section id="the-xml-startup-file">
<span id="bmwlibs-xml"></span><span id="index-13"></span><h4>The XML startup file<a class="headerlink" href="#the-xml-startup-file" title="Link to this heading"></a></h4>
<p><code class="docutils literal notranslate"><span class="pre">BMW_startup.xml</span></code> is a configuration file located in the working directory. In this file some settings
like the time and field resolution of the calculations as well as the present muon implantation profiles
for a LE-μSR analysis have to be defined. The following XML tags are allowed to define settings:</p>
<dl class="docutils">
<dt><strong>&lt;debug&gt;ONE_OR_ZERO&lt;/debug&gt;</strong></dt>
<dd>activate the debugging output of the settings read from the XML file by setting 1, deactivate it with 0.</dd>
<dt><strong>&lt;wisdom&gt;PATH_TO_FILE&lt;/wisdom&gt;</strong></dt>
<dd>specify the <code class="docutils literal notranslate"><span class="pre">PATH_TO_FILE</span></code> to an <a class="reference external" href="http://fftw.org/fftw3_doc/Wisdom.html#Wisdom">FFTW3 wisdom file</a>
that should be used; if the <code class="docutils literal notranslate"><span class="pre">PATH_TO_FILE</span></code> is invalid, no <code class="docutils literal notranslate"><span class="pre">FFTW3</span></code> wisdom will be used.</dd>
<dt><strong>&lt;delta_t&gt;ResT&lt;/delta_t&gt;</strong></dt>
<dd>set the time resolution <code class="docutils literal notranslate"><span class="pre">ResT</span></code> for the calculated depolarization function in microseconds.</dd>
<dt><strong>&lt;delta_B&gt;ResB&lt;/delta_B&gt;</strong></dt>
<dd>set the field resolution <code class="docutils literal notranslate"><span class="pre">ResB</span></code> for the calculated field distribution in Gauss.</dd>
<dt><strong>&lt;VortexLattice&gt;&lt;/VortexLattice&gt;</strong></dt>
<dd><p class="first">set the parameters used for the calculation of the spatial field distribution of a vortex lattice.</p>
<dl class="last docutils">
<dt><strong>&lt;N_VortexGrid&gt;N&lt;/N_VortexGrid&gt;</strong></dt>
<dd>specify the number of points <strong>N</strong> (in each of the two dimensions) for which the fields within the
vortex lattice are calculated (inside a <strong>&lt;VortexLattice&gt;</strong> environment)</dd>
<dl>
<dt><strong>&lt;debug&gt;ONE_OR_ZERO&lt;/debug&gt;</strong></dt><dd><p>activate the debugging output of the settings read from the XML file by setting 1, deactivate it with 0.</p>
</dd>
<dt><strong>&lt;wisdom&gt;PATH_TO_FILE&lt;/wisdom&gt;</strong></dt><dd><p>specify the <code class="docutils literal notranslate"><span class="pre">PATH_TO_FILE</span></code> to an <a class="reference external" href="http://fftw.org/fftw3_doc/Wisdom.html#Wisdom">FFTW3 wisdom file</a>
that should be used; if the <code class="docutils literal notranslate"><span class="pre">PATH_TO_FILE</span></code> is invalid, no <code class="docutils literal notranslate"><span class="pre">FFTW3</span></code> wisdom will be used.</p>
</dd>
<dt><strong>&lt;delta_t&gt;ResT&lt;/delta_t&gt;</strong></dt><dd><p>set the time resolution <code class="docutils literal notranslate"><span class="pre">ResT</span></code> for the calculated depolarization function in microseconds.</p>
</dd>
<dt><strong>&lt;delta_B&gt;ResB&lt;/delta_B&gt;</strong></dt><dd><p>set the field resolution <code class="docutils literal notranslate"><span class="pre">ResB</span></code> for the calculated field distribution in Gauss.</p>
</dd>
<dt><strong>&lt;VortexLattice&gt;&lt;/VortexLattice&gt;</strong></dt><dd><p>set the parameters used for the calculation of the spatial field distribution of a vortex lattice.</p>
<dl class="simple">
<dt><strong>&lt;N_VortexGrid&gt;N&lt;/N_VortexGrid&gt;</strong></dt><dd><p>specify the number of points <strong>N</strong> (in each of the two dimensions) for which the fields within the
vortex lattice are calculated (inside a <strong>&lt;VortexLattice&gt;</strong> environment)</p>
</dd>
</dl>
</dd>
<dt><strong>&lt;LEM&gt;&lt;/LEM&gt;</strong></dt>
<dd><p class="first">set the parameters used for the calculation of LE-μSR field distributions</p>
<dl class="last docutils">
<dt><strong>&lt;data_path&gt;DATA_PATH_PREFIX&lt;/data_path&gt;</strong></dt>
<dd>specify the <code class="docutils literal notranslate"><span class="pre">DATA_PATH_PREFIX</span></code> to the <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> implantation profiles (inside a <strong>&lt;LEM&gt;</strong> environment)</dd>
<dt><strong>&lt;N_theory&gt;N_THEORY&lt;/N_theory&gt;</strong></dt>
<dd>specify the number of points <strong>N_THEORY</strong> for which <em>B(z)</em> is calculated (inside a <strong>&lt;LEM&gt;</strong> environment)
The specification of this number is not needed if the calculation of the inverse of <em>B(z)</em> is implemented!</dd>
<dt><strong>&lt;energy_list&gt;&lt;/energy_list&gt;</strong></dt>
<dd><p class="first">set the energies for which <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> implantation profiles are available (inside a <strong>&lt;LEM&gt;</strong> environment)</p>
<dl class="last docutils">
<dt><strong>&lt;energy_label&gt;LABEL&lt;/energy_label&gt;</strong></dt>
<dd>specify the <strong>LABEL</strong> within the file name of a available <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file (inside a <strong>&lt;energy_list&gt;</strong> environment)
The expected name of the <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file will be: <code class="docutils literal notranslate"><span class="pre">DATA_PATH_PREFIX</span> <span class="pre">+</span> <span class="pre">LABEL</span> <span class="pre">+</span> <span class="pre">.rge</span></code></dd>
<dt><strong>&lt;energy&gt;E&lt;/energy&gt;</strong></dt>
<dd>specify the muon energy <em>E</em> (in keV) belonging to the <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file given above (inside a <strong>&lt;energy_list&gt;</strong> environment)</dd>
<dt><strong>&lt;LEM&gt;&lt;/LEM&gt;</strong></dt><dd><p>set the parameters used for the calculation of LE-μSR field distributions</p>
<dl>
<dt><strong>&lt;data_path&gt;DATA_PATH_PREFIX&lt;/data_path&gt;</strong></dt><dd><p>specify the <code class="docutils literal notranslate"><span class="pre">DATA_PATH_PREFIX</span></code> to the <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> implantation profiles (inside a <strong>&lt;LEM&gt;</strong> environment)</p>
</dd>
<dt><strong>&lt;N_theory&gt;N_THEORY&lt;/N_theory&gt;</strong></dt><dd><p>specify the number of points <strong>N_THEORY</strong> for which <em>B(z)</em> is calculated (inside a <strong>&lt;LEM&gt;</strong> environment)
The specification of this number is not needed if the calculation of the inverse of <em>B(z)</em> is implemented!</p>
</dd>
<dt><strong>&lt;energy_list&gt;&lt;/energy_list&gt;</strong></dt><dd><p>set the energies for which <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> implantation profiles are available (inside a <strong>&lt;LEM&gt;</strong> environment)</p>
<dl class="simple">
<dt><strong>&lt;energy_label&gt;LABEL&lt;/energy_label&gt;</strong></dt><dd><p>specify the <strong>LABEL</strong> within the file name of a available <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file (inside a <strong>&lt;energy_list&gt;</strong> environment)
The expected name of the <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file will be: <code class="docutils literal notranslate"><span class="pre">DATA_PATH_PREFIX</span> <span class="pre">+</span> <span class="pre">LABEL</span> <span class="pre">+</span> <span class="pre">.rge</span></code></p>
</dd>
<dt><strong>&lt;energy&gt;E&lt;/energy&gt;</strong></dt><dd><p>specify the muon energy <em>E</em> (in keV) belonging to the <code class="docutils literal notranslate"><span class="pre">TRIM.SP</span></code> <code class="docutils literal notranslate"><span class="pre">RGE</span></code> file given above (inside a <strong>&lt;energy_list&gt;</strong> environment)</p>
</dd>
</dl>
</dd>
</dl>
@@ -477,43 +396,43 @@ The expected name of the <code class="docutils literal notranslate"><span class=
<p>An example XML file looks as follows:</p>
<div class="highlight-xml notranslate"><div class="highlight"><pre><span></span><span class="cp">&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;</span>
<span class="nt">&lt;BMW&gt;</span>
<span class="nt">&lt;debug&gt;</span>0<span class="nt">&lt;/debug&gt;</span>
<span class="nt">&lt;wisdom&gt;</span>/home/user/WordsOfWisdom.dat<span class="nt">&lt;/wisdom&gt;</span>
<span class="nt">&lt;delta_t&gt;</span>0.01<span class="nt">&lt;/delta_t&gt;</span>
<span class="nt">&lt;delta_B&gt;</span>0.5<span class="nt">&lt;/delta_B&gt;</span>
<span class="nt">&lt;VortexLattice&gt;</span>
<span class="nt">&lt;N_VortexGrid&gt;</span>1024<span class="nt">&lt;/N_VortexGrid&gt;</span>
<span class="nt">&lt;/VortexLattice&gt;</span>
<span class="nt">&lt;LEM&gt;</span>
<span class="nt">&lt;data_path&gt;</span>/home/user/TrimSP/some-sample-<span class="nt">&lt;/data_path&gt;</span>
<span class="nt">&lt;N_theory&gt;</span>5000<span class="nt">&lt;/N_theory&gt;</span>
<span class="nt">&lt;energy_list&gt;</span>
<span class="nt">&lt;energy_label&gt;</span>02_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="nt">&lt;energy&gt;</span>2.0<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy_label&gt;</span>03_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="nt">&lt;energy&gt;</span>3.0<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy_label&gt;</span>03_6<span class="nt">&lt;/energy_label&gt;</span>
<span class="nt">&lt;energy&gt;</span>3.6<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy_label&gt;</span>05_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="nt">&lt;energy&gt;</span>5.0<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy_label&gt;</span>05_3<span class="nt">&lt;/energy_label&gt;</span>
<span class="nt">&lt;energy&gt;</span>5.3<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;/energy_list&gt;</span>
<span class="nt">&lt;/LEM&gt;</span>
<span class="w"> </span><span class="nt">&lt;debug&gt;</span>0<span class="nt">&lt;/debug&gt;</span>
<span class="w"> </span><span class="nt">&lt;wisdom&gt;</span>/home/user/WordsOfWisdom.dat<span class="nt">&lt;/wisdom&gt;</span>
<span class="w"> </span><span class="nt">&lt;delta_t&gt;</span>0.01<span class="nt">&lt;/delta_t&gt;</span>
<span class="w"> </span><span class="nt">&lt;delta_B&gt;</span>0.5<span class="nt">&lt;/delta_B&gt;</span>
<span class="w"> </span><span class="nt">&lt;VortexLattice&gt;</span>
<span class="w"> </span><span class="nt">&lt;N_VortexGrid&gt;</span>1024<span class="nt">&lt;/N_VortexGrid&gt;</span>
<span class="w"> </span><span class="nt">&lt;/VortexLattice&gt;</span>
<span class="w"> </span><span class="nt">&lt;LEM&gt;</span>
<span class="w"> </span><span class="nt">&lt;data_path&gt;</span>/home/user/TrimSP/some-sample-<span class="nt">&lt;/data_path&gt;</span>
<span class="w"> </span><span class="nt">&lt;N_theory&gt;</span>5000<span class="nt">&lt;/N_theory&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_list&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_label&gt;</span>02_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>2.0<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_label&gt;</span>03_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>3.0<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_label&gt;</span>03_6<span class="nt">&lt;/energy_label&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>3.6<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_label&gt;</span>05_0<span class="nt">&lt;/energy_label&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>5.0<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_label&gt;</span>05_3<span class="nt">&lt;/energy_label&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>5.3<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;/energy_list&gt;</span>
<span class="w"> </span><span class="nt">&lt;/LEM&gt;</span>
<span class="nt">&lt;/BMW&gt;</span>
</pre></div>
</div>
</div>
</div>
</div>
<div class="section" id="supeconducting-gap-integrals-to-calculate-vs">
<span id="gap-integral-libs"></span><span id="index-14"></span><h2>Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span><a class="headerlink" href="#supeconducting-gap-integrals-to-calculate-vs" title="Permalink to this headline"></a></h2>
</section>
</section>
</section>
<section id="supeconducting-gap-integrals-to-calculate-1-lambda-2-vs-t">
<span id="gap-integral-libs"></span><span id="index-14"></span><h2>Supeconducting Gap-Integrals to calculate <span class="math notranslate nohighlight">\(1/\lambda^2\)</span> vs <span class="math notranslate nohighlight">\(T\)</span><a class="headerlink" href="#supeconducting-gap-integrals-to-calculate-1-lambda-2-vs-t" title="Link to this heading"></a></h2>
<p>The details about the various superconducting gap-integrals are found in the
pdf-file <strong>GapIntegrals.pdf</strong> which can be found in the musrfit source under
<code class="docutils literal notranslate"><span class="pre">&lt;musrfit-dir&gt;/src/external/libGapIntegrals/</span></code>.</p>
</div>
<div class="section" id="nonlocal-superconductivity-related-meissner-screening-functions-as-libs">
<span id="nonlocal-libs"></span><span id="index-15"></span><h2>Nonlocal superconductivity related Meissner screening functions (AS libs)<a class="headerlink" href="#nonlocal-superconductivity-related-meissner-screening-functions-as-libs" title="Permalink to this headline"></a></h2>
</section>
<section id="nonlocal-superconductivity-related-meissner-screening-functions-as-libs">
<span id="nonlocal-libs"></span><span id="index-15"></span><h2>Nonlocal superconductivity related Meissner screening functions (AS libs)<a class="headerlink" href="#nonlocal-superconductivity-related-meissner-screening-functions-as-libs" title="Link to this heading"></a></h2>
<p>This library allows to calculate the magnetic field profile <span class="math notranslate nohighlight">\(B(z)\)</span> for nonlocal superconductors.
For details see <a class="reference external" href="http://dx.doi.org/10.1103/PhysRevLett.95.197201">A. Suter, et al., PRB 72, 024506 (2005)</a>, and references therein.</p>
<p>The provided function calculates the muon spin polarization</p>
@@ -526,45 +445,45 @@ The corresponding user function is called as</p>
</div>
<p>with the parameters</p>
<ol class="arabic simple">
<li>implantation energy in (keV).</li>
<li>reduced temperature <span class="math notranslate nohighlight">\(t=T/T_c\)</span>.</li>
<li>thickness in (nm).</li>
<li>electron mean path, <span class="math notranslate nohighlight">\(\ell\)</span> in (nm).</li>
<li>superconducting coherence length, <span class="math notranslate nohighlight">\(\xi\)</span> in (nm).</li>
<li>London penetration length, <span class="math notranslate nohighlight">\(\lambda_{\rm L}\)</span> in (nm).</li>
<li>external magnetic field strength in (G).</li>
<li>the effective detector phase, <span class="math notranslate nohighlight">\(\varphi\)</span> in <span class="math notranslate nohighlight">\((^\circ)\)</span>.</li>
<li>a “dead layer” thickness in (nm).</li>
<li><p>implantation energy in (keV).</p></li>
<li><p>reduced temperature <span class="math notranslate nohighlight">\(t=T/T_c\)</span>.</p></li>
<li><p>thickness in (nm).</p></li>
<li><p>electron mean path, <span class="math notranslate nohighlight">\(\ell\)</span> in (nm).</p></li>
<li><p>superconducting coherence length, <span class="math notranslate nohighlight">\(\xi\)</span> in (nm).</p></li>
<li><p>London penetration length, <span class="math notranslate nohighlight">\(\lambda_{\rm L}\)</span> in (nm).</p></li>
<li><p>external magnetic field strength in (G).</p></li>
<li><p>the effective detector phase, <span class="math notranslate nohighlight">\(\varphi\)</span> in <span class="math notranslate nohighlight">\((^\circ)\)</span>.</p></li>
<li><p>a “dead layer” thickness in (nm).</p></li>
</ol>
<p>Typically this function needs to be multiplied by a Gaussian in order to take into account: nuclear dipole broadening, partial trapped flux, etc.</p>
<p>In order to find the muon stopping profile, <span class="math notranslate nohighlight">\(n(z,E)\)</span>, needed for the calculation, the library needs to find the corresponding trimsp
rge-files (muon stoppping profiles). For this the library reads at start-up the following xml-file (example):</p>
<div class="highlight-xml notranslate"><div class="highlight"><pre><span></span><span class="cp">&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;</span>
<span class="nt">&lt;nonlocal</span> <span class="na">xmlns=</span><span class="s">&quot;http://nemu.web.psi.ch/musrfit/nonlocal&quot;</span><span class="nt">&gt;</span>
<span class="nt">&lt;comment&gt;</span>
nonlocal_startup.xml
<span class="nt">&lt;/comment&gt;</span>
<span class="nt">&lt;nonlocal_par&gt;</span>
<span class="nt">&lt;fourier_points&gt;</span>262144<span class="nt">&lt;/fourier_points&gt;</span>
<span class="nt">&lt;/nonlocal_par&gt;</span>
<span class="nt">&lt;trim_sp&gt;</span>
<span class="nt">&lt;data_path&gt;</span>./profiles/<span class="nt">&lt;/data_path&gt;</span>
<span class="nt">&lt;rge_fln_pre&gt;</span>Sn_E<span class="nt">&lt;/rge_fln_pre&gt;</span>
<span class="nt">&lt;energy_list&gt;</span>
<span class="nt">&lt;energy&gt;</span>1000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>2000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>4000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>6000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>8000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>10000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>12000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>14100<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>18000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>22000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>25000<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;energy&gt;</span>27300<span class="nt">&lt;/energy&gt;</span>
<span class="nt">&lt;/energy_list&gt;</span>
<span class="nt">&lt;/trim_sp&gt;</span>
<span class="nt">&lt;nonlocal</span><span class="w"> </span><span class="na">xmlns=</span><span class="s">&quot;http://nemu.web.psi.ch/musrfit/nonlocal&quot;</span><span class="nt">&gt;</span>
<span class="w"> </span><span class="nt">&lt;comment&gt;</span>
<span class="w"> </span>nonlocal_startup.xml
<span class="w"> </span><span class="nt">&lt;/comment&gt;</span>
<span class="w"> </span><span class="nt">&lt;nonlocal_par&gt;</span>
<span class="w"> </span><span class="nt">&lt;fourier_points&gt;</span>262144<span class="nt">&lt;/fourier_points&gt;</span>
<span class="w"> </span><span class="nt">&lt;/nonlocal_par&gt;</span>
<span class="w"> </span><span class="nt">&lt;trim_sp&gt;</span>
<span class="w"> </span><span class="nt">&lt;data_path&gt;</span>./profiles/<span class="nt">&lt;/data_path&gt;</span>
<span class="w"> </span><span class="nt">&lt;rge_fln_pre&gt;</span>Sn_E<span class="nt">&lt;/rge_fln_pre&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_list&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>1000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>2000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>4000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>6000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>8000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>10000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>12000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>14100<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>18000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>22000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>25000<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy&gt;</span>27300<span class="nt">&lt;/energy&gt;</span>
<span class="w"> </span><span class="nt">&lt;/energy_list&gt;</span>
<span class="w"> </span><span class="nt">&lt;/trim_sp&gt;</span>
<span class="nt">&lt;/nonlocal&gt;</span>
</pre></div>
</div>
@@ -574,9 +493,9 @@ contains all the information needed to load the proper muon stopping profiles. <
muon stopping profile for an energy of <span class="math notranslate nohighlight">\(E=1000\)</span> (eV).</p>
<p>The name of the xml-file has to be <code class="docutils literal notranslate"><span class="pre">nonlocal_startup.xml</span></code> and needs to be placed in the directory where the analysis takes place, i.e.
in the directory of all the msr-files.</p>
</div>
<div class="section" id="depth-resolved-information-as-libs">
<span id="depthprof-lib"></span><span id="index-16"></span><h2>Depth resolved information (AS libs)<a class="headerlink" href="#depth-resolved-information-as-libs" title="Permalink to this headline"></a></h2>
</section>
<section id="depth-resolved-information-as-libs">
<span id="depthprof-lib"></span><span id="index-16"></span><h2>Depth resolved information (AS libs)<a class="headerlink" href="#depth-resolved-information-as-libs" title="Link to this heading"></a></h2>
<p>A method to extract depth-resolved information from the implantation energy dependence of the experimental parameters in a low-energy
muon spin spectroscopy experiment. For details see <a class="reference external" href="https://doi.org/10.1063/1.5126529">A. F. A. Simões, et al. Review of Scientific Instruments. 2020; 91(2): 023906 (7 pp.)</a>.</p>
<p>If you have a layered material (e.g. <span class="math notranslate nohighlight">\(N\)</span> layers), properties like the asymmetry might depend on the layer in which the muons are stopped.
@@ -590,8 +509,8 @@ Hence the measured property as function of energy is</p>
<div class="math notranslate nohighlight">
\[f(E) = \sum_{i=1}^N p_{i}(E) \cdot f_i.\]</div>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Currently it is recommended to read in the data in ASCII or DAT format as a non-μSR fit <a class="reference internal" href="user-manual.html#non-musr-fit"><span class="std std-ref">(fit type 8)</span></a>.</p>
<p class="admonition-title">Note</p>
<p>Currently it is recommended to read in the data in ASCII or DAT format as a non-μSR fit <a class="reference internal" href="user-manual.html#non-musr-fit"><span class="std std-ref">(fit type 8)</span></a>.</p>
</div>
<p>The user library for the depth profile analysis looks for a <strong>3 layer material</strong>, assuming one is looking for the diamagnetic fraction, like</p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="c1">###############################################################</span>
@@ -612,33 +531,33 @@ Hence the measured property as function of energy is</p>
<p>In order to find the muon stopping profile, <span class="math notranslate nohighlight">\(n(z,E)\)</span>, needed for the calculation, the library needs to find the corresponding trimsp
rge-files (muon stoppping profiles). For this the library reads at start-up the following xml-file (example):</p>
<div class="highlight-xml notranslate"><div class="highlight"><pre><span></span><span class="cp">&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;</span>
<span class="nt">&lt;depthProf</span> <span class="na">xmlns=</span><span class="s">&quot;http://nemu.web.psi.ch/musrfit/depthProf&quot;</span><span class="nt">&gt;</span>
<span class="nt">&lt;comment&gt;</span>
TrimSp information
<span class="nt">&lt;/comment&gt;</span>
<span class="nt">&lt;trim_sp&gt;</span>
<span class="nt">&lt;data_path&gt;</span>./TRIMSP/<span class="nt">&lt;/data_path&gt;</span>
<span class="nt">&lt;rge_fln_pre&gt;</span>SiO2_70nm2.0_30nm2.2_SiC_E<span class="nt">&lt;/rge_fln_pre&gt;</span>
<span class="nt">&lt;energy_vect</span> <span class="na">start=</span><span class="s">&quot;1000&quot;</span> <span class="na">stop=</span><span class="s">&quot;22000&quot;</span> <span class="na">step=</span><span class="s">&quot;1000&quot;</span><span class="nt">/&gt;</span>
<span class="nt">&lt;/trim_sp&gt;</span>
<span class="nt">&lt;depthProf</span><span class="w"> </span><span class="na">xmlns=</span><span class="s">&quot;http://nemu.web.psi.ch/musrfit/depthProf&quot;</span><span class="nt">&gt;</span>
<span class="w"> </span><span class="nt">&lt;comment&gt;</span>
<span class="w"> </span>TrimSp<span class="w"> </span>information
<span class="w"> </span><span class="nt">&lt;/comment&gt;</span>
<span class="w"> </span><span class="nt">&lt;trim_sp&gt;</span>
<span class="w"> </span><span class="nt">&lt;data_path&gt;</span>./TRIMSP/<span class="nt">&lt;/data_path&gt;</span>
<span class="w"> </span><span class="nt">&lt;rge_fln_pre&gt;</span>SiO2_70nm2.0_30nm2.2_SiC_E<span class="nt">&lt;/rge_fln_pre&gt;</span>
<span class="w"> </span><span class="nt">&lt;energy_vect</span><span class="w"> </span><span class="na">start=</span><span class="s">&quot;1000&quot;</span><span class="w"> </span><span class="na">stop=</span><span class="s">&quot;22000&quot;</span><span class="w"> </span><span class="na">step=</span><span class="s">&quot;1000&quot;</span><span class="nt">/&gt;</span>
<span class="w"> </span><span class="nt">&lt;/trim_sp&gt;</span>
<span class="nt">&lt;/depthProf&gt;</span>
</pre></div>
</div>
</div>
<div class="section" id="functions-to-analyze-bgr-nmr-data-bnmr-libs">
<span id="bnmr-libs"></span><span id="index-17"></span><h2>Functions to analyze β-NMR data (BNMR libs)<a class="headerlink" href="#functions-to-analyze-bgr-nmr-data-bnmr-libs" title="Permalink to this headline"></a></h2>
<p>This is a collection of <code class="docutils literal notranslate"><span class="pre">C++</span></code> classes using the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> <a class="reference internal" href="user-manual.html#id38"><span class="std std-ref">user-functions</span></a>
</section>
<section id="functions-to-analyze-bgr-nmr-data-bnmr-libs">
<span id="bnmr-libs"></span><span id="index-17"></span><h2>Functions to analyze β-NMR data (BNMR libs)<a class="headerlink" href="#functions-to-analyze-bgr-nmr-data-bnmr-libs" title="Link to this heading"></a></h2>
<p>This is a collection of <code class="docutils literal notranslate"><span class="pre">C++</span></code> classes using the <code class="docutils literal notranslate"><span class="pre">musrfit</span></code> <a class="reference internal" href="user-manual.html#id41"><span class="std std-ref">user-functions</span></a>
interface in order to facilitate the usage in conjunction with <code class="docutils literal notranslate"><span class="pre">musrfit</span></code>. It consists of two libraries:</p>
<ul class="simple">
<li><code class="docutils literal notranslate"><span class="pre">libBNMR</span></code> contains functions to fit spin lattice relaxation (SLR) data.</li>
<li><code class="docutils literal notranslate"><span class="pre">libLineProfile</span></code> contains functions to fit resonance lineshapes.</li>
<li><p><code class="docutils literal notranslate"><span class="pre">libBNMR</span></code> contains functions to fit spin lattice relaxation (SLR) data.</p></li>
<li><p><code class="docutils literal notranslate"><span class="pre">libLineProfile</span></code> contains functions to fit resonance lineshapes.</p></li>
</ul>
<div class="admonition note">
<p class="first admonition-title">Note</p>
<p class="last">Currently it is recommended to read in the data in ASCII format as a non-μSR fit <a class="reference internal" href="user-manual.html#non-musr-fit"><span class="std std-ref">(fit type 8)</span></a>.</p>
<p class="admonition-title">Note</p>
<p>Currently it is recommended to read in the data in ASCII format as a non-μSR fit <a class="reference internal" href="user-manual.html#non-musr-fit"><span class="std std-ref">(fit type 8)</span></a>.</p>
</div>
<div class="section" id="libbnmr">
<span id="index-18"></span><h3>libBNMR<a class="headerlink" href="#libbnmr" title="Permalink to this headline"></a></h3>
<section id="libbnmr">
<span id="index-18"></span><h3>libBNMR<a class="headerlink" href="#libbnmr" title="Link to this heading"></a></h3>
<p>In β-NMR the SLR is usually measured by implanting a pulse of <span class="math notranslate nohighlight">\(^8\)</span>Li with a length <span class="math notranslate nohighlight">\(t_0\)</span> into the sample.
The asymmetry is measured both during the pulse and afterwards. For a a general spin relaxation function <span class="math notranslate nohighlight">\(f(t)\)</span> the time evolution of the asymmetry is then given by [<a class="reference external" href="http://dx.doi.org/10.1103/PhysRevLett.96.147601">Z. Salman, et al., PRL 96, 147601 (2006)</a>]:</p>
<div class="math notranslate nohighlight" id="slr">
@@ -647,8 +566,8 @@ The asymmetry is measured both during the pulse and afterwards. For a a general
\frac{\int_0^{t_0}e^{-(t_0-t')/\tau_{\mathrm{Li}}}f(t-t')dt'}{\int_0^{t_0}e^{-t'/\tau_{\mathrm{Li}}}dt'} &amp; t&gt; t_0,
\end{matrix}\right.\end{split}\]</div>
<p>where <span class="math notranslate nohighlight">\(\tau_{\mathrm{Li}}=1.21\)</span>s is the <span class="math notranslate nohighlight">\(^8\)</span>Li lifetime.</p>
<div class="section" id="functions">
<h4>Functions<a class="headerlink" href="#functions" title="Permalink to this headline"></a></h4>
<section id="functions">
<h4>Functions<a class="headerlink" href="#functions" title="Link to this heading"></a></h4>
<p>The <code class="docutils literal notranslate"><span class="pre">libBNMR</span></code> library currently contains the following functions:</p>
<p id="index-20"><strong>Exponential relaxation</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libBNMR</span> <span class="n">ExpRlx</span> <span class="mi">1</span> <span class="mi">2</span>
@@ -656,8 +575,8 @@ The asymmetry is measured both during the pulse and afterwards. For a a general
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>pulse length <span class="math notranslate nohighlight">\(t_0\)</span> (s)</li>
<li>relaxation rate <span class="math notranslate nohighlight">\(\lambda\)</span> (s<span class="math notranslate nohighlight">\(^{-1}\)</span>)</li>
<li><p>pulse length <span class="math notranslate nohighlight">\(t_0\)</span> (s)</p></li>
<li><p>relaxation rate <span class="math notranslate nohighlight">\(\lambda\)</span> (s<span class="math notranslate nohighlight">\(^{-1}\)</span>)</p></li>
</ol>
<p>This function implements <span class="math notranslate nohighlight">\(f(t)=e^{-\lambda t}\)</span>.</p>
<p id="index-21"><strong>Stretched exponential relaxation</strong></p>
@@ -666,15 +585,15 @@ The asymmetry is measured both during the pulse and afterwards. For a a general
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>pulse length <span class="math notranslate nohighlight">\(t_0\)</span> (s)</li>
<li>relaxation rate <span class="math notranslate nohighlight">\(\lambda\)</span> (s<span class="math notranslate nohighlight">\(^{-1}\)</span>)</li>
<li>stretching exponent <span class="math notranslate nohighlight">\(\beta\)</span></li>
<li><p>pulse length <span class="math notranslate nohighlight">\(t_0\)</span> (s)</p></li>
<li><p>relaxation rate <span class="math notranslate nohighlight">\(\lambda\)</span> (s<span class="math notranslate nohighlight">\(^{-1}\)</span>)</p></li>
<li><p>stretching exponent <span class="math notranslate nohighlight">\(\beta\)</span></p></li>
</ol>
<p>This function implements <span class="math notranslate nohighlight">\(f(t)=e^{-(\lambda t)^{\beta}}\)</span>.</p>
</div>
</div>
<div class="section" id="liblineprofile">
<span id="index-22"></span><h3>libLineProfile<a class="headerlink" href="#liblineprofile" title="Permalink to this headline"></a></h3>
</section>
</section>
<section id="liblineprofile">
<span id="index-22"></span><h3>libLineProfile<a class="headerlink" href="#liblineprofile" title="Link to this heading"></a></h3>
<p>In addition to some simple line shapes <code class="docutils literal notranslate"><span class="pre">libLineProfile</span></code> contains functions to fit chemical shift anisotropies in the powder average.
Their functional form can be found in <a class="reference external" href="http://dx.doi.org/10.1007/978-3-642-68756-3_2">M. Mehring, Principles of High Resolution NMR in Solids (Springer 1983)</a>.</p>
<p>For an axially symmetric interaction it is given by:</p>
@@ -699,8 +618,8 @@ m&amp;=\left\{\begin{matrix}
\\
K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\end{split}\]</div>
<p><span class="math notranslate nohighlight">\(K(m)\)</span> is the complete elliptic integral of the first kind.</p>
<div class="section" id="id1">
<h4>Functions<a class="headerlink" href="#id1" title="Permalink to this headline"></a></h4>
<section id="id1">
<h4>Functions<a class="headerlink" href="#id1" title="Link to this heading"></a></h4>
<p>The <code class="docutils literal notranslate"><span class="pre">libLineProfile</span></code> library currently contains the following functions:</p>
<p id="index-25"><strong>Gaussian</strong></p>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">userFcn</span> <span class="n">libLineProfile</span> <span class="n">LineGauss</span> <span class="mi">1</span> <span class="mi">2</span>
@@ -708,8 +627,8 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></li>
<li>FWHM of the line <span class="math notranslate nohighlight">\(\sigma\)</span></li>
<li><p>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></p></li>
<li><p>FWHM of the line <span class="math notranslate nohighlight">\(\sigma\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is 1.</div>
@@ -723,8 +642,8 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></li>
<li>FWHM of the line <span class="math notranslate nohighlight">\(w\)</span></li>
<li><p>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></p></li>
<li><p>FWHM of the line <span class="math notranslate nohighlight">\(w\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is 1.</div>
@@ -738,8 +657,8 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></li>
<li>FWHM of the line <span class="math notranslate nohighlight">\(w\)</span></li>
<li><p>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></p></li>
<li><p>FWHM of the line <span class="math notranslate nohighlight">\(w\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is 1.</div>
@@ -753,9 +672,9 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></li>
<li>width of the line <span class="math notranslate nohighlight">\(w\)</span></li>
<li>skewness parameter <span class="math notranslate nohighlight">\(a\)</span></li>
<li><p>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></p></li>
<li><p>width of the line <span class="math notranslate nohighlight">\(w\)</span></p></li>
<li><p>skewness parameter <span class="math notranslate nohighlight">\(a\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is 1.</div>
@@ -769,9 +688,9 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></li>
<li>width left of the center <span class="math notranslate nohighlight">\(w_1\)</span></li>
<li>width right of the center <span class="math notranslate nohighlight">\(w_2\)</span></li>
<li><p>center of the line <span class="math notranslate nohighlight">\(f_0\)</span></p></li>
<li><p>width left of the center <span class="math notranslate nohighlight">\(w_1\)</span></p></li>
<li><p>width right of the center <span class="math notranslate nohighlight">\(w_2\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is 1.</div>
@@ -785,9 +704,9 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>frequency for the field oriented paralell to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></li>
<li>frequency for the field oriented perpendicular to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></li>
<li>FWHM of the Lorentzian <span class="math notranslate nohighlight">\(w\)</span></li>
<li><p>frequency for the field oriented paralell to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></p></li>
<li><p>frequency for the field oriented perpendicular to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></p></li>
<li><p>FWHM of the Lorentzian <span class="math notranslate nohighlight">\(w\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is <span class="math notranslate nohighlight">\(\sim\)</span>1.</div>
@@ -802,9 +721,9 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li>frequency for the field oriented paralell to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></li>
<li>frequency for the field oriented perpendicular to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></li>
<li>FWHM of the Gaussian <span class="math notranslate nohighlight">\(\sigma\)</span></li>
<li><p>frequency for the field oriented paralell to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></p></li>
<li><p>frequency for the field oriented perpendicular to the symmetry axis <span class="math notranslate nohighlight">\(f_\parallel\)</span></p></li>
<li><p>FWHM of the Gaussian <span class="math notranslate nohighlight">\(\sigma\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is <span class="math notranslate nohighlight">\(\sim\)</span>1.</div>
@@ -819,10 +738,10 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li><span class="math notranslate nohighlight">\(f_1\)</span></li>
<li><span class="math notranslate nohighlight">\(f_1\)</span></li>
<li><span class="math notranslate nohighlight">\(f_3\)</span> frequencies along the principal axes</li>
<li>FWHM of the Lorentzian <span class="math notranslate nohighlight">\(w\)</span></li>
<li><p><span class="math notranslate nohighlight">\(f_1\)</span></p></li>
<li><p><span class="math notranslate nohighlight">\(f_1\)</span></p></li>
<li><p><span class="math notranslate nohighlight">\(f_3\)</span> frequencies along the principal axes</p></li>
<li><p>FWHM of the Lorentzian <span class="math notranslate nohighlight">\(w\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is <span class="math notranslate nohighlight">\(\sim\)</span>1.</div>
@@ -837,10 +756,10 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
</div>
<p>The parameters are:</p>
<ol class="arabic simple">
<li><span class="math notranslate nohighlight">\(f_1\)</span></li>
<li><span class="math notranslate nohighlight">\(f_1\)</span></li>
<li><span class="math notranslate nohighlight">\(f_3\)</span> frequencies along the principal axes</li>
<li>FWHM of the Gaussian <span class="math notranslate nohighlight">\(\sigma\)</span></li>
<li><p><span class="math notranslate nohighlight">\(f_1\)</span></p></li>
<li><p><span class="math notranslate nohighlight">\(f_1\)</span></p></li>
<li><p><span class="math notranslate nohighlight">\(f_3\)</span> frequencies along the principal axes</p></li>
<li><p>FWHM of the Gaussian <span class="math notranslate nohighlight">\(\sigma\)</span></p></li>
</ol>
<div class="line-block">
<div class="line">The height of the peak is <span class="math notranslate nohighlight">\(\sim\)</span>1.</div>
@@ -849,75 +768,38 @@ K(m)&amp;=\int_0^{\pi/2}\frac{\mathrm d\varphi}{\sqrt{1-m^2\sin^2{\varphi}}},\en
<div class="math notranslate nohighlight">
\[A(f)= I(f)\circledast\left( e^{-\frac{4\ln 2 (f-f_0)^2}{ \sigma^2}} \right)\]</div>
<p>with <span class="math notranslate nohighlight">\(I(f)\)</span> defined <a class="reference internal" href="#ianiso"><span class="std std-ref">above</span></a>. Note that <span class="math notranslate nohighlight">\(f_1&lt;f_2&lt;f_3\)</span> is not required by the code.</p>
</div>
</div>
</div>
</div>
</section>
</section>
</section>
</section>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="setup-standard.html" class="btn btn-neutral float-right" title="Setting up musrfit on Different Platforms" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="user-manual.html" class="btn btn-neutral" title="User manual" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="user-manual.html" class="btn btn-neutral float-left" title="User manual" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
<a href="setup-standard.html" class="btn btn-neutral float-right" title="Setting up musrfit on Different Platforms" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2023, Andreas Suter.
Last updated on Apr 23, 2024.
</p>
<p>&#169; Copyright 2025, Andreas Suter.
<span class="lastupdated">Last updated on Jun 07, 2025.
</span></p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT:'./',
VERSION:'1.9.3',
LANGUAGE:'None',
COLLAPSE_INDEX:false,
FILE_SUFFIX:'.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="_static/jquery.js"></script>
<script type="text/javascript" src="_static/underscore.js"></script>
<script type="text/javascript" src="_static/doctools.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<script type="text/javascript">
<script>
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});

File diff suppressed because it is too large Load Diff

View File

@@ -733,9 +733,10 @@ WARN_LOGFILE =
# spaces.
# Note: If this tag is empty the current directory is searched.
INPUT =../src/musredit_qt5/mupp \
../src/musredit_qt5/mupp/var/include \
../src/musredit_qt5/mupp/var/src
INPUT = ./ \
../src/musredit_qt5/mupp \
../src/musredit_qt5/mupp/var/include \
../src/musredit_qt5/mupp/var/src
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
@@ -755,7 +756,7 @@ INPUT_ENCODING = UTF-8
# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf,
# *.qsf, *.as and *.js.
FILE_PATTERNS = *.dox *.cpp *.h *.hpp
FILE_PATTERNS = mupp.dox *.cpp *.h *.hpp
# The RECURSIVE tag can be used to specify whether or not subdirectories should
# be searched for input files as well.
@@ -1532,7 +1533,7 @@ EXTRA_SEARCH_MAPPINGS =
# If the GENERATE_LATEX tag is set to YES doxygen will generate LaTeX output.
# The default value is: YES.
GENERATE_LATEX = YES
GENERATE_LATEX = NO
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of

View File

@@ -32,13 +32,13 @@ DOXYFILE_ENCODING = UTF-8
# title of most generated pages and in a few other places.
# The default value is: My Project.
PROJECT_NAME = "musredit"
PROJECT_NAME = "mupp"
# The PROJECT_NUMBER tag can be used to enter a project or revision number. This
# could be handy for archiving the generated documentation or if some version
# control system is used.
PROJECT_NUMBER = 1.0.0
PROJECT_NUMBER = 1.1.0
# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
@@ -58,7 +58,7 @@ PROJECT_LOGO =
# entered, it will be relative to the location where doxygen was started. If
# left blank the current directory will be used.
OUTPUT_DIRECTORY = ./technical/html/musredit
OUTPUT_DIRECTORY = ./technical/html/mupp
# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub-
# directories (in 2 levels) under the output directory of each output format and
@@ -733,7 +733,10 @@ WARN_LOGFILE =
# spaces.
# Note: If this tag is empty the current directory is searched.
INPUT =../src/musredit_qt5/musredit
INPUT = ./ \
../src/musredit_qt6/mupp \
../src/musredit_qt6/mupp/var/include \
../src/musredit_qt6/mupp/var/src
# This tag can be used to specify the character encoding of the source files
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
@@ -753,7 +756,7 @@ INPUT_ENCODING = UTF-8
# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf,
# *.qsf, *.as and *.js.
FILE_PATTERNS = *.dox *.cpp *.h
FILE_PATTERNS = mupp.dox *.cpp *.h *.hpp
# The RECURSIVE tag can be used to specify whether or not subdirectories should
# be searched for input files as well.
@@ -1530,7 +1533,7 @@ EXTRA_SEARCH_MAPPINGS =
# If the GENERATE_LATEX tag is set to YES doxygen will generate LaTeX output.
# The default value is: YES.
GENERATE_LATEX = YES
GENERATE_LATEX = NO
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
@@ -1969,7 +1972,7 @@ TAGFILES =
# tag file that is based on the input files it reads. See section "Linking to
# external documentation" for more information about the usage of tag files.
GENERATE_TAGFILE = dox-tags/musredit.tag
GENERATE_TAGFILE = dox-tags/mupp.tag
# If the ALLEXTERNALS tag is set to YES all external class will be listed in the
# class index. If set to NO only the inherited external classes will be listed.

View File

@@ -12,8 +12,7 @@
\mainpage musredit
<p>musredit is a simple editor based interface to the musrfit programs. It is based on Qt 5.5
of The Qt Company (<code>http://www.qt.io</code>).
<p>musredit is a simple editor based interface to the musrfit programs. It is based on Qt5.x or Qt6.x (depending of your distro) of The Qt Company (<code>http://www.qt.io</code>).
<p>musredit is free software liensenced under GPL 2 or later (for detail license informations see
<code>http://www.gnu.org/licenses</code>).

2567
doc/musredit_qt5_dox.cfg Normal file

File diff suppressed because it is too large Load Diff

2567
doc/musredit_qt6_dox.cfg Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -16,18 +16,18 @@
<p>People merely interested in the handling of the programs should check this link:
\htmlonly
<a href="http://lmu.web.psi.ch/musrfit/user/html/index.html">musrfit user manual</a>
<a href="https://lmu.pages.psi.ch/musrfit-docu/">musrfit user manual</a>
\endhtmlonly
\latexonly
musrfit user manual: \texttt{http://lmu.web.psi.ch/musrfit/user/html/index.html}
musrfit user manual: \texttt{https://lmu.pages.psi.ch/musrfit-docu/user-manual.html}
\endlatexonly
<p>People which would like to know how to install the musrfit framework, please check this link:
\htmlonly
<a href="http://lmu.web.psi.ch/musrfit/user/html/setup-standard.html">How to setup musrfit on different platforms</a>
<a href="https://lmu.pages.psi.ch/musrfit-docu/setup-standard.html">How to setup musrfit on different platforms</a>
\endhtmlonly
\latexonly
How to setup musrfit on different platforms: \texttt{http://lmu.web.psi.ch/musrfit/user/html/setup-standard.html}
How to setup musrfit on different platforms: \texttt{https://lmu.pages.psi.ch/musrfit-docu/setup-standard.html}
\endlatexonly
//****************************************************************************************************
@@ -47,15 +47,13 @@ under Linux, Mac OS X, and (with some more work) under Windows. The musrfit fram
msr-files with the same parameters and summarize the fitting results either in a TRIUMF DB or a column ASCII file.
- **msr2msr**: old WKM like msr-files can be transformed into musrfit style msr-files with this little program.
- musrgui (obsolete): an editor to handle msr-files, calling musrfit, etc. from within the editor, based on Qt3.x.
Only bug fixing will be done on this version, and if you have >= Qt4.6 available you should use musredit instead.
- **musredit**: an editor to handle msr-files, calling musrfit, etc. from within a simple text editor, based on >= Qt4.6. A technical documentation of musredit can be found
- **musredit**: an editor to handle msr-files, calling musrfit, etc. from within a simple text editor, based on Qt5.x or Qt6.x. A technical documentation of musredit can be found
\htmlonly <a href="./musredit/html/index.html">here.</a>\endhtmlonly
- **musrWiz** (beta): allows to create an initial msr-file by a step-by-step instruction wizard.
- **musrStep**: allows to efficiently deal with initial step values of msr-files. Especially useful for msr-files dealing with many runs/detectors.
- **mupp**: is the muSR parameter plotter. It allows to plot values in db- or dat-files (collections). A technical documentation of mupp can be found
\htmlonly <a href="./mupp/html/index.html">here.</a>\endhtmlonly
- **MuSRFit**: a graphical user interface based on PerlQt (written by Z. Salman) for an easy to use interface to the musrfit framework.
Compared to the more general approach of writing msr-files, it has some limitations, though it might be easier for a first user of the musrfit framework.
- **addRun**: allows to add runs from the command line
- **any2many**: should be a "universal" muSR data-file-format converter.
- **dump_header**: is a small program to dump the header information of a muSR data file to the standard output.
- **musrRootValidation**: this is a program to validate MusrRoot files.
@@ -79,7 +77,11 @@ This two points are somewhat contradictory, and currently it is not clear which
\section bugs How to report bugs
<p>Bugs, unexpected features, can be reported directly to me: \verbatim andreas.suter@psi.ch, \endverbatim or entered in the bug-tracking tool at
bitbkucket \verbatim https://bitbucket.org/muonspin/musrfit/issues \endverbatim.
<p>Bugs, unexpected features, can be reported directly to me: \verbatim andreas.suter@psi.ch, \endverbatim or entered in the bug-tracking tool at \htmlonly
<a href="https://bitbucket.org/muonspin/musrfit/issues">bitbucket issue tracker</a>
\endhtmlonly
\latexonly
\verbatim https://bitbucket.org/muonspin/musrfit/issues \endverbatim.
\endlatexonly
*/

File diff suppressed because it is too large Load Diff

View File

@@ -22,38 +22,6 @@ if (nexus)
endif (nexus)
set(MUSRFIT_LIBS ${MUSRFIT_LIBS} PMusr)
#--- start create git-revision.h ----------------------------------------------
if (IS_GIT_REPO)
configure_file(
${CMAKE_SOURCE_DIR}/cmake/configure_musrfit_version_file.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/configure_musrfit_version_file.cmake
@ONLY
)
add_custom_command(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/git-revision.h
COMMAND ${CMAKE_COMMAND} -P
${CMAKE_CURRENT_BINARY_DIR}/configure_musrfit_version_file.cmake
DEPENDS
${CMAKE_CURRENT_BINARY_DIR}/configure_musrfit_version_file.cmake
${CMAKE_SOURCE_DIR}/cmake/git-revision.h.in
COMMENT "Configuring git-revision.h"
VERBATIM
)
add_custom_target(
configure_musrfit_version ALL
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/git-revision.h
)
set(HAVE_GIT_REV_H "-DHAVE_GIT_REV_H")
set(GIT_REV_H "git-revision.h")
else (IS_GIT_REPO)
set(HAVE_GIT_REV_H "")
set(GIT_REV_H "")
endif (IS_GIT_REPO)
#--- end create git-revision.h ------------------------------------------------
#--- add all executables ------------------------------------------------------
add_executable(addRun ${GIT_REV_H} addRun.cpp)
target_compile_options(addRun BEFORE PRIVATE "-DHAVE_CONFIG_H" "${HAVE_GIT_REV_H}")

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -85,7 +85,7 @@ void any2many_syntax()
std::cout << std::endl << " <inFormat> : input data file format. Supported formats are:";
std::cout << std::endl << " MusrRoot, PSI-BIN, ROOT (LEM), MUD, NeXus, PSI-MDU, WKM";
std::cout << std::endl << " <outFormat> : ouput data file format. Supported formats are:";
std::cout << std::endl << " PSI-BIN, MusrRoot, ROOT, MUD, NeXus1-HDF4, NeXus1-HDF5, NeXus1-XML,";
std::cout << std::endl << " PSI-BIN, MusrRoot, MusrRootDir, ROOT, MUD, NeXus1-HDF4, NeXus1-HDF5, NeXus1-XML,";
std::cout << std::endl << " NeXus2-HDF4, NeXus2-HDF5, NeXus2-XML, WKM, ASCII";
std::cout << std::endl << " Comment: ROOT is superseeded by MusrRoot. If there is not a very good";
std::cout << std::endl << " reason, avoid it!";
@@ -109,6 +109,10 @@ void any2many_syntax()
std::cout << std::endl << " generated according to the input data file name, and the output data";
std::cout << std::endl << " format.";
std::cout << std::endl;
std::cout << std::endl << "NOTE to MusrRoot and MusrRootDir <outFormat>: MusrRoot will convert to the deprecated TFolder format,";
std::cout << std::endl << " whereas MusrRootDir will convert to the TDirectory based format. Typically MusrRootDir should be the";
std::cout << std::endl << " preferred MusrRoot-file-format output format.";
std::cout << std::endl;
std::cout << std::endl << "examples:" << std::endl;
std::cout << std::endl << " any2many -f 2010/lem10_his_0123.root -c ROOT ASCII -rebin 25";
std::cout << std::endl << " Will take the LEM ROOT file '2010/lem10_his_0123.root' rebin it with 25";
@@ -172,6 +176,7 @@ int main(int argc, char *argv[])
// init outputFormat
outputFormat.push_back("psi-bin");
outputFormat.push_back("musrroot");
outputFormat.push_back("musrrootdir");
outputFormat.push_back("root");
outputFormat.push_back("mud");
outputFormat.push_back("nexus1-hdf4");

View File

@@ -18,6 +18,15 @@ root_generate_dictionary(
LINKDEF ${MUSRFIT_INC}/PFourierCanvasLinkDef.h
MODULE PFourierCanvas
)
root_generate_dictionary(
PMsgBoxDict
PMsgBox.h
LINKDEF ${MUSRFIT_INC}/PMsgBoxLinkDef.h
OPTIONS
-I${Boost_INCLUDE_DIR} -I${FFTW3_INCLUDE} -I${MUSRFIT_INC}
-inlineInputHeader
MODULE PMsgBox
)
root_generate_dictionary(
PMusrCanvasDict
PMusrCanvas.h
@@ -73,7 +82,7 @@ set(prefix "${CMAKE_INSTALL_PREFIX}")
set(exec_prefix "\$\{prefix\}")
set(libdir "\$\{exec_prefix\}/lib")
set(includedir "\$\{prefix\}/include")
set(MUSR_VERSION "1.4.0")
set(MUSR_VERSION "1.6.0")
set(MUSR_LIBRARY_NAME "PMusr")
configure_file("PMusr.pc.in" "PMusr.pc" @ONLY)
set(USERFCN_LIBRARY_NAME "PUserFcnBase")
@@ -93,6 +102,8 @@ add_library(PMusr SHARED
PMusrCanvasDict.cxx
PFunction.cpp
PFunctionHandler.cpp
PMsgBox.cpp
PMsgBoxDict.cxx
PMsr2Data.cpp
PMsrHandler.cpp
PMusrCanvas.cpp
@@ -204,6 +215,8 @@ install(TARGETS PMusr DESTINATION lib)
install(
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPFourierCanvas_rdict.pcm
${CMAKE_CURRENT_BINARY_DIR}/libPFourierCanvas.rootmap
${CMAKE_CURRENT_BINARY_DIR}/libPMsgBox_rdict.pcm
${CMAKE_CURRENT_BINARY_DIR}/libPMsgBox.rootmap
${CMAKE_CURRENT_BINARY_DIR}/libPMusrCanvas_rdict.pcm
${CMAKE_CURRENT_BINARY_DIR}/libPMusrCanvas.rootmap
${CMAKE_CURRENT_BINARY_DIR}/libPMusrT0_rdict.pcm

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -39,9 +39,10 @@
#include <iomanip>
#include <fstream>
#include <limits>
#include <cmath>
#include <boost/variant/variant.hpp>
#include <sys/time.h>
#include "Minuit2/FunctionMinimum.h"
@@ -54,6 +55,7 @@
#include "Minuit2/MnPrint.h"
#include "Minuit2/MnScan.h"
#include "Minuit2/MnSimplex.h"
#include "Minuit2/MnStrategy.h"
#include "Minuit2/MnUserParameterState.h"
#include "Minuit2/MinosError.h"
@@ -264,8 +266,8 @@ UInt_t PSectorChisq::GetNDF(UInt_t idx)
* \param runListCollection pointer of the run list collection (pre-processed historgrams)
* \param chisq_only flag: true=calculate chisq only (no fitting)
*/
PFitter::PFitter(PMsrHandler *runInfo, PRunListCollection *runListCollection, Bool_t chisq_only) :
fChisqOnly(chisq_only), fRunInfo(runInfo), fRunListCollection(runListCollection)
PFitter::PFitter(PMsrHandler *runInfo, PRunListCollection *runListCollection, Bool_t chisq_only, Bool_t yaml_out) :
fChisqOnly(chisq_only), fYamlOut(yaml_out), fRunInfo(runInfo), fRunListCollection(runListCollection)
{
// initialize variables
fIsScanOnly = true;
@@ -1762,7 +1764,7 @@ Bool_t PFitter::ExecuteMigrad()
// create migrad object
// strategy is by default = 'default'
ROOT::Minuit2::MnMigrad migrad((*fFitterFcn), fMnUserParams, fStrategy);
ROOT::Minuit2::MnMigrad migrad((*fFitterFcn), fMnUserParams, ROOT::Minuit2::MnStrategy{fStrategy});
// minimize
// maxfcn is MINUIT2 Default maxfcn
@@ -1838,7 +1840,7 @@ Bool_t PFitter::ExecuteMinimize()
// create minimizer object
// strategy is by default = 'default'
ROOT::Minuit2::MnMinimize minimize((*fFitterFcn), fMnUserParams, fStrategy);
ROOT::Minuit2::MnMinimize minimize((*fFitterFcn), fMnUserParams, ROOT::Minuit2::MnStrategy{fStrategy});
// minimize
// maxfcn is MINUIT2 Default maxfcn
@@ -2169,23 +2171,30 @@ Bool_t PFitter::ExecuteSave(Bool_t firstSave)
// calculate expected chisq
std::vector<Double_t> param;
std::vector<Double_t> err;
Double_t totalExpectedChisq = 0.0;
std::vector<Double_t> expectedchisqPerRun;
std::vector<UInt_t> ndfPerHisto;
for (UInt_t i=0; i<fParams.size(); i++)
for (UInt_t i=0; i<fParams.size(); i++) {
param.push_back(fParams[i].fValue);
err.push_back(fParams[i].fStep);
}
// CalcExpectedChiSquare handles both, chisq and mlh
fFitterFcn->CalcExpectedChiSquare(param, totalExpectedChisq, expectedchisqPerRun);
Bool_t ok;
PDoubleVector par_r = ParamRound(param, err, ok);
if (!ok)
par_r = param;
fFitterFcn->CalcExpectedChiSquare(par_r, totalExpectedChisq, expectedchisqPerRun);
// calculate chisq per run
std::vector<Double_t> chisqPerRun;
for (UInt_t i=0; i<fRunInfo->GetMsrRunList()->size(); i++) {
if (fUseChi2)
chisqPerRun.push_back(fRunListCollection->GetSingleRunChisq(param, i));
chisqPerRun.push_back(fRunListCollection->GetSingleRunChisq(par_r, i));
else
chisqPerRun.push_back(fRunListCollection->GetSingleRunMaximumLikelihood(param, i));
chisqPerRun.push_back(fRunListCollection->GetSingleRunMaximumLikelihood(par_r, i));
}
if (totalExpectedChisq != 0.0) { // i.e. applicable for single histogram fits only
@@ -2473,6 +2482,122 @@ Bool_t PFitter::ExecuteSave(Bool_t firstSave)
ccorr->Write("ccorr", TObject::kOverwrite, sizeof(ccorr));
hcorr->Write("hcorr", TObject::kOverwrite, sizeof(hcorr));
ff.Close();
if (fYamlOut) {
// write the fit results to an easy-to-read/parse yaml file
// note: the block names follow those used by Python library iminuit
// https://github.com/scikit-hep/iminuit
// dynamically name the yaml output file
// https://stackoverflow.com/a/25389052
std::string yaml_filename(fRunInfo->GetFileName().Data());
const std::string msr_ext(".msr");
yaml_filename.replace(yaml_filename.find(msr_ext), msr_ext.length(),
".yaml");
// define yaml's 2-space indentation
const std::string yaml_indent(" ");
// open the yaml file for writing
std::ofstream yaml_file(yaml_filename);
// number formatting of the output
yaml_file << std::scientific << std::setprecision(16);
// write the parameter values
yaml_file << "values:\n";
for (unsigned int i = 0; i < fParams.size(); ++i) {
yaml_file << yaml_indent << fParams[i].fName.Data() << ": "
<< fParams[i].fValue << "\n";
}
// write the parabolic errors
yaml_file << "errors:\n";
for (unsigned int i = 0; i < fParams.size(); ++i) {
yaml_file << yaml_indent << fParams[i].fName.Data() << ": "
<< fMnUserParams.Error(i) << "\n";
}
// write the minos errors
yaml_file << "mnerrors:\n";
for (unsigned int i = 0; i < fParams.size(); ++i) {
// use boost's implementation of a variant, which can be streamed by
// default - see: https://stackoverflow.com/q/47168477
boost::variant<double, std::string> positive_error, negative_error;
if (fParams[i].fPosErrorPresent) {
positive_error = fParams[i].fPosError;
negative_error = fParams[i].fStep;
} else {
positive_error = "null";
negative_error = "null";
}
yaml_file << yaml_indent << fParams[i].fName.Data() << ":\n";
yaml_file << yaml_indent << yaml_indent
<< "positive: " << positive_error << "\n";
yaml_file << yaml_indent << yaml_indent
<< "negative: " << negative_error << "\n";
}
// write the parameter limits
yaml_file << "limits:\n";
for (unsigned int i = 0; i < fParams.size(); ++i) {
// use boost's implementation of a variant, which can be streamed by
// default - see: https://stackoverflow.com/q/47168477
boost::variant<double, std::string> upper_limit, lower_limit;
if (fParams[i].fLowerBoundaryPresent) {
lower_limit = fParams[i].fLowerBoundary;
} else {
lower_limit = "null";
}
if (fParams[i].fUpperBoundaryPresent) {
upper_limit = fParams[i].fUpperBoundary;
} else {
upper_limit = "null";
}
yaml_file << yaml_indent << fParams[i].fName.Data() << ":\n";
yaml_file << yaml_indent << yaml_indent << "lower: " << lower_limit
<< "\n";
yaml_file << yaml_indent << yaml_indent << "upper: " << upper_limit
<< "\n";
}
// write if the parameter is fixed
yaml_file << "fixed:\n";
for (unsigned int i = 0; i < fParams.size(); ++i) {
std::string is_fixed = fParams[i].fStep == 0.0 ? "true" : "false";
yaml_file << yaml_indent << fParams[i].fName.Data() << ": " << is_fixed
<< "\n";
}
// write the covariance matrix (omitting fixed parameters)
yaml_file << "covariance:\n";
for (unsigned int i = 0; i < cov.Nrow(); ++i) {
yaml_file << yaml_indent << mnState.Name(parNo[i]) << ":\n";
for (unsigned int j = 0; j < cov.Nrow(); ++j) {
yaml_file << yaml_indent << yaml_indent << mnState.Name(parNo[j])
<< ": " << cov(i, j) << "\n";
}
}
// write the correlation matrix (omitting fixed parameters)
yaml_file << "correlation:\n";
for (unsigned int i = 0; i < cov.Nrow(); ++i) {
yaml_file << yaml_indent << mnState.Name(parNo[i]) << ":\n";
for (unsigned int j = 0; j < cov.Nrow(); ++j) {
double correlation =
i == j ? 1.0
: cov(i, j) / (fMnUserParams.Error(parNo[i]) *
fMnUserParams.Error(parNo[j]));
yaml_file << yaml_indent << yaml_indent << mnState.Name(parNo[j])
<< ": " << correlation << "\n";
}
}
// close the yaml file
yaml_file.close();
}
}
parNo.clear(); // clean up
} else {
@@ -2539,7 +2664,7 @@ Bool_t PFitter::ExecuteSimplex()
// create minimizer object
// strategy is by default = 'default'
ROOT::Minuit2::MnSimplex simplex((*fFitterFcn), fMnUserParams, fStrategy);
ROOT::Minuit2::MnSimplex simplex((*fFitterFcn), fMnUserParams, ROOT::Minuit2::MnStrategy{fStrategy});
// minimize
// maxfcn is 10*MINUIT2 Default maxfcn
@@ -2787,6 +2912,50 @@ Double_t PFitter::MilliTime()
return ((Double_t)now.tv_sec * 1.0e6 + (Double_t)now.tv_usec)/1.0e3;
}
//--------------------------------------------------------------------------
// ParamRound (private)
//--------------------------------------------------------------------------
/**
* <p>Rounds the parameter vector value according to the given error estimate,
* so that the msr-file value and the fitter result are consistent with each
* other. This means that musrfit -c, and musrfit -e -t should give essentially
* the same values of expected chisq (up to small rounding values).
*
* @param par parameter value vector
* @param err error value vector
* @param ok true if size of par and err are identically, otherwise false.
*
* @return rounded parameter value vector, compatible with the msr-file output.
*/
PDoubleVector PFitter::ParamRound(const PDoubleVector &par, const PDoubleVector &err, Bool_t &ok)
{
PDoubleVector par_r;
par_r.resize(par.size());
ok = true;
if (par.size() != err.size()) {
// error msg
ok = false;
return par_r;
}
int exp;
double dval;
for (unsigned int i=0; i<par.size(); i++) {
if (err[i] != 0.0) {
exp = floor(log10(fabs(err[i]))-1);
dval = round(par[i]*pow(10.0, -exp))/pow(10.0, -exp);
par_r[i] = dval;
} else {
par_r[i] = par[i];
}
}
return par_r;
}
//-------------------------------------------------------------------------------------------------
// end
//-------------------------------------------------------------------------------------------------

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -188,13 +188,28 @@ void PFunction::FillFuncEvalTree(iter_t const& i, PFuncTreeNode &node)
node.fID = PFunctionGrammar::constGammaMuID; // keep the ID
node.fDvalue = GAMMA_BAR_MUON; // keep the value
} else if (i->value.id() == PFunctionGrammar::constFieldID) { // handle constant field from meta data
str = std::string(i->value.begin(), i->value.end()); // get string
boost::algorithm::trim(str);
if (strstr(str.c_str(), "-"))
node.fSign = true;
node.fID = PFunctionGrammar::constFieldID; // keep the ID
} else if (i->value.id() == PFunctionGrammar::constEnergyID) { // handle constant energy from meta data
str = std::string(i->value.begin(), i->value.end()); // get string
boost::algorithm::trim(str);
if (strstr(str.c_str(), "-"))
node.fSign = true;
node.fID = PFunctionGrammar::constEnergyID; // keep the ID
} else if (i->value.id() == PFunctionGrammar::constTempID) { // handle constant temperature from meta data
str = std::string(i->value.begin(), i->value.end()); // get string
boost::algorithm::trim(str);
status = sscanf(str.c_str(), "T%d", &ivalue); // convert string to temperature index
std::string pstr;
if (strstr(str.c_str(), "-")) {
node.fSign = true;
pstr = "-T%d";
} else {
pstr = "T%d";
}
status = sscanf(str.c_str(), pstr.c_str(), &ivalue); // convert string to temperature index
node.fID = PFunctionGrammar::constTempID; // keep the ID
node.fIvalue = ivalue; // Temp idx
} else if (i->value.id() == PFunctionGrammar::parameterID) { // handle parameter number
@@ -432,21 +447,30 @@ Double_t PFunction::EvalNode(PFuncTreeNode &node)
} else if (node.fID == PFunctionGrammar::constGammaMuID) {
return node.fDvalue;
} else if (node.fID == PFunctionGrammar::constFieldID) {
return fMetaData.fField;
Double_t dval = fMetaData.fField;
if (node.fSign)
dval *= -1.0;
return dval;
} else if (node.fID == PFunctionGrammar::constEnergyID) {
if (fMetaData.fEnergy == PMUSR_UNDEFINED) {
std::cerr << std::endl << "**PANIC ERROR**: PFunction::EvalNode: energy meta data not available." << std::endl;
std::cerr << std::endl;
exit(0);
}
return fMetaData.fEnergy;
Double_t dval = fMetaData.fEnergy;
if (node.fSign)
dval *= -1.0;
return dval;
} else if (node.fID == PFunctionGrammar::constTempID) {
if (node.fIvalue >= fMetaData.fTemp.size()) {
std::cerr << std::endl << "**PANIC ERROR**: PFunction::EvalNode: Temp idx=" << node.fIvalue << " requested which is >= #Temp(s)=" << fMetaData.fTemp.size() << " available." << std::endl;
std::cerr << std::endl;
exit(0);
}
return fMetaData.fTemp[node.fIvalue];
Double_t dval = fMetaData.fTemp[node.fIvalue];
if (node.fSign)
dval *= -1.0;
return dval;
} else if (node.fID == PFunctionGrammar::parameterID) {
Double_t dval;
if (node.fSign)
@@ -609,10 +633,10 @@ void PFunction::EvalTreeForStringExpression(iter_t const& i, bool funcFlag)
fFuncString += "Pi";
} else if (i->value.id() == PFunctionGrammar::constGammaMuID) {
fFuncString += "gamma_mu";
} else if (i->value.id() == PFunctionGrammar::constFieldID) {
fFuncString += "B";
} else if (i->value.id() == PFunctionGrammar::constFieldID) {
fFuncString += boost::algorithm::trim_copy(std::string(i->value.begin(), i->value.end())).c_str();
} else if (i->value.id() == PFunctionGrammar::constEnergyID) {
fFuncString += "EN";
fFuncString += boost::algorithm::trim_copy(std::string(i->value.begin(), i->value.end())).c_str();
} else if (i->value.id() == PFunctionGrammar::constTempID) {
assert(i->children.size() == 0);
fFuncString += boost::algorithm::trim_copy(std::string(i->value.begin(), i->value.end())).c_str();

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *

78
src/classes/PMsgBox.cpp Normal file
View File

@@ -0,0 +1,78 @@
/***************************************************************************
PMsgBox.cpp
Author: Andreas Suter
e-mail: andreas.suter@psi.ch
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
#include "PMsgBox.h"
PMsgBox::PMsgBox(const std::string errMsg, const TGWindow *p, UInt_t w, UInt_t h) : TGMainFrame(p, w, h)
{
fListBox = new TGListBox(this, 89);
// feed list box with errMsg
size_t start = 0;
size_t end = errMsg.find("\n");
unsigned int i=1;
std::string tok{""};
fListBox->AddEntry(tok.c_str(), i++);
while (end != std::string::npos) {
tok = errMsg.substr(start, end - start);
start = end + 1;
end = errMsg.find("\n", start);
fListBox->AddEntry(tok.c_str(), i++);
}
fListBox->Resize(600, 200);
AddFrame(fListBox, new TGLayoutHints(kLHintsTop | kLHintsLeft | kLHintsExpandX | kLHintsExpandY, 5, 5, 5, 5));
// Create a horizontal frame containing button(s)
TGHorizontalFrame *hframe = new TGHorizontalFrame(this, 150, 20, kFixedWidth);
TGTextButton *exit = new TGTextButton(hframe, "&Exit ");
exit->Connect("Pressed()", "PMsgBox", this, "DoExit()");
hframe->AddFrame(exit, new TGLayoutHints(kLHintsExpandX, 5, 5, 3, 4));
AddFrame(hframe, new TGLayoutHints(kLHintsExpandX, 2, 2, 5, 1));
// Set a name to the main frame
SetWindowName("Error Message");
MapSubwindows();
// Initialize the layout algorithm via Resize()
Resize(GetDefaultSize());
// Map main frame
MapWindow();
}
PMsgBox::~PMsgBox()
{
// nothing to be done here?
}
void PMsgBox::DoExit()
{
gApplication->Terminate(0);
}

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2009-2024 by Bastian M. Wojek / Andreas Suter *
* Copyright (C) 2009-2025 by Bastian M. Wojek / Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -140,29 +140,32 @@ int PMsr2Data::DetermineRunNumberDigits(unsigned int runNo, bool normalMode) con
strLine.str(line);
strLine >> firstOnLine;
if (!to_lower_copy(firstOnLine).compare("run")) {
firstOnLine.clear();
strLine >> firstOnLine;
std::string::size_type loc = firstOnLine.rfind(tempRunNumber.str());
if ( loc != std::string::npos ) {
while ( loc > 0 ) {
if (isdigit(firstOnLine.at(--loc))) {
++fRunNumberDigits;
} else {
break;
// for path-names with spaces
std::string::size_type loc{0};
while (!strLine.eof()) {
firstOnLine.clear();
strLine >> firstOnLine;
loc = firstOnLine.rfind(tempRunNumber.str());
if ( loc != std::string::npos ) {
while ( loc > 0 ) {
if (isdigit(firstOnLine.at(--loc))) {
++fRunNumberDigits;
} else {
break;
}
}
in->close();
fRunVectorIter = fRunVector.begin(); // set back the runlist-iterator which might have changed during the search for the correct file
return 0;
}
in->close();
fRunVectorIter = fRunVector.begin(); // set back the runlist-iterator which might have changed during the search for the correct file
return 0;
} else {
std::cerr << std::endl << ">> msr2data: **ERROR** The first processed run file number does not match the \"file index\"!";
std::cerr << std::endl << ">> msr2data: **ERROR** The number of digits to be used for formatting the run numbers cannot be determined!";
std::cerr << std::endl << ">> msr2data: **ERROR** Please check the first msr-file that should be processed;";
std::cerr << std::endl << ">> msr2data: **ERROR** this is either some template or the first existing file from the run list.";
std::cerr << std::endl;
in->close();
return -2;
}
std::cerr << std::endl << ">> msr2data: **ERROR** The first processed run file number does not match the \"file index\"!";
std::cerr << std::endl << ">> msr2data: **ERROR** The number of digits to be used for formatting the run numbers cannot be determined!";
std::cerr << std::endl << ">> msr2data: **ERROR** Please check the first msr-file that should be processed;";
std::cerr << std::endl << ">> msr2data: **ERROR** this is either some template or the first existing file from the run list.";
std::cerr << std::endl;
in->close();
return -2;
}
}
std::cerr << std::endl << ">> msr2data: **ERROR** Please check the first msr-file that should be processed;";
@@ -558,11 +561,23 @@ bool PMsr2Data::PrepareNewInputFile(unsigned int tempRun, bool calledFromGlobalM
strLine.str(line);
strLine >> firstOnLine;
if (!to_lower_copy(firstOnLine).compare("run")) {
strLine >> firstOnLine;
std::string::size_type loc = firstOnLine.rfind(tempRunNumber.str());
if ( loc != std::string::npos ) {
firstOnLine.replace(loc, fRunNumberDigits, newRunNumber.str());
} else {
// needed for path-fln with spaces
std::string::size_type loc;
std::string sstr{""};
firstOnLine.clear();
while (!strLine.eof()) {
strLine >> sstr;
if (firstOnLine.empty())
firstOnLine = sstr;
else
firstOnLine += " " + sstr;
loc = firstOnLine.rfind(tempRunNumber.str());
if ( loc != std::string::npos ) {
firstOnLine.replace(loc, fRunNumberDigits, newRunNumber.str());
break;
}
}
if (strLine.eof()) {
std::cerr << std::endl << ">> msr2data: **WARNING** The template run file number does not match the \"file index\"";
std::cerr << std::endl << ">> msr2data: **WARNING** Unexpected things will happen... (for sure)";
std::cerr << std::endl;
@@ -694,9 +709,16 @@ bool PMsr2Data::PrepareGlobalInputFile(unsigned int tempRun, const std::string &
msrParamList->at(i).fIsGlobal = true;
++fNumGlobalParam;
}
// std::cout << "debug> " << msrParamList->at(i).fNo << ": " << msrParamList->at(i).fName.Data() << " is global: " << msrParamList->at(i).fIsGlobal << std::endl;
}
// there should be at least one run specific parameter, otherwise the GLOBAL option doesn't make sense
if (fNumSpecParam == 0) {
std::cout << ">> msr2data: **ERROR** found NO run specific parameter, hence the GLOBAL option doesn't make sense." << std::endl;
std::cout << ">> msr2data: Could it be, that your run specific labling is < 4 digits? Please check your msr-Input-File." << std::endl;
return false;
}
// check if parameters have been sorted correctly from the beginning
bool wasSorted(true);
for (unsigned int i(0); i < fNumGlobalParam; ++i) {
@@ -1793,6 +1815,9 @@ int PMsr2Data::WriteOutput(const std::string &outfile, const std::vector<unsigne
rawRunData = fDataHandler->GetRunData((*msrRunList)[0].GetRunName()->Data());
}
if (rawRunData == nullptr)
return -1;
switch (rawRunData->GetNoOfTemperatures()) {
case 1:
dataParamNames.push_back("dataT");

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -276,9 +276,11 @@ Int_t PMsrHandler::ReadMsrFile()
if ((result == PMUSR_SUCCESS) && !fFourierOnly) {
UInt_t parX, parY;
if (!CheckUniquenessOfParamNames(parX, parY)) {
std::cerr << std::endl << ">> PMsrHandler::ReadMsrFile: **SEVERE ERROR** parameter name " << fParam[parX].fName.Data() << " is identical for parameter no " << fParam[parX].fNo << " and " << fParam[parY].fNo << "!";
std::cerr << std::endl << ">> Needs to be fixed first!";
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ReadMsrFile: **SEVERE ERROR** parameter name " << fParam[parX].fName.Data() << " is identical for parameter no " << fParam[parX].fNo << " and " << fParam[parY].fNo << "!\n";
fLastErrorMsg << ">> Needs to be fixed first!\n";
std::cerr << std::endl << fLastErrorMsg.str();
result = PMUSR_MSR_SYNTAX_ERROR;
}
}
@@ -316,13 +318,9 @@ Int_t PMsrHandler::ReadMsrFile()
CheckLegacyLifetimecorrection(); // check if lifetimecorrection is found in RUN blocks, if yes transfer it to PLOT blocks
}
// check if the given phases in the Fourier block are in agreement with the Plot block settings
if ((fFourier.fPhase.size() > 1) && (fPlots.size() > 0)) {
if (fFourier.fPhase.size() != fPlots[0].fRuns.size()) {
std::cerr << std::endl << ">> PMsrHandler::ReadMsrFile: **ERROR** if more than one phase is given in the Fourier block,";
std::cerr << std::endl << ">> it needs to correspond to the number of runs in the Plot block!" << std::endl;
result = PMUSR_MSR_SYNTAX_ERROR;
}
if (result == PMUSR_SUCCESS) {
if (!CheckRealFFT())
result = PMUSR_MSR_SYNTAX_ERROR;
}
// clean up
@@ -2447,8 +2445,10 @@ Int_t PMsrHandler::WriteMsrFile(const Char_t *filename, std::map<UInt_t, TString
Bool_t PMsrHandler::SetMsrParamValue(UInt_t idx, Double_t value)
{
if (idx >= fParam.size()) {
std::cerr << std::endl << ">> PMsrHandler::SetMsrParamValue(): **ERROR** idx = " << idx << " is >= than the number of fit parameters " << fParam.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrParamValue(): **ERROR** idx = " << idx << " is >= than the number of fit parameters " << fParam.size() << "\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -2474,8 +2474,10 @@ Bool_t PMsrHandler::SetMsrParamValue(UInt_t idx, Double_t value)
Bool_t PMsrHandler::SetMsrParamStep(UInt_t idx, Double_t value)
{
if (idx >= fParam.size()) {
std::cerr << std::endl << ">> PMsrHandler::SetMsrParamValue(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrParamValue(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size() << "\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -2500,8 +2502,10 @@ Bool_t PMsrHandler::SetMsrParamStep(UInt_t idx, Double_t value)
Bool_t PMsrHandler::SetMsrParamPosErrorPresent(UInt_t idx, Bool_t value)
{
if (idx >= fParam.size()) {
std::cerr << std::endl << ">> PMsrHandler::SetMsrParamPosErrorPresent(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrParamPosErrorPresent(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size() << "\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -2526,8 +2530,10 @@ Bool_t PMsrHandler::SetMsrParamPosErrorPresent(UInt_t idx, Bool_t value)
Bool_t PMsrHandler::SetMsrParamPosError(UInt_t idx, Double_t value)
{
if (idx >= fParam.size()) {
std::cerr << std::endl << ">> PMsrHandler::SetMsrParamPosError(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrParamPosError(): **ERROR** idx = " << idx << " is larger than the number of parameters " << fParam.size() << "\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -2550,8 +2556,10 @@ Bool_t PMsrHandler::SetMsrParamPosError(UInt_t idx, Double_t value)
void PMsrHandler::SetMsrT0Entry(UInt_t runNo, UInt_t idx, Double_t bin)
{
if (runNo >= fRuns.size()) { // error
std::cerr << std::endl << ">> PMsrHandler::SetMsrT0Entry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrT0Entry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size() << "\n";
std::cerr << fLastErrorMsg.str();
return;
}
@@ -2578,8 +2586,10 @@ void PMsrHandler::SetMsrT0Entry(UInt_t runNo, UInt_t idx, Double_t bin)
void PMsrHandler::SetMsrAddT0Entry(UInt_t runNo, UInt_t addRunIdx, UInt_t histoIdx, Double_t bin)
{
if (runNo >= fRuns.size()) { // error
std::cerr << std::endl << ">> PMsrHandler::SetMsrAddT0Entry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrAddT0Entry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size() << "\n";
std::cerr << fLastErrorMsg.str();
return;
}
@@ -2611,8 +2621,10 @@ void PMsrHandler::SetMsrAddT0Entry(UInt_t runNo, UInt_t addRunIdx, UInt_t histoI
void PMsrHandler::SetMsrDataRangeEntry(UInt_t runNo, UInt_t idx, Int_t bin)
{
if (runNo >= fRuns.size()) { // error
std::cerr << std::endl << ">> PMsrHandler::SetMsrDataRangeEntry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrDataRangeEntry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size() << "\n";
std::cerr << fLastErrorMsg.str();
return;
}
@@ -2632,8 +2644,10 @@ void PMsrHandler::SetMsrDataRangeEntry(UInt_t runNo, UInt_t idx, Int_t bin)
void PMsrHandler::SetMsrBkgRangeEntry(UInt_t runNo, UInt_t idx, Int_t bin)
{
if (runNo >= fRuns.size()) { // error
std::cerr << std::endl << ">> PMsrHandler::SetMsrBkgRangeEntry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size();
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::SetMsrBkgRangeEntry: **ERROR** runNo = " << runNo << ", is out of valid range 0.." << fRuns.size() << "\n";
std::cerr << fLastErrorMsg.str();
return;
}
@@ -2718,8 +2732,10 @@ Bool_t PMsrHandler::HandleFitParameterEntry(PMsrLines &lines)
tokens = iter->fLine.Tokenize(" \t");
if (!tokens) {
std::cerr << std::endl << ">> PMsrHandler::HandleFitParameterEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleFitParameterEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo << "\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -2836,28 +2852,27 @@ Bool_t PMsrHandler::HandleFitParameterEntry(PMsrLines &lines)
// check if enough elements found
if (error) {
std::cerr << std::endl;
std::cerr << std::endl << ">> PMsrHandler::HandleFitParameterEntry: **ERROR** in line " << iter->fLineNo << ":";
std::cerr << std::endl << ">> " << iter->fLine.Data();
std::cerr << std::endl << ">> A Fit Parameter line needs to have the following form: ";
std::cerr << std::endl;
std::cerr << std::endl << ">> No Name Value Step/Error [Lower_Boundary Upper_Boundary]";
std::cerr << std::endl;
std::cerr << std::endl << ">> or";
std::cerr << std::endl;
std::cerr << std::endl << ">> No Name Value Step/Neg_Error Pos_Error [Lower_Boundary Upper_Boundary]";
std::cerr << std::endl;
std::cerr << std::endl << ">> No: the parameter number (an Int_t)";
std::cerr << std::endl << ">> Name: the name of the parameter (less than 256 character)";
std::cerr << std::endl << ">> Value: the starting value of the parameter (a Double_t)";
std::cerr << std::endl << ">> Step/Error,";
std::cerr << std::endl << ">> Step/Neg_Error: the starting step value in a fit (a Double_t), or";
std::cerr << std::endl << ">> the symmetric error (MIGRAD, SIMPLEX), or";
std::cerr << std::endl << ">> the negative error (MINOS)";
std::cerr << std::endl << ">> Pos_Error: the positive error (MINOS), (a Double_t or \"none\")";
std::cerr << std::endl << ">> Lower_Boundary: the lower boundary allowed for the fit parameter (a Double_t or \"none\")";
std::cerr << std::endl << ">> Upper_Boundary: the upper boundary allowed for the fit parameter (a Double_t or \"none\")";
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << "\n";
fLastErrorMsg << ">> PMsrHandler::HandleFitParameterEntry: **ERROR** in line " << iter->fLineNo << ":\n";
fLastErrorMsg << ">> " << iter->fLine.Data() << "\n";
fLastErrorMsg << ">> A Fit Parameter line needs to have the following form:\n";
fLastErrorMsg << "\n";
fLastErrorMsg << ">> No Name Value Step/Error [Lower_Boundary Upper_Boundary]\n\n";
fLastErrorMsg << ">> or\n\n";
fLastErrorMsg << ">> No Name Value Step/Neg_Error Pos_Error [Lower_Boundary Upper_Boundary]\n\n";
fLastErrorMsg << ">> No: the parameter number (an Int_t)\n";
fLastErrorMsg << ">> Name: the name of the parameter (less than 256 character)\n";
fLastErrorMsg << ">> Value: the starting value of the parameter (a Double_t)\n";
fLastErrorMsg << ">> Step/Error,\n";
fLastErrorMsg << ">> Step/Neg_Error: the starting step value in a fit (a Double_t), or\n";
fLastErrorMsg << ">> the symmetric error (MIGRAD, SIMPLEX), or\n";
fLastErrorMsg << ">> the negative error (MINOS)\n";
fLastErrorMsg << ">> Pos_Error: the positive error (MINOS), (a Double_t or \"none\")\n";
fLastErrorMsg << ">> Lower_Boundary: the lower boundary allowed for the fit parameter (a Double_t or \"none\")\n";
fLastErrorMsg << ">> Upper_Boundary: the upper boundary allowed for the fit parameter (a Double_t or \"none\")\n";
std::cerr << fLastErrorMsg.str();
} else { // everything is OK, therefore add the parameter to the parameter list
fParam.push_back(param);
}
@@ -2875,13 +2890,15 @@ Bool_t PMsrHandler::HandleFitParameterEntry(PMsrLines &lines)
for (UInt_t i=0; i<fParam.size(); i++) {
if (fParam[i].fNo != static_cast<Int_t>(i)+1) {
error = true;
std::cerr << std::endl << ">> PMsrHandler::HandleFitParameterEntry: **ERROR**";
std::cerr << std::endl << ">> Sorry, you are assuming to much from this program, it cannot";
std::cerr << std::endl << ">> handle none subsequent numbered parameters yet or in the near future.";
std::cerr << std::endl << ">> Found parameter " << fParam[i].fName.Data() << ", with";
std::cerr << std::endl << ">> parameter number " << fParam[i].fNo << ", at paramter position " << i+1 << ".";
std::cerr << std::endl << ">> This needs to be fixed first.";
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleFitParameterEntry: **ERROR**\n";
fLastErrorMsg << ">> Sorry, you are assuming to much from this program, it cannot\n";
fLastErrorMsg << ">> handle none subsequent numbered parameters yet or in the near future.\n";
fLastErrorMsg << ">> Found parameter " << fParam[i].fName.Data() << ", with\n";
fLastErrorMsg << ">> parameter number " << fParam[i].fNo << ", at paramter position " << i+1 << ".\n";
fLastErrorMsg << ">> This needs to be fixed first.\n";
std::cerr << fLastErrorMsg.str();
break;
}
}
@@ -2990,8 +3007,10 @@ Bool_t PMsrHandler::HandleGlobalEntry(PMsrLines &lines)
// tokenize line
tokens = str.Tokenize(" \t");
if (!tokens) {
std::cerr << std::endl << ">> PMsrHandler::HandleGlobalEntry: **SEVERE ERROR** Couldn't tokenize line " << iter->fLineNo;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleGlobalEntry: **SEVERE ERROR** Couldn't tokenize line " << iter->fLineNo << "\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -3201,9 +3220,12 @@ Bool_t PMsrHandler::HandleGlobalEntry(PMsrLines &lines)
if (error) {
--iter;
std::cerr << std::endl << ">> PMsrHandler::HandleGlobalEntry: **ERROR** in line " << iter->fLineNo << ":";
std::cerr << std::endl << ">> '" << iter->fLine.Data() << "'";
std::cerr << std::endl << ">> GLOBAL block syntax is too complex to print it here. Please check the manual.";
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleGlobalEntry: **ERROR** in line " << iter->fLineNo << ":\n";
fLastErrorMsg << ">> '" << iter->fLine.Data() << "'\n";
fLastErrorMsg << ">> GLOBAL block syntax is too complex to print it here. Please check the manual.\n";
std::cerr << fLastErrorMsg.str();
} else { // save global
fGlobal = global;
}
@@ -3245,14 +3267,19 @@ Bool_t PMsrHandler::HandleRunEntry(PMsrLines &lines)
// remove potential comment at the end of lines
str = iter->fLine;
Ssiz_t idx = str.Index("#");
if (idx != -1)
str.Remove(idx);
idx = str.Index("(");
if (idx != -1)
str.Remove(idx);
// tokenize line
tokens = str.Tokenize(" \t");
if (!tokens) {
std::cerr << std::endl << ">> PMsrHandler::HandleRunEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleRunEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo << "\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -3274,23 +3301,29 @@ Bool_t PMsrHandler::HandleRunEntry(PMsrLines &lines)
}
// get run name, beamline, institute, and file-format
// the path/filename could potentially contain spaces! Hence the run name needs to be reconstructed from the parsing
if (tokens->GetEntries() < 5) {
error = true;
} else {
// run name
ostr = dynamic_cast<TObjString*>(tokens->At(1));
str = ostr->GetString();
str = TString("");
for (Int_t i=1; i<tokens->GetEntries()-3; i++) {
ostr = dynamic_cast<TObjString*>(tokens->At(i));
str += ostr->GetString();
if (i<tokens->GetEntries()-4)
str += TString(" ");
}
param.SetRunName(str);
// beamline
ostr = dynamic_cast<TObjString*>(tokens->At(2));
ostr = dynamic_cast<TObjString*>(tokens->At(tokens->GetEntries()-3));
str = ostr->GetString();
param.SetBeamline(str);
// institute
ostr = dynamic_cast<TObjString*>(tokens->At(3));
ostr = dynamic_cast<TObjString*>(tokens->At(tokens->GetEntries()-2));
str = ostr->GetString();
param.SetInstitute(str);
// data file format
ostr = dynamic_cast<TObjString*>(tokens->At(4));
ostr = dynamic_cast<TObjString*>(tokens->At(tokens->GetEntries()-1));
str = ostr->GetString();
param.SetFileFormat(str);
}
@@ -3302,10 +3335,12 @@ Bool_t PMsrHandler::HandleRunEntry(PMsrLines &lines)
if (line.BeginsWith("addrun", TString::kIgnoreCase)) {
if (!runLinePresent) {
std::cerr << std::endl << ">> PMsrHandler::HandleRunEntry: **ERROR** Found ADDRUN without prior RUN, or";
std::cerr << std::endl << ">> ADDRUN lines intercepted by other stuff. All this is not allowed!";
std::cerr << std::endl << ">> error in line " << iter->fLineNo;
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleRunEntry: **ERROR** Found ADDRUN without prior RUN, or\n";
fLastErrorMsg << ">> ADDRUN lines intercepted by other stuff. All this is not allowed!\n";
fLastErrorMsg << ">> error in line " << iter->fLineNo << "\n";
std::cerr << fLastErrorMsg.str();
error = true;
continue;
}
@@ -3516,7 +3551,10 @@ Bool_t PMsrHandler::HandleRunEntry(PMsrLines &lines)
if (!fFourierOnly) {
for (UInt_t i=0; i<param.GetMap()->size(); i++) {
if ((param.GetMap(i) < 0) || (param.GetMap(i) > static_cast<Int_t>(fParam.size()))) {
std::cerr << std::endl << ">> PMsrHandler::HandleRunEntry: **SEVERE ERROR** map value " << param.GetMap(i) << " in line " << iter->fLineNo << " is out of range!";
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleRunEntry: **SEVERE ERROR** map value " << param.GetMap(i) << " in line " << iter->fLineNo << " is out of range!\n";
std::cerr << fLastErrorMsg.str();
error = true;
break;
}
@@ -3809,9 +3847,12 @@ Bool_t PMsrHandler::HandleRunEntry(PMsrLines &lines)
if (error) {
--iter;
std::cerr << std::endl << ">> PMsrHandler::HandleRunEntry: **ERROR** in line " << iter->fLineNo << ":";
std::cerr << std::endl << ">> " << iter->fLine.Data();
std::cerr << std::endl << ">> RUN block syntax is too complex to print it here. Please check the manual.";
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleRunEntry: **ERROR** in line " << iter->fLineNo << ":\n";
fLastErrorMsg << ">> " << iter->fLine.Data() << "\n";
fLastErrorMsg << ">> RUN block syntax is too complex to print it here. Please check the manual.\n";
std::cerr << fLastErrorMsg.str();
} else { // save last run found
fRuns.push_back(param);
param.CleanUp();
@@ -3964,7 +4005,10 @@ Bool_t PMsrHandler::ParseFourierPhaseValueVector(PMsrFourierStructure &fourier,
TObjArray *tok = str.Tokenize(" ,;\t");
if (tok == nullptr) {
std::cerr << std::endl << ">> PMsrHandler::ParseFourierPhaseValueVector: **ERROR** couldn't tokenize Fourier phase line." << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseValueVector: **ERROR** couldn't tokenize Fourier phase line.\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -3985,8 +4029,11 @@ Bool_t PMsrHandler::ParseFourierPhaseValueVector(PMsrFourierStructure &fourier,
} else {
result = false;
if (i>1) { // make sure that no 'phase val, parX' mixture is present
std::cerr << std::endl << ">> PMsrHandler::ParseFourierPhaseValueVector: **ERROR** in Fourier phase line.";
std::cerr << std::endl << ">> Attempt to mix val, parX? This is currently not supported." << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseValueVector: **ERROR** in Fourier phase line.\n";
fLastErrorMsg << ">> Attempt to mix val, parX? This is currently not supported.\n\n";
std::cerr << fLastErrorMsg.str();
error = true;
}
break;
@@ -4024,7 +4071,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParVector(PMsrFourierStructure &fourier, co
TObjArray *tok = str.Tokenize(" ,;\t");
if (tok == nullptr) {
std::cerr << std::endl << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** couldn't tokenize Fourier phase line." << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** couldn't tokenize Fourier phase line.\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -4040,7 +4090,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParVector(PMsrFourierStructure &fourier, co
TObjString *ostr = dynamic_cast<TObjString*>(tok->At(i));
sstr = ostr->GetString();
if (!sstr.BeginsWith("par")) {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found unhandable token '" << sstr << "'" << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found unhandable token '" << sstr << "'\n";
std::cerr << fLastErrorMsg.str();
error = true;
result = false;
break;
@@ -4058,7 +4111,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParVector(PMsrFourierStructure &fourier, co
}
if (refCount > 1) {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found multiple parR's! Only one reference phase is accepted." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found multiple parR's! Only one reference phase is accepted.\n";
std::cerr << fLastErrorMsg.str();
result = false;
}
@@ -4078,7 +4134,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParVector(PMsrFourierStructure &fourier, co
fourier.fPhaseRef = sstr.Atoi();
fourier.fPhaseParamNo.push_back(sstr.Atoi());
} else {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found token '" << ostr->GetString() << "' which is not parX with X an integer." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParVector: **ERROR** found token '" << ostr->GetString() << "' which is not parX with X an integer.\n";
std::cerr << fLastErrorMsg.str();
fourier.fPhaseParamNo.clear();
error = true;
break;
@@ -4124,7 +4183,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParIterVector(PMsrFourierStructure &fourier
// remove 'par(' from string if present, otherwise and error is issued
if (!wstr.BeginsWith("par(") && !wstr.BeginsWith("parR(")) {
std::cout << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** token should start with 'par(' or 'parR(', found: '" << wstr << "' -> ERROR" << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** token should start with 'par(' or 'parR(', found: '" << wstr << "' -> ERROR\n";
std::cerr << fLastErrorMsg.str();
error = true;
return false;
}
@@ -4146,14 +4208,20 @@ Bool_t PMsrHandler::ParseFourierPhaseParIterVector(PMsrFourierStructure &fourier
// tokenize rest which should have the form 'X0, offset, #Param'
TObjArray *tok = wstr.Tokenize(",;");
if (tok == nullptr) {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** tokenize failed." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** tokenize failed.\n";
std::cerr << fLastErrorMsg.str();
error = true;
return false;
}
// check for proper number of expected elements
if (tok->GetEntries() != 3) {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** wrong syntax for the expected par(X0, offset, #param)." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** wrong syntax for the expected par(X0, offset, #param).\n";
std::cerr << fLastErrorMsg.str();
error = true;
delete tok;
return false;
@@ -4167,7 +4235,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParIterVector(PMsrFourierStructure &fourier
if (wstr.IsDigit()) {
x0 = wstr.Atoi();
} else {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** X0='" << wstr << "' is not an integer." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** X0='" << wstr << "' is not an integer.\n";
std::cerr << fLastErrorMsg.str();
error = true;
delete tok;
return false;
@@ -4179,7 +4250,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParIterVector(PMsrFourierStructure &fourier
if (wstr.IsDigit()) {
offset = wstr.Atoi();
} else {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** offset='" << wstr << "' is not an integer." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** offset='" << wstr << "' is not an integer.\n";
std::cerr << fLastErrorMsg.str();
error = true;
delete tok;
return false;
@@ -4191,7 +4265,10 @@ Bool_t PMsrHandler::ParseFourierPhaseParIterVector(PMsrFourierStructure &fourier
if (wstr.IsDigit()) {
noParam = wstr.Atoi();
} else {
std::cerr << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** #Param='" << wstr << "' is not an integer." << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ParseFourierPhaseParIterVector: **ERROR** #Param='" << wstr << "' is not an integer.\n";
std::cerr << fLastErrorMsg.str();
error = true;
delete tok;
return false;
@@ -4252,8 +4329,10 @@ Bool_t PMsrHandler::HandleFourierEntry(PMsrLines &lines)
// tokenize line
tokens = iter->fLine.Tokenize(" \t");
if (!tokens) {
std::cerr << std::endl << ">> PMsrHandler::HandleFourierEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleFourierEntry: **SEVERE ERROR** Couldn't tokenize Parameters in line " << iter->fLineNo << "\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
@@ -4396,7 +4475,10 @@ Bool_t PMsrHandler::HandleFourierEntry(PMsrLines &lines)
if (fourier.fPhaseParamNo.size() > 0) {
for (UInt_t i=0; i<fourier.fPhaseParamNo.size(); i++) {
if (fourier.fPhaseParamNo[i] > fParam.size()) {
std::cerr << ">> PMsrHandler::HandleFourierEntry: found Fourier parameter entry par" << fourier.fPhaseParamNo[i] << " > #Param = " << fParam.size() << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleFourierEntry: found Fourier parameter entry par" << fourier.fPhaseParamNo[i] << " > #Param = " << fParam.size() << "\n";
std::cerr << fLastErrorMsg.str();
error = true;
--iter;
continue;
@@ -4502,28 +4584,28 @@ Bool_t PMsrHandler::HandleFourierEntry(PMsrLines &lines)
}
if (error) {
std::cerr << std::endl << ">> PMsrHandler::HandleFourierEntry: **ERROR** in line " << iter->fLineNo << ":";
std::cerr << std::endl;
std::cerr << std::endl << ">> " << iter->fLine.Data();
std::cerr << std::endl;
std::cerr << std::endl << ">> FOURIER block syntax, parameters in [] are optinal:";
std::cerr << std::endl;
std::cerr << std::endl << ">> FOURIER";
std::cerr << std::endl << ">> [units Gauss | MHz | Mc/s]";
std::cerr << std::endl << ">> [fourier_power n # n is a number such that zero padding up to 2^n will be used]";
std::cerr << std::endl << ">> n=0 means no zero padding";
std::cerr << std::endl << ">> 0 <= n <= 20 are allowed values";
std::cerr << std::endl << ">> [dc-corrected true | false]";
std::cerr << std::endl << ">> [apodization none | weak | medium | strong]";
std::cerr << std::endl << ">> [plot real | imag | real_and_imag | power | phase | phase_opt_real]";
std::cerr << std::endl << ">> [phase valList | parList | parIterList [# comment]]";
std::cerr << std::endl << ">> valList : val [sep val ... sep val]. sep=' ,;\\t'";
std::cerr << std::endl << ">> parList : parX0 [sep parX1 ... sep parX1]";
std::cerr << std::endl << ">> parIterList : par(X0,offset,#param), with X0=first parameter number";
std::cerr << std::endl << ">> offset=parameter offset, #param=number of phase parameters.";
std::cerr << std::endl << ">> [range_for_phase_correction min max | all]";
std::cerr << std::endl << ">> [range min max]";
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandleFourierEntry: **ERROR** in line " << iter->fLineNo << ":\n\n";
fLastErrorMsg << ">> " << iter->fLine.Data() << "\n\n";
fLastErrorMsg << ">> FOURIER block syntax, parameters in [] are optinal:\n\n";
fLastErrorMsg << ">> FOURIER\n";
fLastErrorMsg << ">> [units Gauss | MHz | Mc/s]\n";
fLastErrorMsg << ">> [fourier_power n # n is a number such that zero padding up to 2^n will be used]\n";
fLastErrorMsg << ">> n=0 means no zero padding\n";
fLastErrorMsg << ">> 0 <= n <= 20 are allowed values\n";
fLastErrorMsg << ">> [dc-corrected true | false]\n";
fLastErrorMsg << ">> [apodization none | weak | medium | strong]\n";
fLastErrorMsg << ">> [plot real | imag | real_and_imag | power | phase | phase_opt_real]\n";
fLastErrorMsg << ">> [phase valList | parList | parIterList [# comment]]\n";
fLastErrorMsg << ">> valList : val [sep val ... sep val]. sep=' ,;\\t'\n";
fLastErrorMsg << ">> parList : parX0 [sep parX1 ... sep parXn], Xi is the parameter number\n";
fLastErrorMsg << ">> parList : parRX0 sep parX1 ... sep parXn, parRX0 is the reference phase, e.g. parR3\n";
fLastErrorMsg << ">> parIterList : par(X0,offset,#param), with X0=first parameter number\n";
fLastErrorMsg << ">> offset=parameter offset, #param=number of phase parameters.\n";
fLastErrorMsg << ">> [range_for_phase_correction min max | all]\n";
fLastErrorMsg << ">> [range min max]\n";
std::cerr << fLastErrorMsg.str();
} else { // save last run found
fFourier = fourier;
}
@@ -4598,8 +4680,10 @@ Bool_t PMsrHandler::HandlePlotEntry(PMsrLines &lines)
if (line.Contains("PLOT")) { // handle plot header
tokens = line.Tokenize(" \t");
if (!tokens) {
std::cerr << std::endl << ">> PMsrHandler::HandlePlotEntry: **SEVERE ERROR** Couldn't tokenize PLOT in line " << iter1->fLineNo;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandlePlotEntry: **SEVERE ERROR** Couldn't tokenize PLOT in line " << iter1->fLineNo << "\n\n";
std::cerr << fLastErrorMsg.str();
return false;
}
if (tokens->GetEntries() < 2) { // plot type missing
@@ -4637,9 +4721,11 @@ Bool_t PMsrHandler::HandlePlotEntry(PMsrLines &lines)
case MSR_PLOT_MU_MINUS:
rl = std::make_unique<PStringNumberList>(line.Data());
if (!rl->Parse(errorMsg, true)) {
std::cerr << std::endl << ">> PMsrHandler::HandlePlotEntry: **SEVERE ERROR** Couldn't tokenize PLOT in line " << iter1->fLineNo;
std::cerr << std::endl << ">> Error Message: " << errorMsg;
std::cerr << std::endl << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::HandlePlotEntry: **SEVERE ERROR** Couldn't tokenize PLOT in line " << iter1->fLineNo << "\n";
fLastErrorMsg << ">> Error Message: " << errorMsg;
std::cerr << fLastErrorMsg.str();
return false;
}
runList = rl->GetList();
@@ -6061,7 +6147,7 @@ Bool_t PMsrHandler::CheckRunBlockIntegrity()
}
//--------------------------------------------------------------------------
// CheckUniquenessOfParamNames (public)
// CheckUniquenessOfParamNames (private)
//--------------------------------------------------------------------------
/**
* <p>Checks if all the fit parameters are unique. If not parX, parY will show
@@ -6093,7 +6179,7 @@ Bool_t PMsrHandler::CheckUniquenessOfParamNames(UInt_t &parX, UInt_t &parY)
}
//--------------------------------------------------------------------------
// CheckMaps (public)
// CheckMaps (private)
//--------------------------------------------------------------------------
/**
* <p>Checks if map entries found in the theory- or function-block are also
@@ -6203,7 +6289,7 @@ Bool_t PMsrHandler::CheckMaps()
}
//--------------------------------------------------------------------------
// CheckFuncs (public)
// CheckFuncs (private)
//--------------------------------------------------------------------------
/**
* <p>Checks if fun entries found in the theory- and run-block are also
@@ -6298,7 +6384,7 @@ Bool_t PMsrHandler::CheckFuncs()
}
//--------------------------------------------------------------------------
// CheckHistoGrouping (public)
// CheckHistoGrouping (private)
//--------------------------------------------------------------------------
/**
* <p>Checks if histogram grouping makes any sense.
@@ -6344,7 +6430,7 @@ Bool_t PMsrHandler::CheckHistoGrouping()
}
//--------------------------------------------------------------------------
// CheckAddRunParameters (public)
// CheckAddRunParameters (private)
//--------------------------------------------------------------------------
/**
* <p>In case addrun is present check that if addt0's are given there are as many addt0's than addrun's.
@@ -6362,9 +6448,11 @@ Bool_t PMsrHandler::CheckAddRunParameters()
// check concerning the addt0 tags
if (fRuns[i].GetAddT0BinEntries() != 0) {
if (fRuns[i].GetAddT0BinEntries() != fRuns[i].GetRunNameSize()-1) {
std::cerr << std::endl << ">> PMsrHandler::CheckAddRunParameters: **ERROR** # of addt0 != # of addruns.";
std::cerr << std::endl << ">> Run #" << i+1;
std::cerr << std::endl;
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::CheckAddRunParameters: **ERROR** # of addt0 != # of addruns.\n";
fLastErrorMsg << ">> Run #" << i+1 << "\n";
std::cerr << std::endl << fLastErrorMsg.str();
result = false;
break;
}
@@ -6376,7 +6464,7 @@ Bool_t PMsrHandler::CheckAddRunParameters()
}
//--------------------------------------------------------------------------
// CheckMaxLikelihood (public)
// CheckMaxLikelihood (private)
//--------------------------------------------------------------------------
/**
* <p>If log max likelihood is requested, make sure that all run blocks are of single histogram type.
@@ -6389,8 +6477,10 @@ void PMsrHandler::CheckMaxLikelihood()
for (UInt_t i=0; i<fRuns.size(); i++) {
if ((fRuns[i].GetFitType() != MSR_FITTYPE_SINGLE_HISTO) && (fGlobal.GetFitType() != MSR_FITTYPE_SINGLE_HISTO) &&
(fRuns[i].GetFitType() != MSR_FITTYPE_MU_MINUS) && (fGlobal.GetFitType() != MSR_FITTYPE_MU_MINUS)) {
std::cerr << std::endl << ">> PMsrHandler::CheckMaxLikelihood: **WARNING**: Maximum Log Likelihood Fit is only implemented";
std::cerr << std::endl << ">> for Single Histogram and Mu Minus Fits. Will fall back to Chi Square Fit.";
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::CheckMaxLikelihood: **WARNING**: Maximum Log Likelihood Fit is only implemented\n";
fLastErrorMsg << ">> for Single Histogram and Mu Minus Fits. Will fall back to Chi Square Fit.\n";
std::cerr << std::endl << std::endl;
fStatistic.fChisq = true;
break;
@@ -6400,7 +6490,7 @@ void PMsrHandler::CheckMaxLikelihood()
}
//--------------------------------------------------------------------------
// CheckRRFSettings (public)
// CheckRRFSettings (private)
//--------------------------------------------------------------------------
/**
* <p>Make sure that if RRF settings are found in the GLOBAL section, the fit types
@@ -6496,6 +6586,54 @@ Bool_t PMsrHandler::CheckRRFSettings()
return result;
}
//--------------------------------------------------------------------------
// CheckRealFFT (private)
//--------------------------------------------------------------------------
/**
* <p>Checks for FOURIER plot REAL, if all necessary parameters are given.
*
* @return true if all necessary parameters are given; false otherwise.
*/
Bool_t PMsrHandler::CheckRealFFT()
{
// check
if (fFourier.fPlotTag == FOURIER_PLOT_POWER)
return true;
// check if the given phases in the Fourier block are in agreement with the Plot block settings
if ((fFourier.fPhase.size() > 1) && (fPlots.size() > 0)) {
if (fFourier.fPhase.size() != fPlots[0].fRuns.size()) {
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ReadMsrFile: **ERROR** if more than one phase is given in the Fourier block,\n";
fLastErrorMsg << ">> it needs to correspond to the number of runs in the Plot block!\n";
fLastErrorMsg << ">> currently:\n";
fLastErrorMsg << ">> number of runs in the PLOT block: " << fPlots[0].fRuns.size() << "\n";
fLastErrorMsg << ">> number of phases in the FOURIER block: " << fFourier.fPhase.size() << "\n";
std::cerr << std::endl << fLastErrorMsg.str();
return false;
}
}
// make sure that FOURIER phases are defined
if ((fFourier.fPhase.size() == 0) && (fFourier.fPhaseParamNo.size() == 0)) {
fLastErrorMsg.str("");
fLastErrorMsg.clear();
fLastErrorMsg << ">> PMsrHandler::ReadMsrFile: **ERROR** for FOURIER plot != POWER,\n";
fLastErrorMsg << ">> phases need to be defined in the FOURIER block!\n";
fLastErrorMsg << ">> Examples:\n";
fLastErrorMsg << ">> phase parR7 par9 par13 par16\n";
fLastErrorMsg << ">> where parR7 is the reference phase, and the others the relative phases.\n";
fLastErrorMsg << ">> I.e. phase of run 2: parR7 + par9, etc.\n";
fLastErrorMsg << ">> For further details see the docu.\n";
std::cerr << std::endl << fLastErrorMsg.str();
return false;
}
return true;
}
//--------------------------------------------------------------------------
// GetGroupingString (public)
//--------------------------------------------------------------------------

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -260,6 +260,7 @@ PRawRunDataSet::PRawRunDataSet()
*/
void PRawRunDataSet::Clear()
{
fTitle = TString("n/a");
fName = TString("n/a");
fHistoNo = -1;
fTimeZeroBin = 0.0;
@@ -581,6 +582,58 @@ PRawRunData::~PRawRunData()
fRedGreenOffset.clear();
}
//--------------------------------------------------------------------------
// CalcStartDateTime (public)
//--------------------------------------------------------------------------
/**
* <p>Calculate time_t of the present fStartDate and fStartTime.
*
* @param ok, true if time_t conversion has been successful
*
* @return time_t of the present fStartDate and fStartTime
*/
const time_t PRawRunData::CalcStartDateTime(bool &ok)
{
time_t dt=0;
ok = true;
struct tm tmStruct;
char date_time[256];
snprintf(date_time, sizeof(date_time), "%s %s", fStartDate.Data(), fStartTime.Data());
char *p_char = strptime(date_time, "%Y-%m-%d %H:%M:%S", &tmStruct);
if (*p_char != '\0') {
ok = false;
return dt;
}
dt = mktime(&tmStruct);
return dt;
}
//--------------------------------------------------------------------------
// CalcStopDateTime (public)
//--------------------------------------------------------------------------
/**
* <p>Calculate time_t of the present fStopDate and fStopTime.
*
* @param ok, true if time_t conversion has been successful
*
* @return time_t of the present fStopDate and fStopTime
*/
const time_t PRawRunData::CalcStopDateTime(bool &ok)
{
time_t dt=0;
ok = true;
struct tm tmStruct;
char date_time[256];
snprintf(date_time, sizeof(date_time), "%s %s", fStopDate.Data(), fStopTime.Data());
char *p_char = strptime(date_time, "%Y-%m-%d %H:%M:%S", &tmStruct);
if (*p_char != '\0') {
ok = false;
return dt;
}
dt = mktime(&tmStruct);
return dt;
}
//--------------------------------------------------------------------------
// GetTemperature (public)
//--------------------------------------------------------------------------

View File

@@ -8,7 +8,7 @@
***************************************************************************/
/***************************************************************************
* Copyright (C) 2007-2024 by Andreas Suter *
* Copyright (C) 2007-2025 by Andreas Suter *
* andreas.suter@psi.ch *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -935,10 +935,18 @@ void PMusrCanvas::Done(Int_t status)
void PMusrCanvas::HandleCmdKey(Int_t event, Int_t x, Int_t y, TObject *selected)
{
if (event != kKeyPress)
return;
return;
// this is a workaround which should prevent that the key event is executed if
// a text/latex is written into the canvas.
if (selected) {
if (!strcmp(selected->GetTitle(), "dataTheoryPad"))
return;
}
if (fBatchMode) {
if (fStartWithAvg) { // this is needed to get the averaging in the batch mode
fAveragedView = fStartWithAvg;
HandleAverage();
PlotAverage(true);
}
@@ -1928,9 +1936,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_DATA:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, diff, errDiff" << std::endl;
fout << "x, diff, errDiff" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()-1; i++) {
fout << "x" << i << " , diff" << i << ", errDiff" << i << ", ";
}
@@ -1940,9 +1947,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_REAL:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, F_diffRe" << std::endl;
fout << "x, F_diffRe" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()-1; i++) {
fout << "freq" << i << ", F_diffRe" << i << ", ";
}
@@ -1952,9 +1958,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_IMAG:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, F_diffIm" << std::endl;
fout << "x, F_diffIm" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()-1; i++) {
fout << "freq" << i << ", F_diffIm" << i << ", ";
}
@@ -1964,9 +1969,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_REAL_AND_IMAG:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, F_diffRe, F_diffIm" << std::endl;
fout << "x, F_diffRe, F_diffIm" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()/2; i++) {
fout << "freq" << i << ", F_diffRe" << i << ", ";
}
@@ -1979,9 +1983,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_PWR:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, F_diffPwr" << std::endl;
fout << "x, F_diffPwr" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()-1; i++) {
fout << "freq" << i << ", F_diffPwr" << i << ", ";
}
@@ -1991,9 +1994,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_PHASE:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% x, F_diffPhase" << std::endl;
fout << "x, F_diffPhase" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size()-1; i++) {
fout << "freq" << i << ", F_diffPhase" << i << ", ";
}
@@ -2042,24 +2044,22 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
fout << "% from averaged view" << std::endl;
fout << "% xData, data, errData, xTheory, theory" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
if (i % 2 == 0)
fout << "xData" << i/2 << " , data" << i/2 << ", errData" << i/2 << ", ";
fout << "xData" << i/2 << ", data" << i/2 << ", errData" << i/2 << ", ";
else
if (i == dumpVector.size()-1)
fout << "xTheory" << (i-1)/2 << " , theory" << (i-1)/2 << std::endl;
fout << "xTheory" << (i-1)/2 << ", theory" << (i-1)/2 << std::endl;
else
fout << "xTheory" << (i-1)/2 << " , theory" << (i-1)/2 << ", ";
fout << "xTheory" << (i-1)/2 << ", theory" << (i-1)/2 << ", ";
}
}
break;
case PV_FOURIER_REAL:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% freq, F_Re, freqTheo, F_theoRe" << std::endl;
fout << "freq, F_Re, freqTheo, F_theoRe" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
if (i % 2 == 0)
fout << "freq" << i/2 << ", F_Re" << i/2 << ", ";
@@ -2074,7 +2074,7 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_IMAG:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% freq, F_Im, freqTheo, F_theoIm" << std::endl;
fout << "freq, F_Im, freqTheo, F_theoIm" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
@@ -2091,9 +2091,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_REAL_AND_IMAG:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% freq, F_Re, freqTheo, F_theoRe, freq, F_Im, freqTheo, F_theoIm" << std::endl;
fout << "freq, F_Re, freqTheo, F_theoRe, freq, F_Im, freqTheo, F_theoIm" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
if (i % 4 == 0)
fout << "freq" << i/4 << ", F_Re" << i/4 << ", ";
@@ -2112,9 +2111,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_PWR:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% freq, F_Pwr, freqTheo, F_theoPwr" << std::endl;
fout << "freq, F_Pwr, freqTheo, F_theoPwr" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
if (i % 2 == 0)
fout << "freq" << i/2 << ", F_Pwr" << i/2 << ", ";
@@ -2129,9 +2127,8 @@ void PMusrCanvas::ExportData(const Char_t *fileName)
case PV_FOURIER_PHASE:
if (fAveragedView) {
fout << "% from averaged view" << std::endl;
fout << "% freq, F_Phase, freqTheo, F_theoPhase" << std::endl;
fout << "freq, F_Phase, freqTheo, F_theoPhase" << std::endl;
} else {
fout << "% ";
for (UInt_t i=0; i<dumpVector.size(); i++) {
if (i % 2 == 0)
fout << "freq" << i/2 << ", F_Phase" << i/2 << ", ";

Some files were not shown because too many files have changed in this diff Show More