Difference between revisions of "Partner state.m"

From Spinach Documentation Wiki
Jump to: navigation, search
(Sync syntax/arguments/outputs with current Spinach source)
 
(Update function See also links and function index membership)
 
(7 intermediate revisions by the same user not shown)
Line 9: Line 9:
 
  [A,descr]=partner_state(spin_system,set_spin,partners)
 
  [A,descr]=partner_state(spin_system,set_spin,partners)
  
−
==Arguments==
+
==Parameters==
  
 
  set_spin    - a cell array of two-element cell arrays
 
  set_spin    - a cell array of two-element cell arrays
Line 15: Line 15:
 
                   of the spin and the second element num-
 
                   of the spin and the second element num-
 
                   ber on the isotope list, for example
 
                   ber on the isotope list, for example
−
 
+
−
                                 {{'L+',3}}
+
                                 { {'L+',3} }
−
 
+
 
                   These spins will have their states set
 
                   These spins will have their states set
 
                   immutably as specified.
 
                   immutably as specified.
−
 
+
 
     partners    - a cell array of partner state specifica-
 
     partners    - a cell array of partner state specifica-
 
                   tions of the form
 
                   tions of the form
−
 
+
 
                           { {states_a,spins_a},...
 
                           { {states_a,spins_a},...
 
                             {states_b,spins_b},... }
 
                             {states_b,spins_b},... }
−
 
+
 
                   where states_a,b are cell arrays of sta-
 
                   where states_a,b are cell arrays of sta-
 
                   tes that the partner spins can have and
 
                   tes that the partner spins can have and
 
                   spins_a,b are lists of numbers of those
 
                   spins_a,b are lists of numbers of those
 
                   spins on the main isotope list, e.g.
 
                   spins on the main isotope list, e.g.
−
 
+
 
                         { {{'E'  'Lz'},[1 5]},...
 
                         { {{'E'  'Lz'},[1 5]},...
 
                           {{'L+' 'L-'},[2 7]},... }
 
                           {{'L+' 'L-'},[2 7]},... }
−
 
+
 
                   These spins will have their state varied
 
                   These spins will have their state varied
 
                   combinatorially as specified.
 
                   combinatorially as specified.
Line 45: Line 45:
 
         ons specified by the user. All spins not explicitly
 
         ons specified by the user. All spins not explicitly
 
         mentioned in the input will be in their 'E' states.
 
         mentioned in the input will be in their 'E' states.
−
 
+
 
     descr - a cell array of product structure descriptors for
 
     descr - a cell array of product structure descriptors for
 
             each element of A
 
             each element of A
−
 
+
 
  Example: in a five-spin system, the following call
 
  Example: in a five-spin system, the following call
−
 
+
−
   A=partner_state(spin_system,{{'L+',2}},{{{'E','Lz'},[1 3]}})
+
   A=partner_state(spin_system,{ {'L+',2} },{{{'E','Lz'},[1 3]}})
−
 
+
 
           will return the following state array
 
           will return the following state array
−
 
+
 
   A={state(spin_system,{'E' ,'L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
 
   A={state(spin_system,{'E' ,'L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
 
     state(spin_system,{'Lz','L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
 
     state(spin_system,{'Lz','L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
 
     state(spin_system,{'E' ,'L+','Lz','E' ,'E'},{1 2 3 4 5}),...
 
     state(spin_system,{'E' ,'L+','Lz','E' ,'E'},{1 2 3 4 5}),...
 
     state(spin_system,{'Lz','L+','Lz','E' ,'E'},{1 2 3 4 5})};
 
     state(spin_system,{'Lz','L+','Lz','E' ,'E'},{1 2 3 4 5})};
−
 
+
 
           and the following descriptor array
 
           and the following descriptor array
−
 
+
 
     descr={{'E' ,'L+','E' ,'E' ,'E'},...
 
     descr={{'E' ,'L+','E' ,'E' ,'E'},...
 
             {'Lz','L+','E' ,'E' ,'E'},...
 
             {'Lz','L+','E' ,'E' ,'E'},...
Line 67: Line 67:
 
             {'Lz','L+','Lz','E' ,'E'}};
 
             {'Lz','L+','Lz','E' ,'E'}};
  
−
ilya.kuprov@weizmann.ac.il
+
==See also==
 +
[[enlev2ist.m]], [[oper2ist.m]], [[state.m]], [[deut_pair.m]], [[equilibrium.m]], [[four_spin_states.m]], [[singlet.m]], [[triplet.m]], [[zftrip.m]], [[Kernel_functions]], [[Kernel_utilities]]
 +
 
 +
''Version 2.11, authors: [[Ilya Kuprov]]''

Latest revision as of 18:39, 6 June 2026


Partner state expansion; a given state of the specified spins is kroneckered with all combinations of the specified states of specfied partner spins.

Syntax

[A,descr]=partner_state(spin_system,set_spin,partners)

Parameters

set_spin    - a cell array of two-element cell arrays
                 with the first element giving the state
                 of the spin and the second element num-
                 ber on the isotope list, for example

                               { {'L+',3} }

                 These spins will have their states set
                 immutably as specified.

   partners    - a cell array of partner state specifica-
                 tions of the form

                         { {states_a,spins_a},...
                           {states_b,spins_b},... }

                 where states_a,b are cell arrays of sta-
                 tes that the partner spins can have and
                 spins_a,b are lists of numbers of those
                 spins on the main isotope list, e.g.

                        { {{'E'  'Lz'},[1 5]},...
                          {{'L+' 'L-'},[2 7]},... }

                 These spins will have their state varied
                 combinatorially as specified.

Outputs

A - a cell array of spin states (matrices in Hilbert space,
       vectors in Liouville space) with the active spin in the
       specified state and the partner spins in all combinati-
       ons specified by the user. All spins not explicitly
       mentioned in the input will be in their 'E' states.

   descr - a cell array of product structure descriptors for
           each element of A

Example: in a five-spin system, the following call

 A=partner_state(spin_system,{ {'L+',2} },{{{'E','Lz'},[1 3]}})

         will return the following state array

 A={state(spin_system,{'E' ,'L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
    state(spin_system,{'Lz','L+','E' ,'E' ,'E'},{1 2 3 4 5}),...
    state(spin_system,{'E' ,'L+','Lz','E' ,'E'},{1 2 3 4 5}),...
    state(spin_system,{'Lz','L+','Lz','E' ,'E'},{1 2 3 4 5})};

         and the following descriptor array

    descr={{'E' ,'L+','E' ,'E' ,'E'},...
           {'Lz','L+','E' ,'E' ,'E'},...
           {'E' ,'L+','Lz','E' ,'E'},...
           {'Lz','L+','Lz','E' ,'E'}};

See also

enlev2ist.m, oper2ist.m, state.m, deut_pair.m, equilibrium.m, four_spin_states.m, singlet.m, triplet.m, zftrip.m, Kernel_functions, Kernel_utilities

Version 2.11, authors: Ilya Kuprov