improved some patterns