Commit efa283d7 authored by Matthias Redies's avatar Matthias Redies

allocate temporary gradients

parent d1562780
......@@ -81,7 +81,10 @@ CONTAINS
nsp=(atoms%lmaxd+1+MOD(atoms%lmaxd+1,2))*(2*atoms%lmaxd+1)
ALLOCATE(ch(nsp*atoms%jmtd,input%jspins))
IF (xcpot%needs_grad()) CALL xcpot%alloc_gradients(SIZE(ch,1),input%jspins,grad)
IF (xcpot%needs_grad()) THEN
CALL xcpot%alloc_gradients(SIZE(ch,1),input%jspins,grad)
CALL xcpot%alloc_gradients(SIZE(ch,1),input%jspins,tmp_grad)
ENDIF
CALL init_mt_grid(nsp,input%jspins,atoms,sphhar,xcpot,sym)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment