A model for the hysteresis of shape memory wires under repeated loading cycles