Does anyone have a formula for calculating center & edge thicknesses that takes into account lens material, lens power, frame specs, PD, etc.?

I am really looking for some software to do this but if I could get an accurate formula I maybe able to create a spreadsheet or basic program to do the calculations.

Thanks!