Fifty patients undergoing unilateral TKA will be randomly assigned to receive 4 sessions, total of 80 minutes of real (n=25) or sham tDCS (n=25). Stimulation will be given on 4 consecutive postoperative days, group 1 will receive real stimulation with the active electrode over the leg representation of the motor strip (cortical motor area of the leg) and the reference electrode over the arm, group 2 will receive Sham tDCS.