Remove some dead codes and some useless print
Fix the wrap of doubles
Improve tests + create the references