public double norm(){
  if (m_Elements != null) {
    int n=m_Elements.length;
    double sum=0.0;
    for (int i=0; i < n; i++) {
      sum+=m_Elements[i] * m_Elements[i];
    }
    return Math.pow(sum,0.5);
  }
 else   return 0.0;
}

public double norm ( ) { if ( m_Elements != null ) { int n = m_Elements . length ; double sum = 0.0 ; for ( int i = 0 ; i < n ; i ++ ) { sum += m_Elements [ i ] * m_Elements [ i ] ; } return Math . pow ( sum , 0.5 ) ; } else return 0.0 ; }
returns the norm of the vector
