When you are using things like sys.database_files it gives size of the file, in 8-KB pages, while many other things you are comparing to it to are in MB.
There are a number of ways to convert the 8-KB pages to MB, several ways are offered in the answers to Query to report disk space allocation and used space
The two most common are
- Multiple by 8 and divide by 1024 (128000 * 8 / 1024 = 100)
- Divide by 128 (128000 / 128 = 100)
The second is simpler, requiring only a single operation. But both seem to give the same answer.
Is there a good reason to choose one method over the other?