Sophie

Sophie

distrib > Fedora > 16 > i386 > by-pkgid > 4bc66056a634db26a1f4d0845dc41ca6 > files > 4315

mrpt-doc-0.9.5-0.1.20110925svn2670.fc16.i686.rpm

<!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>mrpt::math::CSparseMatrix Class Reference</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> &gt; <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.5 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;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 class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
          <div 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>
          </div><div class="right"></div>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespacemrpt.html">mrpt</a>      </li>
      <li class="navelem"><a class="el" href="namespacemrpt_1_1math.html">math</a>      </li>
      <li class="navelem"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a>  </div>
  <div class="headertitle">
<div class="title">mrpt::math::CSparseMatrix Class Reference<div class="ingroups"><a class="el" href="group__mrpt__base__grp.html">[mrpt-base]</a></div></div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="mrpt::math::CSparseMatrix" --><hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>A sparse matrix capable of efficient math operations (a wrapper around the CSparse library) The type of cells is fixed to "double". </p>
<p>There are two main formats for the non-zero entries in this matrix:</p>
<ul>
<li>A "triplet" matrix: a set of (r,c)=val triplet entries.</li>
<li>A column-compressed sparse matrix.</li>
</ul>
<p>The latter is the "normal" format, which is expected by most mathematical operations defined in this class. There're two three ways of initializing and populating a sparse matrix:</p>
<ol>
<li>
<b>As a triplet (empty), then add entries, then compress:</b> <div class="fragment"><pre class="fragment">             <a class="code" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a5d836fcbf333fcd2e5fda9de14d4dad5" title="Create an initially empty sparse matrix, in the &quot;triplet&quot; form.">CSparseMatrix</a>  SM(100,100);
             SM.insert_entry(i,j, val);  <span class="comment">// or</span>
             SM.insert_submatrix(i,j, MAT); <span class="comment">//  ...</span>
             SM.compressFromTriplet();
</pre></div>  </li>
<li>
<b>As a triplet from a CSparseMatrixTemplate&lt;double&gt;:</b> <div class="fragment"><pre class="fragment">             CSparseMatrixTemplate&lt;double&gt;  data;
             data(row,col) = val;
             ...
             <a class="code" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a5d836fcbf333fcd2e5fda9de14d4dad5" title="Create an initially empty sparse matrix, in the &quot;triplet&quot; form.">CSparseMatrix</a>  SM(data);
</pre></div>  </li>
<li>
<p class="startli"><b>From an existing dense matrix:</b> </p>
<div class="fragment"><pre class="fragment">             <a class="code" href="namespacemrpt_1_1math.html#a3814c2b868f059d6a7ab0d8ecd2311d6" title="Declares a matrix of double numbers (non serializable).">CMatrixDouble</a> data(100,100); <span class="comment">// or</span>
             <a class="code" href="namespacemrpt_1_1math.html#a46578d070e41e17dead613002e755aa3" title="Declares a matrix of float numbers (non serializable).">CMatrixFloat</a>  data(100,100); <span class="comment">// or</span>
             CMatrixFixedNumeric&lt;double,4,6&gt;  data; <span class="comment">// etc...</span>
             <a class="code" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a5d836fcbf333fcd2e5fda9de14d4dad5" title="Create an initially empty sparse matrix, in the &quot;triplet&quot; form.">CSparseMatrix</a>  SM(data);
</pre></div> <p class="endli"></p>
</li>
</ol>
<p>Due to its practical utility, there is a special inner class <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix_1_1_cholesky_decomp.html" title="Auxiliary class to hold the results of a Cholesky factorization of a sparse matrix.">CSparseMatrix::CholeskyDecomp</a> to handle Cholesky-related methods and data.</p>
<dl class="note"><dt><b>Note:</b></dt><dd>This class was initially adapted from "robotvision", by Hauke Strasdat, Steven Lovegrove and Andrew J. Davison. See <a href="http://www.openslam.org/robotvision.html">http://www.openslam.org/robotvision.html</a> </dd>
<dd>
CSparse is maintained by Timothy Davis: <a href="http://people.sc.fsu.edu/~jburkardt/c_src/csparse/csparse.html">http://people.sc.fsu.edu/~jburkardt/c_src/csparse/csparse.html</a> . </dd>
<dd>
See also his book "Direct methods for sparse linear systems". <a href="http://books.google.es/books?id=TvwiyF8vy3EC&pg=PA12&lpg=PA12&dq=cs_compress&source=bl&ots=od9uGJ793j&sig=Wa-fBk4sZkZv3Y0Op8FNH8PvCUs&hl=es&ei=UjA0TJf-EoSmsQay3aXPAw&sa=X&oi=book_result&ct=result&resnum=8&ved=0CEQQ6AEwBw#v=onepage&q&f=false">http://books.google.es/books?id=TvwiyF8vy3EC&amp;pg=PA12&amp;lpg=PA12&amp;dq=cs_compress&amp;source=bl&amp;ots=od9uGJ793j&amp;sig=Wa-fBk4sZkZv3Y0Op8FNH8PvCUs&amp;hl=es&amp;ei=UjA0TJf-EoSmsQay3aXPAw&amp;sa=X&amp;oi=book_result&amp;ct=result&amp;resnum=8&amp;ved=0CEQQ6AEwBw#v=onepage&amp;q&amp;f=false</a></dd></dl>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_matrix_fixed_numeric.html" title="A numeric matrix of compile-time fixed size.">mrpt::math::CMatrixFixedNumeric</a>, <a class="el" href="classmrpt_1_1math_1_1_c_matrix_template_numeric.html" title="A matrix of dynamic size.">mrpt::math::CMatrixTemplateNumeric</a>, etc. </dd></dl>
</div>
<p><code>#include &lt;<a class="el" href="_c_sparse_matrix_8h_source.html">mrpt/math/CSparseMatrix.h</a>&gt;</code></p>

<p><a href="classmrpt_1_1math_1_1_c_sparse_matrix-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="nested-classes"></a>
Classes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix_1_1_cholesky_decomp.html">CholeskyDecomp</a></td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Auxiliary class to hold the results of a Cholesky factorization of a sparse matrix.  <a href="classmrpt_1_1math_1_1_c_sparse_matrix_1_1_cholesky_decomp.html#details">More...</a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Constructors, destructor &amp; copy operations</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a5d836fcbf333fcd2e5fda9de14d4dad5">CSparseMatrix</a> (const size_t nRows=0, const size_t nCols=0)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Create an initially empty sparse matrix, in the "triplet" form.  <a href="#a5d836fcbf333fcd2e5fda9de14d4dad5"></a><br/></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;typename T &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a67af500c83f70e8b8b33b4d50fae4759">CSparseMatrix</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix_template.html">CSparseMatrixTemplate</a>&lt; T &gt; &amp;data)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">A good way to initialize a sparse matrix from a list of non NULL elements.  <a href="#a67af500c83f70e8b8b33b4d50fae4759"></a><br/></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;typename T , size_t N, size_t M&gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a9adcd5be76c48044671b4d63de30120a">CSparseMatrix</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_matrix_fixed_numeric.html">CMatrixFixedNumeric</a>&lt; T, N, M &gt; &amp;MAT)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor from a dense matrix of any kind existing in MRPT, creating a "column-compressed" sparse matrix.  <a href="#a9adcd5be76c48044671b4d63de30120a"></a><br/></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;typename T &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#acea14c946787fe0be313d17df3eea221">CSparseMatrix</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_matrix_template_numeric.html">CMatrixTemplateNumeric</a>&lt; T &gt; &amp;MAT)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor from a dense matrix of any kind existing in MRPT, creating a "column-compressed" sparse matrix.  <a href="#acea14c946787fe0be313d17df3eea221"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8c2af318cf940b16a643df01a96c47f1">CSparseMatrix</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Copy constructor.  <a href="#a8c2af318cf940b16a643df01a96c47f1"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8e88aba64a96ee0120a3c342b6ccc9e6">CSparseMatrix</a> (const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const sm)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Copy constructor from an existing "cs" CSparse data structure.  <a href="#a8e88aba64a96ee0120a3c342b6ccc9e6"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a80f5910fcb71a6ceb7ba74b0726f9f4f">~CSparseMatrix</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor.  <a href="#a80f5910fcb71a6ceb7ba74b0726f9f4f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ac0e2e145aff6139b9c90dd3b5ceeb3a1">operator=</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Copy operator from another existing object.  <a href="#ac0e2e145aff6139b9c90dd3b5ceeb3a1"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#aa601afdf66f0d964864544dbd6beaf73">clear</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase all previous contents and leave the matrix as a "triplet" 1x1 matrix without any data.  <a href="#aa601afdf66f0d964864544dbd6beaf73"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Math operations (the interesting stuff...)</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a0e28abd9010a84b6a777c97496cb8eb6">add_AB</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;A, const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;B)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">this = A+B  <a href="#a0e28abd9010a84b6a777c97496cb8eb6"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#aac6d33b70dac52676ab0b7e933d77e80">multiply_AB</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;A, const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;B)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">this = A*B  <a href="#aac6d33b70dac52676ab0b7e933d77e80"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#af1811fc210b7bd8712311e848488ec85">multiply_Ab</a> (const <a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;b, <a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;out_res) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">out_res = this * b  <a href="#af1811fc210b7bd8712311e848488ec85"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ac6ffc42c8bf4b24ac6632add222caef0">operator+</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ae270652280c21219cb6fb54b3b8c6b37">operator*</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ac53f79478dd3ad93d38a64fca27d1212">operator*</a> (const <a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;other) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ad5dd8abf27f0cc2a312751f829da1772">operator+=</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a63b605043228deb4187a7bdce0c50f0c">operator*=</a> (const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;other)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a2b37bf0d7f26fbe5ad803a56f1679464">transpose</a> () const </td></tr>
<tr><td colspan="2"><h2><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;class MATRIX &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a69f2b0a005c61fe8fcf4b0d8c0442c43">construct_from_mrpt_mat</a> (const MATRIX &amp;C)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialization from a dense matrix of any kind existing in MRPT.  <a href="#a69f2b0a005c61fe8fcf4b0d8c0442c43"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a112909cdc981cd08321b522e466174ce">construct_from_triplet</a> (const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;triplet)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialization from a triplet "cs", which is first compressed.  <a href="#a112909cdc981cd08321b522e466174ce"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a32a237dedaf5db78eca0caabf4bee00e">construct_from_existing_cs</a> (const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;sm)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">To be called by constructors only, assume previous pointers are trash and overwrite them.  <a href="#a32a237dedaf5db78eca0caabf4bee00e"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a3d93cde959d189efb767aa780e388c86">internal_free_mem</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">free buffers (deallocate the memory of the i,p,x buffers)  <a href="#a3d93cde959d189efb767aa780e388c86"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#aa5086e2eb62abc2f1017d56cdfb32af0">copy</a> (const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const sm)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Copy the data from an existing "cs" CSparse data structure.  <a href="#aa5086e2eb62abc2f1017d56cdfb32af0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8153ac3003c221a47facdf026f755523">copy_fast</a> (<a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const sm)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Fast copy the data from an existing "cs" CSparse data structure, copying the pointers and leaving NULLs in the source structure.  <a href="#a8153ac3003c221a47facdf026f755523"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#af45bc10e45c938c73ce281f2aea239d5">sparse_matrix</a></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a95918cdc28dc44772ffe5ce72625ae1f">insert_entry</a> (const size_t row, const size_t col, const double val)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">@ Access the matrix, get, set elements, etc.  <a href="#a95918cdc28dc44772ffe5ce72625ae1f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#abc4058c15d5a02f8d56853de8cbab18b">insert_entry_fast</a> (const size_t row, const size_t col, const double val)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">ONLY for TRIPLET matrices: Insert an element into a "cs", without checking if the matrix is in Triplet format and without extending the matrix extension/limits if (row,col) is out of the current size.  <a href="#abc4058c15d5a02f8d56853de8cbab18b"></a><br/></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;class MATRIX &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a894f92cdcb91d4f700d5724bf11e0382">insert_submatrix</a> (const size_t row, const size_t col, const MATRIX &amp;M)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">ONLY for TRIPLET matrices: insert a given matrix (in any of the MRPT formats) at a given location of the sparse matrix.  <a href="#a894f92cdcb91d4f700d5724bf11e0382"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a0ff96fdc90f43ad4bc9c2b4876e42089">compressFromTriplet</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">ONLY for TRIPLET matrices: convert the matrix in a column-compressed form.  <a href="#a0ff96fdc90f43ad4bc9c2b4876e42089"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a077d30335eba8bbc5b5654f5f5a5b867">get_dense</a> (<a class="el" href="namespacemrpt_1_1math.html#a3814c2b868f059d6a7ab0d8ecd2311d6">CMatrixDouble</a> &amp;outMat) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a dense representation of the sparse matrix.  <a href="#a077d30335eba8bbc5b5654f5f5a5b867"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a959b44625e6883fe8f5be83f5cfe4eb2">saveToTextFile_dense</a> (const <a class="el" href="classstd_1_1string.html">std::string</a> &amp;filName)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">save as a dense matrix to a text file  <a href="#a959b44625e6883fe8f5be83f5cfe4eb2"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a1214329cf1365c3438c0f78a92603eb8">getRowCount</a> () const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#af8abe241e9f40a99b6baa0bf7925b5e2">getColCount</a> () const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a10a20d1ac9b6d243517632b106940230">setRowCount</a> (const size_t nRows)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the number of rows in the matrix (can't be lower than current size)  <a href="#a10a20d1ac9b6d243517632b106940230"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a7c712ee22308a4192a607e94781a534e">setColCount</a> (const size_t nCols)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8c4fb86b861bc3cfd690551c25722e94">isTriplet</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns true if this sparse matrix is in "triplet" form.  <a href="#a8c4fb86b861bc3cfd690551c25722e94"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a9b9eb4fd3d1a54d4ced1a2fe2cd5c2ac">isColumnCompressed</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns true if this sparse matrix is in "column compressed" form.  <a href="#a9b9eb4fd3d1a54d4ced1a2fe2cd5c2ac"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#ad71ad9ee625a046b7fd90e40aebd9aa1">cs2dense</a> (const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;SM, <a class="el" href="namespacemrpt_1_1math.html#a3814c2b868f059d6a7ab0d8ecd2311d6">CMatrixDouble</a> &amp;outMat)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Static method to convert a "cs" structure into a dense representation of the sparse matrix.  <a href="#ad71ad9ee625a046b7fd90e40aebd9aa1"></a><br/></td></tr>
</table>
<hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a5d836fcbf333fcd2e5fda9de14d4dad5"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="a5d836fcbf333fcd2e5fda9de14d4dad5" args="(const size_t nRows=0, const size_t nCols=0)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>nRows</em> = <code>0</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>nCols</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Create an initially empty sparse matrix, in the "triplet" form. </p>
<p>Notice that you must call "compressFromTriplet" after populating the matrix and before using the math operatons on this matrix. The initial size can be later on extended with <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a95918cdc28dc44772ffe5ce72625ae1f" title="@ Access the matrix, get, set elements, etc.">insert_entry()</a> or <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a10a20d1ac9b6d243517632b106940230" title="Change the number of rows in the matrix (can&#39;t be lower than current size)">setRowCount()</a> &amp; <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a7c712ee22308a4192a607e94781a534e">setColCount()</a>. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a95918cdc28dc44772ffe5ce72625ae1f" title="@ Access the matrix, get, set elements, etc.">insert_entry</a>, <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a10a20d1ac9b6d243517632b106940230" title="Change the number of rows in the matrix (can&#39;t be lower than current size)">setRowCount</a>, <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a7c712ee22308a4192a607e94781a534e">setColCount</a> </dd></dl>

</div>
</div>
<a class="anchor" id="a67af500c83f70e8b8b33b4d50fae4759"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="a67af500c83f70e8b8b33b4d50fae4759" args="(const CSparseMatrixTemplate&lt; T &gt; &amp;data)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix_template.html">CSparseMatrixTemplate</a>&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>data</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>A good way to initialize a sparse matrix from a list of non NULL elements. </p>
<p>This constructor takes all the non-zero entries in "data" and builds a column-compressed sparse representation. </p>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00174">174</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="mrpt__macros_8h_source.html#l00281">ASSERTMSG_</a>, <a class="el" href="_c_sparse_matrix_template_8h_source.html#l00307">mrpt::math::CSparseMatrixTemplate::empty()</a>, <a class="el" href="_c_sparse_matrix_template_8h_source.html#l00119">mrpt::math::CSparseMatrixTemplate::getRowCount()</a>, <a class="el" href="_c_sparse_matrix_template_8h_source.html#l00126">mrpt::math::CSparseMatrixTemplate::getColCount()</a>, <a class="el" href="_c_sparse_matrix_template_8h_source.html#l00196">mrpt::math::CSparseMatrixTemplate::begin()</a>, <a class="el" href="_c_sparse_matrix_template_8h_source.html#l00203">mrpt::math::CSparseMatrixTemplate::end()</a>, and <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#abc4058c15d5a02f8d56853de8cbab18b">insert_entry_fast()</a>.</p>

</div>
</div>
<a class="anchor" id="a9adcd5be76c48044671b4d63de30120a"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="a9adcd5be76c48044671b4d63de30120a" args="(const CMatrixFixedNumeric&lt; T, N, M &gt; &amp;MAT)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T , size_t N, size_t M&gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_matrix_fixed_numeric.html">CMatrixFixedNumeric</a>&lt; T, N, M &gt; &amp;&#160;</td>
          <td class="paramname"><em>MAT</em></td><td>)</td>
          <td><code> [inline, explicit]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Constructor from a dense matrix of any kind existing in MRPT, creating a "column-compressed" sparse matrix. </p>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00195">195</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="acea14c946787fe0be313d17df3eea221"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="acea14c946787fe0be313d17df3eea221" args="(const CMatrixTemplateNumeric&lt; T &gt; &amp;MAT)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_matrix_template_numeric.html">CMatrixTemplateNumeric</a>&lt; T &gt; &amp;&#160;</td>
          <td class="paramname"><em>MAT</em></td><td>)</td>
          <td><code> [inline, explicit]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Constructor from a dense matrix of any kind existing in MRPT, creating a "column-compressed" sparse matrix. </p>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00198">198</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="a8c2af318cf940b16a643df01a96c47f1"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="a8c2af318cf940b16a643df01a96c47f1" args="(const CSparseMatrix &amp;other)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Copy constructor. </p>

</div>
</div>
<a class="anchor" id="a8e88aba64a96ee0120a3c342b6ccc9e6"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::CSparseMatrix" ref="a8e88aba64a96ee0120a3c342b6ccc9e6" args="(const cs *const sm)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">mrpt::math::CSparseMatrix::CSparseMatrix </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const&#160;</td>
          <td class="paramname"><em>sm</em></td><td>)</td>
          <td><code> [explicit]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Copy constructor from an existing "cs" CSparse data structure. </p>

</div>
</div>
<a class="anchor" id="a80f5910fcb71a6ceb7ba74b0726f9f4f"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::~CSparseMatrix" ref="a80f5910fcb71a6ceb7ba74b0726f9f4f" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual mrpt::math::CSparseMatrix::~CSparseMatrix </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Destructor. </p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a0e28abd9010a84b6a777c97496cb8eb6"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::add_AB" ref="a0e28abd9010a84b6a777c97496cb8eb6" args="(const CSparseMatrix &amp;A, const CSparseMatrix &amp;B)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::add_AB </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>B</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>this = A+B </p>

<p>Referenced by <a class="el" href="_c_sparse_matrix_8h_source.html#l00224">operator+()</a>.</p>

</div>
</div>
<a class="anchor" id="aa601afdf66f0d964864544dbd6beaf73"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::clear" ref="aa601afdf66f0d964864544dbd6beaf73" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::clear </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Erase all previous contents and leave the matrix as a "triplet" 1x1 matrix without any data. </p>

</div>
</div>
<a class="anchor" id="a0ff96fdc90f43ad4bc9c2b4876e42089"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::compressFromTriplet" ref="a0ff96fdc90f43ad4bc9c2b4876e42089" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::compressFromTriplet </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>ONLY for TRIPLET matrices: convert the matrix in a column-compressed form. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a95918cdc28dc44772ffe5ce72625ae1f" title="@ Access the matrix, get, set elements, etc.">insert_entry</a> </dd></dl>

<p>Referenced by <a class="el" href="levmarq_8h_source.html#l00073">mrpt::graphslam::optimize_graph_spa_levmarq()</a>.</p>

</div>
</div>
<a class="anchor" id="a32a237dedaf5db78eca0caabf4bee00e"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::construct_from_existing_cs" ref="a32a237dedaf5db78eca0caabf4bee00e" args="(const cs &amp;sm)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::construct_from_existing_cs </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;&#160;</td>
          <td class="paramname"><em>sm</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>To be called by constructors only, assume previous pointers are trash and overwrite them. </p>

</div>
</div>
<a class="anchor" id="a69f2b0a005c61fe8fcf4b0d8c0442c43"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::construct_from_mrpt_mat" ref="a69f2b0a005c61fe8fcf4b0d8c0442c43" args="(const MATRIX &amp;C)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MATRIX &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::construct_from_mrpt_mat </td>
          <td>(</td>
          <td class="paramtype">const MATRIX &amp;&#160;</td>
          <td class="paramname"><em>C</em></td><td>)</td>
          <td><code> [inline, private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Initialization from a dense matrix of any kind existing in MRPT. </p>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00111">111</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="group__mrpt__system__os.html#gae1184cfb1f617787dc4c9da98becbe3a">mrpt::system::os::memcpy()</a>.</p>

</div>
</div>
<a class="anchor" id="a112909cdc981cd08321b522e466174ce"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::construct_from_triplet" ref="a112909cdc981cd08321b522e466174ce" args="(const cs &amp;triplet)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::construct_from_triplet </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;&#160;</td>
          <td class="paramname"><em>triplet</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Initialization from a triplet "cs", which is first compressed. </p>

</div>
</div>
<a class="anchor" id="aa5086e2eb62abc2f1017d56cdfb32af0"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::copy" ref="aa5086e2eb62abc2f1017d56cdfb32af0" args="(const cs *const sm)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::copy </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const&#160;</td>
          <td class="paramname"><em>sm</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Copy the data from an existing "cs" CSparse data structure. </p>

</div>
</div>
<a class="anchor" id="a8153ac3003c221a47facdf026f755523"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::copy_fast" ref="a8153ac3003c221a47facdf026f755523" args="(cs *const sm)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::copy_fast </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> *const&#160;</td>
          <td class="paramname"><em>sm</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Fast copy the data from an existing "cs" CSparse data structure, copying the pointers and leaving NULLs in the source structure. </p>

</div>
</div>
<a class="anchor" id="ad71ad9ee625a046b7fd90e40aebd9aa1"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::cs2dense" ref="ad71ad9ee625a046b7fd90e40aebd9aa1" args="(const cs &amp;SM, CMatrixDouble &amp;outMat)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static void mrpt::math::CSparseMatrix::cs2dense </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> &amp;&#160;</td>
          <td class="paramname"><em>SM</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespacemrpt_1_1math.html#a3814c2b868f059d6a7ab0d8ecd2311d6">CMatrixDouble</a> &amp;&#160;</td>
          <td class="paramname"><em>outMat</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Static method to convert a "cs" structure into a dense representation of the sparse matrix. </p>

</div>
</div>
<a class="anchor" id="a077d30335eba8bbc5b5654f5f5a5b867"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::get_dense" ref="a077d30335eba8bbc5b5654f5f5a5b867" args="(CMatrixDouble &amp;outMat) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::get_dense </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespacemrpt_1_1math.html#a3814c2b868f059d6a7ab0d8ecd2311d6">CMatrixDouble</a> &amp;&#160;</td>
          <td class="paramname"><em>outMat</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Return a dense representation of the sparse matrix. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a959b44625e6883fe8f5be83f5cfe4eb2" title="save as a dense matrix to a text file">saveToTextFile_dense</a> </dd></dl>

</div>
</div>
<a class="anchor" id="af8abe241e9f40a99b6baa0bf7925b5e2"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::getColCount" ref="af8abe241e9f40a99b6baa0bf7925b5e2" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t mrpt::math::CSparseMatrix::getColCount </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00306">306</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="a1214329cf1365c3438c0f78a92603eb8"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::getRowCount" ref="a1214329cf1365c3438c0f78a92603eb8" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">size_t mrpt::math::CSparseMatrix::getRowCount </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00305">305</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="a95918cdc28dc44772ffe5ce72625ae1f"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::insert_entry" ref="a95918cdc28dc44772ffe5ce72625ae1f" args="(const size_t row, const size_t col, const double val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::insert_entry </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>row</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>col</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const double&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>@ Access the matrix, get, set elements, etc. </p>
<p>ONLY for TRIPLET matrices: insert a new non-zero entry in the matrix. This method cannot be used once the matrix is in column-compressed form. The size of the matrix will be automatically extended if the indices are out of the current limits. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8c4fb86b861bc3cfd690551c25722e94" title="Returns true if this sparse matrix is in &quot;triplet&quot; form.">isTriplet</a>, <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a0ff96fdc90f43ad4bc9c2b4876e42089" title="ONLY for TRIPLET matrices: convert the matrix in a column-compressed form.">compressFromTriplet</a> </dd></dl>

</div>
</div>
<a class="anchor" id="abc4058c15d5a02f8d56853de8cbab18b"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::insert_entry_fast" ref="abc4058c15d5a02f8d56853de8cbab18b" args="(const size_t row, const size_t col, const double val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::insert_entry_fast </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>row</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>col</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const double&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>ONLY for TRIPLET matrices: Insert an element into a "cs", without checking if the matrix is in Triplet format and without extending the matrix extension/limits if (row,col) is out of the current size. </p>

<p>Referenced by <a class="el" href="_c_sparse_matrix_8h_source.html#l00174">CSparseMatrix()</a>, and <a class="el" href="levmarq_8h_source.html#l00073">mrpt::graphslam::optimize_graph_spa_levmarq()</a>.</p>

</div>
</div>
<a class="anchor" id="a894f92cdcb91d4f700d5724bf11e0382"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::insert_submatrix" ref="a894f92cdcb91d4f700d5724bf11e0382" args="(const size_t row, const size_t col, const MATRIX &amp;M)" -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class MATRIX &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::insert_submatrix </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>row</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>col</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const MATRIX &amp;&#160;</td>
          <td class="paramname"><em>M</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>ONLY for TRIPLET matrices: insert a given matrix (in any of the MRPT formats) at a given location of the sparse matrix. </p>
<p>This method cannot be used once the matrix is in column-compressed form. The size of the matrix will be automatically extended if the indices are out of the current limits. Since this is inline, it can be very efficient for fixed-size MRPT matrices. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8c4fb86b861bc3cfd690551c25722e94" title="Returns true if this sparse matrix is in &quot;triplet&quot; form.">isTriplet</a>, <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a0ff96fdc90f43ad4bc9c2b4876e42089" title="ONLY for TRIPLET matrices: convert the matrix in a column-compressed form.">compressFromTriplet</a>, <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a95918cdc28dc44772ffe5ce72625ae1f" title="@ Access the matrix, get, set elements, etc.">insert_entry</a> </dd></dl>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00272">272</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="mrpt__macros_8h_source.html#l00131">THROW_EXCEPTION</a>.</p>

<p>Referenced by <a class="el" href="levmarq_8h_source.html#l00073">mrpt::graphslam::optimize_graph_spa_levmarq()</a>.</p>

</div>
</div>
<a class="anchor" id="a3d93cde959d189efb767aa780e388c86"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::internal_free_mem" ref="a3d93cde959d189efb767aa780e388c86" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::internal_free_mem </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>free buffers (deallocate the memory of the i,p,x buffers) </p>

</div>
</div>
<a class="anchor" id="a9b9eb4fd3d1a54d4ced1a2fe2cd5c2ac"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::isColumnCompressed" ref="a9b9eb4fd3d1a54d4ced1a2fe2cd5c2ac" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool mrpt::math::CSparseMatrix::isColumnCompressed </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns true if this sparse matrix is in "column compressed" form. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a8c4fb86b861bc3cfd690551c25722e94" title="Returns true if this sparse matrix is in &quot;triplet&quot; form.">isTriplet</a> </dd></dl>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00316">316</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="a8c4fb86b861bc3cfd690551c25722e94"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::isTriplet" ref="a8c4fb86b861bc3cfd690551c25722e94" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool mrpt::math::CSparseMatrix::isTriplet </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns true if this sparse matrix is in "triplet" form. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a9b9eb4fd3d1a54d4ced1a2fe2cd5c2ac" title="Returns true if this sparse matrix is in &quot;column compressed&quot; form.">isColumnCompressed</a> </dd></dl>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00313">313</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="aac6d33b70dac52676ab0b7e933d77e80"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::multiply_AB" ref="aac6d33b70dac52676ab0b7e933d77e80" args="(const CSparseMatrix &amp;A, const CSparseMatrix &amp;B)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::multiply_AB </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>B</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>this = A*B </p>

<p>Referenced by <a class="el" href="_c_sparse_matrix_8h_source.html#l00230">operator*()</a>.</p>

</div>
</div>
<a class="anchor" id="af1811fc210b7bd8712311e848488ec85"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::multiply_Ab" ref="af1811fc210b7bd8712311e848488ec85" args="(const mrpt::vector_double &amp;b, mrpt::vector_double &amp;out_res) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::multiply_Ab </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;&#160;</td>
          <td class="paramname"><em>b</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;&#160;</td>
          <td class="paramname"><em>out_res</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>out_res = this * b </p>

</div>
</div>
<a class="anchor" id="ae270652280c21219cb6fb54b3b8c6b37"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator*" ref="ae270652280c21219cb6fb54b3b8c6b37" args="(const CSparseMatrix &amp;other) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> mrpt::math::CSparseMatrix::operator* </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00230">230</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#aac6d33b70dac52676ab0b7e933d77e80">multiply_AB()</a>.</p>

</div>
</div>
<a class="anchor" id="ac53f79478dd3ad93d38a64fca27d1212"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator*" ref="ac53f79478dd3ad93d38a64fca27d1212" args="(const mrpt::vector_double &amp;other) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> mrpt::math::CSparseMatrix::operator* </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="namespacemrpt.html#a4a6aab2c98368ca6b554c04f8fe84cfb">mrpt::vector_double</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00236">236</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="eigen__plugins_8h_source.html#l00537">multiply_Ab()</a>.</p>

</div>
</div>
<a class="anchor" id="a63b605043228deb4187a7bdce0c50f0c"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator*=" ref="a63b605043228deb4187a7bdce0c50f0c" args="(const CSparseMatrix &amp;other)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::operator*= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00244">244</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="eigen__plugins_8h_source.html#l00526">multiply_AB()</a>.</p>

</div>
</div>
<a class="anchor" id="ac6ffc42c8bf4b24ac6632add222caef0"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator+" ref="ac6ffc42c8bf4b24ac6632add222caef0" args="(const CSparseMatrix &amp;other) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> mrpt::math::CSparseMatrix::operator+ </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00224">224</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#a0e28abd9010a84b6a777c97496cb8eb6">add_AB()</a>.</p>

</div>
</div>
<a class="anchor" id="ad5dd8abf27f0cc2a312751f829da1772"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator+=" ref="ad5dd8abf27f0cc2a312751f829da1772" args="(const CSparseMatrix &amp;other)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::operator+= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00241">241</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</div>
</div>
<a class="anchor" id="ac0e2e145aff6139b9c90dd3b5ceeb3a1"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::operator=" ref="ac0e2e145aff6139b9c90dd3b5ceeb3a1" args="(const CSparseMatrix &amp;other)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::operator= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> &amp;&#160;</td>
          <td class="paramname"><em>other</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Copy operator from another existing object. </p>

</div>
</div>
<a class="anchor" id="a959b44625e6883fe8f5be83f5cfe4eb2"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::saveToTextFile_dense" ref="a959b44625e6883fe8f5be83f5cfe4eb2" args="(const std::string &amp;filName)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool mrpt::math::CSparseMatrix::saveToTextFile_dense </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classstd_1_1string.html">std::string</a> &amp;&#160;</td>
          <td class="paramname"><em>filName</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>save as a dense matrix to a text file </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>False on any error. </dd></dl>

</div>
</div>
<a class="anchor" id="a7c712ee22308a4192a607e94781a534e"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::setColCount" ref="a7c712ee22308a4192a607e94781a534e" args="(const size_t nCols)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::setColCount </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>nCols</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00310">310</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="mrpt__macros_8h_source.html#l00282">ASSERT_</a>.</p>

</div>
</div>
<a class="anchor" id="a10a20d1ac9b6d243517632b106940230"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::setRowCount" ref="a10a20d1ac9b6d243517632b106940230" args="(const size_t nRows)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void mrpt::math::CSparseMatrix::setRowCount </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>nRows</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Change the number of rows in the matrix (can't be lower than current size) </p>

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00309">309</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

<p>References <a class="el" href="mrpt__macros_8h_source.html#l00282">ASSERT_</a>.</p>

</div>
</div>
<a class="anchor" id="a2b37bf0d7f26fbe5ad803a56f1679464"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::transpose" ref="a2b37bf0d7f26fbe5ad803a56f1679464" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html">CSparseMatrix</a> mrpt::math::CSparseMatrix::transpose </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<hr/><h2>Member Data Documentation</h2>
<a class="anchor" id="af45bc10e45c938c73ce281f2aea239d5"></a><!-- doxytag: member="mrpt::math::CSparseMatrix::sparse_matrix" ref="af45bc10e45c938c73ce281f2aea239d5" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="cs_8h.html#a44e471a015cf32e012cffef17e81b6db">cs</a> <a class="el" href="classmrpt_1_1math_1_1_c_sparse_matrix.html#af45bc10e45c938c73ce281f2aea239d5">mrpt::math::CSparseMatrix::sparse_matrix</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_c_sparse_matrix_8h_source.html#l00107">107</a> of file <a class="el" href="_c_sparse_matrix_8h_source.html">CSparseMatrix.h</a>.</p>

</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.5</a> for MRPT 0.9.5 SVN: at Sun Sep 25 17:20:18 UTC 2011</td><td></td> <td width="100"> </td> <td width="150">  </td></tr> </table>  </body></html>