Sleep as the solution to an optimization problem ∗ Emmanuel Tannenbaum Department of Chemistry, Ben-Gurion University of the Negev, Be’er-Sheva 84105, Israel This paper develops a highly simplified model with which to analyze the phenomenon of sleep. MotivatedbyCrick’ssuggestionthatsleepisthebrain’swayof“takingoutthetrash,”asuggestion that is supported by emerging evidence, we consider the problem of the filling and emptying of a tank. Atanygiventime,thetankmaytakeinexternalresource,orfill,ifresourceisavailableatthat time, or it may empty. The filling phases correspond to information input from the environment, or input of some material in general, while the emptying phases correspond to processing of the resource. Given a resource-availablility profile over some time interval T, we develop a canonical 6 algorithm for determining the fill-empty profile that produces the maximum quantity of processed 0 resourceattheendofthetimeinterval. Fromthisalgorithm,itreadilyfollowsthatforaperiodically 0 oscillating resource-availability profile,theoptimalfill-emptystrategy isgivenbyafillperiod when 2 resource is available, followed by an empty period when resource is not. This cycling behavior is n analogoustothewake-sleepcyclesinorganismal life,wherethegenerallynocturnalsleepphaseisa a periodwheretheinformationcollectedfromtheday’sactivitiesmaybeprocessed. Thesleepcycleis J thenamechanism for theorganism toprocess amaximalamount ofinformation overadaily cycle. 8 Ourmodel can exhibit phenomena analogous to “microsleeps,” and other behavior associated with breakdown in sleep patterns. ] C Keywords: Sleep,separationoftasks,informationprocessing,optimization N o. I. INTRODUCTION the phenomenon of sleep include the build-up of lactic i acid during periods of intense muscular activity, and the b necessityforcorporations,orevenindividuals,toperiod- - Althoughsleepisexhibitedbyalmostallcomplexmul- q ically significantly reduce their level of external interac- ticellular life, it is still a largely poorly understood phe- [ tions and to update various inventories and finances. nomenon. The difficulty in understanding the necessity Based on Crick’s hypothesis, we argue that the phe- 1 of sleep derives from the observation that sleep-deprived v organismsdonotshowsignsofphysicaldamage,andyet nomenon of sleep occurs because, given alternating cy- 8 cles of available sensory input (day-night), a maximal they arecharacterizedby impairedcognitiveabilities. In 0 amountof informationprocessing occurs when the brain extreme cases, sleep deprivation can even lead to death. 0 devotes its resources to collecting information when it 1 A hypothesis for sleep, advanced by Francis Crick, is is available, and to then process that information when 0 that sleep is a way for the brain to perform various up- external information is significantly less available. 6 keep,oralternatively,“garbagecollecting”functionsnec- In this paper, we proceed to develop a model for the 0 essary for proper brain function [1]. More specifically, / filling and emptying of a tank. Filling the tank corre- o sleep is a time when the brain sorts through various sponds to the input of external information into a bio- i stored memories, and discards those deemed unessen- b logical system (a brain or even a single neuron), while - tial, while processing those deemed essential for long- emptying the tank corresponds to the processing of the q term storage. information. Foragivenresourceavailabilityprofileover : v There is now evidence suggesting thatCrick’s hypoth- some time period, we developa canonicalfill-empty pro- i X esis may be correct: It has been discovered that neu- file that we rigorously prove optimizes the total amount rons contain a protein, termed Fos, which is involved in ofresourceprocessed. We thengoontoconsiderspecific r a properneuronalfunction[1]. Duringperiods ofneuronal resource availability profiles and associated optimal so- stimulation, Fos naturally builds up, apparentlyas a by- lutions, and draw analogies between the optimal profiles product of various neuronal activities. Proper neuronal and observed behavior. functionisnolongerpossibleonceFoslevelsreachacrit- We point out that while mathematical models related ical level. During the sleep state of an organism, Fos to sleep have been previously developed [2, 3, 4, 5], such levelsrapidlydrop. Apparently,theFosproteinactsasa models have primarily focused on the dynamics associ- molecularswitchthatregulatesvariousgenesinvolvedin atedwith the underlying pathwayscontrollingthe wake- proper neuronal function [1]. During sleep, these genes sleep cycle. However, the need for such pathways have aresuppressed,allowingtheneurontore-setforthenext not been addressed. period of wakefulness. This paper presents a model in which an alternat- A number of appropriate analogies for understanding ing pattern of resource input and processing emerges as the solution to an optimization problem, which in the case of sleep presumably leads to a fitness advantage for the organism. To our knowledge, a mathematical model ∗Electronicaddress: [email protected] wherebysleepemergesasthesolutiontoanoptimization 2 problem has not been previously advanced. onthe resourceavailabilityprofile,it maybe optimalfor the system to only take in external resource when it is available, and then process that resource during periods II. SEPARATION OF TASKS AND when resource is significantly less available. OPTIMIZATION OF OUTPUT We note that for finite values of k and k , switch- T d ing from one task to another involves a transient during Before presenting the actual tank filling model in the which the proteins involved in one task degrade and the following section, we give an example illustrating how proteins for the other task reach their steady-state lev- separation of tasks can result in a higher level of infor- els. However, if kT,kd → ∞ in such a way that kT/kd mation processing than if various tasks are performed is fixed, then there is no time associated with switching simultaneously. tasks. In this case, we may assume, for simplicity, that So,considerasystemthatiscapableofengagingintwo only one task can be active at any given time, since a tasks: (1) An “input” task, whereby external resource is profile where both tasks are on over a time interval can input into the system. (2) A “processing”taks, whereby be approximated to arbitrary accuracy by a profile that the resource is processed for use by the system. rapidly oscillates between one task and the other. If we are dealing with a biological system, then we assumethatthefunctionofeachtaskismediatedbysome protein. For the “input” tasks, we denote the protein III. A TANK FILLING MODEL by P , while for the “processing” tasks, we denote the 1 relevantproteinbyP2. Now,P1 andP2 areencodedina A. Model description genome,withcorrespondinggenesdenotedbyG andG . 1 2 If we assume a total transcription plus translation rate Consider a tank that can be filled and emptied with of k , then when only one gene is active, the active gene T some unspecified material. At any given time t, external G producesproteinata ratek ,while when bothgenes i T resourceisavailable,oritisnot. We denote the resource are active, each protein is produced at a rate (1/2)k . T availability profile by a function δ(t), where δ(t) = 1 if We assumethat atleastone ofthe genes is activeatany resource is available at time t, and 0 if not. If δ(t) = given time. 1, then the tank may be filled at a rate r . The tank f Furthermore,weassumethattheproteinshaveadecay may also be emptied at a rate r as long as it is not e rategivenbyafirst-orderconstantk . Therefore,ifǫ (t) d 1 empty. Over any finite interval [t ,t ], we assume that 1 2 isdefinedtobe 0ifgeneG isoff,and1ifgeneG is on, 1 1 δ(t) is discontinuous at a finite number of points. This andǫ (t)isdefinedanalogouslyforgeneG ,then,letting 2 2 impliesthatδ(t)maybetakentobeapiecewiseconstant n , n denote the number of proteins in the system at P1 P2 function. a given time, we have, Atany giventime t, weassume thatthe tank is carry- ing out one of the fill or empty tasks, but that the tasks dn 1 dtP1 = 2(ǫ1(t)−ǫ2(t)+1)kT −kdnP1 cannot occur simulatenously. We let ǫf(t) denote the fill profile function, so that ǫ (t)=1 if the tank is in the fill f dn 1 dtP2 = 2(ǫ2(t)−ǫ1(t)+1)kT −kdnP2 (1) mnootdeethaetteimmpetty,panrodfiǫlef(ftu)n=cti0ono,thseorwthiaset.ǫW(te)l+etǫǫe((tt))=de1- f e at all times. As with δ(t), we assume ǫ (t), ǫ (t) are Now,ifweletδ(t)denotearesourceavailabilityprofile, f e piecewise constant, with a finite number of discontinu- defined to be 1 when external resource is available, and ities over a finite interval. 0 otherwise, then in the simplest assumption the rate at We also let n (t) denote the total amount of material which resource enters the system is proportional to n , T P1 inthe tankattimet,andn (t)denotethe totalamount and the rate at which resource is processed is propor- P of material that has been processed through the tank at tional to n . If n denotes the amount of unprocessed P2 1 time t. It should be apparent that, resourceatany giventime t, andn denotes the amount 2 of processed resource, then we have, dn T =r ǫ (t)δ(t)−r ǫ (t)(1−δ ) dn dt f f e e nT,0 1 dt =r1nP1δ(t)−r2nP2(1−δn1,0) dnP =r ǫ (t)(1−δ ) (3) dn dt e e nT,0 2 =r n (1−δ ) (2) dt 2 P2 n1,0 where δ =1 if n =0, and 0 otherwise. B. Optimal fill-empty profiles n1,0 1 Note then that if δ(t) experiences oscillatory periods ofresourceavailability,thenkeepingbothgenesonatall Givenaresourceavailabilityprofileδ(t)oversometime times may not leadto an optimalprocessing ofresource. interval[0,T],wewishtodeterminethefill-emptyprofile The reason for this is that when δ(t) = 1, resource only ǫ=(ǫ ,ǫ ) that maximizes n (T), given the initial con- f e P enters the system at half the maximal rate. Depending ditions n (0)=n (0)=0. As anotationalconvenience, T P 3 welet n (t), n (t)denote the n andn valuesasso- Since n (T) = r T (I ;ǫ ), then if we can show that ǫ,T ǫ,P T P ǫ0,P f f 1 0 ciated with the fill-empty profile ǫ. T (I ;ǫ )+ T (I ;ǫ)− T (I ;ǫ) ≥ 0, we will have es- e 1 0 e,1 1 e 1 A natural fill-empty profile, denoted ǫ = (ǫ ,ǫ ), tablished that n (T) ≤ n (T), thereby proving the 0 f,0 e,0 ǫ,P ǫ0,P is defined by the following prescription: Fill whenever maximality of ǫ . 0 δ(t)=1, empty whenever δ(t)= 0 as long as nT(t) >0. So,supposeTe(I1;ǫ0)+Te,1(I1;ǫ)−Te(I1;ǫ)<0. Then Continuewiththisfill-emptyprofileuntilnT(t)=re(T− defining I(t) = [0,t], we may note that the function t), at which point the tank should be emptied until time τ(t) ≡ T (I(t);ǫ )+T (I(t);ǫ)−T (I(t);ǫ) is contin- e 0 e,1 e T. Let tǫ0 denote the critical time at which emptying uous, and satisfies τ(0) = 0, τ(tǫ0) < 0. Let us then untiltimeT begins. Thenfornotationalconvenience,we define t∗ = inf{t ∈ [0,t ]|τ(t) < 0}. By continuity of ǫ0 define I1 =[0,tǫ0], I2 =[tǫ0,T]. τ and from the definition of inf, we have that t∗ < tǫ0, We now prove that ǫ yields a maximal value for τ(t∗)=0,andthatforanyt>t∗thereexistsat′ ∈(t∗,t) 0 nP(T). We begin by defining, for an arbitraryfill-empty such that τ(t′)<0. profileǫoversomesetS,thequantitiesTf(S;ǫ),Te(S;ǫ), Now, by assumption δ(t) is piecewise constant, hence Tw(S;ǫ), as follows: We define Sf = {t ∈ S|δ(t) = if δ is discontinuous at t∗, then there exists an interval 1 and ǫf(t) = 1, Se ={t ∈ S|nǫ,T(t) > 0 and ǫe(t)= 1}, (t∗,t∗+h)⊂I1overwhichδisconstant. Ifδiscontinuous and Sw = S/(Sf Se). If µ(Ω) denotes the measure at t∗, then there also exists an interval (t∗,t∗ +h) ⊂ I1 of a set Ω (essentiSally the total length of the set), then over which δ is constant. Tf(S;ǫ) ≡ µ(Sf), Te(S;ǫ) ≡ µ(Se), and Tw(S;ǫ) ≡ Suppose δ(t)=1 on (t∗,t∗+h). Then for any h′ <h, µ(Sw). We should point out that because δ, ǫf, ǫe are we have that Te(I(t∗ +h′);ǫ0) = Te(I(t∗);ǫ0), since the assumed to be piecewise constant, all sets considered in prescription for ǫ is to fill when δ(t) = 1 on I . We 0 1 this paper are unions of disjoint intervals, and hence are also have that T (I(t∗ + h′);ǫ) − T (I(t∗ + h′);ǫ) = e,1 e measurable. T (I(t∗);ǫ)−T (I(t∗);ǫ)+T ([t∗,t∗+h′];ǫ)−T ([t∗,t∗+ e,1 e e,1 e Given a set S, define S0 = {t ∈ S|δ(t) = 0}, and h′];ǫ). Since δ(t) = 1 on (t∗,t∗ + h′), it follows that S1 = {t ∈ S : δ(t) = 1}. Then define Te,0(S;ǫ) = µ(S0e), Te,1([t∗,t∗ +h′];ǫ) = Te([t∗,t∗ +h′];ǫ), and hence that and Te,1(S;ǫ)=µ(S1e). Note that Te(S;ǫ)=Te,0(S;ǫ)+ Te,1(I(t∗ + h′);ǫ) − Te(I(t∗ + h′);ǫ) = Te,1(I(t∗);ǫ) − Te,1(S;ǫ). Te(I(t∗);ǫ). Therefore, τ(t∗ + h′) = τ(t∗), so that Notethatsinceǫ0,f(t)=1wheneverδ(t)=1fort∈I1, τ(t) = 0 on [t∗,t∗ +h], contradicting the definition of it follows that Tf(I1;ǫ)≤Tf(I1;ǫ0)−Te,1(I1;ǫ). t∗. For any fill-empty profile ǫ, we have, So, suppose δ(t) = 0 on (t∗,t∗ +h). Then it should ∗ ∗ be clear that T (I(t);ǫ) is constant over (t ,t +h). If e,1 nǫ,T(T) = nǫ,T(tǫ0)+rfTf(I2;ǫ)−reTe(I2;ǫ) nǫ0,T(t∗) > 0, then according to our prescription there = rfTf(I1;ǫ)−reTe(I1;ǫ) existsanh′ ∈(0,h)suchthatǫe(t)=0withnǫ0,T(t)>0 ∗ ∗ ′ ′′ ′ +r T (I ;ǫ)−r T (I ;ǫ) (4) over (t ,t +h). Therefore, given h ∈ (0,h), we have f f 2 e e 2 ∗ ′′ ∗ ′′ ∗ T (I(t +h );ǫ ) = T (I(t );ǫ )+h , while T (I(t + e 0 e 0 e ′′ ∗ ∗ ∗ ′′ Since Tf(I2;ǫ)+Te(I2;ǫ)≤T −tǫ0, we have, h );ǫ) =∗ Te(′′I(t );ǫ)∗+Te′(′[t ,t +∗h∗];ǫ).′′ The resu∗lt is thatτ(t +h )=τ(t )+h −T ([t ,t +h ];ǫ)≥τ(t )= e ∗ ∗ ′ 0 ≤ n (T) 0. Therefore,τ(t)≥0on[t ,t +h],againcontradicting ǫ,T ∗ the definition of t . ≤ r (T (I ;ǫ )−T (I ;ǫ))−r T (I ;ǫ) f f 1 0 e,1 1 e e 1 ∗ ∗ So, suppose that δ(t) = 0 on (t ,t + h) with +rf(T −tǫ0 −Te(I2;ǫ))−reTe(I2;ǫ) (5) n (t∗)=0. Then, ǫ0,T which may be re-arrangedto give, ∗ ∗ ∗ n (t ) = r T (I(t );ǫ)−r T (I(t );ǫ) ǫ,T f f e e T (I ;ǫ) ≤ rfTf(I1;ǫ0)−reTe(I1;ǫ) ≤ rf(Tf(I(t∗);ǫ0)−Te,1(I(t∗);ǫ)) e 2 re −re(Te(I(t∗);ǫ0)+Te,1(I(t∗);ǫ)) rf ∗ ∗ − (T (I ;ǫ )+T (I ;ǫ)−T (I ;ǫ)) = n (t )−(r +r )T (I(t );ǫ) r +r e 1 0 e,1 1 e 1 ǫ0,T f e e,1 f e ∗ = −(r +r )T (I(t );ǫ) (8) f e e,1 (6) ∗ ∗ whichisonlypossibleifn (t )=0withT (I(t );ǫ)= where the derivation of this inequality makes use of the ∗ ǫ,T ∗ e,1 0. But,sincen (t )=n (t )=0,thensinceδ(t)=0 identity rfTf(I1;ǫ0)−reTe(I1;ǫ0)=re(T −tǫ0). on (t∗,t∗+h),ǫ,iTt followsǫt0h,Tat n (t) = n (t) = 0 on We then obtain that, ∗ ∗ ∗ ǫ∗,T ′ ǫ0,T ∗ ∗ (t ,t +h), and hence T ([t ,t +h];ǫ) = T ([t ,t + e,1 e ′ ∗ ∗ ′ ′ h];ǫ) = T ([t ,t + h];ǫ ) = 0 on for all h ∈ [0,h], n (T) = r (T (I ;ǫ)+T (I ;ǫ)) e 0 ǫ,P e e 1 e 2 ∗ so that τ(t) = τ(t ) = 0 on [t,t+h], which is again a ≤ r T (I ;ǫ ) f f 1 0 contradiction. r r − f e (T (I ;ǫ )+T (I ;ǫ) Sincewehaveexhaustedallpossibilites,wehaveestab- e 1 0 e,1 1 rf +re lishedthatτ(tǫ0)<0leadstoacontradiction. Therefore, −T (I ;ǫ)) (7) τ(t )≥0, and the proof is complete. e 1 ǫ0 4 We should note that, although the optimal fill-empty sleeping). When δ(t) = 0, any combination of filling, or profile ǫ may not necessarily be unique, if ǫ denotes emptyingwhenn =0,overthesetimeintervalswillnot 0 T any other optimal fill-empty profile, then we must have affectthe finalvalueofn (T). Thus,thereis aconsider- P T ([0,T];ǫ)=T ([0,T];ǫ ). Itmaybereadilyshownthat able degree of freedom in choosing an optimal fill-empty e e 0 n (T)=n (T)=0: profile, which is consistent with the observedbreakdown ǫ,T ǫ0,T An ǫ for which n (T)> 0 is not optimal, for letting in sleeping patterns in environments with limited expo- ǫ,T t denote when n (t) = r (T −t) (by the Intermedi- sure to the sun. ǫ ǫ,T e ate Value Theorem, such a t exists), we have n (T) = Nowconsider the casewhen r T <r T . Thenatthe ǫ,P e 2 f 1 n (t ) + r T ([t ,T];ǫ) ≤ n (t ) + r (T − t ), with end of every resource availability cycle [n(T +T ),(n+ ǫ,P ǫ e e ǫ ǫ,P ǫ e ǫ 1 2 equality only occurring when T ([t ,T];ǫ) = r (T −t ). 1)(T +T )],wehavethatn increasesbyr T −r T , e ǫ e ǫ 1 2 ǫ0,T f 1 e 2 However,T ([t ,T];ǫ)=r (T−t )impliesthatn (T)= as long as we are before the final emptying phase. So, if e ǫ e ǫ ǫ,T 0, and so our claim is proved. n is chosen so that n(r T −r T )≤r (T −n(T +T )) f 1 e 2 e 1 2 But this implies that r T ([0,T];ǫ)=r T ([0,T];ǫ)= but (n + 1)(r T − r T ) > r (T − (n + 1)(T + T )), f f e e f 1 e 2 e 1 2 r T ([0,T];ǫ ) = r T ([0,T];ǫ ), so that T ([0,T];ǫ) = then we have t ∈ [n(T +T ),(n+1)(T +T )], which e e 0 f f 0 f ǫ0 1 2 1 2 T ([0,T];ǫ ). Finally, T ([0,T];ǫ) = T −T ([0,T];ǫ)− further implies that t ∈ [n(T +T ),n(T +T )+T ]. f 0 w f ǫ0 1 2 1 2 1 T ([0,T];ǫ) = T − T ([0,T];ǫ ) − T ([0,T];ǫ ) = Therefore, n (t ) = n(r T −r T )+r (t −n(T + e f 0 e 0 ǫ,T ǫ0 f 1 e 2 f ǫ0 1 T ([0,T];ǫ ). T ))=r (T −t ). w 0 2 e ǫ0 Therefore,althoughthe optimalfill-empty profile may Solving for t , we obtain, ǫ0 not be unique, the T , T , and T values are uniquely f e w r e specified. tǫ0 =nT2+ r +r T (10) e f from which it follows that, C. Examples of optimal fill-empty profiles r e T ([0,T];ǫ )= T f 0 r +r For simplicity, we consider optimal fill-empty profiles e f r generatedbyaδ(t)thatisperiodicoverthetimeinterval T ([0,T];ǫ )= f T e 0 r +r [0,T]. Specifically, we consider a basic profile, denoted e f σ , defined by, T ([0,T];ǫ )=0 (11) (T1,T2) w 0 1 if t∈[0,T ] An interesting fill-empty profile that arises from this σ(T1,T2)(t)=(cid:26)0 if t∈(T1,T1+1 T2] condition is defined as follows: Over the interval [0,T], ǫ (t) = 1 whenever δ(t) = 0. Whenever δ(t) = 1, ǫ (t) e f Over the time interval [0,T], we then define δ(t) by set- and ǫe(t) alternate in being 1, with corresponding time ting δ(t)=σ(T1,T2)(t) on [0,T1+T2], and then imposing lengths tf, te. To determine these time lengths, we first the periodicity relation δ(t) = δ(t+T +T ). We also assume that there are M such cycles over each δ(t) = 1 1 2 assume that T = N(T1+T2), for some positive integer interval of length T1, so that tf +te = T1/M. The net N. accumulation in the tank over each such interval should Now, if reT2 ≥ rfT1, then it should be apparent that be reT2 =M(rftf −rete), which may be solved to give, an optimal fill-empty profile, defined by our ǫ prescrip- 0 1 r tion, is to fill whenever δ(t)=1, and to empty whenever t = e (T +T ) f 1 2 M r +r δ(t) = 0 and n (t) > 0, until time T. For this profile, f e ǫ,T then, we have that the optimal values of Tf, Te, and Tw t = 1 rfT1−reT2 (12) are given by, e M r +r f e T ([0,T];ǫ )=NT Note that r t > r t , and that T ([0,T];ǫ) = r /(r + f 0 1 f f e e e f e r r )T, so that this profile is indeed an optimal one. f f T ([0,T];ǫ )= NT e 0 r 1 Essentially, when the amount of time during which e r T −r T δ(t) = 0 is not sufficiently long to process all of the re- e 2 f 1 Tw([0,T];ǫ0)=N (9) source that can fill the tank, then one optimal solution r e profileis,duringperiodswhenδ(t)=1,tofillandempty and so any other optimal fill-empty profile must fill ex- thetankinalternatingtimeintervalsoflengtht ,t ,and f e actly when δ(t) = 1. Note that T only occurs in inter- thentoemptythetankwheneverδ(t)=0. Wearguethat w vals where δ(t) = 0 (since T ([0,T];ǫ ) = NT ). There- the t empty periods are analogous to the phenomenon f 0 1 e fore,duringtheseperiods,sincethereisalackofavailable of “microsleep” that occurs during sleep deprivation. resource(analogousto periodsofnightwhenmakingthe In general, we claim that any optimal solution profile analogy to sleep), the tank is either filling when there is forthisformofδ(t)willhaveǫ (t)=1wheneverδ(t)=0. e nothing to fill it with (analogous to wakefulness periods Otherwise, we obtain, r /(r + r )T = T ([0,T];ǫ) = f f e e duringlackofavailablesensoryinformation),orisempty- T ([0,T];ǫ)+ T ([0,T];ǫ) < NT + T ([0,T];ǫ) ⇒ e,0 e,1 2 e,1 ing when the tank is alreadyempty (analogousto excess T ([0,T];ǫ)>N(r T −r T )/(r +r ). e,1 f 1 e 2 f e 5 But this implies that T ([0,T];ǫ) ≤ NT − proved. f 1 T ([0,T];ǫ) < NT − N(r T − r T )/(r + r ) = As a final example for this subsection, we consider a e,1 1 f 1 e 2 f e r /(r +r )T ⇒⇐. Withthiscontradiction,ourclaimis resource availability profile given by, e e f σ (t) if t∈[0,T +T ] δ(t)= (T1,T2) 1 2 ′ (cid:26)σ(T1,T2′)(t+T1+T2) if t∈[T1+T2,T =2T1+T2+T2] ′ where r T < r T < r T . Then it is possible to show period when the resource may be processed. Intuitively, e 2 f 1 e 2 that, thismakessense,since,oncethebrainhas“takenoutthe trash,”furthersleepwillnotpreventtheaccumulationof r T ([0,T];ǫ )=T + e (T +T′) “trash” during a later cycle. f 0 1 r +r 1 2 e f r r f f ′ T ([0,T];ǫ )= T + (T +T ) e 0 r 1 r +r 1 2 e e f IV. CONCLUSIONS AND FUTURE RESEARCH r T −r T e 2 f 1 T ([0,T];ǫ )= (13) w 0 r e This paper presented a simplified model of the filling and emptying of a tank as an analogy with which to WenowshowthatthisuniquelydeterminesT ([0,T + f 1 analyze the phenomenon of sleep. Our model is moti- T ];ǫ ), T ([T +T ,T];ǫ ), T ([0,T +T ];ǫ ), T ([T + 2 0 f 1 2 0 e 1 2 0 e 1 vated by a hypothesis that sleep is the brain’s way of T ,T];ǫ ), T ([0,T +T ];ǫ ), T ([T +T ,T];ǫ ). 2 0 w 1 2 0 w 1 2 0 processing material accumulated during periods of sen- Note that T ([0,T];ǫ ) ≥ T ([0,T + T ];ǫ ) + f 0 f 1 2 0 sory input. By analogy with a corporation, which may rer+erf(T1+T2′) ⇒ Tf([T1+T2,T];ǫ0) ≥ rer+erf(T1+T2′). need to periodically update inventories and finances for Therefore, Te([T1 +T2,T];ǫ0) ≤ rer+frf(T1 +T2′). How- proper functioning, so too the brain may need to peri- ever, n (T) = 0 ≥ r T ([T +T ,T];ǫ )−r T ([T + odically cut-off external inputs and process accumulated ǫ0,T f f 1 2 0 e e 1 T ,T];ǫ ) ≥ rfre (T +T′) − r T ([T + T ,T];ǫ ) ⇒ material, in order to maintain updated information with 2 0 re+rf 1 2 e e 1 2 0 T ([T + T ,T];ǫ ) ≥ rf (T + T′), and so T ([T + which to properly analyze the environment. Te,T]1;ǫ ) 2= r0f (T re++rTf ′).1 Bu2t this impliees t1hat Based on our tank filling model, we were able to show TT22f,(T[T]1;ǫ+00)T=2,rTerr]+e;e+rǫf0rf)(T1≤1+Tre2′r+)e2.rfT(Th1is+fuTrt2′h),ersiompTlfie(s[Tt1ha+t tebhxeateptrrwnoahcleesnisneptdhuetirfse,inathfroeermaolpattetirimonnaatliisnagmcopollueerncitotedodsfwoinfhfaoevnramiiltaatbiisoilnaitvycaaioln-f T ([T +T ,T];ǫ )=0,andsothatT ([0,T +T ];ǫ )= able (during the day forthe vastmajorityoforganisms), w 1 2 0 w 1 2 0 reT2−rfT1. Finally, we obtain T ([0,T +T ];ǫ ) = T , and processed when it is not, or considerably less, avail- andrTe ([0,T +T ];ǫ )= rfT . f 1 2 0 1 able(atnight,again,forthevastmajorityoforganisms). e 1 2 0 re 1 We showed that when there are excessive periods where Summarizing the results, we have, resource is unavailable, then there is a continuum of op- timal fill-empty profiles, involving either filling when no T ([0,T +T ];ǫ )=T f 1 2 0 1 resourceis present,oremptying when the tank is empty. r e ′ T ([T +T ,T];ǫ )= (T +T )<T Thus, our model is consistent with the observed break- f 1 2 0 r +r 1 2 1 e f down in sleeping patterns in environments with minimal r T ([0,T +T ];ǫ )= fT exposure to the sun. e 1 2 0 1 r e Furthermore, we showed that when the periods of in- r T ([T +T ,T];ǫ )= f (T +T′)>T′ formation deficiency are not sufficiently long to process e 1 2 0 r +r 1 2 2 f e all of the collected information, an optimal information reT2−rfT1 collection strategy can involve periodic tank emptying T ([0,T +T ];ǫ )= w 1 2 0 r intervals during periods of information availability. We e T ([T +T ,T];ǫ )=0 (14) argued that this behavior is analogous to the observed w 1 2 0 phenomenon of “microsleeps.” Therefore, maximal processing of external resource still Ourmodelalsosuggeststhatitis notpossibletostore requires emptying the tank when δ(t) = 1 on the in- sleep time beyond a certain amount, so that periods of terval [T + T ,T]. In making the analogy with sleep, extended sleep will not prevent sleep deprivation at a 1 2 this implies that excess sleep in a certain time interval later time. Our model also captures the breakdown in will not prevent sleep deprivation in a later time inter- sleeping patterns val when the period of resource availability exceeds the Although our model is consistent with a number of 6 phenomenaassociatedwithsleep,itisneverthelesshighly gletank. Inreality,anorgansuchasthebrainconsistsof simplistic: Ourmodelassumesthatthetankcanbefilled billionsofinteractingneurons,andthusourmodelshould without limit, corresponding to an organismal ability to be extended to include interactions amongst numerous maintainunlimitedperiodsofwakefulness. Thisofcourse tanks. An important issue to consider is neuronal syn- isincorrect,becauseanover-accumulationofunprocessed chronization,wherebytheneuronsoscillatebetweentheir information will eventually lead to improper brain func- wakingandsleepmodestogether. Presumably,sinceitis tion. Therefore, one important modification that must advantageous for each component of a system to switch be made toourmodelis toplaceanupper boundonn , between input and processing tasks in accordance with T denoted n , so that the fill-empty profile must be external resource availability, and since system perfor- T,max such that n (t)≤n at all times. manceisoptimizedwhenallcomponentscoordinatetheir ǫ,T T,max Furthermore, our model also assumes that there is no actions,thestrategywherebyallsystemcomponentscol- time delay associated with switching tasks (from fill to lectively switch between input and processing tasks in empty and vice versa). In reality, when task switching accordance with external resource availability is a self- occurs,therearegenerallytransientsassociatedwiththe reinforcing one. time it takesforthe components forperformingone task toshut-down,andforanothersetofcomponentsforper- As a final remark, because sleep arises as the need for formingthe othertaskto startup. Thesetransientslead the brain to perform upkeep tasks that accumulate over to a time cost τ during which neither system is ac- a period of sensory input, mathematical models related switch tive, and so future models will need to consider posi- tosleepcouldalsobeusefulforanalyzingotherintercon- tivevaluesofτ whendeterminingoptimalfill-empty nected structures where a proper ordering of tasks could switch profiles. leadtooptimalsystemperformance. Inparticular,mod- In addition, pursuing the analogy with a corporation, elsofsleepcouldbeusefulinunderstandingsystemsthat we may note that althoughinventoriesand finances may exhibit oscillatory periods of relatively intense apparent be updated at regular intervals, it may nevertheless be activity(asexhibitedbyabsorptionofinformationorma- anoptimalstrategyto alsoperformsomelevelofupkeep terial into the system), followed by periods of apparent duringperiodsofexternalinput. Alowerlevelofupkeep stasis. could have shorter associated transients, and by lessen- Acknowledgments ing the rate of accumulation of material, will allow for a greater overall input of external resource before system- wide upkeep becomes necessary. This research was supported by the Israel Science Ourmodelconsideredthefillingandemptyingofasin- Foundation. [1] http://www.med.harvard.edu/publications/On The Brain/Volum5e858/-N59u7m(b1e9r939/)S.leep.html [2] A.A. Borbely and P. Achermann, J. Sleep Res. 1, 63-79 [5] S.H. Strogatz, The Mathematical Structure of the Hu- (1992). manSleep-WakeCycle(LectureNotesinBiomathematics) [3] A.A. Borbely and P. Achermann, J. Biol. Rhythms 14, (Springer-Verlag, New York,NY,1986). 557-568 (1999). [4] M.E. Jewett and R.E. Kronauer, J. Biol. Rhythms 14,