How to calculate ideal Decision Tree depth without overfitting?
No! the best score on validation set means you are not in overfitting zone. As explained in my previous answer to your question, overfitting is about high score on training data but low score on validation. So to avoid overfitting you need to check your score on Validation Set and then you are fine. There is no theoretical calculation of the best depth of a decision tree to the best of my knowledge.

So here is what you do: 


Choose a number of tree depths to start a for loop (try to cover whole area so try small ones and very big ones as well)
Inside a for loop divide your dataset to train/validation (e.g. 70%/30%)
Each time train your decision tree with that depth on training data and test it on the validation set, then keep the validation error (you can also keep the training error)
Plot the validation error (you can combine it with evolution of training error to have a prettier plot for understanding!) 
Find the global minimum of validation error.
Then you can narrow your search in a new for loop according to the value you found to reach a more precise value