! Called for kodNorm >=0:
! kodNorm =0: infinity-norm
!         =1: 1-norm
!		  =2: Euclidian norm
!
subroutine Normalize(n, x, kodNorm)

real(8) x(n,n)
real(8) y(n), vNorm, yNorm

! Normalize:
DO i =1,n
y =x(:,i)

! Skip if y ==0:
IF(maxval(dabs(y)) /=0) THEN

yNorm =vNorm(n, y, kodNorm)

y =y/yNorm
x(:, i) =y
ENDIF

ENDDO

END subroutine Normalize
