Depreciation functions available in Google Sheets with examples
As a practical expedient, book (not tax) depreciation is typically calculated on the straight line basis. This involves a relatively simple calculation which outputs an expense amount for each period which can be days, months, quarters, etc.
If you had a company policy of computer equipment having a useful life of three years, the calculation would be to divide the acquisition cost by 36 months and multiply the result by the number of months in the period.
Some fixed assets may lose their value at a faster rate in the beginning of their life and a slower rate towards the end. This pattern can be shown with an accelerated method such as declining balance, double declining balance, or sum of the years digits.