Real(8) function Norm(n, x)
implicit real(8) (a-h, o-z)
real(8) x(n)

!norm =0D0

!do i =1,n
!norm =max( norm, dabs(x(i)) )
!enddo
norm =maxval(dabs(x))
end


