Commit 4baff0f1 authored by Matthias Redies's avatar Matthias Redies

use handwritten outerproduct -> better preformance

parent 5ffa07cf
......@@ -58,14 +58,14 @@ CONTAINS
function outer_prod(x,y) result(outer)
implicit NONE
complex, intent(in) :: x(:), y(:)
complex, allocatable :: x_mat(:,:), y_mat(:,:), outer(:,:)
allocate(x_mat(size(x), 1) )
allocate(y_mat(1, size(y)) )
x_mat(:,1) =x
y_mat(1,:) = y
outer = matmul(x_mat,y_mat)
complex :: outer(size(x),size(y))
integer :: i,j
do j = 1,size(y)
do i = 1,size(x)
outer(i,j) = x(i) * y(j)
end function outer_prod
end module m_wavefproducts_aux
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