Inheritance diagram for ipc::BarrierBase:
Base class for barrier functions.
Subclassed by ipc::ClampedLogBarrier< T >, ipc::ClampedLogSqBarrier< T >, ipc::CubicBarrier< T >, ipc::InversePowerBarrier< T >, ipc::NearFarBarrier< T >, ipc::TwoStageBarrier< T >
Public Functions
-
BarrierBase() = default;
-
virtual ~BarrierBase() = default;
-
virtual T operator()(const T d, const T dhat) const = 0;
Evaluate the barrier function.
- Parameters:
- const T d
Distance.
- const T dhat
Activation distance of the barrier.
- Returns:
The value of the barrier function at d.
-
virtual T first_derivative(const T d, const T dhat) const = 0;
Evaluate the first derivative of the barrier function wrt d.
- Parameters:
- const T d
Distance.
- const T dhat
Activation distance of the barrier.
- Returns:
The value of the first derivative of the barrier function at d.
-
virtual T second_derivative(const T d, const T dhat) const = 0;
Evaluate the second derivative of the barrier function wrt d.
- Parameters:
- const T d
Distance.
- const T dhat
Activation distance of the barrier.
- Returns:
The value of the second derivative of the barrier function at d.
-
virtual T units(const T dhat) const = 0;
Get the units of the barrier function.
Essentially, barrier(d, d̂) / units(d̂) should be dimensionless.
- Parameters:
- const T dhat
The activation distance of the barrier.
- Returns:
The units of the barrier function.
Protected Types
-
using value_type = T;