⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dimen.html

📁 矩阵算法库newmat10.tar.gz的帮助文件
💻 HTML
字号:
<HTML><HEAD><TITLE>Newmat09 - change dimensions</TITLE></HEAD><BODY><H2>Change dimensions</H2><A HREF="ch_type.html">  next</A> - <A HREF="ch_type.html">  skip</A> - <A HREF="refer.html">  up</A> - <A HREF="index.html">  start</A><P>The following operations change the dimensions of a matrix. The valuesof the elements are lost.<PRE>    A.ReSize(nrows,ncols);        // for type Matrix or nricMatrix    A.ReSize(n);                  // for all other types, except Band    A.ReSize(n,lower,upper);      // for BandMatrix    A.ReSize(n,lower);            // for LowerBandMatrix    A.ReSize(n,upper);            // for UpperBandMatrix    A.ReSize(n,lower);            // for SymmetricBandMatrix</PRE>Use <TT>A.CleanUp()</TT> to set the dimensions of <TT>A</TT> to zeroand release all the heap memory.<P>Remember that <TT>ReSize</TT> destroys values.If you want to <TT>ReSize</TT>, butkeep the values in the bit that is left use something like<PRE>   ColumnVector V(100);   ...                            // load values   V = V.Rows(1,50);              // to get first 50 values.</PRE>If you want to extend a matrix or vector use something like<PRE>   ColumnVector V(50);   ...                            // load values   { V.Release(); ColumnVector X=V; V.ReSize(100); V.Rows(1,50)=X; }                                  // V now length 100</PRE><P><A HREF="ch_type.html">  next</A> - <A HREF="ch_type.html">  skip</A> - <A HREF="refer.html">  up</A> - <A HREF="index.html">  start</A><P></BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -