Page 1 of 1

curry / variation of field and temperature

Posted: Thu Jan 19, 2017 8:25 am
by radovanh
Dear developers

I would like to calculate magnetic properties for given pairs of T and B, so I defined
Exp.Temperature and Exp.Field as follows
Exp.Temperature =[2 5 10 ...300 2 2 2 2 2]
Exp.Field = [1 1 1 ....1 0 1 3 5 7]
because I would like to have data set for
T B M
2 1 value
5 1 value
10 1 value
...
300 1 value
2 0 value
2 1 value
2 3 value
2 5 value
2 7 value

which I could eventually used also for esfit.

However, curry calculates magnetization for all combination of Temperature and Field!
So in the end, I have matrix of Magnetization for
T 2 5 10 ...300 2 2 2 2 2
B
1
1
1
1
...
1
0
1
3
5
7

Then, of course, esfit does not work.

Is it somehow possible to tell easyspin to calculate magnetic moment only for given combination of T and B, that means for
Exp.Temperature[1] and Exp.Field[1], then for [Exp.Temperature[2] and Exp.Field[2]... and last Exp.Temperature[n] and Exp.Field[n]
?

Thank you very much for any help

Radovan

Re: curry / variation of field and temperature

Posted: Thu Jan 19, 2017 10:42 am
by Stefan Stoll

Code: Select all

Field = [1 1 2 2 2];
Temp = [1 2 3 4 5];
for k = 1:numel(Temp)
  Exp.Temperature  = Temp(k);
  Exp.Field = Field(k);
  muz(k) = curry(Sys,Exp);
end

Re: curry / variation of field and temperature

Posted: Thu Jan 19, 2017 11:29 am
by radovanh
Thank you for help.
So this is the way to do calculation for one set of parameter.
But evidently, it is not suitable for ESFIT, maybe in some of next releases.

Once more thank for help

Radovan

Re: curry / variation of field and temperature

Posted: Mon Jan 23, 2017 4:20 am
by joscha_nehrkorn
You can define a custom function for fitting. See:

http://easyspin.org/easyspin/documentat ... omfunction