Thursday, December 31, 2015

Space Mining (Not Illegal!), Interplanetary (Not The Movie), and Quadcopters (Not Breaking)

Today I Learned:
1) Obama just signed into law a bill allowing corporations to sell materials found on extraplanetary bodies. In other words, we just legalized space mining.

2) Interplanetary is on sale on Steam for $1! Interplanetary is a delightful game of, well, interplanetary war in which players "[develop] their home planets and [fire] massive artilleries through the unpredictable gravity fields of the planetary system." Great game for a LAN party.

3) ...that tiny little quadcopters also have tiny little batteries, which appear to last about five minutes in the air. Also, Quark Micro Drones are surprisingly sturdy -- today I watched one nosedive into asphalt from three feet in the air, slam into it repeatedly several times, then fly off and fall from about 50 feet onto grass, suffering only a bent propeller, which was easily bent back into place. Also, today I learned never to give up looking for a lost 'copter. You never know where you might find it.

Wednesday, December 30, 2015

Delayed-Line Memory, Olfactory Neuron Fate Determination, and FlyNap

Today I Learned:
1) ...about a crazy old form of computer memory called delayed line memory. A delayed line memory device is, conceptually, a really long twisted-up wire with a transmitter and a receiver at each end. To store information in the device, you feed data to the head end. The head sends the data down the line, which takes some number of seconds to get to the other end. While that information is traveling down, the head can fire off more data down the pipe. When the data gets to the other end, it is made available for reading and is sent back to the head, which immediately retransmits. So you basically have all of your bits flowing around in a circular pipe, with a window at one end that lets you see the bits go by.

As you might imagine, programming efficient memory usage on a computer with delayed line memory was loads of fun.

2) Consider olfactory (scent-detecting) neurons. Each individually-discernable scent that a human can smell is detected by a single receptor protein, of which there are order-of-magnitude 1,000. Each olfactory neuron expresses exactly one receptor type; when that receptor fires, the neuron signals to projection neurons, which signals to interneurons, which send signals to the appropriate higher-level brain functional circuit in order to induce the experience of the scent (or, in the case of pheromones, possibly directly influence behavior).

Today I learned how each neuron picks its receptor. The thousand-odd different olfactory receptor proteins come with pretty much identical regulatory regions (promoters, enhancers, repressors, and such). These regions are uniformly repressed by methylation control via the polycomb protein, making each olfactory receptor neuron a sort of blank by default. When several of the regulatory regions for olfactory receptor proteins stochastically come together in the nucleus, they form a complex which activates one of the promoters, causing the neuron to start expressing the corresponding olfactory receptor protein.

Something I'm now wondering about -- if olfactory receptors are picked randomly for each neuron, then there must be something *downstream* of the olfactory receptor protein regulatory elements that controls how each neuron is wired through to its appropriate higher-level olfactory brain circuit. Otherwise, scent molecules would have effectively random sensations associated with them, as there would be no way to consistently wire the receptors for, say, ammonia to the sharp, painful sensory experience of smelling ammonia.

So I have this hypothesis that the receptor types chosen for a neuron somehow determines the wiring of that neuron. A consequence of this hypothesis is that receptor type must be (randomly) selected before the receptor neurons are wired up to higher-level circuitry. Does anyone know enough about olfactory development to confirm or deny this hypothesis?

3) The active (and distinctive-smelling) ingredient in FlyNap is triethylamine. Based on the structure and smell, it probably activates more or less the same scent receptors as ammonia.

Squirrel Observation, Ocular Harpsichords, and The Cat Organ

Today I Learned:
1) Did a little bit of squirrel-watching today. After I got a squirrel used to my presence, I watched it gallivanting around its tree for a while. I'm guessing it was male, though I didn't check the obvious way, because it kept snuzzling its cheeks against the branches in a decidedly territory-marking (though adorable) way. I *also* saw it stop at leaves several times, kind of bite or taste the base of the leaf, then move on. "Why would it be trying to eat a leaf?" I wondered. "Squirrels don't eat leaves." Then it did the little tasting thing to a leaf, but instead of leaving it be, the squirrel nipped it off just under the base of the leaf and carried it away up the tree. It didn't actually get it very far -- it dropped the leaf after a couple of feet of speed-climbing -- but I'm guessing that it was looking for leaves from which to make a nest.

2) The ocular harpsichord was a contraption conceived by Louis Bertrand Castel to make music with colors. The idea was that it was a keyboard that produced colors instead of sound. Castel claimed that there was a fundamental... metaphor, I suppose is the word... between sound and color, and that with the appropriate mapping you could make music out of color that could be appreciated as music. The ocular harpsichord was probably never built during Castel's life, and the reason why gets to the fundamentals of Castel's philosophy, which throws some contrast on our modern scientific philosophy.

Castel was a natural philosopher in the burgeoning first age of natural philosophers. His contemporaries included the likes of Voltaire, Hooke, and Newton. Castel was a bit of an old-fashioned natural philsopher, though. He heavily critiqued Newton for his straightforward, fact-based presentation style and for his reliance on experiment and mathematics. Yeah, Castel didn't like the idea of getting knowledge from experimentation. He believed that truth should be understood through the accumulation of everyday, real-world experience. According to Castel, laboratory experiments were almost always unnatural scenarios, and therefore not to be trusted.

Castel preferred science by metaphor -- real truth, he argued, could only be arrived at through analogy to commonplace, everyday, oft-experienced phenomena. The truth of light, for instance, could best be arrived at by analogy to something else well-understood -- sound, for example. Newton's prisms experiments, by contrast, Castel viewed as unnatural setups yielding unnatural results unlikely to reveal the real truth of things. Castel wasn't interested in proving theories right or wrong by experiment, but rather in finding connections between phenomena well-grounded in experience. That's why he wasn't keen on building an actual ocular harpsichord -- the point of it was that it was a thought experiment that revealed something of the natures of sound and light. Actually building one would be like building a working example of the trolley problem. Er. Bad example, perhaps -- more like making a... hmm... why does it seem like all the best thought experiments involve morally dubious setups? Anyway, building one wasn't the point.

The above four paragraphs were distilled from the following article, linked to me by Chigozie Nri late last night: http://ift.tt/1JJf4qr

3) From the same source as above, the cat organ was a terrible contraption built by an Italian musician of the 17th century. It was a keyboard instrument hooked to a bank of caged cats, picked out for the pitch of their meows and arranged in increasing order. When a key was struck, it would drive a nail into the tail of one of the cats, causing it to shriek with specifically-pitched pain. By all period accounts, it never failed to get a laugh. If you want to know how a vegetarian feels about the slaughter of animals for tasty food, just remember that people built and enjoyed the cat organ.

Tuesday, December 29, 2015

Hacklemesh Weavers, Colony Pheromones, and The Last Bookstore

Tody I Learned:
1) ...a little bit about the hacklemesh weaver, which I suspect may be the species to which my newly acquired lab spider may belong. The hacklemesh weaver is a South American spider that has been recently transplanted to the south-west US and, as far as I can tell, has essentially gone native. They dig burrows, outside of which they build coarse, tube-like-ish webs. The webs aren't sticky, but they're spun out of gajillions of tiny little loops, which trap prey. The weavers have a specialized comb-like structure on their fourth leg, which they use to comb their silk to the right consistency.

Unfortunately, as I'm discovering, in general, spider identification is difficult unless you can get close enough to get a good sense of the eye layout -- the first, most important distinguishing characteristic to look for on any brown spider is the eye layout, which varies quite a bit between species.

2) I already kind of figured that different ant species would use different pheromones. Recently I've been learning about just how different those pheromones are -- not amazingly different, but the variety is great enough that checking what chemicals an ant responds to is a good way of determining the ant's species, and looking at patterns of pheromone chemistry is one of the (many) ways myrmecologists organize evolutionary relatedness among ants. There has even been at least one case where two quite distinct species of ant were misidentified as one species for decades until someone checked what trail pheromones they laid.

Today I learned that pheromones also vary by *colony*, to the point where ants seem can distinguish which colony laid a trail. There's also evidence that *individual ants* have distinguishable trails, so that an ant can specifically follow its own trail and not get confused by other ants'. Mostly the variation comes from differing ratios of standard pheromones.

There must be some kind of randomization that happens early in a colony's development that fixes its pheromone mix, which eventually gets set. I suppose it *could* be genetic, but I would expect too much variation between sisters' trails (most (all?) ants share about 50% genetic similarity to their sisters). A lot of pheromones are apparently produced in the hindgut, which makes me suspect that the ants' microbiomes are involved.

3) Somewhere I need to go -- The Last Bookstore, in downtown LA. From the descriptions I've gotten, it sounds like exactly the kind of magical place I wish I could live in for a couple of decades. Thanks to Chigozie!!!! and friends for pointing this out to me!

Sunday, December 27, 2015

Projector Keyboard, Fluorescent Protein Comparison, and A Little Antiques Store

Today I Learned:
1) I got to try out a projector keyboard today! It worked... better than I expected, but still not well enough to want to use it.

2) There are really a lot of fluorescent proteins out there! Andy Halleran pointed me to this handy page, which has a ton of information on the various fluorescent proteins that have been made. http://ift.tt/1JDxMQc

3) ...of an awesome little antiques place near here. Actually, it's not that little -- it's solidly medium-size, but built like a labyrinth, which makes it fun to explore. There are lots of little back alleys and side rooms to check out. It seems to be a sort of rental place for antique sellers. I only caught snippets of relevant conversation, but I think antique dealers can rent sections to house and display their wares? As a result, every little niche has its own feel. For example, there's one corner all the way in the back that sells what are claimed to be authentic Hollywood props, stuff like John Wayne's hat or faux jewelry from the Titanic. Fun stuff!

Auditory Hallucinations, Cockateal Dances, and Alarming Candles

Today I Learned:
1) There are people for whom "music stuck in their head" is actual auditory hallucination, which can be quite annoying and potentially problematic -- imagine trying to sleep with big band music constantly playing outside your window.

One line of theory on the effect is that it has something to do with failure of the neurons feeding back from the brain to the neurons of the ear, which is supported somewhat by the fact that many people with this condition later go deaf, and restoring hearing in these cases with cochlear implants can alleviate or completely remove the hallucinations.

This is one of these quirks of biology that must have caused considerable confusion to our pre-scientific ancestors. What are they to think when someone constantly hears, really *hears* music? I'll bet you at least one god, demigod, demon, spirit, sprite, or other supernatural being has been invented to explain musical auditory hallucinations.

2) Speaking of music, today I learned that cockateals can not only sing along to a song, but will dance to human music and match their moves to the beat, even changing to match the beat when the beat changes.

3) Yes, burning candles in my apartment *can* trigger the fire alarm. =(

Saturday, December 26, 2015

Big Drones, Tandem Running, and Leptanilla Ants

Today I Learned:
1) Yes, a Star Destroyer will fly, but only if it's small enough: https://www.youtube.com/watch?v=gWp9cGqHKiA

Note how they film -- what a cool setup!

2) Some ant species use a very particular form of signaling called tandem running. In tandem running, one ant grabs another one, getting its attention. The second ant moves behind the first ant and touches it with its antennae. The first ant then runs to wherever the second ant is needed, and as long as a)the second ant maintains contact and b) the first ant emits the right pheromone, the second ant will follow closely behind. If contact is lost, the first ant doubles back and looks for its mate, and the second ant begins a spiraling search pattern to find its leader.

There is exactly one known case of tandem-running between different *species* of ants, and that's the parasitic Polyrhachis lama. Polyrhachis build their own nests, but they also send workers to infiltrate nearby colonies of Diacamma rugosum ants. There are a few unusual things about this particular case of parasitism. For one thing, most ant parasites are very closely-related to their hosts, but this isn't the case with Polyrhachis. Also, Polyrhachis will leave their eggs and larva in Diacamma nests. Diacamma workers won't spend much time caring for the Polyrhachis young (and never appear to feed them), but they tolerate their presence... unless the Polyrhachis *workers* leave or are removed, in which case Diacamma start eating and removing Polyrhachis young after a day or two.

But I digress. Tandem running.

Diacamma use tandem running to move workers when new nest sites are constructed, and Polyrhachis has figured out how to follow tandem-running signals -- a Diacamma worker will cue a Polyrhachis worker to follow it, and the Polyrhachis worker will follow (clumsily) to the new nest site.

3) The most ancestral-known ant species, Leptanilla japonica (the only member of the family Leptanilla) is also one of the oddest.

Firstly, Leptanillae are tiny ants, measuring about a millimeter long, which according to E. O. Wilson and Bert Hölldobler is small enough to move around in dirt, not by tunneling, but by just moving between dirt particles. Their size and habits make them very hard to find, and most mrymicologists never see one in the wild.

Leptanilla are rather odd-looking -- they look to me like someone drew a concept drawing of an ant, then one artist used the concept drawing to make Leptanilla and a different artist used the concept drawing to make all the other ants.

Leptanilla are social, but their colonies are fairly small, numbering around a few hundred individuals.

Leptanilla workers eat arthropods, particularly centipedes. They do this, despite being much smaller than your average centipede, by injecting a venom that paralyzes the centipede. The workers can then haul the centipede back to the nest, or, if the centipede is too big, relocate the nest to the centipede(!!!).

Note I say that's what the workers eat. The queen doesn't. The queen only eats the blood of her children. Seriously. Leptanillaean larva have a specialized organ called a "larval hemolymph tap", which is essentially a spigot allowing the queen to suck out the larval equivalent of blood (hemolymph). This is the only nutrition the queen receives once a brood has been established (I don't know what new queens do).

Thursday, December 24, 2015

SIDS History, Cloning Tip, and LB Problems

Today I Learned:

1) There's a tragic story about SIDS, sudden infant death syndrome, with a valuable lesson for scientists like yours truly.

Back when SIDS was first, uh, I guess "discovered" as a distinct thing, doctors were very confused about it (they still are). One of the first things they tried to do was autopsy a bunch of infants who had died from SIDS. This was before SIDS was *defined* as any infant death still unexplained after an autopsy, so there was hope that they might find some obvious cause.

They found one. It turned out that babies with SIDS had massively enlarged thymuses (thymi?). Researchers (doctors? I'm honestly not sure who did the autopsies) reasoned, reasonably, that something was causing the infants' thymuses to become grossly enlarged, blocking their airways and choking them to death. The treatment? Shrink the thymus. How? Blast it with radiation.

Bear in mind that this was before we knew much about the effects of radiation on biology. Radiation was new and miraculous and had the kind of mystique around it that I would argue quantum mechanics and antioxidants have today. This was back in the day when many scientists thought radiation was a promising way to make crops grow bigger. *Exactly* how they figured radiation would shrink a thymus without also thinking it might be bad for you, I'm not really sure, but the point is that nobody understood that blasting radiation into a baby was a dangerous proposition. Nevertheless, it was, and an estimated 20,000 babies died as a result before they figured out that thymus irradiation was a bad idea (specifically, thymus irradiation tended to cause cancer of the thyROID, which is quite close to the thymus).

But at least the radiation kept thymus swelling down, saving babies from SIDS. Right? Wrong. Here's where the important lesson comes in. I could just go ahead and state it right here, but this story is more entertaining told in the order Radiolab presented it (thanks to Radiolab, by the way!), so I'm going to tell it that way.

To understand what went wrong here, we have to go back to the late 18th century, right around the American Revolution. This was a time of exploding interest in medicine, and it was when the first medical schools were established, at least in America. One of the rather important and rather valuable raw materials required to run a medical school is corpses. Human corpses, in particular. It's hard to properly learn human anatomy without them. So there was a huge demand for cadavers, which was met for quite some time by freelance acquisition specialists known as "resurrectionists". These resurrectionists would find corpses wherever they could, dig them up, and sell them to scientific establishments and medical schools. People soon caught on to this, and the wealthy started investing in resurrectionist-proof burial coffins to protect their bodies. Anyone who couldn't afford it remained at risk. To stop wanton looting of graveyards while ensuring that scientific institutions would still have a steady source of bodies, the government stepped in and established that a) resurrectionists could no longer sell any corpse they could get their hands on, and b) that anybody who died in a poor house would have their body donated to science/medicine.

This worked for quite a while. There's a problem, though. Tenants of poor houses are not random members of the population. Tenants of poor houses tend to be, well, poor. Also stressed, and malnourished. As it happens, poor, stressed, malnourished people tend to have abnormally small thymuses, particularly poor, stressed, malnourished *infants*. This wasn't understood until well after the first SIDS autopsies. When researchers had autopsied SIDS victims, they had been seeing healthy, normally-sized thymi for the first time. The rest is history.

So, today I learned to USE GOOD FRACKING CONTROLS.

2) When designing pieces for cloning, it's worth doing a virtual (i.e., in silico) digest before starting to build the parts. Learned this the hard way. *sigh* More positively, I learned a nice trick when making linear DNA for cloning. If you're making a bunch of linear pieces with the same cloning ends (say, biobrick ends), it can be worth it to extend those ends until you can amplify the piece with a primer that can be shared between all the pieces. This lets you use one pair of primers to amplify all of your parts.

3) More reason to use that M9 minimal media I mentioned yesterday. This from Andy Halleran's comment on my last TIL: "I've heard weird things about people trying to get reproducible promoter strength and variability measurements in LB. Basically it's not reproducible at all unless you use a minimal media and then it's really nice. Especially true if you're driving multiple things under strong promoters. The general idea is that strong promoters hog a huge amount of cellular resource. Put a few of those into one cell and you're siphoning off a large % of metabolic flux and this causes problems." This is good to know! Thanks, obviously, to Andy Halleran.

Arduino Drivers, Taylorism, and M9 Minimal Media

Today I Learned:
1) ...what Arduino driver code looks like. It's a lot of switch statements to parse incoming commands, and a lot of hex gibberish to translate that into hardware commands. Overall, not too bad, though.

2) Taylorism, also known as scientific management, was the first attempt to rationally, systematically, scientifically describe and optimize managerial practices, usually to optimize output. Pretty much every particular of Taylorism is now considered obsolete or plain wrong, but it was the first rationally-driven management science, and so has been hugely influential on modern management theory.

3) M9 minimal (a known-composition bacterial media made from pure components, unlike most media, which is basically exploded yeast and salt) media is colorless (and a bit cloudy?), which to me looks somewhat obscene after years of using yellowish medias.

Wednesday, December 23, 2015

Dyeless gels, Poinsettias, and Servo Innards

Today I Learned:
1) Apparently you can run DNA gels without a dye -- you can just put it on a nice UV-fluorescent background, shine a UV light on it, and the DNA will show up as dark bands.

2) Apparently some people think that poinsettias are poisonous? But they're not. There are tens of thousands of cases of people being admitted to hospitals after eating poinsettias... and zero cases of those people needing medical treatment. There is also no known LD50 for poinsettias, because no toxic dose could be found.

3) ...what the inside of a servo looks like! That turbidostat I mentioned in the last TIL? It has a servo that's probably bad, so we took it apart to look for problems. We didn't find any (though after taking it apart and putting it back together, it seemed to work better), but I got to see the inside. First impressions -- far more gears than I was expected. I was expecting one, maybe two, and there were more like four. That's required because most servos have their motor shaft geared to a potentiometer (a resistor whose value changes based on the position of a dial) that gives feedback about how far the motor has moved.

Monday, December 21, 2015

Turbidostat, Double Colons (in Python), and Multivariate Mapping (in Python)

Today I Learned:
1) ...how this thing works: http://ift.tt/1V09oyZ

It's a simple, build-it-yourself, low-scale turbidostat, which is a device for growing cells (usually bacterial) at more-or-less constant density. We have one of these in the lab, but it wasn't... really... working.... I want to use one of these for a long-term experiment I have planned, so I and a colleague took a look at it. We figured out a few problems, and now it's time to run some tests and print out some replacement parts!

2) ...some new Python notation -- the double colon! In Python, the statement X[a:b] means the a- through b-th elements of list X. The statement X[a::b] means every bth element of X, starting with a. Rather handy for pulling the even or odd elements out of a list.

3) ...more about the map function* in Python. I use map a lot (more than I should), but I didn't know that you could map over functions with more than one argument -- you just pass multiple lists, one for each argument, and map will iterate over the first list for the first argument, the second list for the second, et.

Example:

def add(x,y):
    return x+y

a = [0,1,2,3,4]
b = [2,4,6,8,10]
print(map(add, a, b))

Output: [2, 5, 8, 1, 14]

* map takes a function and a list, applies the function to each element of the list, and returns a list of the results. For instance, if you have a function "square" that takes a number and squares it, then map(square, [0,1,2,3]) returns [0,1,4,9].

BK-Trees, Toad Poison, and Tweaked Breakfast

Today I Learned:
1) ...the BK-tree algorithm for fuzzy text searching.

Consider the following problem. You are in charge of a network of a whole lot of emergency response drones, sitting in randomly-positioned stations across the state (whichever state you're in will do fine; if you're not in a state, then whichever country you're in will do fine; if you're not in a country, then you can fill in the 100 km radius centered on you will do fine). When an emergency of any kind is detected, the nearest drone requests the aid of all other drones within some radius to help. This needs to happen as quickly as possible.

The trouble is, although the drones are good at helping with emergencies, they're not very good at communicating, so the dispatching has to be done from a central control station. You, at the control station, can ask any two drones to check how far apart they are from each other, but this takes a non-trivial amount of time. That's all the information you get. A first-response drone requests assistance, and you can ask for the distances between drones, and you have to find all of the drones within some radius of the first-response drone and tell them to go help.

How do you tackle this problem? As always, I encourage you to take ten minutes to think about this. Right now. Set a timer for ten minutes, and just scribble out ideas on a piece of paper, if you have one.

...

...

...

...

So, the simplest thing you can do would be to go through the list of all of the emergency response drones, ask them how far they are from the first-response drone, and send any within some radius to go help. That's fine, unless you really, really have a lot of drones. Say it takes a couple of seconds to query one pairwise distance, and you have a million drones. It would take months to run that search, which is probably not fast enough.

If the drones are stationary, you could always all of your spare time between emergencies querying drone distances and writing them down on a table -- you'd end up with a big grid of pairwise distances between drones, where the distance in row X column Y is the distance between drone Y and column X. You could sort each row of the table so that you could just read off the answers from one side of the table. That gives you great emergency response time... but it's not very space-efficient. I don't know how many books it takes to hold a million-by-a-million entry table, but I'm guessing it isn't small. For scale, even if you digitized the table and put it in a computer, a million-by-a-million table is still order of terabytes in size. That's... maybe doable, if this is important enough. Not very efficient, though, and it won't scale well if you go to, say, a billion drones, because the size of the table gets scales with the square of the number of drones.

All of this is essentially based on the algorithm "check all of the distances from each drone to the first-responder drone" to find close drones. The BK-tree algorithm is another approach you can take to find drones in range. It's not as intuitive, but it turns out to be much more time and space efficient. The basic idea is to use the triangle inequality (of geometry) to narrow down the set of drones you have to check by excluding everything outside of arbitrarily-centered rings containing the region you're looking for. That doesn't make sense? Let's walk through it.

First, consider a geometric way of thinking about the "check all the distances from each drone to the first-responder drone". You could, if you have paper, a pencil, a ruler, and a compass, solve this problem by *mapping out* all of the drones' locations on a map (beforehand), then drawing a circle around the first-responder drone with the required radius and seeing which drones fall in circle. That's the simple way to solve the problem, but you can't really do that programmatically. It's fine if a human operator can just *do* it, but if this system needs to be automated (or you couldn't draw the circles -- that's coming up later), then the draw-a-circle method isn't going to work fantastically well.

The BK-tree method, interpreted geometrically, looks works like the following. Pick a random drone to be a reference drone. Your first responder drone requests the assistance of everything within radius R_assist. You measure the distance from the reference drone to the first-responder drone -- call it R_reference. Draw a circle around the reference drone (not the first responder drone!) of radius (R_reference + R_assist) and another of radius (R_reference - R_assist). The ring between these two circles has to contain all of the drones of interest. Why? That's where the triangle inequality comes in -- the length of one side of a triangle can't be greater than the sum of the lengths of the other two sides, or put another way, the distance between two drones can't be greater than the sum of the distances from those drones to an arbitrary third drone. In other words, if a drone is farther from the reference than (R_reference + R_assist) or closer than (R_reference - R_assist), then it can't be within R_assist of the first responder. If this isn't obvious, try drawing out a case.

Now, you've cut down the space of drones to check by potentially quite a bit, but there could still be drones in that ring that aren't drones of interest. You'll have to do some kind of search on the remaining possibly-useful drones to find all the close ones. If there are only a few left, you could use the "check all the distances" algorithm. If there are lots of drones still in that ring, then you can just pick another reference drone (within the ring) and apply the BK-tree method again (using only elements of the ring)!

"Wait a second", you might be thinking, "don't you still have to search through all of the drone distances to figure out which ones are in the ring?" Sort of. The beautiful thing about the reference drone, though, is that it doesn't matter which one you use -- any drone can be a reference drone, and the BK-algorithm will still cut down on the search time dramatically. That means that you can make a table of distances, just as you could for the simple algorithm, but *only for one drone*. That means the size of the table scales linearly with the number of drones, so a table for a billion drones will fit snugly on a decently-sized USB stick. There's actually an even *better* way to pre-cache the distances so that the whole thing is recursive, which lets you do multiple rounds of pruning-by-ring until you're down to single elements -- for details on the actual BK-tree structure that the algorithm is named after, see http://ift.tt/1O2ZzPw.

One more cool thing about the BK-tree algorithm, which is actually central to its usefulness. The BK-tree algorithm is a geometric algorithm, but the nifty thing is that it only uses one axiom of geometry -- the triangle inequality. (Ok, technically it's probably also using symmetry and a couple other trivial properties, but the triangle inequality is the big one). That means that (very much UNLIKE the "draw a circle and see what falls inside" algorithm) you can apply the BK-tree algorithm to objects in other spaces that satisfy the triangle inequality, and the algorithm doesn't change one bit. For instance, the BK-tree algorithm works just as well for drones scattered across a nebula. Or a galaxy. Or a pocket universe whose dimension is unknown. Or, more practically, the space of *words*. In fact, this is the algorithm behind autocorrect and other fuzzy-search features. Say you want to find all of the words that are less than N single-letter mistakes away from a search term. To the BK-tree algorithm, it's the same problem. The space is different, but there's still a distance metric (number of single-letter changes to get from one to another) on objects (words) in that space, and the triangle inequality still holds there, so the algorithm still works.

For the record, I learned all this because instead of getting out of bed in the morning, I decided to pull out my laptop and google "cool algorithms". After wading through some mucky probabilistic algorithms, I ran across this one, learned it, and decided I would try to find a more geometric, visualizable explanation for it. Let me know if it worked!

2) Toads have poison sacks behind their eyes -- not *behind* their eyeballs, but near the surface of the skin, next to the eyeballs but farther from the nose. Thanks to Chigozie on this one!

3) A variation on my breakfast that will save some trouble. I favor a bowl of cereal with blueberries most mornings. The old protocol for making this breakfast was to cover the bottom of the bowl with blueberries, microwave it for 1 minute, add ceral on top, and stir. Today I realized that if I put the cereal in *before* microwaving the blueberries, it keeps the blueberries from splattering while they heat, which saves either a paper towel for cleaning or water and time sponging out the microwave. (The ceral comes out a *little* bit more rubbery, but it also absorbs the blueberries a little better, especially at the bottom of the bowl).

Saturday, December 19, 2015

Cloudprinting, Withdrawing Plastic, and Water-jet vs Laser

Today I Learned:
1) There's a thing called "cloudprinting" (not to be mistaken with cloud printing, which is a network printer) where you make floating shapes out of foamy bubbles. It's easier to show than to explain: http://ift.tt/1JHxbw2

2) When 3D printers print (at least, when ours prints), they force out the plastic as they print, then withdraw the plastic inside the nozzle a little when they move from print site to print site. I'm not sure why they withdraw the plastic, but I suspect it has something to do with not trailing little bits of print material around.

3) Water-jet cutters are better than laser cutters because they're more powerful (a water jet cutter can cut through steel, easily). Laser cutters are better than water-jet cutters because a) they can engrave things (water-jet utters are too powerful) and b) they are more precise.

DNA Synthesis, Spider Tanks, and A Search Tip For Biologists

Today I Learned:
1) ...a new technique for synthesizing long stretches of DNA. If you want to make a piece of DNA that's longer than a primer, but you don't want to order a gene block, then you can order several nested sets of primers to build up the piece you want. The innermost set might just be a pair of large overlapping oligos; each subsequent piece out extends the piece. You can even do the whole synthesis in one PCR pot by adding the inner primer parts in low concentration, so that most of what you get at the end is the whole piece.

2) Apparently it's not a good idea to keep large spiders in tanks with high walls (higher than a couple of times the width of the spider's leg-span). They'll try to climb them, and sometimes they fall, break themselves, and bleed out. Also, mesh cage tops can be a problem -- if the spider gets up to it, it will sometimes get stuck in the cage and either fall or hurt itself getting free. As awesome as spiders are, they can be pretty silly sometimes.

3) Sometimes, finding basic biological information is surprisingly hard. Oh, sure, you can find plenty of papers on whole proteome responses to this that and the other, but try to ask google or pubmed a basic question like "what's the sequence of the cI promoter?!?!" and all you get is a bunch of papers mapping regulatory pathways and metabolic responses (and metabolic pathways and regulatory responses). Even wikipedia is reticent to give an actual *sequence*.

Today I learned a helpful trick for finding basic information about stuff like promoters, repressors, terminators, mechanisms of action, structures, and probably more. Just do an image search instead of a text search. Text searches give you back scientific papers. Image searches give you back figures, which invariably have more thought put into conveying important information cleanly than the papers they came from.

Friday, December 18, 2015

Measurable vs. Topological, PAMs, and The Speed of Sound

Today I Learned:
1) A measurable space is a space with a notion of measure, which means you can talk about the distance between two points in the space.

A topological space is a space with a notion of proximity, which means you can say that two points in the space are "close" (or not). Most measurable spaces are also topological, by virtue of having a measure.

2) ...the details of guide RNAs and tracrRNAs and PAM sequences in CRISPR/Cas. In particular, I cleared up some confusion over PAMs.... A PAM is a fixed sequence that has to be present in front of any sequence targeted by Cas9. The Cas9 enzyme, independently of any guide RNA, can unwind DNA, detect the PAM sequence, and start checking to see if it has a match to its associated guide. The PAM sequence varies by the species from which the Cas9 was derived, the most famous being the S. pyogenes Cas9 PAM, which is NGG (any nucleotide followed by two Gs). I was always confused about why there was an "N" in the specified sequence -- after all, if there can be any nucleotide there, why not just call the PAM "GG"? Well, turns out it's because the PAM is at the 3' end of the targeted sequence, not the 5' end, so the targeted sequence looks like

<sequence here>NGG

not

NGG<sequence here>

Also, I learned today that the PAM sequence does not appear in the guide, which makes sense.

3) The speed of sound in air is around 300 m/s (but varies by temperature, humidity, pressure, etc), which totally invalidates the advice I was once given about measuring distance to lighting by counting the seconds between a lightning bolt and its associated thunder. We'll see how long I remember this number.

Thursday, December 17, 2015

My Erdös Number, Texas German, and The Pineal Gland

Today I Learned:
1) My Erdös* number** is 5!

* To type a "ö" on a mac, press alt+u, release both keys, then type an o. This works for any vowel, including y.

** An Erdös number is the number of degrees of separation you are from Paul Erdös by publication co-authorship. Erdös numbers are, in general, quite small, as Erdös published massive numbers of articles and was well-known for collaborating widely and extensively.

2) There is a dialect of German called Texas German, spoken by the descendants of German immigrants who moved to Texas sometime... a while ago. It sounds just like German-German to my ears, but it's a bit softer and it has experienced one or two major vowel shifts. It's also a dying tongue -- it's pretty much only spoken by older folks now.

Thanks to Anders Knight for teaching me about Texas German!

3) Let's talk about the pineal gland! I mostly know about the pineal gland because of its central role in the metaphysics of Descartes. See, Descartes was a dualist*, which means he espoused a metaphysics in which physical stuff and spiritual stuff are both real and both exist, but are causally separate -- one does not affect the other. The obvious problem with this theory is that if there are physical bodies and souls, they obviously interact SOMEHOW, since your soul can sense what happens to the body and can control it at least to some degree. Descartes' answer was that the soul interacts with the body through the pineal gland. This is a fairly silly idea. For one thing... why the pineal gland?!?!** More importantly, though, this only begs the question of how the soul interacts with the pineal gland if the pineal gland is physical... Descartes' answer to this was basically a shrug. (Lest you think poorly of Descartes, I should point out that Descartes was also the biggest single force in moving the focus of western philosophy from questions of "what do ancient sources tell us is the truth?" to questions of "what can we figure out?". Oh, and he invented algebraic geometry, which is the idea of graphing algebraic equations. Kind of a big deal.)

This came up in conversation earlier today, so I decided to go learn a little bit about the pineal gland. The pineal gland is a tiny, roughly pinecone-shaped organ deep in the brain. We don't know all *that* much about what the pineal gland does, but it does make at least several important hormones. The pineal gland's primary function seems to be maintenance of circadian rythms. What's the evidence for that? Well, the pineal gland is the primary producer of melatonin in the brain, which is the most well-known and I'm pretty sure the most well-understood, signaling molecule involved in sleep and wakefulness. Also, there are optic nerves that run directly from the eye to the pineal gland, which appear to more-or-less directly regulate melatonin levels based on light intensity.

The coolest evidence, however, comes from reptiles and some other more-basal vertebrates, who use an extension of the pineal gland as a third eye. See, the pineal gland shares a surprising amount of structure with the retina, up to the point of being sensitive to light. Many lizards, frogs, and fish have a "third eye" more or less in the middle of their foreheads (check out the wiki article on "parietal eye" for some nice pictures) that is actually an outgrowth of the pineal gland *through* the skull and just below the skin. This "parietal eye" seems to act as a direct sensor for the pineal gland to detect light, and is important for circadian rhythm and thermoregulation (which is tied to circadian rhythm) in the species that have one.

The pineal gland can be removed from humans apparently without too much effect other than screwed up sleep patterning (at least, in adults; youths whose pineal glands are damaged apparently tend to go through puberty much earlier, so the pineal gland is probably responsible for hormonal homeostasis in the young). It very rarely happens, though, because its situation deep in the brain makes it very difficult to get to safely to remove. The pineal gland also doesn't get diseased particularly often, although it *does* calcify in the majority of people. This seems to be normal, or at least common, although severity of pineal calcification does correlate with incidence of Alzheimers (I would guess because of some third cause related to brain maintenance).

Thanks to Bear Bear Bear and Andrés Muñuz for stimulating my curiosity on this subject!

* I've also heard the theory that Descartes was actually much more a physical materialist than a dualist, but that he faced potentially lethal pressure from the church to include souls in his philosophy. Under this theory, Descartes tried to establish dualism as a way to partition the spiritual as much as possible *away* from the physical so that he could talk about physical stuff without being constantly bogged down by spiritual metaphysics. If true, the whole idea of the pineal gland linking the spiritual and physical may have been a throwaway idea to push back the rather obvious question of spirit/material interaction; it may have even been chosen to highlight how silly the idea was. I'm pretty sure this theory is far outside the mainstream, but it amuses me.

** I also learned today why Descartes chose the pineal gland as the seat of consciousness. His reasoning was threefold: a) The pineal gland appears to be a single organ, where many other structures (particularly in the brain) are composed of two more-or-less identical organs in either hemisphere (this turns out to be the case for the pineal gland, too); b) The pineal gland is deep in the brain and located conveniently close to the spine, making it well-situated to quickly react to and control bodily functions; and c) The pineal gland is heavily vascularized, which would help it communicate with the body (Descartes speculated that the pineal gland sent out little corpuscular machines to influence the rest of the body). Descartes was criticized for his lack of anatomical knowledge when he wrote about that, and he has been ever since.

Tuesday, December 15, 2015

Habañeros, Carrier Hotels, and Distributed Aperture Systems

Today I Learned:
1) 1 Chopped-up habanero pepper, minus about half the seeds, is a perfectly appropriate amount of hot pepper to spice up a jar of tomato sauce.

2) A "carrier hotel" is essentially a router for the internet -- it's a big server complex where big data networks are switched together. Apparently they're pretty mundane-looking places once you get past the loads of server towers and gobs of wires. For some nifty photos of a carrier hotel in New York, check out http://ift.tt/1UxeSRm.

3) The in-development F-35 fighter plane is planned to have a really advanced helmet. The fighter has a thing called the Distributed Aperture System (DAS). DAS is a network of cameras and computers that captures 360 degrees of vision in every direction (indlucing up and down), tracks objects of interest in the air and on the ground, and relays all of this information to the pilot's helmet. This gives the pilot total visibility in every direction -- they could look down between their legs and see a tank directly beneath them, highlighted by the DAS.

The US navy is also keen on adopting DAS technology. Among other things, some folks in the navy think it could help track crew who have fallen out of the ship, which has been a notoriously difficult problem ever since there were boats on the open ocean.

Sunday, December 13, 2015

Detecting Selection Bias, Ant Thoraxes, and Tidal Locking

Tody I Learned:
1) An interesting rough method of detecting bias in selection processes (like hiring for jobs or applying to college) under certain conditions -- in particular, when you can measure the performance subsequent performance of a random sample of selectees and when applicant ability is equally high among different groups. If there is bias in the selection process against some group, then only the very best applicants from that group will be accepted, so a group overperforming dramatically is potentially a sign of bias against that group in a selection process.

A few more words about this here: http://ift.tt/1PclVhl

2) There's not all that much in an ant's thorax. Based on a couple of anatomical drawings of ants (from a book, so I can't link them), there's not much in an ant's thorax aside form its esophagus (important but kind of boring), nervous system (ok, that's pretty important), and some specialized endocrine glands. Speaking of which, ants have a lot of endocrine glands! And lots of pheromone-depositing glands! Different species have different glands, and there are dozens of them known in total, located all over the ant body plan.

3) Tidal locking* is much more common among bodies orbiting close to their parent. The reason is that tidal locking usually happens because tidal forces slow down or speed up a close-orbiting body until its rotation matches its parent, and tidal forces are much stronger for close-orbiting bodies. I had kind of inferred this trend from reading planetary descriptions in Mass Effect, but it's nice to have a mechanism to explain why it is so.

*when a planet/moon rotates and revolves in such a way that one side always faces its parent star/planet, as with Mercury or our moon.

Saturday, December 12, 2015

New Machine Learning Algorithm, The Crowning of Charlemagne, and Jovian Distances

Today I Learned:
1) ...about a machine learning algorithm with an interesting model from a joint project out of New York's Center for Data Science, the University of Toronto, and MIT. It's designed to solve the same sort of problem that most machine learning algorithms face -- to take some examples of a thing and some examples of not-the-thing, then tell you whether other stuff is more of that same thing or something else (in this case, the authors considered the problem of recognizing written characters).

The novelty of this algorithm is that it breaks the thing it's looking at (in this case, a character) into sub-parts, figures out how those parts are put together, and produces a *generative* model of the thing. In the case of characters, it breaks the character into things like lines and circles (things you can easily make with the stroke of a pen), figures out where those things start and end with respect to one another, and produces a sub-algorithm that describes how to produce a random example of that character (with some imperfections in the strokes and their positions). The algorithm can then look at a new character and figure out how likely it is that generative model would produce that.

For example, you might show the algorithm a few examples of handwritten lower-case 'i'. It might break its conception of 'i' into 'a longish vertical line' and 'a very short line' with the relationship 'the very short line goes <some amount> above the longish vertical line'. It makes a generative model out of this information -- call it makeI -- such that calling makeI returns a bitmap of a possible handwritten instance of a lower-case 'i'. If you show it a handwritten 'w', it essentially tries to make a bunch of 'i's using makeI, sees that none of them look like the 'w' you showed it, and declares with very high probability that it's not an 'i'. If you show it a handwritten 'j', it might see that some of the 'i's made by makeI look kind of like it, but not completely, so it might declare with only moderately high probability that the 'j' is not an 'i'.

(For the curious, this is a hierarchical Bayesian model over a nastily-high dimensional model. The algorithm does a quick, dirty estimate of the posterior to find likely maximum a posteriori peaks, then optimizes using numeric methods around that range to find maximum-likelihood generative models for a new piece of data. If the maximum a posteriori peak corresponds to a generative model close enough to the model the algorithm has for a known thing, it delares the new example to be of that type. There's another nifty thing it does that I don't understand as well where it can tune what "close enough" is using past examples.)

One startling thing about this algorithm is that it performs quite well given only one training example -- on some random real-world characters, after seeing exactly one example of a new character, it had a misclassification rate around 3%, which is slightly better than humans given the same task (and waaaay better than hierarchical deep learning (and about twice as good as the best modern machine learning network the authors applied)). Another cool thing -- the algorithm's generative models produced "written characters" that were, statistically speaking, indistinguishable from human-written characters, according to human judges.

Sadly, the article describing this algorithm is behind a paywall unless you have a Science subscription, but here it is anyway: http://tinyurl.com/pt9nked

2) It turns out the story of the birth of the Western Roman Empire is pretty interesting and pretty controversial. It happened right around 800 AD, in the court of Charlemagne, the King of the Franks at the time. For some time, the Roman empire had been ruled for some time from Constantinople, far in the east. It was a Christian empire that nomially ruled most of Europe, though in practice this it collected taxes and kept lots of bureaucratic notes and didn't do much else.

This changed on Christmas of 800, when then-pope Leo III crowned Charlemagne Emperor of Rome, pretty much declaring the Western Roman Empire overnight.

Leo III wasn't very popular, when elected. Shortly after his... ascension?... Leo was almost assassinated (technically, almost had his eyes and tongue ripped out -- this was a popular way of stripping public officials of power without damning ones-self to eternal damnation for murder), and he fled west and sought refuge with Charlemagne. He ingratiated himself with the King, and together the two decided that for Charlemagne to have the authority of Emperor of Rome would further Charlemagne's interests and help legitimize and protect Leo III. A bunch of administrative stuff happened more or less behind the scenes, of which we have some documentation today, but the big moment happened on Christmas, when, as part of a regular ritual ceremony, Charlemagne knelt before Leo III. To everyone's surprise (possibly even Charlemagne's!), Leo put a crown on Charlemagne's head and declared him Emperor. The written histories from the period are very dramatic on this point.

This was obviously incredibly important because it marked the beginning of the Western Roman Empire. It was also critically important as a symbol, because it implied that the authority of the Emperor came from God, and thus was granted by the papacy. This crowning moment more or less defined the relationship between the religious and secular leadership of the Western Roman Empire. There's some speculation that Leo did this more or less behind Charlemagne's back. If so, it may be the most important PR stunt in European history, all thanks to one man.

3) Jupiter is about as far from Saturn as it is from Earth (at the closest approaches of each, respectively).

Trial by Combat, Tempering and Annealing, and the Ice Line

Today I Learned:
1) Trial by combat was a real thing. In many of the Christian germanic tribes of the dark ages, when disputes couldn't be settled in other ways, the disputing parties would fight to the death, and it was expected that God would let the innocent party survive. This probably worked really well as long as everyone believed that it worked, because most guilty parties would rather confess their guilt than enter a trial by combat and, presumably, die.

2) Tempering a metal (when you heat a metal pretty hot and cool it quickly) works by disrupting the crystal structure of the metal. This makes it harder for cracks to propagate through the metal -- if a spreading crack encounters a defect in the crystal structure, the defect can often just absorb the crack without propagating it.

Annealing, on the other hand (when you heat a metal pretty hot and cool it *slowly*) reforms the crystal structure, giving the metal greater strength at the cost of some brittleness.

3) Astronomy seems to be full of critical lines and points and distances. Today I learned that one of these is the ice line, which is an orbital radius (in our solar system, between Mars and Jupiter). The ice line is the minimum distance at which icy bodies can form without being vaporized over geologic timescales by the parent star. This is imporant because a lot of material in early solar systems is ice, so bodies forming outside the ice line can generally collect many more large objects. That's why all of the planets outside the ice line are so much bigger than the ones outside it -- all the juicy ice mass in the inner solar system was melted away before it could form any really big chunks.

Friday, December 11, 2015

Wage Controls, Frosting Glass, and Abstract Algebra Terminology

Today I Learned:
1) During World War II, one of the effects of the wartime emergency plans in the US was wage controls, meaning that US companies were not allowed to pay more than a certain amount to their employees. This was part of a larger set of price controls to reign in inflation. This was a bit problematic for companies because it meant they couldn't compete for better workers by raising prices. What they *could* do was offer other benefits that weren't restricted by law, which is how employer-paid healthcare became standard.

After the war, Harry Truman proposed a national universal healthcare system, which was quite popular but opposed by doctors and hospitals, who had a lot of money in the private health insurance business, and labor unions, for whom employer-paid healthcare was a big trophy and bargaining chip. Truman lost.

2) ...how to frost glass! There are many ways to add a frosty finish to glass, but most of them are just variations on acid treatment (mostly using nasty fluoride-based acids of one form or another). You can also sand-blast glass, which is probably not as precise or nice as acid etching for, say, chemical glassware, but perhaps that's fine. If you're making many identical frosted glass pieces, you can also just etch the frosting into a glass mold.

3) A few abstract algebra terms:

Field: A field is a set of things on which "addition" and "multiplication" are defined (and their inverses, subtraction and division), such that the field is closed under both multiplcation and addition, and with some common sense properties satisfied for both operations (i.e., there is an addative and multiplicative identity, there are inverses for both operations for all elements of the field, both addition and subtraction are commutative and associative, and the distributive property holds). Some standard fields include the rational numbers, the real numbers, and the complex numbers. I tried really hard to come up with a good, instructive, non-numeric field, but I couldn't (the closest I could come up with was the set of lists of logical propositions, with addition being the set union of two lists of statements and multiplication being the list of all statements you could prove using two lists of statements, but it didn't really work out... for one thing, I'm not sure whether division is actually defined on such a "field"; for another, I couldn't come up with good addative and multiplicative identities that satisfied all of the properties of identities).

This is one of these terms that I keep learning and forgetting over and over again. Clearly I'm not using fields enough in my life.

Extension of a field: An extension of a field is basically a field that's a superset of another field. The most common example is the complex numbers, which are an extension of the real numbers -- it's the real numbers, "extended" with an extra element i and all the things you can get by adding and multiplying real numbers and i together. Another example would be the field consisting of all numbers of the form a + b*sqrt(2), where a and b are rational numbers -- this is the rational numbers extended with sqrt(2).

Automorphism: This is a mapping/function/rule that maps from a set onto itself and preserves some important property. Exactly what property is maintained depends on the kind of automorphism, but I think a good rule of thumb is that with an automorphism, if you add/multipy two elements together and apply the automorphism, it doesn't matter which one you do first (so for an automorphism A, you have A(x + y) = A(x) + A(y)).

Transcendental: This is a term I've heard all the time, but I never actually knew what it meant until today. A transcendental number (or element of a group) is one which cannot be defined as a root of an expression (usually a polynomial of some sort).

Also kind of learned about Galois groups, but at that point my comprehension dropped pretty precipitously. They may show up in a later TIL.

Wednesday, December 9, 2015

Repressing Plasmids, Honebee Song, and Facts About Transcriptases

Tody I Learned:
1) An important cloning consideration -- if you have a gene on a plasmid under repressor control, it's almost always a good idea to grow up the plasmid in a strain that expresses the repressor (or to co-express the repressor on the same or another plasmid). You don't want the gene to express because a) most genes are toxic when highly expressed, which lowers your plasmid yield and puts selection pressure on the bacteria to spit out or disable your plasmid, and b) expressed genes tend to mutate more, which can be a real pain downstream.

2) Honeybees are fairly vocal communicators. Or perhaps musical. They use sound to communicate, in any case, mostly but not entirely by buzzing their wings. Depending on the frequency and context, their sounds can mean a number of things, most of which amount to requesting more bees to do some task.

3) There are reverse transcriptases* that will copy both RNA and DNA templates. I didn't know that -- I thought there were only reverse transcriptases that only work on RNA and transcriptases that only work on DNA. Anyway, this is handy if you want to make lots of copies of cDNA**

Along these lines, I also learned today that, according to NEB (New England Biolabs, for the uninitiated -- a really awesome biotech company specializing in enzyme engineering with good prices and a fiercely independent mentality), transcription reactions should be run longer on short templates than on long templates. That's surprising. In almost every other context I've heard of, long templates require more time to process, which makes sense. I suspect there's some kind of piling up of enzymes that happens with short templates.

Also also, while I'm talking about transcriptases, today I learned that transcription works much better on linear DNA than on plasmids (circular DNA), because on a circular template the transcriptase will just run around and around and around, making very long transcripts of multiple copies of the plasmid. I'm pretty sure I should have known this (and may have learned it) in my last lab -- can anyone confirm or deny this?

*A transcriptase is an enzyme that "transcribes", which means it copies sequences of DNA into equivalent (reverse complementary) RNA. A *reverse* transcriptase is an enzyme that converts RNA into the equivalent (reverse complement) DNA. Reverse transcriptases are useful for turning RNAs from a sample into DNA, which is easier to work with and analyze.

**cDNA = complementary DNA, which means that it was produced from an RNA template. I think cDNA used to also stand for "cloned DNA", which didn't really mean much... can anyone else confirm this?

Tuesday, December 8, 2015

Signals vs Cues, Electric Cars, and Fire... In Spaaaaace!

Today I Learned:
1) In sociobiology (in particular the study of social insects) the term "signal" means something an organism does, and is evolutionarily selected to do, in order to intentionally tell others about some condition; the term "cue", in contrast, denotes something that an organism can use to infer some condition, but isn't selected for to act as communication. For example, a wounded person screaming for help is a signal, which another person can pick up on to know that somebody's in trouble; a person bleeding all over everything is a cue, which another person can pick up on to know that somebody's in trouble. Both are effective communication, but the signal is selected for on the basis of its information-bearing nature and the cue isn't. (Another example, an ant changing its behavior in response to a pheromone indicating the presence of food is picking up on a signal, while an ant changing its behavior in response to lower food availability in the colony is picking up on a cue).

2) Chevrolet sells a fully-electric small car (the Chevrolet Spark) for around $25,500 -- which becomes a net $17,000 after a US tax credit, at least as long as total Spark sales remain below 200,000 cars. That's more than *I* can afford right now, but I'm surprised how cheap it is. The Spark has an 80-mile/charge range, and takes between 7 and 20 hours to charge depending on what voltage you use to charge it. It has decent overall ratings, coming in at the #10 Affordable Subcompact Car in US News & World Report rankings.

I also learned today that electric vehicles don't, in general, need oil changes... because they don't need oil... because they have shockingly simple engines.

For a fun little anecdotal review of electric car ownership, see: http://ift.tt/1FRYwJf

Thanks to Chigozie Nri for pointing me down a rabbit hold of fascinating internet posts on electric cars.

3) Flammability works differently in space. NASA recently sent a burn-box to the ISS, in which they tried burning a bunch of common spacecraft materials. It turns out that the burning properties of some materials are radically different in low-G. For instance, a flame-retardant cotton-fiberglass blend similar to the stuff used in a lot of astronaut's cloths burns quite well in space. Also, the usual methods of putting out fires don't necessarily work -- spraying on flame-retardant foam, for example, can end up just spewing fire everywhere and making the situation worse.

Monday, December 7, 2015

Who Built The Moon, Live Streaming, and Induction Sensors

Today I Learned:
1) Sometime in the not-too-distant future, humanity will go back in time and construct the moon. No, seriously, a guy on the internet told me: http://ift.tt/1okOaNY

2) People will live stream almost anything, given an audience. In addition to the usual Russian dash cams, there are live streams of people eating, walking to work, and coding. The last one particularly interests me -- this is third-hand, but apparently some programmer decided to program on live stream once, and he decided it was the best thing ever because it's basically like pair-programming with 10 helpers over your shoulder. Except the ten guys don't have to be paid. I feel like there's a lot of potential value to be had in this area.

3) An induction sensor is a sensor that detects nearby metal by watching for inductive effects. Basically, it has a little bit of running current, which generates a magentic field, which in turn affects the current. When a metal object is brought nearby, it changes the shape of the magnetic field and in turn changes the current. Induction sensors are used on some 3D printers to detect the print bed.

Sunday, December 6, 2015

Solidworks, Aspect Oriented Programming, and Cake Pops

Today I Learned:
1) How to design a cuvette holder in Solidworks! Thanks to Erik Jue on this one!

2) Aspect Oriented Programming is a style of programming designed to address a thing called "cross-cutting concerns", which is anything that shows up in a bunch of places in code but is hard to actually make modular for some reason. For instance, lots of times you want to log a bunch of different events whenever they happen. Say, for instance, that whenever you make a call to any of an object's "set..." functions (say, setX, setY, setColor, or setVisible for some kind of shape Object), you want to print all the member variables of that object to a debug file.

You could manually wrap each call to the set function with some logging code, a la

outfile.write("Logging for setX: " + str(myObj.properties))
myObj.setX(5)
outfile.write("Logging for SetVisible: " + str(myObj.properties))
myObj.setVisible(True)

but this isn't maintainable in the least and involves a ton of redundant code

A slightly better thing to do would be to put the logging code inside the set functions for the class, a la

class ExampleShape:
   ...
   def setX(self, x):
       outfile.write("Logging for setX: " + str(myObj.properties))
       self.x = x
...
myObj.setX(5)

which is better but still a pain if you have many set functions in many different kinds of objects, and if you ever decide to log in a different way (say, by using some third-party logging package), then you have to go back and potentially rework a ton of code.

The Aspect Oriented (TM)* solution is to define an aspect with advice and cutpoints that define where to apply the... oh to heck with the official language -- basically you can write a rule that adds some wrapper code around STUFF, and a second rule that defines what STUFF is, and the compiler (assuming you're working in a language with AOP support) will find STUFF with the second rule and add whatever you need to STUFF using the first rule.

Using the logging example, the first rule would say "add a logging statement with the name of the function and all of the object's information", and the second rule would say "any method of the ExampleShape class starting with 'set'".

All this is kind of nifty, but potentially adds a lot of non-locality to code, and frankly I'm not convinced you can't do all of this with some carefully thoguht-out object-oriented programming.

*That's a joke, aspect oriented programming is not, in fact, trademarked.

3) There's a thing called a cake pop, which is a cake, crumbled into little bits, mixed with icing to form a pasty substance, and reformed into a delicious, starchy lolipop. Why didn't anybody tell me about this *before* I was vegan?

Saturday, December 5, 2015

PSA: Things As Scary As Guns

PSA:
In light of recent events in the media, I've decided to run down a short list of things that should scare you (if you're a statistically average US citizen) as much as civilians with guns. I'm not espousing any particular agenda with respect to guns-- I just wanted to calibrate my sense of damage done by guns against other causes of death, so I went and looked up some numbers. All numbers that follow are US figures, not world figures (sorry rest-of-world!).

First, let's get a baseline. A number of sources, including the CDC (where I've gotten most of the data for this post) peg the annual number of deaths from gun homicide at about 10,000. Deaths from mass shooting are a negligible contributor to this total, even with fairly liberal definitions (one of the standard definitions is an incident in which 4 or more people are injured or killed by a gunman).

So, what should frighten you as much as other people with guns?

1) Yourself with a gun. Technically, this should, statistically speaking, scare you twice as much as other people with a gun. Close to 20,000 people die annually by suicide with gun. I wanted to start with this one to prime you to be a little suspect of the statistics I'm going to present. Just because you should be scared of something "statistically" doesn't mean you should actually be scared of it. (For a numerically-better comparison, 10,062 people died from suicide by suffocation in 2013.)

2) Coal plants. Estimated premature deaths from coal usage are around 10,000/year. Most of these deaths are from respiratory disease exacerbated by particulates and other stuff produced by coal plants. This, by the way, is about 1/20th the per-kilowatt-hour rate of death caused by coal in China and most of the rest of the world, largely thanks to the Clean Air Act. This is also HUNDREDS OF TIMES more deadly per kilowatt hour than nuclear power, even including incidents like Chernobyl and Fukushima. Also, it produces comparable amounts of radioactive waste. Basically, coal is worse than nuclear in every respect except price -- nuclear power costs about twice as much, on average. (Also, for the record, oil is about twice as deadly as coal, natural gas is about 1/4 as deadly as coal, and wind and solar are both much safer than those but still not as safe as nuclear because of worker accidents.)

3) "Malignant neoplasm of the stomach". CDC's wording here. In 2013, 11,261 Americans died from malignant neoplasms of the stomach. So, if you stay up at night worrying about gunmen, you should stay up slightly more worrying about stomach cancer.

4) "Certain other intestinal infections". Yeah, ok, cancer's bad, but it turns out that all of the intestinal infections that don't get their own category add up to being just about as deadly as stomach cancer. Yech.

5) "Congenital malformations, deformations, and chromosomal abnormalities". How many people do you know who died from congenital malformations? How many do you know who died from gunshots? Those numbers are probably pretty close. Again, a reminder that nobody is the statistical average.

6) Flu. Sort of. The annual death rate by flu varies pretty wildly due to differences in strains and differences in the length of flu season. I decided to take the geometric mean of the minimum and maximum numbers of deaths in one flu season (usually a good way to find a rough estimate when you only have the minimum and maximum possible values of a quantity), which comes out to about 12,000.

I hope this helps!

Facebook Ad Settings, Imagerial Discs, and Early Life

Today I Learned:
1) Facebook keeps track of what it thinks you're interested in, obviously, so that it can post ads to you that it thinks you'll be interested in. Well, today I learned that you can view and modify those stored preferences! You can find them under Settings, in the Ads tab on the left, then "edit" on "Ads based on my preferences", and I'm not going to give more detail about how to find it because that's the kind of thing Facebook changes all the time. You may be able to URL-hack your way there at "http://ift.tt/1ODtC09" It will show you a list of topics Facebook thinks you're interested in. You can delete and add (sorry, pun) interests as you want.

This seems like an awesome feature that Facebook should advertise more (again, sorry). Yeah, Facebook is going to give you ads, but you get to pick what stuff it shows you! You can, in fact, make Facebook's ads work for you and be relevant to you, and the beauty of it is that this is exactly what Facebook wants. Every ad Facebook shows you that annoys you lowers Facebook's profit. Every ad Facebook shows you that you go "oh hey, that's actually kind of cool" and click on is money in the bank for Facebook. So why don't they advertise ad customization more? Do they think their automated algorithms are better at finding you relevant things than you are? Or maybe they just don't have a great PR department or UI. Or maybe they don't want to mention it because they think people will be creeped out by Facebook keeping track of their interests.

...speaking of which, if, unlike me, you're creeped out by Facebook keeping track of your interests, this post is for you too. From the "ads" tab in settings, you can also delete all of your interests, if you like, and you can also disable the use of ads based on site usage (yeah, Facebook does that too) and automatic ad-like sharing of your social actions. Just be warned, based on Facebook's track record, you may need to re-set these from time to time, so if it's something you're interested in, I would recommend checking up on your settings every once in a while.

In the meantime, I was quite entertained by Facebook's list of my "interests". Here's a semi-curated list, with some commentary.

Amazon.com (no lie there)
University (makes sense)
Education (being a University lover, I can understand that)
Sales (???)
Student
IFTTT (I guess it's been reading my TILs)
NBC (....)
Facebook (Should Facebook really be advertising for Facebook on Facebook?)
Psychology
Biology
Internet
meme
HowStuffWorks (Yes, this is the kind of thing I want to see more of!)
Philosophy
Family
Friendship
Child
Love (For these last four... what human *isn't* at least somewhat interested in these?)
Cycling (uh no. I don't know how to ride a bike, Facebook. Nice try.)
Crying (ok, 1) what? 2) Why is this under "Fitness and wellness"?)
Coffee (again, fail)
Food (...what human *isn't* at least somewhat interested in this?)
Dogs (eh)
Gardening (Sort of, I don't do it though)
Millennium Falcon (This I can get behind. (BTW, it's classified under "Hobbies and Activities"))
Dance (Thanks a lot, Mengsha and Michael!)
Reading
Arts and Music
Son (...?)
Image
Fan
Concept (????)
Hogwarts
Republican Party (United States)
Democratic Party (United States)
Religion Rebel Alliance
Life Fictional Universe
(Not going to put it down here, but Facebook nailed exactly which phone model I have....)
Gmail users (yup, I tend to like those)
League of Legends (I've barely played, not sure where that's coming from)
NPR (yup)
Chewbacca (Ok, how the heck did it know that???)
i fucking love science (that explains why I get so many "i fucking love science" posts)
Bernie Sanders (interesting...)
George Takei (I'd vote for *him*)
Don McCullin (I don't know who that is)
Girls (band) (I don't know who that is)
Why? (American band) (I don't know who that is)
Cosmetics (?!?!)
Shopping and Fashion (?!?!?!?!?!)
Wand (?!?!... what?!?!?)
(five tags under "sports". It really doesn't even matter what they are, it's just hilarious that there were any)
Wait (system call) (Has facebook been profiling my software?!?! =P)

2) Imaginal discs are found in all insects! I'd previously heard of imaginal discs in the contexts of pupating caterpillars. In case you don't know, caterpillar metamorphosis is kind of creepy, quite mysterious, and really, really cool. Once ensconced in a cocoon, a caterpillar essentially melts into a goop of loose cells and nutrient broth, from which the butterfly is reformed whole. The caterpillar doesn't *completely* break down, though -- small clusters of cells, called imaginal discs, stay intact, and it's these clumps of tissue that form the seed for the new butterfly's organs.

Today I learned that imaginal discs are common to... I think all insects? They control development of insect body parts. In ants, for example, caste differentiation is driven at least in part by differences in regulation of the different imaginal discs to achieve different body plans. This goes some way toward explaining how butterfly metamorphosis evolved -- it's one of the more complex components to the metamorphosis, and this means that it would have already been present in the earliest proto-butterflies.

3) This one's going to be an unusual TIL in that it's not a fact. It's more a realization and a change of interpretation. Quick question -- when would you say was the birth of the modern land biome? Think about that for a little bit.

Before today, I probably would have said something like the Triassic (the first geologic period with dinosaurs), or maybe before then, sometime around when fungi evolved the ability to break down wood and we got the first carboniferous forests that we would recognize as forests, rather than giant piles of dead, unrotted wood covered in plants. Today I realized that a *lot* of the macroscopic life most important to our modern land biomes actually didn't evolve until the Cretaceous (the last age of the dinosaurs, a warm period lasting 80 million years, ending with the mass-extinction that offed the non-bird dinosaurs). The cretaceous saw the early evolution of birds(!), mammals(!!), eusocial insects(!!!), and flowering plants(!!!!). That's... really a lot of important groups, at least on land. It puts into perspective just how alien this planet was a hundred or two hundred million years ago -- no birds flitting from branch to branch, no bees buzzing from flower to flower and no flowers for bees to buzz between. Not a rat or mouse or vole or shrew. There might have been ants... but they weren't colonial yet. Just single ants, wandering about. No pollen allergies... because there was no pollen.

Sometimes I think that if you want to be a xenobiologist, you should study plants. Maybe archaeology would be just as good a substitute.

(Also, while double-checking facts for this fact, today I learned that in the Cretaceous, corals were not the dominant reef-builders on Earth -- check out rudists!)

Friday, December 4, 2015

Likes, Graphite Crucibles, and Amoeba Culture

Today I Learned:
1) You can "Like" your own posts on Facebook. Seriously?

2) Graphite makes a really good crucible material. It won't meld to your metal while it's molten, and it's very resistant to warping at high temperatures. Relatedly, insulation for things like crucibles include a kind of ceramic that feels like styrofoam -- it's light and porous and seems a little crumbly. Apparently the space shuttle is heat-insulated with stuff kind of like that.

3) Culturing amoebas is really cool. There's this interesting dynamic you get growing protists that you don't have with bacteria or mammalian cells... involving contamination. See, amoebas eat bacteria, so the way you feed them is to co-culture them with E. coli or some other standard bacteria. The trouble is, if there are too many bacteria, they outgrow the amoeba and take over the culture. So you have to keep it at a sort of low-level contamination, which can apparently be... tricky. Also, amoeba need more air than most lab bacteria. Some species also can't swim very well, so they tend to settle to the bottom of any culture they grow in. That's bad, if they grow quantities such that the form a sediment and choke each other out. The solution: bubblers! Also also, amoeba pellet weirdly when you centrifuge them -- they make a tiny normal-looking pellet, then a giant, totally clear pellet on top of that. I didn't learn why.

Thursday, December 3, 2015

Fish Yawns, Gun Defense, and Runoff Reactions

Today I Learned:
1) Fish are generally believed to yawn (they do a thing that looks like yawning, which is usually but not always interpreted as a yawn). Fish sometimes use yawns as an aggressive or territorial signal, but they also seem to just... do it, sometimes.

2) Guns are used a LOT in self-defense in the US. This is a big, politically-charged topic, so reading Wikipedia is probably not giving me the full story. Furthermore, different groups have come up with WILDLY different estimates of defensive gun use, but they're pretty much all far above what I would have guessed. Technically, the range of possible rates of defensive gun use range from 127/year (not a typo) to 33.1 million/year. That's about the highest variance I've seen in any estimate not involving things like Dyson spheres and bagels.

33.1 million per year seems ludicrously high -- I'm pretty sure fewer than one out of six Americans uses a gun in self defense each year -- but even the more accepted lower estimates are pretty high. One of the lowest was an estimate by a professor at the Harvard School of Law at 55,000-80,000/year. For reference, that's 5-8 times higher than the annual number of *deaths* caused by guns in the US. Another interesting statistic: in cases of defensive gun use, the gun is actually fired somewhere between 1/4 and 1/3 of the time.

3) We have a thing in our lab where we prepare extracts from bacterial cells, and one of the steps involved is an 80 minute incubation of the freshly-prepared extract at 37 C. We call this a "runoff reaction", and it's supposed to be the step in which genomic DNA is degraded. Today I learned why that step is called a "runoff reaction". This kind of step is used in other cell-innard-extracting techniques to get rid of lingering RNA strands that might still be bound to ribosomes, which makes them temporarily inaccessible to degradation machinery. The incubation step gives the ribosomes a chance to finish translating out protein, freeing the RNA for degradation... since the ribosomes literally run off the end of the RNA, it's a "runoff reaction". Thanks to Anders Knight for this epipheny!

Wednesday, December 2, 2015

Python's Name, Icy, and Continuum Analytics

Today I Learned:
1) Python, the computer language, was not named after the animal. It was named after Monty Python's Flying Circus.

2) ...about an alternative to ImageJ called Icy. It's also an open-source, easily-extensible image analysis program written in Java (or at least something that runs on the JVM). It seems to be written with even more of an eye than ImageJ towards linking with other kinds of programming -- you can write scripts for it in Python and javascript, and it has some sort of native compatibility with Matlab. The cutest thing is that it has a tab that appears to be literally an emulated instance of ImageJ, so that you'll always have ImageJ at your fingertips if you want it. Icy does seem quite sluggish and a little rough around the edges, though, so I don't see myself using it a ton.

3) Anaconda, the python scientific computing environment manager, was developed by and is owned by a for-profit company, Continuum Analytics. This despite Anaconda being free and open-source, and being the only major project of the company. It seems Continuum Analytics' monetization scheme is essentially training programs for companies. I hope this catches on, because it's a very nice system (once again, declaring no conflicts of interest here).

4th Order Polynomials, Soviets on Mars, and The First Female President

Today I Learned:
1) There is an analytical solution for 4th-order polynomials! It's a godawful mess, but it exists. Also, there is provably no analytical solution for 5th-order or higher polynomials.

2) In 1971, the Soviet Union became the first organization to put a rocket on Mars. It broadcasted for about 20 seconds before going silent. At least they got it there!

3) The United States has had a female president, albeit very briefly and not an elected one. In 1920, Woodrow Wilson had a stroke during some rather important diplomatic proceedings. Turns out that at the time, there wasn't a formal chain of command, and Wilson's Vice President simply refused to take the position. So his wife stepped up and Presidented for Wilson while he recovered.

Tuesday, December 1, 2015

Maude Menten, Michaelis-Menten, and Free-Climbing

Today I Learned:
1) The "Menten" in "Michaelis-Menten kinetics" refers to Maude Menton, a Canadian MD from the turn of the 20th Century. From her wiki page, it looks like she was a heck of an interesting person. Quote, "Skloot portrays Menten as a petite dynamo of a woman who wore "Paris hats, blue dresses with stained-glass hues, and Buster Brown shoes." She drove a Model T Ford through the University of Pittsburgh area for some 32 years and enjoyed many adventurous and artistic hobbies. She played the clarinet, painted paintings worthy of art exhibitions, climbed mountains, went on an Arctic expedition, and enjoyed astronomy. She also mastered several languages, including Russian, French, German, Italian, and at least one Native-American language." Oh, and she got her full professorship in 1948, at the age of 70. If that had happened closer to our time, I would have wondered whether it spoke more to sexism in science or to the fiercely competitive nature of academia. Given the time period, though, I'm pretty sure that was mostly sexism.

2) Speaking of Michaelis-Menten kinetics, today I learned that Michaelis-Menten kinetics can be derived from one of two similar-sounding assumptions -- either that the intermediate reaction is at steady state, or that the intermediate reaction has zero flux. Somehow, apparently, the results you get from these two assumptions are slightly different?! Why? Aren't those the same assumption? I would really like to confirm this. Chris Lennox?

3) Free climbers *do* use climbing equipment like pistons and hooks and safety lines, but only as safeguards against slips and falls, not to make the climbing easier. Also, free-climbers often (always?) chalk their hands when the climb. In retrospect, those two facts should have been obvious, but they were not.