Page 1 of 1

three-dimensional magnetization

Posted: Wed Nov 06, 2024 3:04 am
by radovanh

Hello.

I would like to calculate magnetization with CURRY for various orientations of the magnetic field.
From the documentation, I guess I need to use Exp.SampleFrame command.

So I generated simple loop for three different Euler angles

Code: Select all

Temp=2;  %K
Field=500; %mT

npoints=10; %number of point for PI section
delta=pi/(npoints);
count=0;
%alfa
for i = 0:2*npoints
    alfa=i*delta;
%beta
for j = 0:npoints
    beta=j*delta;
%gama
for k = 0:2*npoints
    gama=k*delta;
    count=count+1;
    mag=simulate(x0,alfa,beta,gama,Temp,Field);
    f_alfa(count)=alfa;
    f_beta(count)=beta;
    f_gama(count)=gama;
    Magnetization(count)=mag;
    
end end end

where the function "simulate" calculates the magnetization for given angles:

Code: Select all

Exp.MolFrame = [0 0 0];  
Exp.CrystalSymmetry = 'P1'; % crystal space group Exp.SampleFrame = [gama beta alfa]; simspc = curry(FitSys,Exp,Opt);

However, I do not know how to properly transfer Euler angles to information about X,Y,Z coordinates. So I do not know for which orientation of the magnetic field the curry calculates magnetization. So in other words I would like to calculate (Bx,By,Bz).

Any help is truly welcomed

Radovan


Re: three-dimensional magnetization

Posted: Wed Nov 06, 2024 2:47 pm
by Stefan Stoll

Have a look here: https://easyspin.org/easyspin/documenta ... es.html#CL

This describes how to get axes from the Exp.SampleFrame Euler angles.