vnl_lsqr Class Reference

#include <vnl_lsqr.h>

List of all members.


Detailed Description

Linear least squares.

vnl_lsqr implements an algorithm for large, sparse linear systems and sparse, linear least squares. It is a wrapper for the LSQR algorithm of Paige and Saunders (ACM TOMS 583). The sparse system is encapsulated by a vnl_linear_system.

Definition at line 35 of file vnl_lsqr.h.


Public Member Functions

 vnl_lsqr (vnl_linear_system &ls)
 ~vnl_lsqr ()
void set_max_iterations (long max_iter)
int minimize (vnl_vector< double > &x)
 Perform the minimization starting from x=0 and putting the result into x.
long get_number_of_iterations () const
void diagnose_outcome (vcl_ostream &os) const
 Pontificate about the outcome of the last minimization.
double get_resid_norm_estimate () const
 Return the residual norm estimate:.
int return_code () const
 Get the return code for the last minimization.

Static Public Member Functions

static void translate_return_code (vcl_ostream &os, int return_code)

Static Protected Member Functions

static int aprod_ (long *mode, long *m, long *n, double *x, double *y, long *leniw, long *lenrw, long *iw, double *rw, void *userdata)

Protected Attributes

vnl_linear_systemls_
long max_iter_
long num_iter_
double resid_norm_estimate_
double result_norm_estimate_
double A_condition_estimate_
double result_norm_
long return_code_

Constructor & Destructor Documentation

vnl_lsqr::vnl_lsqr ( vnl_linear_system ls  )  [inline]

Definition at line 38 of file vnl_lsqr.h.

vnl_lsqr::~vnl_lsqr (  ) 

Definition at line 19 of file vnl_lsqr.cxx.


Member Function Documentation

void vnl_lsqr::set_max_iterations ( long  max_iter  )  [inline]

Definition at line 43 of file vnl_lsqr.h.

int vnl_lsqr::minimize ( vnl_vector< double > &  x  ) 

Perform the minimization starting from x=0 and putting the result into x.

Return code may be translated with translate_return_code(), or the result of the minimization may be printed in more detail with diagnose_outcome()

Definition at line 48 of file vnl_lsqr.cxx.

long vnl_lsqr::get_number_of_iterations (  )  const [inline]

Definition at line 50 of file vnl_lsqr.h.

void vnl_lsqr::diagnose_outcome ( vcl_ostream &  os  )  const

Pontificate about the outcome of the last minimization.

Definition at line 101 of file vnl_lsqr.cxx.

void vnl_lsqr::translate_return_code ( vcl_ostream &  os,
int  return_code 
) [static]

Definition at line 110 of file vnl_lsqr.cxx.

double vnl_lsqr::get_resid_norm_estimate (  )  const [inline]

Return the residual norm estimate:.

Definition at line 58 of file vnl_lsqr.h.

int vnl_lsqr::return_code (  )  const [inline]

Get the return code for the last minimization.

Definition at line 61 of file vnl_lsqr.h.

int vnl_lsqr::aprod_ ( long *  mode,
long *  m,
long *  n,
double *  x,
double *  y,
long *  leniw,
long *  lenrw,
long *  iw,
double *  rw,
void *  userdata 
) [static, protected]

Definition at line 24 of file vnl_lsqr.cxx.


Member Data Documentation

Definition at line 64 of file vnl_lsqr.h.

long vnl_lsqr::max_iter_ [protected]

Definition at line 65 of file vnl_lsqr.h.

long vnl_lsqr::num_iter_ [protected]

Definition at line 66 of file vnl_lsqr.h.

double vnl_lsqr::resid_norm_estimate_ [protected]

Definition at line 67 of file vnl_lsqr.h.

double vnl_lsqr::result_norm_estimate_ [protected]

Definition at line 68 of file vnl_lsqr.h.

double vnl_lsqr::A_condition_estimate_ [protected]

Definition at line 69 of file vnl_lsqr.h.

double vnl_lsqr::result_norm_ [protected]

Definition at line 70 of file vnl_lsqr.h.

long vnl_lsqr::return_code_ [protected]

Definition at line 71 of file vnl_lsqr.h.


The documentation for this class was generated from the following files:

Generated on Sun Nov 22 06:17:21 2009 for core/vnl by  doxygen 1.5.5