Added matrix parsing.