Changeset 1172
- Timestamp:
- Feb 27, 2008, 3:32:15 PM (16 years ago)
- Location:
- trunk/yat/utility
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/yat/utility/Matrix.cc
r1147 r1172 320 320 delete_allocated_memory(); 321 321 322 m_ = gsl_matrix_alloc(r,c); 323 if (!m_) 324 throw utility::GSL_error("Matrix::Matrix failed to allocate memory"); 325 all(init_value); 322 assert( (r&&c) || (!r&&!c) ); 323 if (r && c){ 324 m_ = gsl_matrix_alloc(r,c); 325 if (!m_) 326 throw utility::GSL_error("Matrix::Matrix failed to allocate memory"); 327 all(init_value); 328 } 326 329 327 330 // no need to delete blas_result_ if the number of rows fit, it -
trunk/yat/utility/Vector.cc
r1147 r1172 220 220 { 221 221 delete_allocated_memory(); 222 if (!n) 223 return; 222 224 const_vec_ = vec_ = gsl_vector_alloc(n); 223 225 if (!vec_)
Note: See TracChangeset
for help on using the changeset viewer.