remove some unused files.
Updated method validate().
Updated.