Skip to main content
`Ctrl`+`K`

# BrokenPowerLaw1D

class astropy.modeling.powerlaws.BrokenPowerLaw1D(amplitude=1, x_break=1, alpha_1=1, alpha_2=1, **kwargs)

  Bases: `Fittable1DModel`

  One dimensional power law model with a break.

  Parameters:
    amplitude `python:float`

      Model amplitude at the break point.

    x_break `python:float`

      Break point.

    alpha_1 `python:float`

      Power law index for x < x_break.

    alpha_2 `python:float`

      Power law index for x > x_break.

  See also

  `PowerLaw1D`, `ExponentialCutoffPowerLaw1D`, `LogParabola1D`

  Notes

  Model formula (with \(A\) for `amplitude` and \(\alpha_1\) for `alpha_1` and \(\alpha_2\) for `alpha_2`):

  > \[\begin{split}f(x) = \left \{ \begin{array}{ll} A (x / x_{break}) ^ {-\alpha_1} & : x < x_{break} \\ A (x / x_{break}) ^ {-\alpha_2} & : x > x_{break} \\ \end{array} \right.\end{split}\]

  Attributes Summary

  `alpha_1` |
  `alpha_2` |
  `amplitude` |
  `input_units` | This property is used to indicate what units or sets of units the evaluate method expects, and returns a dictionary mapping inputs to units (or `None` if any units are accepted).
  `param_names` | Names of the parameters that describe models of this type.
  `x_break` |

  Methods Summary

  `evaluate`(x, amplitude, x_break, alpha_1, alpha_2) | One dimensional broken power law model function.
  `fit_deriv`(x, amplitude, x_break, alpha_1, ...) | One dimensional broken power law derivative with respect to parameters.

  Attributes Documentation

  alpha_1 = Parameter('alpha_1', value=1.0)
  alpha_2 = Parameter('alpha_2', value=1.0)
  amplitude = Parameter('amplitude', value=1.0)
  input_units
  param_names = ('amplitude', 'x_break', 'alpha_1', 'alpha_2')

    Names of the parameters that describe models of this type.

    The parameters in this tuple are in the same order they should be passed in when initializing a model of a specific type. Some types of models, such as polynomial models, have a different number of parameters depending on some other property of the model, such as the degree.

    When defining a custom model class the value of this attribute is automatically set by the `Parameter` attributes defined in the class body.

  x_break = Parameter('x_break', value=1.0)

  Methods Documentation

  static evaluate(x, amplitude, x_break, alpha_1, alpha_2)

    One dimensional broken power law model function.

  static fit_deriv(x, amplitude, x_break, alpha_1, alpha_2)

    One dimensional broken power law derivative with respect to parameters.