*/
void scale (const Number factor);
+ /**
+ * Scale each element of the
+ * vector by a constant
+ * value. This operator is an
+ * alias to the @ref{scale}
+ * function, except that it
+ * returns a reference to itself.
+ */
+ BlockVector<Number> & operator *= (const Number factor);
+
/**
* U=a*V. Replacing.
*/
+template <typename Number>
+inline
+BlockVector<Number> & BlockVector<Number>::operator *= (const Number factor)
+{
+ scale (factor);
+ return *this;
+};
+
+
+
template <typename Number>
inline
Vector<Number> &
* Scale each element of the
* vector by the given factor.
*/
-//TODO:[?] Why not have an operator *= instead of/in addition to `scale'?
void scale (const Number factor);
+ /**
+ * Scale each element of the
+ * vector by a constant
+ * value. This operator is an
+ * alias to the @ref{scale}
+ * function, except that it
+ * returns a reference to itself.
+ */
+ Vector<Number> & operator *= (const Number factor);
+
/**
* Scale each element of this
* vector by the corresponding
}
+
template <typename Number>
inline
Vector<Number>::~Vector ()
}
+
template <typename Number>
inline
void Vector<Number>::reinit (const unsigned int n, const bool fast)
}
+
template <typename Number>
inline
void Vector<Number>::clear ()
}
+
template <typename Number>
inline
unsigned int Vector<Number>::size () const
}
+
template <typename Number>
inline
typename Vector<Number>::iterator
};
+
template <typename Number>
inline
typename Vector<Number>::const_iterator
};
+
template <typename Number>
inline
typename Vector<Number>::iterator
};
+
template <typename Number>
inline
typename Vector<Number>::const_iterator
};
+
template <typename Number>
inline
Number Vector<Number>::operator() (const unsigned int i) const
}
+
template <typename Number>
inline
Number& Vector<Number>::operator() (const unsigned int i)
+template <typename Number>
+inline
+Vector<Number> & Vector<Number>::operator *= (const Number factor)
+{
+ scale (factor);
+ return *this;
+};
+
+
+
/**
* Global function @p{swap} which overloads the default implementation
* of the C++ standard library which uses a temporary object. The