Difference between revisions of "Assume.m"
(Document the 'cavity' and 'spin-phonon' assumption sets and mode retention rules (PR 195)) |
|||
| (19 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
| + | {{DISPLAYTITLE:assume.m}} __NOTOC__ | ||
Sets case-specific assumptions for various simulation contexts. This function determines the behaviour of the Hamiltonian generation function and should be called before the Hamiltonian is requested. Syntax: | Sets case-specific assumptions for various simulation contexts. This function determines the behaviour of the Hamiltonian generation function and should be called before the Hamiltonian is requested. Syntax: | ||
| Line 10: | Line 11: | ||
|- | |- | ||
|'nmr' | |'nmr' | ||
| − | | | + | |Rotating frame approximation for electrons; rotating frame approximation for nuclei; secular terms for electron Zeeman interactions; secular terms for nuclear Zeeman interactions; secular terms for giant spin model interactions; secular coupling terms for spins belonging to the same species; weak coupling terms for spins belonging to different species; secular coupling terms for quadratic and higher order couplings |
|- | |- | ||
| − | |'esr' | + | |'esr', 'deer' |
| − | |Rotating frame approximation for electrons | + | |Rotating frame approximation for electrons; laboratory frame simulation for nuclei; secular terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; secular terms for inter-electron couplings; secular terms for electron zero-field splittings; secular terms for giant spin model interactions; secular and pseudosecular terms for hyperfine couplings; all terms for inter-nuclear couplings; all terms for nuclear quadrupolar couplings. |
|- | |- | ||
|'labframe' | |'labframe' | ||
| − | |Laboratory frame simulation for electrons, laboratory frame simulation for nuclei | + | |Laboratory frame simulation for electrons, laboratory frame simulation for nuclei; all terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; all terms for giant spin model interactions; all terms for all couplings. Bosonic modes are allowed and stay in the laboratory frame with all of their interaction terms retained. |
|- | |- | ||
|'qnmr' | |'qnmr' | ||
| − | | | + | |A special assumption set for quadrupolar spectroscopy in which the quadrupolar nuclei are kept in the laboratory frame: rotating frame approximation for S=1/2 nuclei; laboratory frame simulation for S>1/2 nuclei; electrons disallowed by the approximation; secular Zeeman terms for S=1/2 nuclei; all Zeeman terms for S>1/2 nuclei; secular terms for couplings between S=1/2 nuclei; weak and pseudosecular terms for couplings between S=1/2 and S>1/2 nuclei; all terms for couplings between S>1/2 nuclei; all terms for nuclear quadrupolar couplings. |
|- | |- | ||
| − | |'deer' | + | |'deer-zz' |
| − | | | + | |A special assumption set for DEER simulations with flip-flop terms switched off in the inter-electron coupling Hamiltionian: rotating frame approximation for electrons; laboratory frame simulation for nuclei; secular terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; weak terms for inter-electron couplings; secular terms for electron zero-field splittings; secular terms for giant spin model interactions; weak and pseudosecular terms for hyperfine couplings; all terms for inter-nuclear couplings; all terms for nuclear quadrupolar couplings. |
| + | |- | ||
| + | |'cavity' | ||
| + | |For cavity QED: spins and bosonic modes in a common rotating frame with the rotating wave approximation; mode energies are built as detunings from the carrier frequency; exchange terms keep flip-flop components only; anharmonicity, cross-Kerr, and dispersive terms in full; longitudinal and Hamiltonian modulation terms are disallowed because they average out in this frame. | ||
| + | |- | ||
| + | |'spin-phonon' | ||
| + | |For spins in their usual rotating frames with bosonic modes in the laboratory frame: electron and nuclear terms as in the 'esr' set; electron-mode exchange terms dropped as non-secular; mode-mode and nucleus-mode exchange terms retained in full; longitudinal, dispersive, and Hamiltonian modulation terms and all diagonal mode terms retained. | ||
| + | |} | ||
| + | |||
| + | If the retention argument is aupplied, the following Hamiltonian term retention settings are supported: | ||
| + | |||
| + | {| class="wikitable" | ||
| + | !retention | ||
| + | !description | ||
| + | |- | ||
| + | |'zeeman' | ||
| + | |all spin-spin couplings are ignored | ||
| + | |- | ||
| + | |'couplings' | ||
| + | |all Zeeman interactions are ignored | ||
|} | |} | ||
| − | + | Retention options are refused when bosonic modes are present in the system, because their meaning for spin-boson Hamiltonians is not defined. | |
Some pulse sequences (notably those dealing with DNP) set their own assumptions internally before calling the Hamiltonian generation function. To that end, assume.m function also contains more specialized assumption sets – see the function code for further information. | Some pulse sequences (notably those dealing with DNP) set their own assumptions internally before calling the Hamiltonian generation function. To that end, assume.m function also contains more specialized assumption sets – see the function code for further information. | ||
| Line 34: | Line 54: | ||
User-specified assumptions are ignored when generating thermal equilibrium states and relaxation superoperators – assumption sets for those functions are fixed by the nature of the physical problems that they solve. | User-specified assumptions are ignored when generating thermal equilibrium states and relaxation superoperators – assumption sets for those functions are fixed by the nature of the physical problems that they solve. | ||
| + | |||
| + | ==Syntax== | ||
| + | |||
| + | spin_system=assume(spin_system,assumptions,retention) | ||
| + | |||
| + | ==Parameters== | ||
| + | |||
| + | assumptions - 'nmr' for high-field NMR) | ||
| + | |||
| + | 'esr' for electron rotating frame ESR | ||
| + | |||
| + | 'deer' for DEER spectroscopy | ||
| + | |||
| + | 'deer-zz' for DEER spectroscopy with electron | ||
| + | flip-flop terms removed | ||
| + | |||
| + | 'labframe' for full laboratory frame simulation | ||
| + | with all Hamiltonian terms retained; | ||
| + | bosonic modes are allowed and stay in | ||
| + | the laboratory frame with all of their | ||
| + | interaction terms retained | ||
| + | |||
| + | 'qnmr' for quadrupolar NMR with numerical | ||
| + | rotating frames: spin-1/2 particles | ||
| + | will be in the rotating frame but | ||
| + | spin>1/2 particles initially in the | ||
| + | laboratory frame | ||
| + | |||
| + | 'cavity' for cavity QED: spins and bosonic | ||
| + | modes in a common rotating frame with | ||
| + | the rotating wave approximation, mode | ||
| + | energies to be built as detunings from | ||
| + | the carrier frequency, exchange terms | ||
| + | keeping flip-flop components only, | ||
| + | anharmonicity, Kerr, and dispersive | ||
| + | terms in full; longitudinal and modu- | ||
| + | lation terms are disallowed because | ||
| + | they average out | ||
| + | |||
| + | 'spin-phonon' for spins in their usual rotating | ||
| + | frames with bosonic modes in the la- | ||
| + | boratory frame: electron and nuclear | ||
| + | terms as in the 'esr' set, electron- | ||
| + | mode exchange terms dropped as non- | ||
| + | secular, mode-mode and nucleus-mode | ||
| + | exchange terms retained in full, | ||
| + | longitudinal, dispersive, and modula- | ||
| + | tion terms and all diagonal mode | ||
| + | terms retained | ||
| + | |||
| + | retention - 'zeeman' drops all spin-spin interactions | ||
| + | |||
| + | 'couplings' drops all Zeeman interactions | ||
| + | |||
| + | ==Outputs== | ||
| + | |||
| + | the function updates the spin_system object | ||
| + | |||
| + | ==See also== | ||
| + | [[create.m]], [[basis.m]], [[crystal.m]], [[doublerot.m]], [[residual.m]], [[device.m]], [[rlx_modes.m]], [[Kernel_functions]], [[Kernel_contexts]] | ||
| + | |||
| + | ''Version 1.9, authors: [[Ilya Kuprov]]'' | ||
Latest revision as of 05:41, 6 August 2026
Sets case-specific assumptions for various simulation contexts. This function determines the behaviour of the Hamiltonian generation function and should be called before the Hamiltonian is requested. Syntax:
spin_system=assume(spin_system,assumptions,retention)
The following assumption sets are supported:
| assumption set | description |
|---|---|
| 'nmr' | Rotating frame approximation for electrons; rotating frame approximation for nuclei; secular terms for electron Zeeman interactions; secular terms for nuclear Zeeman interactions; secular terms for giant spin model interactions; secular coupling terms for spins belonging to the same species; weak coupling terms for spins belonging to different species; secular coupling terms for quadratic and higher order couplings |
| 'esr', 'deer' | Rotating frame approximation for electrons; laboratory frame simulation for nuclei; secular terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; secular terms for inter-electron couplings; secular terms for electron zero-field splittings; secular terms for giant spin model interactions; secular and pseudosecular terms for hyperfine couplings; all terms for inter-nuclear couplings; all terms for nuclear quadrupolar couplings. |
| 'labframe' | Laboratory frame simulation for electrons, laboratory frame simulation for nuclei; all terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; all terms for giant spin model interactions; all terms for all couplings. Bosonic modes are allowed and stay in the laboratory frame with all of their interaction terms retained. |
| 'qnmr' | A special assumption set for quadrupolar spectroscopy in which the quadrupolar nuclei are kept in the laboratory frame: rotating frame approximation for S=1/2 nuclei; laboratory frame simulation for S>1/2 nuclei; electrons disallowed by the approximation; secular Zeeman terms for S=1/2 nuclei; all Zeeman terms for S>1/2 nuclei; secular terms for couplings between S=1/2 nuclei; weak and pseudosecular terms for couplings between S=1/2 and S>1/2 nuclei; all terms for couplings between S>1/2 nuclei; all terms for nuclear quadrupolar couplings. |
| 'deer-zz' | A special assumption set for DEER simulations with flip-flop terms switched off in the inter-electron coupling Hamiltionian: rotating frame approximation for electrons; laboratory frame simulation for nuclei; secular terms for electron Zeeman interactions; all terms for nuclear Zeeman interactions; weak terms for inter-electron couplings; secular terms for electron zero-field splittings; secular terms for giant spin model interactions; weak and pseudosecular terms for hyperfine couplings; all terms for inter-nuclear couplings; all terms for nuclear quadrupolar couplings. |
| 'cavity' | For cavity QED: spins and bosonic modes in a common rotating frame with the rotating wave approximation; mode energies are built as detunings from the carrier frequency; exchange terms keep flip-flop components only; anharmonicity, cross-Kerr, and dispersive terms in full; longitudinal and Hamiltonian modulation terms are disallowed because they average out in this frame. |
| 'spin-phonon' | For spins in their usual rotating frames with bosonic modes in the laboratory frame: electron and nuclear terms as in the 'esr' set; electron-mode exchange terms dropped as non-secular; mode-mode and nucleus-mode exchange terms retained in full; longitudinal, dispersive, and Hamiltonian modulation terms and all diagonal mode terms retained. |
If the retention argument is aupplied, the following Hamiltonian term retention settings are supported:
| retention | description |
|---|---|
| 'zeeman' | all spin-spin couplings are ignored |
| 'couplings' | all Zeeman interactions are ignored |
Retention options are refused when bosonic modes are present in the system, because their meaning for spin-boson Hamiltonians is not defined.
Some pulse sequences (notably those dealing with DNP) set their own assumptions internally before calling the Hamiltonian generation function. To that end, assume.m function also contains more specialized assumption sets – see the function code for further information.
When calling kernel contexts assumptions should be passed as the last argument, for example:
fid=liquid(spin_system,@pulse_acquire,parameters,'nmr');
User-specified assumptions are ignored when generating thermal equilibrium states and relaxation superoperators – assumption sets for those functions are fixed by the nature of the physical problems that they solve.
Syntax
spin_system=assume(spin_system,assumptions,retention)
Parameters
assumptions - 'nmr' for high-field NMR)
'esr' for electron rotating frame ESR
'deer' for DEER spectroscopy
'deer-zz' for DEER spectroscopy with electron
flip-flop terms removed
'labframe' for full laboratory frame simulation
with all Hamiltonian terms retained;
bosonic modes are allowed and stay in
the laboratory frame with all of their
interaction terms retained
'qnmr' for quadrupolar NMR with numerical
rotating frames: spin-1/2 particles
will be in the rotating frame but
spin>1/2 particles initially in the
laboratory frame
'cavity' for cavity QED: spins and bosonic
modes in a common rotating frame with
the rotating wave approximation, mode
energies to be built as detunings from
the carrier frequency, exchange terms
keeping flip-flop components only,
anharmonicity, Kerr, and dispersive
terms in full; longitudinal and modu-
lation terms are disallowed because
they average out
'spin-phonon' for spins in their usual rotating
frames with bosonic modes in the la-
boratory frame: electron and nuclear
terms as in the 'esr' set, electron-
mode exchange terms dropped as non-
secular, mode-mode and nucleus-mode
exchange terms retained in full,
longitudinal, dispersive, and modula-
tion terms and all diagonal mode
terms retained
retention - 'zeeman' drops all spin-spin interactions
'couplings' drops all Zeeman interactions
Outputs
the function updates the spin_system object
See also
create.m, basis.m, crystal.m, doublerot.m, residual.m, device.m, rlx_modes.m, Kernel_functions, Kernel_contexts
Version 1.9, authors: Ilya Kuprov