added a function that controls the incremental process of the dc sweep