Skip to content

Instantly share code, notes, and snippets.

@y8
y8 / 2015-06-22
Last active August 29, 2015 14:23
Simple kalman filter for water well level ultrasonic sensor
00:00:00.50,244.97
00:00:00.142,244.90
00:00:00.234,245.03
00:00:00.327,244.21
00:00:00.419,245.10
00:00:00.512,244.76
00:00:00.604,245.10
00:00:00.696,245.03
00:00:00.789,244.55
00:00:00.881,244.62
@y8
y8 / kalman.rb
Created June 22, 2015 00:51
kalman.rb
require "matrix"
# Simple Kalman implementation, with one hidden variable: velocity.
# For very simple explanation see https://www.udacity.com/course/artificial-intelligence-for-robotics--cs373 (Lession 2)
class Kalman
attr_accessor :state
attr_accessor :process_noise
attr_reader :control
attr_accessor :model

Keybase proof

I hereby claim:

  • I am y8 on github.
  • I am y8 (https://keybase.io/y8) on keybase.
  • I have a public key whose fingerprint is 4631 D814 4663 5D31 343F 46AF D1CD A675 0B90 F131

To claim this, I am signing this object: