The Tomita operator for the free scalar field