abs_functor< X >

Description

Computes the modulus (absolute value or magnitude). This functor is used to implement abs().

The added value of the abs_functor is that it can be extended to any value-type that one might want to use in glas.

Example

Definition

Defined in abs.hpp

Template parameters

ParameterDescriptionDefault
Xtype of abs_functor's argument.

Model of

AdaptableUnaryFunction

Type requirements

X can be

Public base classes

Members

MemberWhere definedComment
argument_type AdaptableUnaryFunction
result_type AdaptableUnaryFunction
result_type operator() (const X& a) const UnaryFunction