fix a bug and add multiply test