Although the loss of function is practically rapid, there is no defined clinical death time at which the non-functioning brain obviously dies. The most sensitive cells in the brain, the CA1 neurons of the hippocampus, are killed by as little as 10 minutes of oxygen deprivation. The majority of cells in the brain are not particularly vulnerable to anoxia from lack of blood flow; instead it is the small number of extremely metabolically active cells called glial cells that die first. These include the astrocytes that form the supportive framework for the neurons and the microglia that survey the environment for invasion by foreign particles or infection by disease-causing organisms. Your brain continues functioning after you die because all of the cells remain alive for several days. During this time, they continue to consume nutrients and remove waste, just like when you were living. The only difference is that now they are doing these things without any connection to the outside world: there are no more signals coming in from your eyes saying "it's day" or "it's night", so the cells keep on working even when you're dead. After about three days, the remaining glial cells begin to degrade faster than they're being created, and within a few more days the tissue becomes saturated with toxic substances that can lead to further degradation. Finally, after about a week, there is very little more that can be done for the tissues beyond removing any visible remains.