The calculation is really trial & error.
The first step is to determine the tank's pressure and vacuum rating.
Second step is to assume a pipe diameter.
As an example, if the pressure rating is 10" h20 and assume 2" pipe.
The friction loss through the 2" swan neck would need to be less than 10" h20 at 200m3/hr flow.
If the fricion loss is too high, redo the calculation for larger pipe.
Similar logic for the vacuum side.
JStephens is correct -- use a calibtaed device if you need to follow API-2000 standards.
Years ago, Groth used to sell calibrated Swan neck vents
but today I do not know where to purchase similar hardware.
Otherwise Note that OSHA requires a 100% safety factor be applied for uncalibrated venting devices.
So the calculation would need to be at 400m3/hr flow to satisfy OSHA.
Additionally, most swan necks I have seen have bug screens which typically reduce the flow area to 2/3 of base pipe area.
I typically add one pipe diameter if a bug screen is used.
Normal filling and pumpout is typically small flows compared to other ways to overpressure a tank.
Consider also nitrogen pad requlator failure.
Consider also the maintenance practice of clearing connecting pipe by air blowing.
A 3/4" air hose 10-ft long with wide open block valve can generate alot of pressure which must be vented.