Markov bases algorithm for ML in contingency tables