Please download the Fire PSV Sizing Calculation Spreadsheet using following link.
DOWNLOAD EXCEL SPREADSHEET
Calculation: According API-RP-521
Validation Example: Crosby Engineering Handbook, Page 7-22, Example1
I am still working to improve this spreadsheet but it is a good starting point. You can get further detailes on calculation and validation in Crosby Engineering Handbook.