Temperature and density determination in heavy ion reactions at intermediate energies