Implementation of a self-organizing map