Tvm validation, fixed calculations, added tests