delays

package
v0.0.0-...-a06e19b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 3, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NegativeExponential

type NegativeExponential struct {
	// contains filtered or unexported fields
}

NOTE: d(x) = a + b * exp(-steep * x)

func NewNegativeExponential

func NewNegativeExponential(min, max, steep float64) (*NegativeExponential, error)

NOTE: Bigger steep leads to faster descent

func (*NegativeExponential) Calc

func (ne *NegativeExponential) Calc(x float64) float64

func (*NegativeExponential) Invert

func (ne *NegativeExponential) Invert(y float64) float64

type SmoothNormalizedFn

type SmoothNormalizedFn interface {
	Calc(t float64) float64
	Invert(y float64) float64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL