<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>The MRPT project: XprHelper.h Source File</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> <link href="tabs.css" rel="stylesheet" type="text/css"> </head><body> <div align="left"><a href="http://www.mrpt.org/">Main MRPT website</a> > <b>C++ reference</b> </div> <div align="right"> <a href="index.html"><img border="0" src="mrpt_logo.png" alt="MRPT logo"></a> </div> <!-- Generated by Doxygen 1.7.2 --> <script type="text/javascript"><!-- var searchBox = new SearchBox("searchBox", "search",false,'Search'); --></script> <div class="navigation" id="top"> <div class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> <li id="searchli"> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <form id="FSearchBox" action="search.php" method="get"> <img id="MSearchSelect" src="search/mag.png" alt=""/> <input type="text" id="MSearchField" name="query" value="Search" size="20" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)"/> </form> </span><span class="right"></span> </div> </li> </ul> </div> <div class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> <div class="header"> <div class="headertitle"> <h1>XprHelper.h</h1> </div> </div> <div class="contents"> <a href="_xpr_helper_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">// This file is part of Eigen, a lightweight C++ template library</span> <a name="l00002"></a>00002 <span class="comment">// for linear algebra.</span> <a name="l00003"></a>00003 <span class="comment">//</span> <a name="l00004"></a>00004 <span class="comment">// Copyright (C) 2008 Gael Guennebaud <gael.guennebaud@inria.fr></span> <a name="l00005"></a>00005 <span class="comment">// Copyright (C) 2006-2008 Benoit Jacob <jacob.benoit.1@gmail.com></span> <a name="l00006"></a>00006 <span class="comment">//</span> <a name="l00007"></a>00007 <span class="comment">// Eigen is free software; you can redistribute it and/or</span> <a name="l00008"></a>00008 <span class="comment">// modify it under the terms of the GNU Lesser General Public</span> <a name="l00009"></a>00009 <span class="comment">// License as published by the Free Software Foundation; either</span> <a name="l00010"></a>00010 <span class="comment">// version 3 of the License, or (at your option) any later version.</span> <a name="l00011"></a>00011 <span class="comment">//</span> <a name="l00012"></a>00012 <span class="comment">// Alternatively, you can redistribute it and/or</span> <a name="l00013"></a>00013 <span class="comment">// modify it under the terms of the GNU General Public License as</span> <a name="l00014"></a>00014 <span class="comment">// published by the Free Software Foundation; either version 2 of</span> <a name="l00015"></a>00015 <span class="comment">// the License, or (at your option) any later version.</span> <a name="l00016"></a>00016 <span class="comment">//</span> <a name="l00017"></a>00017 <span class="comment">// Eigen is distributed in the hope that it will be useful, but WITHOUT ANY</span> <a name="l00018"></a>00018 <span class="comment">// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS</span> <a name="l00019"></a>00019 <span class="comment">// FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License or the</span> <a name="l00020"></a>00020 <span class="comment">// GNU General Public License for more details.</span> <a name="l00021"></a>00021 <span class="comment">//</span> <a name="l00022"></a>00022 <span class="comment">// You should have received a copy of the GNU Lesser General Public</span> <a name="l00023"></a>00023 <span class="comment">// License and a copy of the GNU General Public License along with</span> <a name="l00024"></a>00024 <span class="comment">// Eigen. If not, see <http://www.gnu.org/licenses/>.</span> <a name="l00025"></a>00025 <a name="l00026"></a>00026 <span class="preprocessor">#ifndef EIGEN_XPRHELPER_H</span> <a name="l00027"></a>00027 <span class="preprocessor"></span><span class="preprocessor">#define EIGEN_XPRHELPER_H</span> <a name="l00028"></a>00028 <span class="preprocessor"></span> <a name="l00029"></a>00029 <span class="comment">// just a workaround because GCC seems to not really like empty structs</span> <a name="l00030"></a>00030 <span class="comment">// FIXME: gcc 4.3 generates bad code when strict-aliasing is enabled</span> <a name="l00031"></a>00031 <span class="comment">// so currently we simply disable this optimization for gcc 4.3</span> <a name="l00032"></a>00032 <span class="preprocessor">#if (defined __GNUG__) && !((__GNUC__==4) && (__GNUC_MINOR__==3))</span> <a name="l00033"></a>00033 <span class="preprocessor"></span><span class="preprocessor"> #define EIGEN_EMPTY_STRUCT_CTOR(X) \</span> <a name="l00034"></a>00034 <span class="preprocessor"> EIGEN_STRONG_INLINE X() {} \</span> <a name="l00035"></a>00035 <span class="preprocessor"> EIGEN_STRONG_INLINE X(const X& ) {}</span> <a name="l00036"></a>00036 <span class="preprocessor"></span><span class="preprocessor">#else</span> <a name="l00037"></a><a class="code" href="_xpr_helper_8h.html#a4363bfa78f2780a0714888ec373b2673">00037</a> <span class="preprocessor"></span><span class="preprocessor"> #define EIGEN_EMPTY_STRUCT_CTOR(X)</span> <a name="l00038"></a>00038 <span class="preprocessor"></span><span class="preprocessor">#endif</span> <a name="l00039"></a>00039 <span class="preprocessor"></span> <a name="l00040"></a><a class="code" href="_xpr_helper_8h.html#a0cd03d34614dcb302c968e4fe1391ca3">00040</a> <span class="keyword">typedef</span> <a class="code" href="_macros_8h.html#a23fafe2bd4e27ecadab4deb95691bcf4">EIGEN_DEFAULT_DENSE_INDEX_TYPE</a> <a class="code" href="_xpr_helper_8h.html#a0cd03d34614dcb302c968e4fe1391ca3">DenseIndex</a>; <a name="l00041"></a>00041 <a name="l00042"></a>00042 <span class="keyword">namespace </span>internal { <a name="l00043"></a>00043 <a name="l00044"></a>00044 <span class="comment">//classes inheriting no_assignment_operator don't generate a default operator=.</span> <a name="l00045"></a><a class="code" href="classinternal_1_1no__assignment__operator.html">00045</a> <span class="keyword">class </span><a class="code" href="classinternal_1_1no__assignment__operator.html">no_assignment_operator</a> <a name="l00046"></a>00046 { <a name="l00047"></a>00047 <span class="keyword">private</span>: <a name="l00048"></a>00048 <a class="code" href="classinternal_1_1no__assignment__operator.html">no_assignment_operator</a>& <a class="code" href="classinternal_1_1no__assignment__operator.html#a3cada1f8660391bd20a99e4e1805916d">operator=</a>(<span class="keyword">const</span> <a class="code" href="classinternal_1_1no__assignment__operator.html">no_assignment_operator</a>&); <a name="l00049"></a>00049 }; <a name="l00050"></a>00050 <span class="comment"></span> <a name="l00051"></a>00051 <span class="comment">/** \internal return the index type with the largest number of bits */</span> <a name="l00052"></a>00052 <span class="keyword">template</span><<span class="keyword">typename</span> I1, <span class="keyword">typename</span> I2> <a name="l00053"></a><a class="code" href="structinternal_1_1promote__index__type.html">00053</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1promote__index__type.html">promote_index_type</a> <a name="l00054"></a>00054 { <a name="l00055"></a>00055 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional<(sizeof(I1)<sizeof(I2)), I2, I1>::type</a> <a class="code" href="classinternal_1_1dense__xpr__base_1_1type.html">type</a>; <a name="l00056"></a>00056 }; <a name="l00057"></a>00057 <span class="comment"></span> <a name="l00058"></a>00058 <span class="comment">/** \internal If the template parameter Value is Dynamic, this class is just a wrapper around a T variable that</span> <a name="l00059"></a>00059 <span class="comment"> * can be accessed using value() and setValue().</span> <a name="l00060"></a>00060 <span class="comment"> * Otherwise, this class is an empty structure and value() just returns the template parameter Value.</span> <a name="l00061"></a>00061 <span class="comment"> */</span> <a name="l00062"></a><a class="code" href="classinternal_1_1variable__if__dynamic.html">00062</a> <span class="keyword">template</span><<span class="keyword">typename</span> T, <span class="keywordtype">int</span> Value> <span class="keyword">class </span><a class="code" href="classinternal_1_1variable__if__dynamic.html">variable_if_dynamic</a> <a name="l00063"></a>00063 { <a name="l00064"></a>00064 <span class="keyword">public</span>: <a name="l00065"></a>00065 <a class="code" href="_xpr_helper_8h.html#a4363bfa78f2780a0714888ec373b2673">EIGEN_EMPTY_STRUCT_CTOR</a>(<a class="code" href="classinternal_1_1variable__if__dynamic.html">variable_if_dynamic</a>) <a name="l00066"></a><a class="code" href="classinternal_1_1variable__if__dynamic.html#a36331ec92ffa454016ebea80fc24d573">00066</a> explicit <a class="code" href="classinternal_1_1variable__if__dynamic.html">variable_if_dynamic</a>(T v) { <a class="code" href="_macros_8h.html#aa92b5a5bd7b7cbc4754cea71c0866023">EIGEN_ONLY_USED_FOR_DEBUG</a>(v); assert(v == T(Value)); } <a name="l00067"></a><a class="code" href="classinternal_1_1variable__if__dynamic.html#ac044d1d4afbdd3de0fd8b3ed664b14ab">00067</a> <span class="keyword">static</span> T <a class="code" href="classinternal_1_1variable__if__dynamic.html#ac044d1d4afbdd3de0fd8b3ed664b14ab">value</a>() { <span class="keywordflow">return</span> T(Value); } <a name="l00068"></a><a class="code" href="classinternal_1_1variable__if__dynamic.html#ae4e92ce0bc1fef6b961c5a90c20cfdc3">00068</a> <span class="keywordtype">void</span> <a class="code" href="classinternal_1_1variable__if__dynamic.html#ae4e92ce0bc1fef6b961c5a90c20cfdc3">setValue</a>(T) {} <a name="l00069"></a>00069 }; <a name="l00070"></a>00070 <a name="l00071"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html">00071</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">class </span><a class="code" href="classinternal_1_1variable__if__dynamic.html">variable_if_dynamic</a><T, <a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a>> <a name="l00072"></a>00072 { <a name="l00073"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#afffbdeeb2889dd2863cbd506f5269dbf">00073</a> T <a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#afffbdeeb2889dd2863cbd506f5269dbf">m_value</a>; <a name="l00074"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#af5f3f55a5d56288b0a1c474c7270c1f5">00074</a> <a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#af5f3f55a5d56288b0a1c474c7270c1f5">variable_if_dynamic</a>() { assert(<span class="keyword">false</span>); } <a name="l00075"></a>00075 <span class="keyword">public</span>: <a name="l00076"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a16ff033d5c5b788fb8d20d5d52b9c43e">00076</a> <span class="keyword">explicit</span> <a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a16ff033d5c5b788fb8d20d5d52b9c43e">variable_if_dynamic</a>(T <a class="code" href="classinternal_1_1variable__if__dynamic.html#ac044d1d4afbdd3de0fd8b3ed664b14ab">value</a>) : m_value(value) {} <a name="l00077"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a181dbb66a9c47fdb43f4da0a17485140">00077</a> T <a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a181dbb66a9c47fdb43f4da0a17485140">value</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> m_value; } <a name="l00078"></a><a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a3c167f9dcaa6b1cd8c3cfce29e99d993">00078</a> <span class="keywordtype">void</span> <a class="code" href="classinternal_1_1variable__if__dynamic_3_01_t_00_01_dynamic_01_4.html#a3c167f9dcaa6b1cd8c3cfce29e99d993">setValue</a>(T <a class="code" href="classinternal_1_1variable__if__dynamic.html#ac044d1d4afbdd3de0fd8b3ed664b14ab">value</a>) { m_value = <a class="code" href="classinternal_1_1variable__if__dynamic.html#ac044d1d4afbdd3de0fd8b3ed664b14ab">value</a>; } <a name="l00079"></a>00079 }; <a name="l00080"></a>00080 <a name="l00081"></a><a class="code" href="structinternal_1_1functor__traits.html">00081</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span><a class="code" href="structinternal_1_1functor__traits.html">functor_traits</a> <a name="l00082"></a>00082 { <a name="l00083"></a>00083 <span class="keyword">enum</span> <a name="l00084"></a>00084 { <a name="l00085"></a><a class="code" href="structinternal_1_1functor__traits.html#a0b28c8af1dab94bc656446e55a8901c5aa111d208cb73a3e1559f8263c099c9e7">00085</a> <a class="code" href="structinternal_1_1functor__traits.html#a0b28c8af1dab94bc656446e55a8901c5aa111d208cb73a3e1559f8263c099c9e7">Cost</a> = 10, <a name="l00086"></a><a class="code" href="structinternal_1_1functor__traits.html#a0b28c8af1dab94bc656446e55a8901c5a9d4c2b71f4a4a26a1337bea90fa8ccdf">00086</a> <a class="code" href="structinternal_1_1functor__traits.html#a0b28c8af1dab94bc656446e55a8901c5a9d4c2b71f4a4a26a1337bea90fa8ccdf">PacketAccess</a> = <span class="keyword">false</span> <a name="l00087"></a>00087 }; <a name="l00088"></a>00088 }; <a name="l00089"></a>00089 <a name="l00090"></a>00090 <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span>packet_traits; <a name="l00091"></a>00091 <a name="l00092"></a><a class="code" href="structinternal_1_1unpacket__traits.html">00092</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span><a class="code" href="structinternal_1_1unpacket__traits.html">unpacket_traits</a> <a name="l00093"></a>00093 { <a name="l00094"></a><a class="code" href="structinternal_1_1unpacket__traits.html#a2a5662d52e9049fca5e2c4784a196c15">00094</a> <span class="keyword">typedef</span> T <a class="code" href="structinternal_1_1unpacket__traits.html#a2a5662d52e9049fca5e2c4784a196c15">type</a>; <a name="l00095"></a><a class="code" href="structinternal_1_1unpacket__traits.html#a6252d14bb46621ea236b1671b1c1c05ea30b3429df150faf7de9763535adf4321">00095</a> <span class="keyword">enum</span> {<a class="code" href="structinternal_1_1unpacket__traits.html#a6252d14bb46621ea236b1671b1c1c05ea30b3429df150faf7de9763535adf4321">size</a>=1}; <a name="l00096"></a>00096 }; <a name="l00097"></a>00097 <a name="l00098"></a>00098 <span class="keyword">template</span><<span class="keyword">typename</span> _Scalar, <span class="keywordtype">int</span> _Rows, <span class="keywordtype">int</span> _Cols, <a name="l00099"></a>00099 <span class="keywordtype">int</span> _Options = <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa02a97bb4792f98916a1156a521fa9813">AutoAlign</a> | <a name="l00100"></a>00100 ( (_Rows==1 && _Cols!=1) ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> <a name="l00101"></a>00101 : (_Cols==1 && _Rows!=1) ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a> <a name="l00102"></a>00102 : <a class="code" href="_macros_8h.html#aaf936bcdb51d724163230369fdcb3447">EIGEN_DEFAULT_MATRIX_STORAGE_ORDER_OPTION</a> ), <a name="l00103"></a>00103 <span class="keywordtype">int</span> _MaxRows = _Rows, <a name="l00104"></a>00104 <span class="keywordtype">int</span> _MaxCols = _Cols <a name="l00105"></a><a class="code" href="classinternal_1_1make__proper__matrix__type.html">00105</a> > <span class="keyword">class</span> <a class="code" href="classinternal_1_1make__proper__matrix__type.html">make_proper_matrix_type</a> <a name="l00106"></a>00106 { <a name="l00107"></a>00107 <span class="keyword">enum</span> { <a name="l00108"></a><a class="code" href="classinternal_1_1make__proper__matrix__type.html#ae42b3bf5fde1e12cc125051b7681dfbaa9f084a04c7f1e7bf961096727b467bfb">00108</a> IsColVector = _Cols==1 && _Rows!=1, <a name="l00109"></a><a class="code" href="classinternal_1_1make__proper__matrix__type.html#ae42b3bf5fde1e12cc125051b7681dfbaaf0eead95d342619dccd73757b6d70c8c">00109</a> IsRowVector = _Rows==1 && _Cols!=1, <a name="l00110"></a><a class="code" href="classinternal_1_1make__proper__matrix__type.html#ae42b3bf5fde1e12cc125051b7681dfbaad2b4a2470792ee9e7a6e52cf665915af">00110</a> Options = IsColVector ? (_Options | <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a>) & ~<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> <a name="l00111"></a>00111 : IsRowVector ? (_Options | <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a>) & ~<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a> <a name="l00112"></a>00112 : _Options <a name="l00113"></a>00113 }; <a name="l00114"></a>00114 <span class="keyword">public</span>: <a name="l00115"></a><a class="code" href="classinternal_1_1make__proper__matrix__type.html#a35d3480b651a4794b0a2bc93631d1341">00115</a> <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<_Scalar, _Rows, _Cols, Options, _MaxRows, _MaxCols></a> <a class="code" href="classinternal_1_1make__proper__matrix__type.html#a35d3480b651a4794b0a2bc93631d1341">type</a>; <a name="l00116"></a>00116 }; <a name="l00117"></a>00117 <a name="l00118"></a>00118 <span class="keyword">template</span><<span class="keyword">typename</span> Scalar, <span class="keywordtype">int</span> Rows, <span class="keywordtype">int</span> Cols, <span class="keywordtype">int</span> Options, <span class="keywordtype">int</span> MaxRows, <span class="keywordtype">int</span> MaxCols> <a name="l00119"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html">00119</a> <span class="keyword">class </span><a class="code" href="classinternal_1_1compute__matrix__flags.html">compute_matrix_flags</a> <a name="l00120"></a>00120 { <a name="l00121"></a>00121 <span class="keyword">enum</span> { <a name="l00122"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html#a5bd61ea3684439f9c6bba002504b575da26b9a3d429d308a000456cde949b0ba0">00122</a> row_major_bit = Options&<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> ? <a class="code" href="group__flags.html#ga7bd49e7b260e869e10fb9dc4fd081a85" title="for a matrix, this means that the storage order is row-major.">RowMajorBit</a> : 0, <a name="l00123"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html#a5bd61ea3684439f9c6bba002504b575dabe62b3bd311aa73840f0387f91629b4c">00123</a> is_dynamic_size_storage = MaxRows==<a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> || MaxCols==<a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a>, <a name="l00124"></a>00124 <a name="l00125"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html#a5bd61ea3684439f9c6bba002504b575dac2b8aa9dab2c08a3f2f533b82ce615c8">00125</a> aligned_bit = <a name="l00126"></a>00126 ( <a name="l00127"></a>00127 ((Options&<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa761c0504a518c7450ed6dfe9eaeab8a6">DontAlign</a>)==0) <a name="l00128"></a>00128 && <a class="code" href="structinternal_1_1packet__traits.html">packet_traits<Scalar>::Vectorizable</a> <a name="l00129"></a>00129 && ( <a name="l00130"></a>00130 <span class="preprocessor">#if EIGEN_ALIGN_STATICALLY</span> <a name="l00131"></a>00131 <span class="preprocessor"></span> ((!is_dynamic_size_storage) && (((MaxCols*MaxRows) % <a class="code" href="structinternal_1_1packet__traits.html">packet_traits<Scalar>::size</a>) == 0)) <a name="l00132"></a>00132 #<span class="keywordflow">else</span> <a name="l00133"></a>00133 0 <a name="l00134"></a>00134 #endif <a name="l00135"></a>00135 <a name="l00136"></a>00136 || <a name="l00137"></a>00137 <a name="l00138"></a>00138 #<span class="keywordflow">if</span> <a class="code" href="_macros_8h.html#a767b896bda5f5eb62fe15a32c9ca27ec">EIGEN_ALIGN</a> <a name="l00139"></a>00139 is_dynamic_size_storage <a name="l00140"></a>00140 #<span class="keywordflow">else</span> <a name="l00141"></a>00141 0 <a name="l00142"></a>00142 #endif <a name="l00143"></a>00143 <a name="l00144"></a>00144 ) <a name="l00145"></a>00145 ) ? <a class="code" href="group__flags.html#ga972a2dcb6603215fa53e0b9e82051426" title="means the first coefficient packet is guaranteed to be aligned">AlignedBit</a> : 0, <a name="l00146"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html#a5bd61ea3684439f9c6bba002504b575dac095f5228eb630b61493ea146b7ce8b5">00146</a> packet_access_bit = <a class="code" href="structinternal_1_1packet__traits.html">packet_traits<Scalar>::Vectorizable</a> && aligned_bit ? <a class="code" href="group__flags.html#gaa780614dc11271c147db56e9c1524e76" title="Short version: means the expression might be vectorized.">PacketAccessBit</a> : 0 <a name="l00147"></a>00147 }; <a name="l00148"></a>00148 <a name="l00149"></a>00149 <span class="keyword">public</span>: <a name="l00150"></a><a class="code" href="classinternal_1_1compute__matrix__flags.html#a6ddef6c4b00a66dad4834a8c216daba3a8886b52ef8dad293b4716921609ed358">00150</a> <span class="keyword">enum</span> { ret = <a class="code" href="group__flags.html#gab9799bf6feed77fc9fce0136ee55b99c" title="Short version: means the expression can be seen as 1D vector.">LinearAccessBit</a> | <a class="code" href="group__flags.html#ga64e21b7543bdedce27f013512a4403a3" title="Means the expression has a coeffRef() method, i.e.">LvalueBit</a> | <a class="code" href="group__flags.html#ga54c3b872f5a14e7e0d3d6539b704ea67" title="Means that the underlying array of coefficients can be directly accessed as a plain strided array...">DirectAccessBit</a> | <a class="code" href="_constants_8h.html#ade73e088e9921d459e89667b7c96cadb">NestByRefBit</a> | packet_access_bit | row_major_bit | aligned_bit }; <a name="l00151"></a>00151 }; <a name="l00152"></a>00152 <a name="l00153"></a><a class="code" href="structinternal_1_1size__at__compile__time.html">00153</a> <span class="keyword">template</span><<span class="keywordtype">int</span> _Rows, <span class="keywordtype">int</span> _Cols> <span class="keyword">struct </span><a class="code" href="structinternal_1_1size__at__compile__time.html">size_at_compile_time</a> <a name="l00154"></a>00154 { <a name="l00155"></a><a class="code" href="structinternal_1_1size__at__compile__time.html#ad0bf5f17c9ada68f3a76a3fcb46a5818a0e878465c726089478a5b2174ee04528">00155</a> <span class="keyword">enum</span> { ret = (_Rows==<a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> || _Cols==<a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a>) ? <a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> : _Rows * _Cols }; <a name="l00156"></a>00156 }; <a name="l00157"></a>00157 <a name="l00158"></a>00158 <span class="comment">/* plain_matrix_type : the difference from eval is that plain_matrix_type is always a plain matrix type,</span> <a name="l00159"></a>00159 <span class="comment"> * whereas eval is a const reference in the case of a matrix</span> <a name="l00160"></a>00160 <span class="comment"> */</span> <a name="l00161"></a>00161 <a name="l00162"></a>00162 template<typename T, typename StorageKind = typename traits<T>::StorageKind> <span class="keyword">struct </span>plain_matrix_type; <a name="l00163"></a>00163 <span class="keyword">template</span><<span class="keyword">typename</span> T, <span class="keyword">typename</span> BaseClassType> <span class="keyword">struct </span>plain_matrix_type_dense; <a name="l00164"></a><a class="code" href="structinternal_1_1plain__matrix__type_3_01_t_00_01_dense_01_4.html">00164</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span>plain_matrix_type<T,<a class="code" href="struct_dense.html" title="The type used to identify a dense storage.">Dense</a>> <a name="l00165"></a>00165 { <a name="l00166"></a><a class="code" href="structinternal_1_1plain__matrix__type_3_01_t_00_01_dense_01_4.html#ab806b45b5e33fadb5cf2e52dfa0052af">00166</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> plain_matrix_type_dense<T,typename traits<T>::XprKind><a class="code" href="structinternal_1_1plain__matrix__type_3_01_t_00_01_dense_01_4.html#ab806b45b5e33fadb5cf2e52dfa0052af">::type</a> <a class="code" href="structinternal_1_1plain__matrix__type_3_01_t_00_01_dense_01_4.html#ab806b45b5e33fadb5cf2e52dfa0052af">type</a>; <a name="l00167"></a>00167 }; <a name="l00168"></a>00168 <a name="l00169"></a><a class="code" href="structinternal_1_1plain__matrix__type__dense_3_01_t_00_01_matrix_xpr_01_4.html">00169</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span>plain_matrix_type_dense<T,<a class="code" href="struct_matrix_xpr.html" title="The type used to identify a matrix expression.">MatrixXpr</a>> <a name="l00170"></a>00170 { <a name="l00171"></a>00171 <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<typename traits<T>::Scalar</a>, <a name="l00172"></a>00172 traits<T>::RowsAtCompileTime, <a name="l00173"></a>00173 traits<T>::ColsAtCompileTime, <a name="l00174"></a>00174 <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa02a97bb4792f98916a1156a521fa9813">AutoAlign</a> | (traits<T>::Flags&<a class="code" href="group__flags.html#ga7bd49e7b260e869e10fb9dc4fd081a85" title="for a matrix, this means that the storage order is row-major.">RowMajorBit</a> ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> : <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a>), <a name="l00175"></a>00175 traits<T>::MaxRowsAtCompileTime, <a name="l00176"></a>00176 traits<T>::MaxColsAtCompileTime <a name="l00177"></a><a class="code" href="structinternal_1_1plain__matrix__type__dense_3_01_t_00_01_matrix_xpr_01_4.html#a9650c298654de44eb28c60929a53333d">00177</a> > <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">type</a>; <a name="l00178"></a>00178 }; <a name="l00179"></a>00179 <a name="l00180"></a><a class="code" href="structinternal_1_1plain__matrix__type__dense_3_01_t_00_01_array_xpr_01_4.html">00180</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span>plain_matrix_type_dense<T,<a class="code" href="struct_array_xpr.html" title="The type used to identify an array expression.">ArrayXpr</a>> <a name="l00181"></a>00181 { <a name="l00182"></a>00182 <span class="keyword">typedef</span> <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array<typename traits<T>::Scalar</a>, <a name="l00183"></a>00183 traits<T>::RowsAtCompileTime, <a name="l00184"></a>00184 traits<T>::ColsAtCompileTime, <a name="l00185"></a>00185 <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa02a97bb4792f98916a1156a521fa9813">AutoAlign</a> | (traits<T>::Flags&<a class="code" href="group__flags.html#ga7bd49e7b260e869e10fb9dc4fd081a85" title="for a matrix, this means that the storage order is row-major.">RowMajorBit</a> ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> : <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a>), <a name="l00186"></a>00186 traits<T>::MaxRowsAtCompileTime, <a name="l00187"></a>00187 traits<T>::MaxColsAtCompileTime <a name="l00188"></a><a class="code" href="structinternal_1_1plain__matrix__type__dense_3_01_t_00_01_array_xpr_01_4.html#af91f663300f9a9005bd81d2ca49cf339">00188</a> > <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">type</a>; <a name="l00189"></a>00189 }; <a name="l00190"></a>00190 <a name="l00191"></a>00191 <span class="comment">/* eval : the return type of eval(). For matrices, this is just a const reference</span> <a name="l00192"></a>00192 <span class="comment"> * in order to avoid a useless copy</span> <a name="l00193"></a>00193 <span class="comment"> */</span> <a name="l00194"></a>00194 <a name="l00195"></a>00195 template<typename T, typename StorageKind = typename traits<T>::StorageKind> <span class="keyword">struct </span>eval; <a name="l00196"></a>00196 <a name="l00197"></a><a class="code" href="structinternal_1_1eval_3_01_t_00_01_dense_01_4.html">00197</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span>eval<T,<a class="code" href="struct_dense.html" title="The type used to identify a dense storage.">Dense</a>> <a name="l00198"></a>00198 { <a name="l00199"></a><a class="code" href="structinternal_1_1eval_3_01_t_00_01_dense_01_4.html#aee7ecd23e714488000a60eb76a00e20e">00199</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> plain_matrix_type<T>::type <a class="code" href="structinternal_1_1eval_3_01_t_00_01_dense_01_4.html#aee7ecd23e714488000a60eb76a00e20e">type</a>; <a name="l00200"></a>00200 <span class="comment">// typedef typename T::PlainObject type;</span> <a name="l00201"></a>00201 <span class="comment">// typedef T::Matrix<typename traits<T>::Scalar,</span> <a name="l00202"></a>00202 <span class="comment">// traits<T>::RowsAtCompileTime,</span> <a name="l00203"></a>00203 <span class="comment">// traits<T>::ColsAtCompileTime,</span> <a name="l00204"></a>00204 <span class="comment">// AutoAlign | (traits<T>::Flags&RowMajorBit ? RowMajor : ColMajor),</span> <a name="l00205"></a>00205 <span class="comment">// traits<T>::MaxRowsAtCompileTime,</span> <a name="l00206"></a>00206 <span class="comment">// traits<T>::MaxColsAtCompileTime</span> <a name="l00207"></a>00207 <span class="comment">// > type;</span> <a name="l00208"></a>00208 }; <a name="l00209"></a>00209 <a name="l00210"></a>00210 <span class="comment">// for matrices, no need to evaluate, just use a const reference to avoid a useless copy</span> <a name="l00211"></a>00211 <span class="keyword">template</span><<span class="keyword">typename</span> _Scalar, <span class="keywordtype">int</span> _Rows, <span class="keywordtype">int</span> _Cols, <span class="keywordtype">int</span> _Options, <span class="keywordtype">int</span> _MaxRows, <span class="keywordtype">int</span> _MaxCols> <a name="l00212"></a><a class="code" href="structinternal_1_1eval_3_01_matrix_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01a3fa727c7557392b2ea1e9c1139c7571.html">00212</a> <span class="keyword">struct </span>eval<<a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix</a><_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>, <a class="code" href="struct_dense.html" title="The type used to identify a dense storage.">Dense</a>> <a name="l00213"></a>00213 { <a name="l00214"></a><a class="code" href="structinternal_1_1eval_3_01_matrix_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01a3fa727c7557392b2ea1e9c1139c7571.html#a192fc767b39487bd7b331fda21550941">00214</a> <span class="keyword">typedef</span> <span class="keyword">const</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols></a>& <a class="code" href="structinternal_1_1eval_3_01_matrix_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01a3fa727c7557392b2ea1e9c1139c7571.html#a192fc767b39487bd7b331fda21550941">type</a>; <a name="l00215"></a>00215 }; <a name="l00216"></a>00216 <a name="l00217"></a>00217 <span class="keyword">template</span><<span class="keyword">typename</span> _Scalar, <span class="keywordtype">int</span> _Rows, <span class="keywordtype">int</span> _Cols, <span class="keywordtype">int</span> _Options, <span class="keywordtype">int</span> _MaxRows, <span class="keywordtype">int</span> _MaxCols> <a name="l00218"></a><a class="code" href="structinternal_1_1eval_3_01_array_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01_e8b529e922d236c3f6040ea323ab247e.html">00218</a> <span class="keyword">struct </span>eval<<a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array</a><_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols>, <a class="code" href="struct_dense.html" title="The type used to identify a dense storage.">Dense</a>> <a name="l00219"></a>00219 { <a name="l00220"></a><a class="code" href="structinternal_1_1eval_3_01_array_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01_e8b529e922d236c3f6040ea323ab247e.html#a6e89dcbc20681a5c69433ced04d4494b">00220</a> <span class="keyword">typedef</span> <span class="keyword">const</span> <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array<_Scalar, _Rows, _Cols, _Options, _MaxRows, _MaxCols></a>& <a class="code" href="structinternal_1_1eval_3_01_array_3_01___scalar_00_01___rows_00_01___cols_00_01___options_00_01_e8b529e922d236c3f6040ea323ab247e.html#a6e89dcbc20681a5c69433ced04d4494b">type</a>; <a name="l00221"></a>00221 }; <a name="l00222"></a>00222 <a name="l00223"></a>00223 <a name="l00224"></a>00224 <a name="l00225"></a>00225 <span class="comment">/* plain_matrix_type_column_major : same as plain_matrix_type but guaranteed to be column-major</span> <a name="l00226"></a>00226 <span class="comment"> */</span> <a name="l00227"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html">00227</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html">plain_matrix_type_column_major</a> <a name="l00228"></a>00228 { <a name="l00229"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a58f9d294fcf39c49d49fd876c6d38f65">00229</a> <span class="keyword">enum</span> { <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a58f9d294fcf39c49d49fd876c6d38f65">Rows</a> = traits<T>::RowsAtCompileTime, <a name="l00230"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a8b2a1e79f1c1b79c03d799b446656052">00230</a> <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a8b2a1e79f1c1b79c03d799b446656052">Cols</a> = traits<T>::ColsAtCompileTime, <a name="l00231"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72ae38abadd96060ad24dc6230f53ee28bb">00231</a> <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72ae38abadd96060ad24dc6230f53ee28bb">MaxRows</a> = traits<T>::MaxRowsAtCompileTime, <a name="l00232"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a87174097959a15149dbaf1b1c1fab5f4">00232</a> <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a87174097959a15149dbaf1b1c1fab5f4">MaxCols</a> = traits<T>::MaxColsAtCompileTime <a name="l00233"></a>00233 }; <a name="l00234"></a>00234 <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<typename traits<T>::Scalar</a>, <a name="l00235"></a>00235 <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a58f9d294fcf39c49d49fd876c6d38f65">Rows</a>, <a name="l00236"></a>00236 <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a8b2a1e79f1c1b79c03d799b446656052">Cols</a>, <a name="l00237"></a>00237 (<a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72ae38abadd96060ad24dc6230f53ee28bb">MaxRows</a>==1&&<a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a87174097959a15149dbaf1b1c1fab5f4">MaxCols</a>!=1) ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> : <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a>, <a name="l00238"></a>00238 <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72ae38abadd96060ad24dc6230f53ee28bb">MaxRows</a>, <a name="l00239"></a>00239 <a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a495cac70b024e77ca2ea9ac606494b72a87174097959a15149dbaf1b1c1fab5f4">MaxCols</a> <a name="l00240"></a><a class="code" href="structinternal_1_1plain__matrix__type__column__major.html#a5171c61e9fbc18a4bd46c47878824e7b">00240</a> > <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">type</a>; <a name="l00241"></a>00241 }; <a name="l00242"></a>00242 <a name="l00243"></a>00243 <span class="comment">/* plain_matrix_type_row_major : same as plain_matrix_type but guaranteed to be row-major</span> <a name="l00244"></a>00244 <span class="comment"> */</span> <a name="l00245"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html">00245</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html">plain_matrix_type_row_major</a> <a name="l00246"></a>00246 { <a name="l00247"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aabefbb39a2cd41852fc12f6a8a64a7578">00247</a> <span class="keyword">enum</span> { <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aabefbb39a2cd41852fc12f6a8a64a7578">Rows</a> = traits<T>::RowsAtCompileTime, <a name="l00248"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa31ce6165994f519d4b9c5fc2c68ed5df">00248</a> <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa31ce6165994f519d4b9c5fc2c68ed5df">Cols</a> = traits<T>::ColsAtCompileTime, <a name="l00249"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa3f1fe473f1b983e35b899c5316bc20a7">00249</a> <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa3f1fe473f1b983e35b899c5316bc20a7">MaxRows</a> = traits<T>::MaxRowsAtCompileTime, <a name="l00250"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aacedd447ff6befa7403d11418a682e4b6">00250</a> <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aacedd447ff6befa7403d11418a682e4b6">MaxCols</a> = traits<T>::MaxColsAtCompileTime <a name="l00251"></a>00251 }; <a name="l00252"></a>00252 <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<typename traits<T>::Scalar</a>, <a name="l00253"></a>00253 <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aabefbb39a2cd41852fc12f6a8a64a7578">Rows</a>, <a name="l00254"></a>00254 <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa31ce6165994f519d4b9c5fc2c68ed5df">Cols</a>, <a name="l00255"></a>00255 (<a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aacedd447ff6befa7403d11418a682e4b6">MaxCols</a>==1&&<a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa3f1fe473f1b983e35b899c5316bc20a7">MaxRows</a>!=1) ? <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a> : <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aac86184b0e3be936fbfd20249a057a0bf">ColMajor</a>, <a name="l00256"></a>00256 <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aa3f1fe473f1b983e35b899c5316bc20a7">MaxRows</a>, <a name="l00257"></a>00257 <a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#a7ecbe7b4c0e4a424e519151dffa12b5aacedd447ff6befa7403d11418a682e4b6">MaxCols</a> <a name="l00258"></a><a class="code" href="structinternal_1_1plain__matrix__type__row__major.html#aac86ad1e7258e410f294db094ab36ba3">00258</a> > <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">type</a>; <a name="l00259"></a>00259 }; <a name="l00260"></a>00260 <a name="l00261"></a>00261 <span class="comment">// we should be able to get rid of this one too</span> <a name="l00262"></a><a class="code" href="structinternal_1_1must__nest__by__value.html#aa996d05003f84fa8fdf671bfe1789507ab79d1333fa389387b3c6895a7e100f1d">00262</a> <span class="keyword">template</span><<span class="keyword">typename</span> T> <span class="keyword">struct </span><a class="code" href="structinternal_1_1must__nest__by__value.html">must_nest_by_value</a> { <span class="keyword">enum</span> { <a class="code" href="structinternal_1_1must__nest__by__value.html#aa996d05003f84fa8fdf671bfe1789507ab79d1333fa389387b3c6895a7e100f1d">ret</a> = <span class="keyword">false</span> }; }; <a name="l00263"></a>00263 <a name="l00264"></a>00264 <span class="keyword">template</span><<span class="keyword">class</span> T> <a name="l00265"></a><a class="code" href="structinternal_1_1is__reference.html">00265</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1is__reference.html">is_reference</a> <a name="l00266"></a>00266 { <a name="l00267"></a><a class="code" href="structinternal_1_1is__reference.html#a823805d9abfb681fbdce30d06a4c4254a7cc33b5f9862f079a7afee4a7a1e9407">00267</a> <span class="keyword">enum</span> { <a class="code" href="structinternal_1_1is__reference.html#a823805d9abfb681fbdce30d06a4c4254a7cc33b5f9862f079a7afee4a7a1e9407">ret</a> = <span class="keyword">false</span> }; <a name="l00268"></a>00268 }; <a name="l00269"></a>00269 <a name="l00270"></a>00270 <span class="keyword">template</span><<span class="keyword">class</span> T> <a name="l00271"></a><a class="code" href="structinternal_1_1is__reference_3_01_t_01_6_01_4.html">00271</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1is__reference.html">is_reference</a><T&> <a name="l00272"></a>00272 { <a name="l00273"></a><a class="code" href="structinternal_1_1is__reference_3_01_t_01_6_01_4.html#a331a55064fc8014e0d0d28d856e8591fae623123acf2c80e23327b59a5a0066cb">00273</a> <span class="keyword">enum</span> { ret = <span class="keyword">true</span> }; <a name="l00274"></a>00274 }; <a name="l00275"></a>00275 <span class="comment"></span> <a name="l00276"></a>00276 <span class="comment">/**</span> <a name="l00277"></a>00277 <span class="comment">* \internal The reference selector for template expressions. The idea is that we don't</span> <a name="l00278"></a>00278 <span class="comment">* need to use references for expressions since they are light weight proxy</span> <a name="l00279"></a>00279 <span class="comment">* objects which should generate no copying overhead.</span> <a name="l00280"></a>00280 <span class="comment">**/</span> <a name="l00281"></a>00281 <span class="keyword">template</span> <<span class="keyword">typename</span> T> <a name="l00282"></a><a class="code" href="structinternal_1_1ref__selector.html">00282</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1ref__selector.html">ref_selector</a> <a name="l00283"></a>00283 { <a name="l00284"></a>00284 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional</a>< <a name="l00285"></a>00285 bool(traits<T>::Flags & <a class="code" href="_constants_8h.html#ade73e088e9921d459e89667b7c96cadb">NestByRefBit</a>), <a name="l00286"></a>00286 T <span class="keyword">const</span>&, <a name="l00287"></a>00287 T <a name="l00288"></a><a class="code" href="structinternal_1_1ref__selector.html#ab8553edc80456706561ce7fed727309b">00288</a> ><a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">::type</a> <a class="code" href="structinternal_1_1ref__selector.html#ab8553edc80456706561ce7fed727309b">type</a>; <a name="l00289"></a>00289 }; <a name="l00290"></a>00290 <span class="comment"></span> <a name="l00291"></a>00291 <span class="comment">/** \internal Determines how a given expression should be nested into another one.</span> <a name="l00292"></a>00292 <span class="comment"> * For example, when you do a * (b+c), Eigen will determine how the expression b+c should be</span> <a name="l00293"></a>00293 <span class="comment"> * nested into the bigger product expression. The choice is between nesting the expression b+c as-is, or</span> <a name="l00294"></a>00294 <span class="comment"> * evaluating that expression b+c into a temporary variable d, and nest d so that the resulting expression is</span> <a name="l00295"></a>00295 <span class="comment"> * a*d. Evaluating can be beneficial for example if every coefficient access in the resulting expression causes</span> <a name="l00296"></a>00296 <span class="comment"> * many coefficient accesses in the nested expressions -- as is the case with matrix product for example.</span> <a name="l00297"></a>00297 <span class="comment"> *</span> <a name="l00298"></a>00298 <span class="comment"> * \param T the type of the expression being nested</span> <a name="l00299"></a>00299 <span class="comment"> * \param n the number of coefficient accesses in the nested expression for each coefficient access in the bigger expression.</span> <a name="l00300"></a>00300 <span class="comment"> *</span> <a name="l00301"></a>00301 <span class="comment"> * Example. Suppose that a, b, and c are of type Matrix3d. The user forms the expression a*(b+c).</span> <a name="l00302"></a>00302 <span class="comment"> * b+c is an expression "sum of matrices", which we will denote by S. In order to determine how to nest it,</span> <a name="l00303"></a>00303 <span class="comment"> * the Product expression uses: nested<S, 3>::ret, which turns out to be Matrix3d because the internal logic of</span> <a name="l00304"></a>00304 <span class="comment"> * nested determined that in this case it was better to evaluate the expression b+c into a temporary. On the other hand,</span> <a name="l00305"></a>00305 <span class="comment"> * since a is of type Matrix3d, the Product expression nests it as nested<Matrix3d, 3>::ret, which turns out to be</span> <a name="l00306"></a>00306 <span class="comment"> * const Matrix3d&, because the internal logic of nested determined that since a was already a matrix, there was no point</span> <a name="l00307"></a>00307 <span class="comment"> * in copying it into another matrix.</span> <a name="l00308"></a>00308 <span class="comment"> */</span> <a name="l00309"></a><a class="code" href="structinternal_1_1nested.html">00309</a> template<typename T, int n=1, typename PlainObject = typename eval<T>::type> <span class="keyword">struct </span><a class="code" href="structinternal_1_1nested.html">nested</a> <a name="l00310"></a>00310 { <a name="l00311"></a>00311 <span class="keyword">enum</span> { <a name="l00312"></a>00312 <span class="comment">// for the purpose of this test, to keep it reasonably simple, we arbitrarily choose a value of Dynamic values.</span> <a name="l00313"></a>00313 <span class="comment">// the choice of 10000 makes it larger than any practical fixed value and even most dynamic values.</span> <a name="l00314"></a>00314 <span class="comment">// in extreme cases where these assumptions would be wrong, we would still at worst suffer performance issues</span> <a name="l00315"></a>00315 <span class="comment">// (poor choice of temporaries).</span> <a name="l00316"></a>00316 <span class="comment">// it's important that this value can still be squared without integer overflowing.</span> <a name="l00317"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ab644cfddef2b2c434a0f1c37f54f9917">00317</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ab644cfddef2b2c434a0f1c37f54f9917">DynamicAsInteger</a> = 10000, <a name="l00318"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9aca02394ec54c206b8d497d126cd5d8b2">00318</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9aca02394ec54c206b8d497d126cd5d8b2">ScalarReadCost</a> = <a class="code" href="struct_num_traits.html" title="Holds information about the various numeric (i.e.">NumTraits<typename traits<T>::Scalar</a>>::ReadCost, <a name="l00319"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a1b90f4d4860325707107a266839fff1f">00319</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a1b90f4d4860325707107a266839fff1f">ScalarReadCostAsInteger</a> = <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9aca02394ec54c206b8d497d126cd5d8b2">ScalarReadCost</a> == <a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> ? <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ab644cfddef2b2c434a0f1c37f54f9917">DynamicAsInteger</a> : <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9aca02394ec54c206b8d497d126cd5d8b2">ScalarReadCost</a>, <a name="l00320"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a9739414cb25cad5f624f80e7ab14d980">00320</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a9739414cb25cad5f624f80e7ab14d980">CoeffReadCost</a> = traits<T>::CoeffReadCost, <a name="l00321"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9acabdfc67d4f37d1d2a8becbcaf5e324f">00321</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9acabdfc67d4f37d1d2a8becbcaf5e324f">CoeffReadCostAsInteger</a> = <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a9739414cb25cad5f624f80e7ab14d980">CoeffReadCost</a> == <a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> ? <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ab644cfddef2b2c434a0f1c37f54f9917">DynamicAsInteger</a> : <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a9739414cb25cad5f624f80e7ab14d980">CoeffReadCost</a>, <a name="l00322"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a2d017183af59909a05e2358ca0317f6b">00322</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a2d017183af59909a05e2358ca0317f6b">NAsInteger</a> = n == <a class="code" href="_constants_8h.html#adc9da5be31bdce40c25a92c27999c0e3" title="This value means that a quantity is not known at compile-time, and that instead the value is stored i...">Dynamic</a> ? int(<a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ab644cfddef2b2c434a0f1c37f54f9917">DynamicAsInteger</a>) : n, <a name="l00323"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ae1694cacac9b8337573563e9bdf523e9">00323</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ae1694cacac9b8337573563e9bdf523e9">CostEvalAsInteger</a> = (<a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a2d017183af59909a05e2358ca0317f6b">NAsInteger</a>+1) * <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a1b90f4d4860325707107a266839fff1f">ScalarReadCostAsInteger</a> + <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9acabdfc67d4f37d1d2a8becbcaf5e324f">CoeffReadCostAsInteger</a>, <a name="l00324"></a><a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a288838728095ab5e206f981beede2793">00324</a> <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a288838728095ab5e206f981beede2793">CostNoEvalAsInteger</a> = <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a2d017183af59909a05e2358ca0317f6b">NAsInteger</a> * <a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9acabdfc67d4f37d1d2a8becbcaf5e324f">CoeffReadCostAsInteger</a> <a name="l00325"></a>00325 }; <a name="l00326"></a>00326 <a name="l00327"></a>00327 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional</a>< <a name="l00328"></a>00328 ( (int(traits<T>::Flags) & <a class="code" href="group__flags.html#gaf8ad6e2956f7368b8e3f7407e2319e63" title="means the expression should be evaluated by the calling expression">EvalBeforeNestingBit</a>) || <a name="l00329"></a>00329 <span class="keywordtype">int</span>(<a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9ae1694cacac9b8337573563e9bdf523e9">CostEvalAsInteger</a>) < int(<a class="code" href="structinternal_1_1nested.html#a064398ebc637f9c81a399a3163e06ea9a288838728095ab5e206f981beede2793">CostNoEvalAsInteger</a>) <a name="l00330"></a>00330 ), <a name="l00331"></a>00331 PlainObject, <a name="l00332"></a>00332 <span class="keyword">typename</span> <a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">ref_selector<T>::type</a> <a name="l00333"></a>00333 >::<a class="code" href="classinternal_1_1dense__xpr__base_1_1type.html">type</a> <a class="code" href="classinternal_1_1dense__xpr__base_1_1type.html">type</a>; <a name="l00334"></a>00334 }; <a name="l00335"></a>00335 <a name="l00336"></a>00336 template<typename Derived, typename XprKind = typename traits<Derived>::XprKind> <a name="l00337"></a><a class="code" href="structinternal_1_1dense__xpr__base.html">00337</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1dense__xpr__base.html">dense_xpr_base</a> <a name="l00338"></a>00338 { <a name="l00339"></a>00339 <span class="comment">/* dense_xpr_base should only ever be used on dense expressions, thus falling either into the MatrixXpr or into the ArrayXpr cases */</span> <a name="l00340"></a>00340 }; <a name="l00341"></a>00341 <a name="l00342"></a>00342 <span class="keyword">template</span><<span class="keyword">typename</span> Derived> <a name="l00343"></a><a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_matrix_xpr_01_4.html">00343</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1dense__xpr__base.html">dense_xpr_base</a><Derived, <a class="code" href="struct_matrix_xpr.html" title="The type used to identify a matrix expression.">MatrixXpr</a>> <a name="l00344"></a>00344 { <a name="l00345"></a><a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_matrix_xpr_01_4.html#a1d31a85fd3f2ea4233681821dc741abf">00345</a> <span class="keyword">typedef</span> <a class="code" href="class_matrix_base.html" title="Base class for all dense matrices, vectors, and expressions.">MatrixBase<Derived></a> <a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_matrix_xpr_01_4.html#a1d31a85fd3f2ea4233681821dc741abf">type</a>; <a name="l00346"></a>00346 }; <a name="l00347"></a>00347 <a name="l00348"></a>00348 <span class="keyword">template</span><<span class="keyword">typename</span> Derived> <a name="l00349"></a><a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_array_xpr_01_4.html">00349</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1dense__xpr__base.html">dense_xpr_base</a><Derived, <a class="code" href="struct_array_xpr.html" title="The type used to identify an array expression.">ArrayXpr</a>> <a name="l00350"></a>00350 { <a name="l00351"></a><a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_array_xpr_01_4.html#ad044d9f642d52ce7ecbd59fc0ed2bab6">00351</a> <span class="keyword">typedef</span> <a class="code" href="class_array_base.html" title="Base class for all 1D and 2D array, and related expressions.">ArrayBase<Derived></a> <a class="code" href="structinternal_1_1dense__xpr__base_3_01_derived_00_01_array_xpr_01_4.html#ad044d9f642d52ce7ecbd59fc0ed2bab6">type</a>; <a name="l00352"></a>00352 }; <a name="l00353"></a>00353 <span class="comment"></span> <a name="l00354"></a>00354 <span class="comment">/** \internal Helper base class to add a scalar multiple operator</span> <a name="l00355"></a>00355 <span class="comment"> * overloads for complex types */</span> <a name="l00356"></a>00356 <span class="keyword">template</span><<span class="keyword">typename</span> Derived,<span class="keyword">typename</span> Scalar,<span class="keyword">typename</span> OtherScalar, <a name="l00357"></a>00357 <span class="keywordtype">bool</span> EnableIt = !<a class="code" href="structinternal_1_1is__same.html">is_same<Scalar,OtherScalar>::value</a> > <a name="l00358"></a><a class="code" href="structinternal_1_1special__scalar__op__base.html">00358</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1special__scalar__op__base.html">special_scalar_op_base</a> : <span class="keyword">public</span> <a class="code" href="class_dense_coeffs_base.html">DenseCoeffsBase</a><Derived> <a name="l00359"></a>00359 { <a name="l00360"></a>00360 <span class="comment">// dummy operator* so that the</span> <a name="l00361"></a>00361 <span class="comment">// "using special_scalar_op_base::operator*" compiles</span> <a name="l00362"></a>00362 <span class="keywordtype">void</span> <a class="code" href="namespacemrpt_1_1math.html#a2fd1d2d32443d99a6a819ca114a61873" title="a*b (element-wise multiplication)">operator*</a>() <span class="keyword">const</span>; <a name="l00363"></a>00363 }; <a name="l00364"></a>00364 <a name="l00365"></a>00365 <span class="keyword">template</span><<span class="keyword">typename</span> Derived,<span class="keyword">typename</span> Scalar,<span class="keyword">typename</span> OtherScalar> <a name="l00366"></a><a class="code" href="structinternal_1_1special__scalar__op__base_3_01_derived_00_01_scalar_00_01_other_scalar_00_01true_01_4.html">00366</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1special__scalar__op__base.html">special_scalar_op_base</a><Derived,Scalar,OtherScalar,true> : <span class="keyword">public</span> <a class="code" href="class_dense_coeffs_base.html">DenseCoeffsBase</a><Derived> <a name="l00367"></a>00367 { <a name="l00368"></a>00368 <span class="keyword">const</span> <a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">CwiseUnaryOp<scalar_multiple2_op<Scalar,OtherScalar></a>, Derived> <a name="l00369"></a><a class="code" href="structinternal_1_1special__scalar__op__base_3_01_derived_00_01_scalar_00_01_other_scalar_00_01true_01_4.html#af9480d3713c2a2572bd30796f226b7d1">00369</a> <a class="code" href="namespacemrpt_1_1math.html#a2fd1d2d32443d99a6a819ca114a61873" title="a*b (element-wise multiplication)">operator*</a>(<span class="keyword">const</span> OtherScalar& scalar)<span class="keyword"> const</span> <a name="l00370"></a>00370 <span class="keyword"> </span>{ <a name="l00371"></a>00371 <span class="keywordflow">return</span> <a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">CwiseUnaryOp<scalar_multiple2_op<Scalar,OtherScalar></a>, Derived> <a name="l00372"></a>00372 (*<span class="keyword">static_cast<</span><span class="keyword">const </span>Derived*<span class="keyword">></span>(<span class="keyword">this</span>), <a class="code" href="structinternal_1_1scalar__multiple2__op.html">scalar_multiple2_op<Scalar,OtherScalar></a>(scalar)); <a name="l00373"></a>00373 } <a name="l00374"></a>00374 <a name="l00375"></a>00375 <span class="keyword">inline</span> <span class="keyword">friend</span> <span class="keyword">const</span> <a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">CwiseUnaryOp<scalar_multiple2_op<Scalar,OtherScalar></a>, Derived> <a name="l00376"></a><a class="code" href="structinternal_1_1special__scalar__op__base_3_01_derived_00_01_scalar_00_01_other_scalar_00_01true_01_4.html#a13907a97652bd22ffb76a37f6cb87814">00376</a> <a class="code" href="namespacemrpt_1_1math.html#a2fd1d2d32443d99a6a819ca114a61873" title="a*b (element-wise multiplication)">operator*</a>(<span class="keyword">const</span> OtherScalar& scalar, <span class="keyword">const</span> Derived& matrix) <a name="l00377"></a>00377 { <span class="keywordflow">return</span> <span class="keyword">static_cast<</span><span class="keyword">const </span><a class="code" href="structinternal_1_1special__scalar__op__base.html">special_scalar_op_base</a>&<span class="keyword">></span>(matrix).<span class="keyword">operator</span>*(scalar); } <a name="l00378"></a>00378 }; <a name="l00379"></a>00379 <a name="l00380"></a><a class="code" href="structinternal_1_1cast__return__type.html">00380</a> <span class="keyword">template</span><<span class="keyword">typename</span> XprType, <span class="keyword">typename</span> CastType> <span class="keyword">struct </span><a class="code" href="structinternal_1_1cast__return__type.html">cast_return_type</a> <a name="l00381"></a>00381 { <a name="l00382"></a><a class="code" href="structinternal_1_1cast__return__type.html#a17ec2d721096743b7ce254edaf42882e">00382</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> XprType::Scalar <a class="code" href="structinternal_1_1cast__return__type.html#a17ec2d721096743b7ce254edaf42882e">CurrentScalarType</a>; <a name="l00383"></a><a class="code" href="structinternal_1_1cast__return__type.html#a587ec5756ca6784c76fba5fc8f8ea96f">00383</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1remove__all.html#a563ebdff4a8ca3825b500e7efb95c4bc">remove_all<CastType>::type</a> <a class="code" href="structinternal_1_1cast__return__type.html#a587ec5756ca6784c76fba5fc8f8ea96f">_CastType</a>; <a name="l00384"></a><a class="code" href="structinternal_1_1cast__return__type.html#a57d40ccef9db874323561ac32cca9b13">00384</a> <span class="keyword">typedef</span> <span class="keyword">typename</span> _CastType::Scalar <a class="code" href="structinternal_1_1cast__return__type.html#a57d40ccef9db874323561ac32cca9b13">NewScalarType</a>; <a name="l00385"></a>00385 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional<is_same<CurrentScalarType,NewScalarType>::value</a>, <a name="l00386"></a><a class="code" href="structinternal_1_1cast__return__type.html#ade757b0ee02658466cdecc878f4b9b0b">00386</a> <span class="keyword">const</span> XprType&,CastType><a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">::type</a> <a class="code" href="structinternal_1_1cast__return__type.html#ade757b0ee02658466cdecc878f4b9b0b">type</a>; <a name="l00387"></a>00387 }; <a name="l00388"></a>00388 <a name="l00389"></a>00389 <span class="keyword">template</span> <<span class="keyword">typename</span> A, <span class="keyword">typename</span> B> <span class="keyword">struct </span>promote_storage_type; <a name="l00390"></a>00390 <a name="l00391"></a><a class="code" href="structinternal_1_1promote__storage__type_3_01_a_00_01_a_01_4.html">00391</a> <span class="keyword">template</span> <<span class="keyword">typename</span> A> <span class="keyword">struct </span>promote_storage_type<A,A> <a name="l00392"></a>00392 { <a name="l00393"></a><a class="code" href="structinternal_1_1promote__storage__type_3_01_a_00_01_a_01_4.html#aeb56f5eb3fff97dfe573f54b695b48af">00393</a> <span class="keyword">typedef</span> A <a class="code" href="structinternal_1_1promote__storage__type_3_01_a_00_01_a_01_4.html#aeb56f5eb3fff97dfe573f54b695b48af">ret</a>; <a name="l00394"></a>00394 }; <a name="l00395"></a>00395 <span class="comment"></span> <a name="l00396"></a>00396 <span class="comment">/** \internal gives the plain matrix or array type to store a row/column/diagonal of a matrix type.</span> <a name="l00397"></a>00397 <span class="comment"> * \param Scalar optional parameter allowing to pass a different scalar type than the one of the MatrixType.</span> <a name="l00398"></a>00398 <span class="comment"> */</span> <a name="l00399"></a>00399 <span class="keyword">template</span><<span class="keyword">typename</span> ExpressionType, <span class="keyword">typename</span> Scalar = <span class="keyword">typename</span> ExpressionType::Scalar> <a name="l00400"></a><a class="code" href="structinternal_1_1plain__row__type.html">00400</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1plain__row__type.html">plain_row_type</a> <a name="l00401"></a>00401 { <a name="l00402"></a>00402 <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix</a><Scalar, 1, ExpressionType::ColsAtCompileTime, <a name="l00403"></a><a class="code" href="structinternal_1_1plain__row__type.html#ab6ea8cf1df84b075bb0c9baacbcd8578">00403</a> ExpressionType::PlainObject::Options | <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a>, 1, ExpressionType::MaxColsAtCompileTime> <a class="code" href="structinternal_1_1plain__row__type.html#ab6ea8cf1df84b075bb0c9baacbcd8578">MatrixRowType</a>; <a name="l00404"></a>00404 <span class="keyword">typedef</span> <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array</a><Scalar, 1, ExpressionType::ColsAtCompileTime, <a name="l00405"></a><a class="code" href="structinternal_1_1plain__row__type.html#ab17cf83f70735acd0e66159df012cc0b">00405</a> ExpressionType::PlainObject::Options | <a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a>, 1, ExpressionType::MaxColsAtCompileTime> <a class="code" href="structinternal_1_1plain__row__type.html#ab17cf83f70735acd0e66159df012cc0b">ArrayRowType</a>; <a name="l00406"></a>00406 <a name="l00407"></a>00407 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional</a>< <a name="l00408"></a>00408 <a class="code" href="structinternal_1_1is__same.html">is_same< typename traits<ExpressionType>::XprKind</a>, <a class="code" href="struct_matrix_xpr.html" title="The type used to identify a matrix expression.">MatrixXpr</a> >::value, <a name="l00409"></a>00409 <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">MatrixRowType</a>, <a name="l00410"></a>00410 <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">ArrayRowType</a> <a name="l00411"></a><a class="code" href="structinternal_1_1plain__row__type.html#a3d99051d08e96608030fdb5a0f699152">00411</a> ><a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">::type</a> <a class="code" href="structinternal_1_1plain__row__type.html#a3d99051d08e96608030fdb5a0f699152">type</a>; <a name="l00412"></a>00412 }; <a name="l00413"></a>00413 <a name="l00414"></a>00414 <span class="keyword">template</span><<span class="keyword">typename</span> ExpressionType, <span class="keyword">typename</span> Scalar = <span class="keyword">typename</span> ExpressionType::Scalar> <a name="l00415"></a><a class="code" href="structinternal_1_1plain__col__type.html">00415</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1plain__col__type.html">plain_col_type</a> <a name="l00416"></a>00416 { <a name="l00417"></a>00417 <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix</a><Scalar, ExpressionType::RowsAtCompileTime, 1, <a name="l00418"></a><a class="code" href="structinternal_1_1plain__col__type.html#a99860be8d19ba33833efe2ce0ca257ea">00418</a> ExpressionType::PlainObject::Options & ~<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a>, ExpressionType::MaxRowsAtCompileTime, 1> <a class="code" href="structinternal_1_1plain__col__type.html#a99860be8d19ba33833efe2ce0ca257ea">MatrixColType</a>; <a name="l00419"></a>00419 <span class="keyword">typedef</span> <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array</a><Scalar, ExpressionType::RowsAtCompileTime, 1, <a name="l00420"></a><a class="code" href="structinternal_1_1plain__col__type.html#a4f1ad44544c6936fd71e7ec1c9a9033b">00420</a> ExpressionType::PlainObject::Options & ~<a class="code" href="_constants_8h.html#aab4d131ba129f519b9e2bd349dc19e3aa1e16fa1b92ed7a058cd4ce7a9a0db044">RowMajor</a>, ExpressionType::MaxRowsAtCompileTime, 1> <a class="code" href="structinternal_1_1plain__col__type.html#a4f1ad44544c6936fd71e7ec1c9a9033b">ArrayColType</a>; <a name="l00421"></a>00421 <a name="l00422"></a>00422 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional</a>< <a name="l00423"></a>00423 <a class="code" href="structinternal_1_1is__same.html">is_same< typename traits<ExpressionType>::XprKind</a>, <a class="code" href="struct_matrix_xpr.html" title="The type used to identify a matrix expression.">MatrixXpr</a> >::value, <a name="l00424"></a>00424 <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">MatrixColType</a>, <a name="l00425"></a>00425 <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">ArrayColType</a> <a name="l00426"></a><a class="code" href="structinternal_1_1plain__col__type.html#a77db047cc39fa6789eacc700dbdb4981">00426</a> ><a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">::type</a> <a class="code" href="structinternal_1_1plain__col__type.html#a77db047cc39fa6789eacc700dbdb4981">type</a>; <a name="l00427"></a>00427 }; <a name="l00428"></a>00428 <a name="l00429"></a>00429 <span class="keyword">template</span><<span class="keyword">typename</span> ExpressionType, <span class="keyword">typename</span> Scalar = <span class="keyword">typename</span> ExpressionType::Scalar> <a name="l00430"></a><a class="code" href="structinternal_1_1plain__diag__type.html">00430</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1plain__diag__type.html">plain_diag_type</a> <a name="l00431"></a>00431 { <a name="l00432"></a><a class="code" href="structinternal_1_1plain__diag__type.html#a2d7e80eed656d0127e0b1f01e5702558a34d0463ccfa72eaf8348d5a091eae951">00432</a> <span class="keyword">enum</span> { diag_size = <a class="code" href="_macros_8h.html#a2a07ba221d47a7d636fd13678c8c75b3">EIGEN_SIZE_MIN_PREFER_DYNAMIC</a>(ExpressionType::RowsAtCompileTime, ExpressionType::ColsAtCompileTime), <a name="l00433"></a><a class="code" href="structinternal_1_1plain__diag__type.html#a2d7e80eed656d0127e0b1f01e5702558a4630c18a3585ff10f2474e1f980ddf03">00433</a> max_diag_size = <a class="code" href="_macros_8h.html#af2d58514e6156c4da2d4af66fafd0b12">EIGEN_SIZE_MIN_PREFER_FIXED</a>(ExpressionType::MaxRowsAtCompileTime, ExpressionType::MaxColsAtCompileTime) <a name="l00434"></a>00434 }; <a name="l00435"></a><a class="code" href="structinternal_1_1plain__diag__type.html#a50d2c5ac7a49f2eb138b4bb8351bce9e">00435</a> <span class="keyword">typedef</span> <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix<Scalar, diag_size, 1, ExpressionType::PlainObject::Options & ~RowMajor, max_diag_size, 1></a> <a class="code" href="structinternal_1_1plain__diag__type.html#a50d2c5ac7a49f2eb138b4bb8351bce9e">MatrixDiagType</a>; <a name="l00436"></a><a class="code" href="structinternal_1_1plain__diag__type.html#a59e1b04dbfef7098e05043c21f6b5f95">00436</a> <span class="keyword">typedef</span> <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">Array<Scalar, diag_size, 1, ExpressionType::PlainObject::Options & ~RowMajor, max_diag_size, 1></a> <a class="code" href="structinternal_1_1plain__diag__type.html#a59e1b04dbfef7098e05043c21f6b5f95">ArrayDiagType</a>; <a name="l00437"></a>00437 <a name="l00438"></a>00438 <span class="keyword">typedef</span> <span class="keyword">typename</span> <a class="code" href="structinternal_1_1conditional.html">conditional</a>< <a name="l00439"></a>00439 <a class="code" href="structinternal_1_1is__same.html">is_same< typename traits<ExpressionType>::XprKind</a>, <a class="code" href="struct_matrix_xpr.html" title="The type used to identify a matrix expression.">MatrixXpr</a> >::value, <a name="l00440"></a>00440 <a class="code" href="class_matrix.html" title="The matrix class, also used for vectors and row-vectors.">MatrixDiagType</a>, <a name="l00441"></a>00441 <a class="code" href="class_array.html" title="General-purpose arrays with easy API for coefficient-wise operations.">ArrayDiagType</a> <a name="l00442"></a><a class="code" href="structinternal_1_1plain__diag__type.html#a49717129e0632a573c1265e0da76eee7">00442</a> ><a class="code" href="class_cwise_unary_op.html" title="Generic expression where a coefficient-wise unary operator is applied to an expression.">::type</a> <a class="code" href="structinternal_1_1plain__diag__type.html#a49717129e0632a573c1265e0da76eee7">type</a>; <a name="l00443"></a>00443 }; <a name="l00444"></a>00444 <a name="l00445"></a>00445 <span class="keyword">template</span><<span class="keyword">typename</span> ExpressionType> <a name="l00446"></a><a class="code" href="structinternal_1_1is__lvalue.html">00446</a> <span class="keyword">struct </span><a class="code" href="structinternal_1_1is__lvalue.html">is_lvalue</a> <a name="l00447"></a>00447 { <a name="l00448"></a><a class="code" href="structinternal_1_1is__lvalue.html#a7b2f1dedfb6d0893f10f6d663cf97fc8a25edc21733af6f5ef50630c2fcbf4381">00448</a> <span class="keyword">enum</span> { value = !bool(<a class="code" href="structinternal_1_1is__const.html">is_const<ExpressionType>::value</a>) && <a name="l00449"></a>00449 bool(traits<ExpressionType>::Flags & <a class="code" href="group__flags.html#ga64e21b7543bdedce27f013512a4403a3" title="Means the expression has a coeffRef() method, i.e.">LvalueBit</a>) }; <a name="l00450"></a>00450 }; <a name="l00451"></a>00451 <a name="l00452"></a>00452 } <span class="comment">// end namespace internal</span> <a name="l00453"></a>00453 <a name="l00454"></a>00454 <span class="preprocessor">#endif // EIGEN_XPRHELPER_H</span> </pre></div></div> </div> <br><hr><br> <table border="0" width="100%"> <tr> <td> Page generated by <a href="http://www.doxygen.org" target="_blank">Doxygen 1.7.2</a> for MRPT 0.9.4 SVN: at Mon Jan 10 22:30:30 UTC 2011</td><td></td> <td width="100"> </td> <td width="150"> </td></tr> </table> </body></html>