Mikhail Veshtort
unread,Nov 7, 2013, 6:16:25 AM11/7/13Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to spinev-...@googlegroups.com
Hi Mike,
What you are asking for should ideally be done using the non-unit sampling (g>1) feature, the interface for which has been described in the SPINEVOLUTION paper, but the feature itself has not been implemented yet. The good news though is that I have very certain plans to implemented it some time in January-February next year.
For now, the only option you have for this is to use a more tricky approach. I'll illustrate it using an example that is completely analogous to yours, but is much simpler to explain.
Let's say your pulse sequence is simply ABC, where each letter stands for a group of pulses and delays, and all three groups (I'll call them subcycles) have the same length in time. And you want to observe after every subcycle. In other words, you want to sample as follows:
[S]
A[S]
AB[S]
ABC[S]
ABCA[S]
ABCAB[S]
etc.
where [S] means "sample a point". In your example, there are 16 such subcycles. Each of them is 0.5 usec long, and together they make up the TPPM cycle.
The period of this pulse sequence is ABC, and you want to take 3 sampling points each period. I call this the sampling rate, g. So, g=3 in this case. In the current version, SPINEVOLUTION can handle only g=1 cases. One can overcome this limitation by noticing that the same data points can be obtained by properly combining the results of three independent simulations with the pulse sequences of the form:
(X)D0 (Y)100
where
for simulation 1: X=0 Y=ABC
for simulation 2: X=A Y=BCA
for simulation 3: X=AB Y=CAB
By X=0 above I mean a "zero pulse" – a pulse of zero duration and zero power/phase/freq. The specific number of sampling points above (100) is chosen just as an example. Note that in all three cases, g equals 1, and so they can be simulated without problem.
Practically, one can do this by setting up 2 input files for SpinEvolution: one will drive the simulation, and the other will do the actual computations of the spin dynamics. The computational file should have the pulse sequence of the form (X)D0 (Y)100, where X and Y are macros that are substituted for actual file names when this computation is called by the driver. The files corresponding to all three versions of X and Y should be created (manually) prior to running the simulation. The driver can have the "zero pulse" as its sequence and use the Variables section to perform the following actions:
1) call the three simulations using the system() function
2) load the outputs of the three simulations and store them as columns of a 100x3 matrix
3) transpose the matrix
4) reshape it into a vector and save this vector into a file
If you are not sure how one can do these things, look up the following in the Reference Manual:
the -macro option, the system(), load(), save(), reshape(), and transpose() functions. And read the section called "Variables Section Functionality" if you are still unclear.
Best regards,
Mikhail