Drosophila Adult Olfactory Shock Learning

1Physiology and Pharmacology, University of Bristol
Published 8/07/2014


The method to measure adult Drosophila associative memory is described. The assay is based on the ability of the fly to associate an odor presented with a negative reinforcer (electric shock) and then recall this information at a later time, allowing memory to be measured.

Cite this Article

Copy Citation

Malik, B. R., Hodge, J. J. Drosophila Adult Olfactory Shock Learning. J. Vis. Exp. (90), e50107, doi:10.3791/50107 (2014).


Drosophila have been used in classical conditioning experiments for over 40 years, thus greatly facilitating our understanding of memory, including the elucidation of the molecular mechanisms involved in cognitive diseases1-7. Learning and memory can be assayed in larvae to study the effect of neurodevelopmental genes8-10 and in flies to measure the contribution of adult plasticity genes1-7. Furthermore, the short lifespan of Drosophila facilitates the analysis of genes mediating age-related memory impairment5,11-13. The availability of many inducible promoters that subdivide the Drosophila nervous system makes it possible to determine when and where a gene of interest is required for normal memory as well as relay of different aspects of the reinforcement signal3,4,14,16.

Studying memory in adult Drosophila allows for a detailed analysis of the behavior and circuitry involved and a measurement of long-term memory15-17. The length of the adult stage accommodates longer-term genetic, behavioral, dietary and pharmacological manipulations of memory, in addition to determining the effect of aging and neurodegenerative disease on memory3-6,11-13,15-21.

Classical conditioning is induced by the simultaneous presentation of a neutral odor cue (conditioned stimulus, CS+) and a reinforcement stimulus, e.g., an electric shock or sucrose, (unconditioned stimulus, US), that become associated with one another by the animal1,16. A second conditioned stimulus (CS-) is subsequently presented without the US. During the testing phase, Drosophila are simultaneously presented with CS+ and CS- odors. After the Drosophila are provided time to choose between the odors, the distribution of the animals is recorded. This procedure allows associative aversive or appetitive conditioning to be reliably measured without a bias introduced by the innate preference for either of the conditioned stimuli. Various control experiments are also performed to test whether all genotypes respond normally to odor and reinforcement alone.


The method presented here is that described by Tully and Quinn with some small modifications1. The experiment is performed in two phases: the flies are trained in the first phase, and the trained flies are tested in the second phase. During training, a group of flies are simultaneously exposed to odor 1 (CS+) and an electric shock (US) in a training tube. The flies then receive odor 2 (CS-) without an electric shock. This single pairing of a particular odor with a shock is called 1-cycle training, and the odors that are most frequently used are 4-methylcyclohexanol (MCH) and 3-octanol (OCT).

One-cycle training leads to the formation of a labile phase of memory that can be detected for up to 7 hr; however, memory is typically tested immediately to determine what is termed learning, acquisition or 2 min memory. Memory measured at 30 min or 1 hr is referred to as short-term memory, whereas 3 hr memory is referred to as mid-term memory. The exposure of flies to repetitive training cycles with gaps between the training cycles (spaced training) leads to a consolidated form of long-term memory that is CREB transcription dependent and lasts up to a week. Training without gaps (massed training) leads to the formation of anesthesia-resistant memory (ARM), which similar to long-term memory, is typically measured 24 hr after 5 cycles of training7,13,15-17,20,21.

With this approach, the effect of various gene mutations on these different phases of memory can be determined. The promoter-driven expression of light- or temperature-sensitive transgenes to activate or block the neural activity of specific neurons allows one to investigate which neurons are required for memory acquisition, consolidation and retrieval3,4,11,15,16,20,22-24. Memory at 1 hr is typically measured when studying age-related memory impairment because this form of memory appears particularly vulnerable to the effects of ageing11-13. A full range of behavioral and genetic controls are performed with memory experiments, for example, to determine whether a performance defect is because of a central memory defect or a peripheral sensory defect that prevents the fly from sensing the shock or olfactory cue5-7,17,25,26.


1. Fly Preparation

  1. Outcross all mutants, Gal4/UAS and other lines with a wildtype strain, such as CSw-, for at least six generations prior to the behavioral experiments to control for genetic background26.
  2. Grow flies on a standard cornmeal, yeast and molasses food diet under a 12:12 hr light-dark cycle at 25 °C unless specific manipulations require a different temperature.
    1. To determine the effects of transgene expression: Use 18 °C to prevent the expression of transgenes in Gal4 Gal80ts (TARGET system) through development and then move the flies to a 30 °C incubator 1-2 days before the behavioral experiment. Conduct the experiment at 30 °C to determine the effects of transgene expression3,4,6,7,14.
    2. For experiments using heat-activated TRPA1 channels to stimulate neurons: Raise the flies at 23 °C, which is a temperature known to maintain an inactive channel, and then shift to a behavior room at 30 °C to activate the TRPA1 expressing neurons.
    3. For experiments using Shibiretemperature sensitive to block synaptic output11,14,24: Rear the flies at 18 °C and conduct testing at 30 °C.
  3. Collect the flies 1-2 days before the experiment and count them in groups of approximately 25 under light CO2 anesthesia. Store the flies at least O/N in food vials (without yeast) at 25 °C (unless specific manipulations required a different temperature) and 70% relative humidity in an environmentally controlled room with 12:12 hr light:dark conditions until the time of the experiment.
    Note: This storage allows the flies to acclimatize to the subsequent learning test performed in the environmentally controlled room, which had the optimal conditions for Drosophila learning and, importantly, removes any daily environmental variations that might have affected the behavioral phenotype.

2. Preparation Before the Experiment

  1. Perform the experiments in a custom-made Perspex T-maze (Figure 1).
  2. Regularly check the tube fitting to ensure that an airtight seal is obtained during the experiment. If necessary, change the O-rings that seal the inside compartments of the T-maze.
  3. Place custom-made copper grids inside the training tubes. Check and clean these grids regularly, and replace if oxidized. Attach the copper grids to wires via crocodile clips that run to a switch-box connected to an electric stimulator. Use a voltmeter to ensure that the apparatus is delivering the required shock.
  4. Use g-clamps to hold the maze tightly to avoid any air leakage.
  5. Attach the T-maze to tubing that runs to an air pump, to allow odors to be drawn across the flies and subsequently removed from the T-maze. Maintain mild airflow at ~2 L/min

3. Odor Dilutions

  1. Use two different odors at concentrations such that the flies show an equal preference for both odors. Use 4-methylcyclohexanol (1:67) and 3-octanol (1:100) diluted in mineral oil7,13.
    Note: Carefully determine these concentrations, which will vary by laboratory. For instance others use 1:10 for both odors24 . Other commonly used odors include ethyl acetate and iso-amyl acetate.
  2. Pipette 30 μl of the diluted odor into a custom-made odor cup placed in an odor block covered by a plastic tube with a perforated top that allows air to be drawn over the odor in the cup, thus exposing the flies to an odor plume.

4. Training Protocol (Figures 1 and 2)

  1. For adult olfactory shock conditioning, perform all experiments under a dim red light (i.e., red LED), which allows the researcher to see but prevents the fly from seeing, thus allowing the flies to concentrate on olfaction as opposed to visual inputs.
  2. Introduce the flies into the training tube and then attach to the T-maze and allow them to adapt to the tube and airflow for 90 sec.
  3. Present the first odor (4-methylcyclohexanol, MCH) with a 60-V shock (consisting of twelve 1.25 sec pulses with 3.75 sec inter-pulse intervals) for a total duration of 60 sec.
  4. Follow the shock with a 30 sec rest period without an odor or shock.
  5. Present the second odor (3-octanol, OCT) for 60 sec without a shock.
  6. Follow the shock with a 30 sec rest period without an odor or shock.
  7. Move the flies from the training chamber into the central chamber of the T-maze by turning the T-maze on its side and gently banging the bottom of the T-maze on a soft surface such as an old mouse mat. Maintain the flies in the central chamber for 90 sec.
  8. Fit the choice tubes into the bottom of the apparatus to form the T-maze.
  9. To measure learning, move the flies to the choice point of the T-maze, where they were simultaneously exposed to both odors and move towards one. Conduct a test period for 120 sec.
  10. Trap the flies in the choice tubes by sliding the central chamber up thereby blocking the ends of the choice tubes. Collect the flies in each arm of the T-maze and in the central compartment into food vials and count.
  11. To measure memory, collect the flies after training (4.6) and transfer them from the T-maze to food vials without yeast. Store flies in the dark at 25 °C and 70% humidity for the remaining time necessary to determine the memory phase of interest (see introduction). Reintroduce the flies to the T-maze as in stage 4.7.
  12. For long-term memory, use a custom built maze which allows several batches of flies to be trained simultaneously. Administer 5 cycles of training with a 15 min inter-cycle interval (spaced) or without an inter-cycle interval (massed). Maintain the flies at 18 °C and 70% humidity in the dark until testing. Prior to testing, move the flies to 25 °C and allow them to acclimatize for at least 1 hr. Assess long-term memory 24 hr after training.
  13. After the behavioral experiments, clean the odor cups with hot water and odorless detergent. After drying, coat the cups with 10 μl sigmacote. Dry the sigmacote by heating in a microwave oven. Occasionally clean the T-maze perspex tubes and odor blocks with hot water and odorless detergent.

5. Calculation of the Performance Index: a Measure of the Flies’ Memory

  1. Calculate the Performance Index (PI) for each condition as the number of flies avoiding the shock-paired odor (CS-) minus the number of flies choosing the shock-paired odor (CS+) divided by the total number of flies (CS- + CS+)1.
    Performance index (PI) = (# CS- flies - # CS+ flies) / (# total flies)
  2. Calculate the final PI of the experiment by averaging the PI of the experiment in which MCH was the shock-paired odor and one in which OCT was the shock-paired odor. This removes any bias of the flies having a higher preference for one odor.

6. Sensorimotor Controls

  1. Perform odor acuity by introducing ~40-50 flies into the T-maze6,7,17.
  2. After 90 sec, move the flies to the choice point, and allow them 2 min to choose between pure odors and air.
  3. Collect and count the flies. Calculate the avoidance percentage by dividing the total number of flies that chose the odor by those that participated in the test.
  4. For shock reactivity6,7,17, introduce the flies into the shock chamber.
  5. After 90 sec of rest, administer a 60-V DC electric shock, from which the flies can escape to a similar tube without a shock.
  6. Allow 2 min for the flies to choose; collect and count the flies. Calculate the shock avoidance percentage by dividing the number of flies that avoided the shock by escaping the shock tube by the total number of flies in the experiment. Include the flies that remain in the central chamber in the total of those that escaped the electric shock.

Representative Results

The performance index (PI) serves as a measure of memory. Table 1 illustrates a representative calculation of PI.

MCH paired with shock 3-OCT paired with shock
Flies avoiding MCH (in OCT tube) = 80
Flies preferring MCH (in MCH tube) = 20
PI1- (80-20)/80+20)
= 0.6
Flies avoiding OCT (in MCH tube) = 75
Flies preferring OCT (in OCT tube) = 25
PI= (75-25)/(75+25)
PI of the experiment= (0.6+0.5)/2=0.55

Table 1. A representative calculation of performance index using illustrative data. Performance indices for different experiments can be compared to elucidate memory effects. Once such comparison is shown in Figure 3, which contains the results from a series of experiments performed with Canton S wildtype adult flies (WT) and dunce learning mutant adult flies1. The mean of 10 PIs is provided, with error bars representing the standard error of mean (SEM). These results demonstrate that dunce flies show a reduction in learning compared to wildtype.

Figure 1
Figure 1. The adult experimental set-up. The flies are trained and tested in a T maze. The training involves presenting an odor A with electric shock followed by a second odor B without electric shock. After a rest period in the middle chamber the flies are presented with both the odors simultaneously. The flies are trapped in the two tubes and collected and counted to obtain learning/memory scores.

Figure 2
Figure 2. The adult training protocol. The flies are training in two steps. The first step where flies receive an odor (CS+) paired with electric shock (US) for 60 sec. In the next step flies receive a second odor (CS-) without electric shock. Flies are then allowed to rest for 90 sec after which they are tested for their choice between CS+ and CS-.

Figure 3
Figure 3. A representative graph showing dunce and wildtype learning in adult Drosophila. WT and dunce flies were tested following one session of training. dunce flies show a reduction in learning compared to the WT (n = 10).


The Drosophila adult olfactory shock learning assay presented here allows analysis of the molecular mechanisms underlying different phases of memory, including long-term memory15-17. As well as determination of the effect of circadian rhythms18, sleep19, diet20,21, senescence11-13, neurodegenerative disease5 and drug treatments5,6,19 on memory.

Many powerful approaches have been recently developed for the functional imaging of the neural circuits that mediate olfactory memory in flies3,4,7,11,16,27. These optogenetic techniques use the vast repertoire of the different promoters available in Drosophila14,16. These promoters are used to express genetically encoded calcium and cAMP reporters in the memory neurons16,27 to study the effect of specific gene mutations on memory traces.

The use of conditional promoters and mutations in adults allows the study of the post-developmental role of a gene product in memory3,4,6,7,13,14. Imaging and behavioral approaches can be combined with light- and heat-activated channels to stimulate or inhibit different neurons in the memory circuit11,14,16,22-24 to further elucidate their function. Furthermore, mushroom body memory neurons are accessible to whole-cell patch clamp recordings28, and mathematical and computational techniques are being used to model Drosophila olfactory memory29.

These experimental advances, combined with the different forms of associative memory protocols introduced here, allow Drosophila to be used to model the molecular- and circuit-level changes in associative memory that occur in response to reward, punishment, motivation, addiction, aging and disease5,6,11-13,16,30-31.


The authors have nothing to disclose.


We acknowledge Bloomington stock centers for the fly strain. This work was supported by research grant from BBSRC (BB/G008973/1).


Name Company Catalog Number Comments
3-Octanol Sigma 218405
4-Methyl cyclohexanol Sigma 15309-5
Benzaldehyde Sigma 418099
Mineral oil Fluka BP2629-1
Hexyl acetate Sigma 108154
Fructose Sigma F0127
Agarose Bioline BIO-41025



  1. Tully, T., Quinn, W. G. Classical conditioning and retention in normal and mutant Drosophila melanogaster. Journal of Comparative Physiology A. 157, 263-277 (1985).
  2. Bolduc, F. V., Tully, T. Fruit flies and intellectual disability. Fly (Austin). 3, 91-104 (2009).
  3. McGuire, S. E., Deshazer, M., Davis, R. L. Thirty years of olfactory learning and memory research in Drosophila melanogaster. Prog Neurobiol. 76, 328-347 (2005).
  4. Keene, A. C., Waddell, S. Drosophila olfactory memory: single genes to complex neural circuits. Nat Rev Neurosci. 8, 341-354 (2007).
  5. Chiang, H. C., Wang, L., Xie, Z., Yau, A., Zhong, Y. PI3 kinase signaling is involved in Abeta-induced memory loss in Drosophila. Proc Natl Acad Sci USA. 107, 7060-7065 (2010).
  6. Kanellopoulos, A. K., Semelidou, O., Kotini, A. G., Anezaki, M., Skoulakis, E. M. C. Learning and memory deficits consequent to reduction of the Fragile X mental retardation protein result from metabotropic glutamate-mediated inhibition of cAMP signalling in Drosophila. J Neurosci. 32, 13111-13124 (2012).
  7. Malik, B. R., Gillespie, J. M., Hodge, J. J. L. CASK and CaMKII function in the mushroom body a’/ß’ neurons during Drosophila memory formation. Front Neural Circuits. 7, 52 (2013).
  8. Gerber, B., Stocker, R. F. The Drosophila larva as a model for studying chemosensation and chemosensory learning: a review. Chem Senses. 32, 65-89 (2007).
  9. Gillespie, J. M., Hodge, J. J. L. CASK regulates CaMKII autophosphorylation in control of synaptic growth and appetitive learning. Front Molecular Neuroscience. 6, 27 (2013).
  10. Apostolopoulou, A. A., Widmann, A., Rohwedder, A., Pfitzenmaier, J. E., Thum, A. S. Appetitive associative olfactory learning in Drosophila larvae. J Vis Exp. (72), e4334 (2013).
  11. Tonoki, A., Davis, R. L. Aging impairs intermediate-term behavioral memory by disrupting the dorsal paired medial neuron memory trace. Proc Natl Acad Sci USA. 109, 6319-6324 (2012).
  12. Yamazaki, D., Horiuchi, J., Nagano, S., Tamura, T., Saitoe, M. The Drosophila DCO mutation suppresses age-related memory impairment without affecting lifespan. Nat Neurosci. 10, 478-484 (2007).
  13. Cavaliere, S., Malik, B. R., Hodge, J. J. L. KCNQ channels regulate age-related memory impairment. PLoS One. 8, e62445 (2013).
  14. Venken, K. J., Simpson, J. H., Bellen, H. J. Genetic manipulation of genes and cells in the nervous system of the fruit fly. Neuron. 72, 202-230 (2011).
  15. Isabel, G., Pascual, A., Preat, T. Exclusive consolidated memory phases in Drosophila. Science. 304, 1024-1027 (2004).
  16. Perisse, E., Burke, C., Huetteroth, W., Waddell, S. Shocking revelations and saccharin sweetness in the study of Drosophila olfactory memory. Curr Biol. 23, R752-R763 (2013).
  17. Tully, T., Preat, T., Bonyton, S. C., Del Vecchio, M. Genetic dissection of consolidated memory in Drosophila. Cell. 79, 35-47 (1994).
  18. Lyons, L. C., Roman, G. Circadian modulation of short-term memory in Drosophila. Learning and memory. 16, 19-27 (2009).
  19. Le Glou, E., Seugnet, L., Shaw, P. J., Preat, T., Gouguel, V. Circadian modulation of consolidated memory retrieval following sleep deprivation in Drosophila. Sleep. 35, (10), 1377-1384 (2012).
  20. Placais, P. Y., Preat, T. To favour survival under food shortage, the brain disables costly memory. Science. 339, 440-442 (2012).
  21. Hirano, Y., et al. Fasting launches CRTC to faciltate long-term memory formation in Drosophila. Science. 339, 443-446 (2012).
  22. Schroll, C., et al. Light-induced activation of distinct modulatory neurons triggers appetitive or aversive learning in Drosophila larvae. Curr Biol. 16, 1741-1747 (2006).
  23. Claridge-Chang, A., et al. Writing memories with light-addressable reinforcement circuitry. Cell. 139, 405-415 (2009).
  24. Aso, Y., et al. Three dopamine pathways induce aversive odor memories with different stability. PLoS Genetics. 8, e1002768 (2012).
  25. Connolly, J. B., Tully, T. Drosophila: a Practical Approach. Roberts, D. B. Oxford University Press. 265-319 (1998).
  26. Connolly, J. B., et al. Associative learning disrupted by impaired Gs signaling in Drosophila mushroom bodies. Science. 274, 2104-2107 (1996).
  27. Davis, R. L. Traces of Drosophila memory. Neuron. 70, 8-19 (2011).
  28. Gu, H., O'Dowd, D. K. Cholinergic synaptic transmission in adult Drosophila kenyon cells in situ. J Neurosci. 26, 265-272 (2006).
  29. Young, J. M., Wessnitzer, J., Armstrong, J. D., Webb, B. Elemental and non-elemental olfactory learning in Drosophila. Neurobiol Learn Mem. 96, 339-353 (2011).
  30. Kaun, K. R., Azanchi, R., Maung, Z., Hirsh, J., Heberlein, U. .A. Drosophila model for alcohol reward. Nat Neurosci. 14, 612-619 (2011).
  31. Waddell, S. Dopamine reveals neural circuit mechanisms of fly memory. Trends Neurosci. 33, 457-464 (2010).



  1. Hellow. I'm a high school students in Korean. I'd like to try your experiment. But I have something that is difficult to understand. I want to know your circuit of electric shock, and how to make that electric shock. I will really appreciate that you give me some advice through my e-mail.

    Posted by: 기우
    August 4, 2015 - 2:55 AM
  2. Hi,
    The electric circuit consists of the stimulator (Grass technologies) and a copper grid inside the shock tube. The shock delivery is controlled by the stimulator. If you want to design your own circuit I suggest you make sure it delivers 12 60V shocks each for 1.25 sec seperated by 3.25 sec intervals.

    Good luck

    Posted by: Bilal M.
    August 13, 2015 - 4:07 AM

Post a Question / Comment / Request

You must be signed in to post a comment. Please or create an account.

Video Stats