Formualizer Docs

DB

Returns fixed-declining-balance depreciation for a specified period.

DB computes per-period depreciation using a declining-balance rate and an optional first-year month proration.

The Formualizer engine in this repository at 0.15.0 plus unreleased changes computes the example results. Known differences from Excel are listed on this page.

Syntax

=DB(cost, salvage, life, period, [month])

Arguments

ArgumentTypeRequiredDefault
costnumberRequired—
salvagenumberRequired—
lifenumberRequired—
periodnumberRequired—
monthnumberOptional—

Remarks

  • Parameters: cost, salvage, life, period, and optional month (default 12).
  • life and period are truncated to integers for period checks and iteration.
  • The declining rate is rounded to three decimals; if cost <= 0 or salvage <= 0, this implementation uses a rate of 1.0.
  • Returned value is the period depreciation amount (generally positive expense, but sign follows provided inputs).

Error cases

  • month must be in 1..=12; life and period must be positive; invalid values return #NUM!.

Examples

Apply the fixed declining-balance rate in the second year after a full first year.

Formula =DB(1000,100,5,2)

Expected result 232.839

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Recalculate the second-year depreciation when the first year has only one month.

Formula =DB(1000,100,5,2,1)

Expected result 357.65325

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Apply the fixed rate to the original cost in year one.

Formula =DB(1000,100,5,1)

Expected result 369

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Year zero precedes the depreciation schedule.

Formula =DB(1000,100,5,0)

Expected result #NUM!

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

First full-year DB period

Formula =DB(10000, 1000, 5, 1)

Expected result 3690

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Fractional period input is truncated

Formula =DB(10000, 1000, 5, 2.9)

Expected result 2328.39

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

FAQ

How is month used in DB?

month prorates the first-year depreciation; if omitted it defaults to 12.

Why can fractional period inputs behave like integers?

DB truncates life and period to integers for iteration and period bounds.

Implementation

Engine source

On this page