Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
fleur
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
52
Issues
52
List
Boards
Labels
Service Desk
Milestones
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
fleur
fleur
Commits
0e447815
Commit
0e447815
authored
Jan 05, 2019
by
Matthias Redies
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
indent new file
parent
00c67ec6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
51 additions
and
52 deletions
+51
-52
xc-pot/excepbe.f90
xc-pot/excepbe.f90
+51
-52
No files found.
xc-pot/excepbe.f90
View file @
0e447815
MODULE
m_excepbe
MODULE
m_excepbe
!.....-----------------------------------------------------------------
!.....epbe(easy_pbe) exchange-correlation energy density in hartree.
! excepbe - easypbe
!.....------------------------------------------------------------------
CONTAINS
SUBROUTINE
excepbe
(
&
xcpot
,
jspins
,
mirm
,
irmx
,
&
rh
,
agr
,
agru
,
agrd
,
&
g2ru
,
g2rd
,
gggr
,
gggru
,
gggrd
,
&
exc
)
CONTAINS
SUBROUTINE
excepbe
(
&
xcpot
,
jspins
,
mirm
,
irmx
,
&
rh
,
agr
,
agru
,
agrd
,
&
g2ru
,
g2rd
,
gggr
,
gggru
,
gggrd
,
&
exc
)
USE
m_easypbe
USE
m_types_xcpot_data
USE
m_easypbe
USE
m_types_xcpot_data
IMPLICIT
NONE
IMPLICIT
NONE
! .. Arguments ..
TYPE
(
t_xcpot_data
),
INTENT
(
IN
)::
xcpot
INTEGER
,
INTENT
(
IN
)
::
irmx
,
jspins
,
mirm
REAL
,
INTENT
(
IN
)
::
rh
(
mirm
,
jspins
)
REAL
,
INTENT
(
IN
)
::
agr
(
mirm
),
agru
(
mirm
),
agrd
(
mirm
)
REAL
,
INTENT
(
IN
)
::
g2ru
(
mirm
),
g2rd
(
mirm
),
gggr
(
mirm
)
REAL
,
INTENT
(
IN
)
::
gggru
(
mirm
),
gggrd
(
mirm
)
REAL
,
INTENT
(
OUT
)
::
exc
(
mirm
)
TYPE
(
t_xcpot_data
),
INTENT
(
IN
)::
xcpot
INTEGER
,
INTENT
(
IN
)
::
irmx
,
jspins
,
mirm
REAL
,
INTENT
(
IN
)
::
rh
(
mirm
,
jspins
)
REAL
,
INTENT
(
IN
)
::
agr
(
mirm
),
agru
(
mirm
),
agrd
(
mirm
)
REAL
,
INTENT
(
IN
)
::
g2ru
(
mirm
),
g2rd
(
mirm
),
gggr
(
mirm
)
REAL
,
INTENT
(
IN
)
::
gggru
(
mirm
),
gggrd
(
mirm
)
REAL
,
INTENT
(
OUT
)
::
exc
(
mirm
)
! .. local variables ..
INTEGER
::
lcor
,
lpot
,
i
REAL
::
ro
,
rou
,
rod
,
xedl
,
cedl
,
xedg
,
cedg
,
xced
REAL
::
up
,
agrup
,
delgrup
,
uplap
,
dn
,
agrdn
,
delgrdn
,
dnlap
,
&
agrt
,
delgrt
,
&
exlsd
,
vxuplsd
,
vxdnlsd
,
eclsd
,
vcuplsd
,
vcdnlsd
,
&
expbe
,
vxuppbe
,
vxdnpbe
,
ecpbe
,
vcuppbe
,
vcdnpbe
,
&
vxupsr
,
vxdnsr
INTEGER
::
lcor
,
lpot
,
i
REAL
::
ro
,
rou
,
rod
,
xedl
,
cedl
,
xedg
,
cedg
,
xced
REAL
::
up
,
agrup
,
delgrup
,
uplap
,
dn
,
agrdn
,
delgrdn
,
dnlap
,
&
agrt
,
delgrt
,
&
exlsd
,
vxuplsd
,
vxdnlsd
,
eclsd
,
vcuplsd
,
vcdnlsd
,
&
expbe
,
vxuppbe
,
vxdnpbe
,
ecpbe
,
vcuppbe
,
vcdnpbe
,
&
vxupsr
,
vxdnsr
REAL
,
PARAMETER
::
sml
=
1.e-14
REAL
,
PARAMETER
::
smlc
=
2.01e-14
REAL
,
PARAMETER
::
sml
=
1.e-14
REAL
,
PARAMETER
::
smlc
=
2.01e-14
! OMP parallel do default(private)
! OMP& SHARED(xcpot,jspins,mirm,irmx)
! OMP& SHARED(rh,agr,agru,agrd)
! OMP& SHARED(g2ru,g2rd,gggr,gggru,gggrd)
! OMP& SHARED(exc)
DO
i
=
1
,
irmx
DO
i
=
1
,
irmx
IF
(
jspins
==
1
)
THEN
IF
(
jspins
==
1
)
THEN
rou
=
rh
(
i
,
1
)/
2
rou
=
max
(
rou
,
sml
)
rod
=
rou
ELSE
ELSE
rou
=
rh
(
i
,
1
)
rod
=
rh
(
i
,
jspins
)
rou
=
max
(
rou
,
sml
)
rod
=
max
(
rod
,
sml
)
ENDIF
ENDIF
ro
=
rou
+
rod
ro
=
rou
+
rod
!.....
! xedl,xedg: exchange energy density (local,grad.exp.) in ry.
! cedl,cedg: exchange energy density (local,grad.expnd.) in ry.
!.....
xedl
=
0.0e0
cedl
=
0.0e0
xedg
=
0.0e0
cedg
=
0.0e0
!.....
! xedl,xedg: exchange energy density (local,grad.exp.) in ry.
! cedl,cedg: exchange energy density (local,grad.expnd.) in ry.
!.....
xedl
=
0.0e0
cedl
=
0.0e0
xedg
=
0.0e0
cedg
=
0.0e0
IF
(
ro
>
smlc
)
THEN
IF
(
ro
>
smlc
)
THEN
lcor
=
1
lpot
=
1
...
...
@@ -82,24 +81,24 @@
delgrt
=
gggr
(
i
)
CALL
easypbe
(
xcpot
,
&
up
,
agrup
,
delgrup
,
uplap
,
dn
,
agrdn
,
delgrdn
,
dnlap
,
&
agrt
,
delgrt
,
lcor
,
lpot
,
&
exlsd
,
vxuplsd
,
vxdnlsd
,
eclsd
,
vcuplsd
,
vcdnlsd
,
&
expbe
,
vxuppbe
,
vxdnpbe
,
ecpbe
,
vcuppbe
,
vcdnpbe
,
&
vxupsr
,
vxdnsr
)
up
,
agrup
,
delgrup
,
uplap
,
dn
,
agrdn
,
delgrdn
,
dnlap
,
&
agrt
,
delgrt
,
lcor
,
lpot
,
&
exlsd
,
vxuplsd
,
vxdnlsd
,
eclsd
,
vcuplsd
,
vcdnlsd
,
&
expbe
,
vxuppbe
,
vxdnpbe
,
ecpbe
,
vcuppbe
,
vcdnpbe
,
&
vxupsr
,
vxdnsr
)
xedl
=
exlsd
cedl
=
eclsd
xedg
=
expbe
-
exlsd
cedg
=
ecpbe
-
eclsd
ENDIF
! ro > smlc
ENDIF
! ro > smlc
xced
=
(
xedl
+
cedl
+
xedg
+
cedg
)
xced
=
(
xedl
+
cedl
+
xedg
+
cedg
)
exc
(
i
)
=
xced
*
2
! in ry
exc
(
i
)
=
xced
*
2
! in ry
ENDDO
ENDDO
! OMP end parallel do
END
SUBROUTINE
excepbe
END
MODULE
m_excepbe
END
SUBROUTINE
excepbe
END
MODULE
m_excepbe
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment