Update doc and remove unused functions