Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidProcNoise = fmt.Errorf("invalid process noise arguments")
ErrInvalidProcNoise is returned when we can't compute process noise.
Functions ¶
This section is empty.
Types ¶
type Filter ¶
type Filter struct {
// contains filtered or unexported fields
}
Filter is a Kalman filter.
func NewFilter ¶
func NewFilter(d *ProcessNoise) (*Filter, error)
NewFilter creates and returns a new Kalman filter.
type GeoEstimated ¶
type GeoEstimated struct {
Lat, Lng, Altitude float64
Speed float64
Direction float64
HorizontalAccuracy float64
}
GeoEstimated contains estimated location, obtained by processing several observed locations.
type GeoFilter ¶
type GeoFilter struct {
// contains filtered or unexported fields
}
GeoFilter is a Kalman filter that deals with geographic coordinates and altitude.
func NewGeoFilter ¶
func NewGeoFilter(d *GeoProcessNoise) (*GeoFilter, error)
NewGeoFilter creates and returns a new GeoFilter.
func (*GeoFilter) Estimate ¶
func (g *GeoFilter) Estimate() *GeoEstimated
Estimate returns the best location estimate.
type GeoObserved ¶
type GeoObserved struct {
Lat, Lng, Altitude float64 // Geographical coordinates (in degrees) and latitude.
Speed float64 // Speed, in meters per second.
SpeedAccuracy float64 // Speed accuracy, in meters per second.
Direction float64 // Travel direction, in degrees from North, 0 to 360 range.
DirectionAccuracy float64 // Direction accuracy, in degrees.
HorizontalAccuracy float64 // Horizontal accuracy, in meters.
VerticalAccuracy float64 // Vertical accuracy, in meters.
}
GeoObserved represents a single observation, in geographical coordinates and altitude.
type GeoProcessNoise ¶
type GeoProcessNoise struct { // Base latitude to use for computing distances. BaseLat float64 // DistancePerSecond is the expected random walk distance per second. DistancePerSecond float64 // SpeedPerSecond is the expected speed per second change. SpeedPerSecond float64 }
GeoProcessNoise is used to initialize the process noise.
type Observed ¶
type Observed struct {
X, Y, Z float64 // Coordinates.
VX, VY, VZ float64 // Speed.
XA, YA, ZA float64 // Accuracy (coordinates).
VXA, VYA, VZA float64 // Accuracy (speed).
}
Observed represents a single observation.
type ProcessNoise ¶
type ProcessNoise struct {
SX, SY, SZ float64 // Random step (coordinates).
SVX, SVY, SVZ float64 // Random step (speed).
ST float64 // Random step (time).
}
ProcessNoise represents process noise.
Click to show internal directories.
Click to hide internal directories.