<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html><head><meta name="robots" content="noindex"> <meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> <title>matrix_i.h Source File</title> <link href="doxygen.css" rel="stylesheet" type="text/css"> </head><body bgcolor="#ffffff"> <!-- Generated by Doxygen 1.2.5 on Mon Oct 14 14:16:37 2002 --> <center> <a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="pages.html">Related Pages</a> </center> <hr><h1>matrix_i.h</h1><div class="fragment"><pre>00001 <font class="comment">//</font> 00002 <font class="comment">// matrix_i.h</font> 00003 <font class="comment">//</font> 00004 <font class="comment">// Copyright (C) 1996 Limit Point Systems, Inc.</font> 00005 <font class="comment">//</font> 00006 <font class="comment">// Author: Curtis Janssen <cljanss@limitpt.com></font> 00007 <font class="comment">// Maintainer: LPS</font> 00008 <font class="comment">//</font> 00009 <font class="comment">// This file is part of the SC Toolkit.</font> 00010 <font class="comment">//</font> 00011 <font class="comment">// The SC Toolkit is free software; you can redistribute it and/or modify</font> 00012 <font class="comment">// it under the terms of the GNU Library General Public License as published by</font> 00013 <font class="comment">// the Free Software Foundation; either version 2, or (at your option)</font> 00014 <font class="comment">// any later version.</font> 00015 <font class="comment">//</font> 00016 <font class="comment">// The SC Toolkit is distributed in the hope that it will be useful,</font> 00017 <font class="comment">// but WITHOUT ANY WARRANTY; without even the implied warranty of</font> 00018 <font class="comment">// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</font> 00019 <font class="comment">// GNU Library General Public License for more details.</font> 00020 <font class="comment">//</font> 00021 <font class="comment">// You should have received a copy of the GNU Library General Public License</font> 00022 <font class="comment">// along with the SC Toolkit; see the file COPYING.LIB. If not, write to</font> 00023 <font class="comment">// the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.</font> 00024 <font class="comment">//</font> 00025 <font class="comment">// The U.S. Government is granted a limited license as per AL 91-7.</font> 00026 <font class="comment">//</font> 00027 00028 <font class="preprocessor">#ifndef _math_scmat_matrix_i_h</font> 00029 <font class="preprocessor"></font><font class="preprocessor">#define _math_scmat_matrix_i_h</font> 00030 <font class="preprocessor"></font><font class="preprocessor">#ifdef __GNUC__</font> 00031 <font class="preprocessor"></font><font class="preprocessor">#pragma interface</font> 00032 <font class="preprocessor"></font><font class="preprocessor">#endif</font> 00033 <font class="preprocessor"></font> 00034 <font class="preprocessor">#include <math/scmat/matrix.h></font> 00035 00036 <font class="comment">// These are the inline candidates for the members defined in matrix.h.</font> 00037 00038 <font class="preprocessor">#ifdef INLINE_FUNCTIONS</font> 00039 <font class="preprocessor"></font><font class="preprocessor">#define INLINE inline</font> 00040 <font class="preprocessor"></font><font class="preprocessor">#else</font> 00041 <font class="preprocessor"></font><font class="preprocessor">#define INLINE</font> 00042 <font class="preprocessor"></font><font class="preprocessor">#endif</font> 00043 <font class="preprocessor"></font> 00044 <font class="keyword">namespace </font>sc { 00045 00046 <font class="comment">// /////////////////////////////////////////////////////////////////////////</font> 00047 <font class="comment">// SCMatrixdouble inline candidates</font> 00048 00049 INLINE 00050 SCMatrixdouble::SCMatrixdouble(SCMatrix*a,<font class="keywordtype">int</font> b,<font class="keywordtype">int</font> c): 00051 matrix(a),i(b),j(c) 00052 { 00053 } 00054 INLINE 00055 SCMatrixdouble::~SCMatrixdouble()<font class="keyword"></font> 00056 <font class="keyword"></font>{ 00057 } 00058 INLINE <font class="keywordtype">double</font> 00059 SCMatrixdouble::operator=(<font class="keywordtype">double</font> a)<font class="keyword"></font> 00060 <font class="keyword"></font>{ 00061 matrix.set_element(i,j,a); 00062 <font class="keywordflow">return</font> a; 00063 } 00064 INLINE <font class="keywordtype">double</font> 00065 SCMatrixdouble::operator=(<font class="keyword">const</font> SCMatrixdouble& md)<font class="keyword"></font> 00066 <font class="keyword"></font>{ 00067 <font class="keywordtype">double</font> a = md.val(); 00068 matrix.set_element(i,j,a); 00069 <font class="keywordflow">return</font> a; 00070 } 00071 INLINE 00072 SCMatrixdouble::operator double()<font class="keyword"></font> 00073 <font class="keyword"></font>{ 00074 <font class="keywordflow">return</font> matrix.get_element(i,j); 00075 } 00076 INLINE <font class="keywordtype">double</font> 00077 SCMatrixdouble::val()<font class="keyword"> const</font> 00078 <font class="keyword"></font>{ 00079 <font class="keywordflow">return</font> matrix.get_element(i,j); 00080 } 00081 00082 <font class="comment">// /////////////////////////////////////////////////////////////////////////</font> 00083 <font class="comment">// SymmSCMatrixdouble inline candidates</font> 00084 00085 INLINE 00086 SymmSCMatrixdouble::SymmSCMatrixdouble(SymmSCMatrix*a,<font class="keywordtype">int</font> b,<font class="keywordtype">int</font> c): 00087 matrix(a),i(b),j(c) 00088 { 00089 } 00090 INLINE 00091 SymmSCMatrixdouble::~SymmSCMatrixdouble()<font class="keyword"></font> 00092 <font class="keyword"></font>{ 00093 } 00094 INLINE <font class="keywordtype">double</font> 00095 SymmSCMatrixdouble::operator=(<font class="keywordtype">double</font> a)<font class="keyword"></font> 00096 <font class="keyword"></font>{ 00097 matrix.set_element(i,j,a); 00098 <font class="keywordflow">return</font> a; 00099 } 00100 INLINE <font class="keywordtype">double</font> 00101 SymmSCMatrixdouble::operator=(<font class="keyword">const</font> SymmSCMatrixdouble& md)<font class="keyword"></font> 00102 <font class="keyword"></font>{ 00103 <font class="keywordtype">double</font> a = md.val(); 00104 matrix.set_element(i,j,a); 00105 <font class="keywordflow">return</font> a; 00106 } 00107 INLINE 00108 SymmSCMatrixdouble::operator double()<font class="keyword"></font> 00109 <font class="keyword"></font>{ 00110 <font class="keywordflow">return</font> matrix.get_element(i,j); 00111 } 00112 INLINE <font class="keywordtype">double</font> 00113 SymmSCMatrixdouble::val()<font class="keyword"> const</font> 00114 <font class="keyword"></font>{ 00115 <font class="keywordflow">return</font> matrix.get_element(i,j); 00116 } 00117 00118 <font class="comment">// /////////////////////////////////////////////////////////////////////////</font> 00119 <font class="comment">// DiagSCMatrixdouble inline candidates</font> 00120 00121 INLINE 00122 DiagSCMatrixdouble::DiagSCMatrixdouble(DiagSCMatrix*a,<font class="keywordtype">int</font> b,<font class="keywordtype">int</font> c): 00123 matrix(a),i(b),j(c) 00124 { 00125 } 00126 INLINE 00127 DiagSCMatrixdouble::~DiagSCMatrixdouble()<font class="keyword"></font> 00128 <font class="keyword"></font>{ 00129 } 00130 INLINE <font class="keywordtype">double</font> 00131 DiagSCMatrixdouble::operator=(<font class="keywordtype">double</font> a)<font class="keyword"></font> 00132 <font class="keyword"></font>{ 00133 matrix.set_element(i,a); 00134 <font class="keywordflow">return</font> a; 00135 } 00136 INLINE <font class="keywordtype">double</font> 00137 DiagSCMatrixdouble::operator=(<font class="keyword">const</font> DiagSCMatrixdouble& md)<font class="keyword"></font> 00138 <font class="keyword"></font>{ 00139 <font class="keywordtype">double</font> a = md.val(); 00140 matrix.set_element(i,a); 00141 <font class="keywordflow">return</font> a; 00142 } 00143 INLINE 00144 DiagSCMatrixdouble::operator double()<font class="keyword"></font> 00145 <font class="keyword"></font>{ 00146 <font class="keywordflow">return</font> matrix.get_element(i); 00147 } 00148 INLINE <font class="keywordtype">double</font> 00149 DiagSCMatrixdouble::val()<font class="keyword"> const</font> 00150 <font class="keyword"></font>{ 00151 <font class="keywordflow">return</font> matrix.get_element(i); 00152 } 00153 00154 <font class="comment">// /////////////////////////////////////////////////////////////////////////</font> 00155 <font class="comment">// SCVectordouble inline candidates</font> 00156 00157 INLINE 00158 SCVectordouble::SCVectordouble(SCVector*a,<font class="keywordtype">int</font> b): 00159 vector(a),i(b) 00160 { 00161 } 00162 INLINE 00163 SCVectordouble::~SCVectordouble()<font class="keyword"></font> 00164 <font class="keyword"></font>{ 00165 } 00166 INLINE <font class="keywordtype">double</font> 00167 SCVectordouble::operator=(<font class="keywordtype">double</font> a)<font class="keyword"></font> 00168 <font class="keyword"></font>{ 00169 vector.set_element(i,a); 00170 <font class="keywordflow">return</font> a; 00171 } 00172 INLINE <font class="keywordtype">double</font> 00173 SCVectordouble::operator=(<font class="keyword">const</font> SCVectordouble& vd)<font class="keyword"></font> 00174 <font class="keyword"></font>{ 00175 <font class="keywordtype">double</font> a = vd.val(); 00176 vector.set_element(i,a); 00177 <font class="keywordflow">return</font> a; 00178 } 00179 INLINE 00180 SCVectordouble::operator double()<font class="keyword"></font> 00181 <font class="keyword"></font>{ 00182 <font class="keywordflow">return</font> vector.get_element(i); 00183 } 00184 INLINE <font class="keywordtype">double</font> 00185 SCVectordouble::val()<font class="keyword"> const</font> 00186 <font class="keyword"></font>{ 00187 <font class="keywordflow">return</font> vector.get_element(i); 00188 } 00189 00190 } 00191 00192 <font class="preprocessor">#undef INLINE</font> 00193 <font class="preprocessor"></font> 00194 <font class="preprocessor">#endif</font> 00195 <font class="preprocessor"></font> 00196 <font class="comment">// Local Variables:</font> 00197 <font class="comment">// mode: c++</font> 00198 <font class="comment">// c-file-style: "CLJ"</font> 00199 <font class="comment">// End:</font> </div></pre><hr> <address> <small> Generated at Mon Oct 14 14:16:37 2002 for <a href="http://aros.ca.sandia.gov/~cljanss/mpqc">MPQC</a> 2.1.2 using the documentation package <a href="http://www.stack.nl/~dimitri/doxygen/index.html">Doxygen</a> 1.2.5. </small> </address> </body> </html>