The Elk Code
Loading...
Searching...
No Matches
r3cross.f90
Go to the documentation of this file.
1
2
! Copyright (C) 2002-2005 J. K. Dewhurst, S. Sharma and C. Ambrosch-Draxl.
3
! This file is distributed under the terms of the GNU Lesser General Public
4
! License. See the file COPYING for license details.
5
6
!BOP
7
! !ROUTINE: r3cross
8
! !INTERFACE:
9
pure
subroutine
r3cross
(x,y,z)
10
! !INPUT/OUTPUT PARAMETERS:
11
! x : input vector 1 (in,real(3))
12
! y : input vector 2 (in,real(3))
13
! z : output cross-product (out,real(3))
14
! !DESCRIPTION:
15
! Returns the cross product of two real 3-vectors.
16
!
17
! !REVISION HISTORY:
18
! Created September 2002 (JKD)
19
!EOP
20
!BOC
21
implicit none
22
! arguments
23
real
(8),
intent(in)
:: x(3),y(3)
24
real
(8),
intent(out)
:: z(3)
25
z(1)=x(2)*y(3)-x(3)*y(2)
26
z(2)=x(3)*y(1)-x(1)*y(3)
27
z(3)=x(1)*y(2)-x(2)*y(1)
28
end subroutine
29
!EOC
30
r3cross
pure subroutine r3cross(x, y, z)
Definition
r3cross.f90:10
r3cross.f90
Generated by
1.9.8