|
||||
File indexing completed on 2025-01-18 09:43:02
0001 /** 0002 * -*- c++ -*- 0003 * 0004 * \file num_rows.hpp 0005 * 0006 * \brief The \c num_rows operation. 0007 * 0008 * Copyright (c) 2009-2012, Marco Guazzone 0009 * 0010 * Distributed under the Boost Software License, Version 1.0. (See 0011 * accompanying file LICENSE_1_0.txt or copy at 0012 * http://www.boost.org/LICENSE_1_0.txt) 0013 * 0014 * \author Marco Guazzone, marco.guazzone@gmail.com 0015 */ 0016 0017 #ifndef BOOST_NUMERIC_UBLAS_OPERATION_NUM_ROWS_HPP 0018 #define BOOST_NUMERIC_UBLAS_OPERATION_NUM_ROWS_HPP 0019 0020 0021 #include <boost/numeric/ublas/detail/config.hpp> 0022 #include <boost/numeric/ublas/expression_types.hpp> 0023 #include <boost/numeric/ublas/traits.hpp> 0024 0025 0026 namespace boost { namespace numeric { namespace ublas { 0027 0028 /** 0029 * \brief Return the number of rows. 0030 * \tparam MatrixExprT A type which models the matrix expression concept. 0031 * \param m A matrix expression. 0032 * \return The number of rows. 0033 */ 0034 template <typename MatrixExprT> 0035 BOOST_UBLAS_INLINE 0036 typename matrix_traits<MatrixExprT>::size_type num_rows(matrix_expression<MatrixExprT> const& me) 0037 { 0038 return me().size1(); 0039 } 0040 0041 }}} // Namespace boost::numeric::ublas 0042 0043 0044 #endif // BOOST_NUMERIC_UBLAS_OPERATION_NUM_ROWS_HPP
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |