Background Modeling with Applications in Video Surveillance Systems