adds log to similarity score and changes tests. Also adds matrix