# Newbie - scripts to plot susceptibility and specific heat

Up to HΦ Forum / HΦ フォーラム### Newbie - scripts to plot susceptibility and specific heat

Posted by Vamshi Katukuri at June 23. 2017Dear Developers,

I am new to using HPhi. I am interested in obtaining Chi and Cp for spin Hamiltonians. If I understand correctly, I will have to write my own script to obtain those from the TPQ (something I am still trying to understand) output. Are there any scripts available already. If not, could you please steer me to write them.

Thanks and regards

Vamshi

Dear Katukuri

Thank you for using HPhi !

In the TPQ calculations, temperature dependence of Energy <H> and its square <H^2> are output in SS_rand#.dat (# represents the number of bins). From this the specific heat is calculated by C= (<H^2>-<H>^2)/T^2. Attached Ave.pl is a perl script for calculating temperature dependence of the energy, the specific heat, and other physical properties.

In a similar way, total Sz <Sz> and its square <Sz^2> are output in Flct_rand#.dat. The uniform susceptibility chi can be calculated by chi = (<Sz^2>-<Sz>^2)/T. However, please note that, this expression of chi is only valid for the Sz-conserved systems. To obtain the uniform susceptibility for Sz-non-conserved systems such as the Kitaev model, it is necessary to apply the small but finite magnetic field H explicitly. By applying the magnetic field H, from the temperature dependence of <Sz>, uniform susceptibility is calculated as chi = <Sz>/H.

Best,

Takahiro Misawa

### Re: Newbie - scripts to plot susceptibility and specific heat

Posted by Vamshi Katukuri at June 25. 2017Dear Katukuri

Thank you for using HPhi !

In the TPQ calculations, temperature dependence of Energy <H> and its square <H^2> are output in SS_rand#.dat (# represents the number of bins). From this the specific heat is calculated by C= (<H^2>-<H>^2)/T^2. Attached Ave.pl is a perl script for calculating temperature dependence of the energy, the specific heat, and other physical properties.

In a similar way, total Sz <Sz> and its square <Sz^2> are output in Flct_rand#.dat. The uniform susceptibility chi can be calculated by chi = (<Sz^2>-<Sz>^2)/T. However, please note that, this expression of chi is only valid for the Sz-conserved systems. To obtain the uniform susceptibility for Sz-non-conserved systems such as the Kitaev model, it is necessary to apply the small but finite magnetic field H explicitly. By applying the magnetic field H, from the temperature dependence of <Sz>, uniform susceptibility is calculated as chi = <Sz>/H.

Best,

Takahiro Misawa

Dear Misawa, Thank you very much for your explanation and the scripts as well. I appreciate your help. Regards Vamshi