# [Pw_forum] problem with primitive cell

Stefano de Gironcoli degironc at sissa.it
Tue Nov 18 08:57:14 CET 2008

```Dear Krishna chaitanya ,
the problem with eq 2 is that it defines the surface energy as a
(small) difference between large numbers and tiny inaccuracies in the
calculation of Ebulk (due to different k-point sampling or limited
self-consistency) are amplified by the factor proportional to the number
of layer.
One way the surfare can be calculated is to rewrite  eq 2 as
En = n Ebulk + 2 A Ens
and then extract Ebulk and Ens from a linear fit of calculated En for
large enough n.
The slope of the resulting straight line is related to Ebulk and
should be close to the directly calculated value in a bulk cell while
the intersection with the vertical axis gives you the surface energy
(times 2A).
Hope this helps,
Stefano de Gironcoli  -  SISSA and DEMOCRITOS

Krishna chaitanya wrote:
> Hi,
>
> I am trying to calculate surface energy of MgO surface layers using
> PWSCF. For that i have used 2 methods given as
>
> 1)Ens={En-n(En-En-1)}/2A
>     here n=no of layers, En and En-1 are total energies of n and n-1
> layers, A=surface area of primitive cell
>
> 2)Ens=(En-n Ebulk)/2A
>    here m=no of primitive units present in surface, Ebulk=total energy
> of primitive unit cell
>
> I have got converged surfae energy 0.004au/bohr**2 by using method 1,
> but by using method 2 i got very different energies and not converged
> by varying number of layers. When i checked with xcrysden the periodic
> repetetion in primitive cell is not good. Initially i have followed by
> cartesian coordinates but the number of symmetry operations observed
> as 1, but when followed by fractional coordinates symmetry operations
> are 48 now.
>
>
>   MgO conventional cell is in FCC bravis lattice group and i have used
> the following input for the primitive cell description
>
> &SYSTEM
>
> ibrav = 2,
>
> A = 2.977768,
>
> B = 2.977768,
>
> C = 2.977768,
>
> cosAB = 0.5,
>
> cosAC = 0.5,
>
> cosBC = 0.5,
>
> nat = 2,
>
> ntyp = 2,
>
> ecutwfc = 25,
>
> ecutrho = 200,
>
> /
>
> &ELECTRONS
>
> electron_maxstep = 500,
>
> diago_david_ndim = 6,
>
> /
>
> &IONS
>
> ion_dynamics = 'bfgs',
>
> /
>
> ATOMIC_SPECIES
>
> O 16.000 O.pw91-van_ak.UPF
>
> Mg 24.305 Mg.pw91-np-van.UPF
>
> ATOMIC_POSITIONS crystal
>
> Mg 0.00000000 0.00000000 0.00000000
>
> O 0.50000000 0.50000000 0.50000000
>
> K_POINTS automatic
>
> 4 4 4 0 0 0
>
>
>
> Please suggest me where i have done mistake and thanks in advance
>
> G. Krishna Chaitanya
> Senior research fellow
> C/o Dr. Bhanuprakash K.
> Inorganic Chemistry Division
> Indian Institute of Chemical Technology
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org
> http://www.democritos.it/mailman/listinfo/pw_forum
>

```