barrierPenalty
R2026bLogarithmic barrier penalty value for a point with respect to a bounded region
Description
calculates the nonnegative (logarithmic barrier) penalty vector p = barrierPenalty(x,xmin,xmax)p for
the point x with respect to the region bounded by
xmin and xmax. p has the
same dimension as x. This syntax uses the default values of
1 and 0.1 for the maxValue and
curvature parameters of the barrier function, respectively.
Examples
Input Arguments
Output Arguments
Extended Capabilities
Version History
Introduced in R2021b
![Logarithmic barrier penalty values plotted over the interval from -5 to 5, showing near-zero penalty within the bounded region [-2, 2] and a sharp rise to the maximum value at the boundaries](../../examples/rl/CalculateLogarithmicBarrierPenaltyForAPointExample_01.png)