Exception Classes¶
gsl_Error derived from Exception, can be constructed with any object as
parameter. It is baseclass to all other GSL Exceptions
These classes are translations of gsl/gsl_errno.h to python exceptions.
gsl_ArithmeticErrorderived fromExceptionandexceptions.ArithmeticError,base of all common arithmetic exceptions
gsl_OverflowError derived from gsl_Error and exceptions.OverflowError
gsl_ZeroDivisionError derived from gsl_Error and exceptions.ZeroDivisionError
gsl_FloatingPointError derived from gsl_Error and exceptions.FloatingPointError
gsl_ArithmeticError is derived from gsl_Error and from exceptions.ArithmeticError.
This exception is the base of all common arithmetic exceptions.
gsl_AccuracyLossError is derived from gsl_ArithmeticError. This exception is raised if the
algorithm failed to reach the specified tolerance.
gsl_BadFuncError is derived from gsl_Error. This exception is raised if problem
with a user-supplied function occur.
gsl_BadLength is derived from gsl_Error. This exception is raised if matrix or
vector lengths are not conformant.
gsl_BadToleranceError is derived from gsl_Error. This exception is raised if
user specified an tolerance which can not be reached.
gsl_CacheLimitError is derived from gsl_Error. This exception is raised if the
cache limit is exceeded.
gsl_DivergeError is derived from . This exception is raised if an
integral or series is divergent.
gsl_DomainError is derived from gsl_Error. This exception is raised if domain
errors occure. e.g. sqrt(-1).
gsl_EOFErroris derived fromgsl_Errorand fromEOFError.This exception is raised if end of file is reached.
gsl_FactorizationError is derived from gsl_Error. This exception is raised if
factorization failed.
gsl_FloatingPointError is derived from gsl_Error and from FloatingPointError.
gsl_GenericError is derived from gsl_Error.
gsl_InvalidArgumentError is derived from gsl_Error. This exception is raised if
an invalid argument is supplied by the user.
gsl_JacobianEvaluationError is derived from gsl_ArtithmetricError. This exception is raised
if jacobian evaluations are not improving the solution.
gsl_MatrixNotSquare is derived from gsl_Error. This exception is raised if the
given matrix is not square.
gsl_MaximumIterationError is derived from gsl_ArtithmetricError. This exception is raised if
the maximum number of iterations is exceeded.
gsl_NoHardwareSupportError is derived from gsl_Error. This exception is raised
if the requested feature is not supported by the hardware.
gsl_NoProgressError is derived from gsl_ArtithmetricError. This exception is raised if the
iteration is not making progress towards solution.
gsl_NotImplementedError is derived from and from . This exception is
raised if a requested feature is not (yet) implemented .
gsl_OverflowError is derived from gsl_Error and from OverflowError.
gsl_PointerError is derived from gsl_Error. This exception is raised if an
invalid pointer is found by the C wrapper code or by the GSL library.
gsl_RangeError is derived from gsl_ArtithmetricError. This exception is raised if output
would be out or range, e.g. exp(1e100) .
gsl_RoundOffError is derived from gsl_ArtithmetricError. This exception is raised if
arithmetic failed because of roundoff error.
gsl_RunAwayError is derived from gsl_ArtithmetricError. This exception is raised if
iterative process is out of control.
gsl_SanityCheckError is derived from gsl_Error. This exception is raised if a
sanity check failed - shouldn’t happen.
gsl_SingularityError is derived from gsl_ArtithmetricError. This exception is raised if an
apparent singularity is detected.
gsl_TableLimitError is derived from gsl_Error. This exception is raised if the
table limit is exceeded.
gsl_ToleranceError is derived from gsl_ArtithmetricError. This exception is raised if the
alghorithm failed to reach the specified tolerance.
gsl_ToleranceFError is derived from gsl_ArtithmetricError. This exception is raised if the
alghorithm cannot reach the specified tolerance in F (typically the
variation of the evaluated function).
gsl_ToleranceGradientError is derived from gsl_ArtithmetricError. This exception is raised
if cannot reach the specified tolerance for the gradient.
gsl_ToleranceXError is derived from gsl_ArtithmetricError. This exception is raised if
cannot reach the specified tolerance in X (typically a search result).
gsl_UnderflowError is derived from gsl_Error and from Overflowwerror.
gsl_ZeroDivisionError is derived from gsl_Error and from ZeroDivisionError.
All the above errors are just translations of the errno to python exceptions.
The following two are specific to pygsl:
pygsl.errors.pygsl_NotImplementedError is derived from and from . This
exception is raised if a feature is requested but not implemented.
Currently only used if a module requests the debugging enviroment of the
init module, but the init module was not compiled with
pygsl.errors.pygsl_StrideError is derived from . GSL uses as strides
multiples of the basis type; for a vector or doubles, one means from one
double to the next. Numpy or numarray count the stride in multiples of
the size of a char. Therefore the stride has to be recalculated before
the approbriate GSL function can be called. If that fails this exception
is raised.
Warning Classes¶
gsl_Warning The dedicated warning class for GSL has as base class.
gsl_DomainWarning derived from , used by some functions