Question:
I understand that a DSP is optimized for digital signal processing, but I'm not sure how that impacts to the task of choosing an IC.  Almost everything I do with a microcontroller involves the processing of digital signals!
For example, let's compare the popular Microchip dsPIC30 or 33 DSP  and their other 16-bit offering, the PIC24 general purpose microcontroller.  The dsPIC and the PIC can be configured to have the same memory and speed, they have similar peripherial sets, similar A/D capability, pin counts, current draw, etc.  The only major difference that appears on Digikey's listing is the location of the oscillator.  I can't tell the difference by looking at the prices (or any other field, for that matter.)
If I want to work with a couple of external sensors using various protocols (I2C, SPI, etc.), do some A/D conversions, store some data on some serial flash,  respond to some buttons, and push data out to a character LCD and over an FT232 (a fairly generic embedded system), which chip should I use?  It doesn't appear that the DSP will lag behind the PIC in any way, and it offers this mysterious "DSP Engine."  My code always does math, and once in a while I need floating point or fractional numbers, but I don't know if I'll benefit from using a DSP.
A more general comparison between another vendor's DSPs and microcontrollers would be equally useful; I'm just using these as a starting point for discussion.

To be honest the line between the two is almost gone nowadays and there are processors that can be classified as both (AD Blackfin for instance).
Generally speaking:
Microcontrollers are integer math processors with an interrupt sub system.  Some may have hardware multiplication units, some don't, etc.  Point is they are designed for simple math, and mostly to control other devices.
DSPs are processors optimized for streaming signal processing.  They often have special instructions that speed common tasks such as multiply-accumulate in a single instruction.  They also often have other vector or SIMD instructions.  Historically they weren't interrupt based systems and operated with non-standard memory systems optimized for their purpose making them more difficult to program.  They were usually designed to operate in one big loop processing a data stream.  DSP's can be designed as integer, fixed point or floating point processors.
Historically if you wanted to process audio streams, video streams, do fast motor control, anything that required processing a stream of data at high speed you would look to a DSP.
If you wanted to control some buttons, measure a temperature, run a character LCD, control other ICs which are processing things, you'd use a microcontroller.
Today, you mostly find general purpose microcontroller type processors with either built in DSP-like instructions or with on chip co-processors to deal with streaming data or other DSP operations.  You don't see pure DSP's used much anymore except in specific industries.
The processor market is much broader and more blurry than it used to be.  For instance i hardly consider a ARM cortex-A8 SoC a micro-controller but it probably fits the standard definition, especially in a PoP package.
EDIT: Figured i'd add a bit to explain when/where i've used DSPs even in the days of application processors.
A recent product i designed was doing audio processing with X channels of input and X channels of output per 'zone'.  The intended use for the product meant that it would often times sit there doing its thing, processing the audio channels for years without anyone touching it.  The audio processing consisted of various acoustical filters and functions.  The system also was "hot plugable" with the ability to add some number of independent 'zones' all in one box.  It was a total of 3 PCB designs (mainboard, a backplane and a plug in module) and the backplane supported 4 plug in modules.  Quite a fun project as i was doing it solo, i got to do the system design, schematic, PCB layout and firmware.
Now i could have done the entire thing with an single bulky ARM core, i only needed about 50MIPS of DSP work on 24bit fixed point numbers per zone.  But because i knew this system would operate for an extremely long time and knew it was critical that it never click or pop or anything like that.  I chose to implement it with a low power DSP per zone and a single PIC microcontroller that played the system management role.  This way even if one of the uC functions crashed, maybe a DDOS attack on its Ethernet port, the DSP would happily just keep chugging away and its likely no one would ever know.
So the microcontroller played the role of running the 2 line character LCD, some buttons, temperature monitoring and fan control (there were also some fairly high power audio amplifiers on each board) and even served an AJAX style web page via ethernet.  It also managed the DSPs via a serial connection.
So thats a situation where even in the days where i could have used a single ARM core to do everything, the design dictated a dedicated signal processing IC.
Other areas where i've run into DSPs:
*High End audio - Very high end receivers and concert quality mixing and processing gear
*Radar Processing - I've also used ARM cores for this in low end apps.
*Sonar Processing
*Real time computer vision
For the most part, the low and mid ends of the audio/video/similar space have been taken over by application processors which combine a general purpose CPU with co-proc offload engines for various applications.


Question:
The event horizon of a black hole is where gravity is such that not even light can escape. This is also the point I understand that according to Einstein time dilation will be infinite for a far-away-observer.
If this is the case how can anything ever fall into a black hole.  In my thought experiment I am in a spaceship with a powerful telescope that can detect light at a wide range of wavelengths.  I have it focused on the black hole and watch as a large rock approaches the event horizon.
Am I correct in saying that from my far-away-position the rock would freeze outside the event horizon and would never pass it? If this is the case how can a black hole ever consume any material, let alone grow to millions of solar masses.  If I was able to train the telescope onto the black hole for millions of years would I still see the rock at the edge of the event horizon?
I am getting ready for the response of the object would slowly fade.  Why would it slowly fade and if it would how long would this fading take?  If it is going to red shift at some point would the red shifting not slow down to a standstill? This question has been bugging me for years!
OK - just an edit based on responses so far.  Again, please keep thinking from an observers point of view.  If observers see objects slowly fade and slowly disappear as they approach the event horizon would that mean that over time the event horizon would be "lumpy" with objects invisible, but not passed through?  We should be able to detect the "lumpiness" should we not through?

It is true that, from an outside perspective, nothing can ever pass the event horizon.  I will attempt to describe the situation as best I can, to the best of my knowledge.
First, let's imagine a classical black hole.  By "classical" I mean a black-hole solution to Einstein's equations, which we imagine not to emit Hawking radiation (for now).  Such an object would persist for ever.  Let's imagine throwing a clock into it.  We will stand a long way from the black hole and watch the clock fall in.
What we notice as the clock approaches the event horizon is that it slows down compared to our clock.  In fact its hands will asymptotically approach a certain time, which we might as well call 12:00.  The light from the clock will also slow down, becoming red-shifted quite rapidly towards the radio end of the spectrum.  Because of this red shift, and because we can only ever see photons emitted by the clock before it struck twelve, it will rapidly become very hard to detect.  Eventually it will get to the point where we'd have to wait billions of years in between photons.  Nevertheless, as you say, it is always possible in principle to detect the clock, because it never passes the event horizon.
I had the opportunity to chat to a cosmologist about this subject a few months ago, and what he said was that this red-shifting towards undetectability happens very quickly. (I believe the "no hair theorem" provides the justification for this.)  He also said that the black-hole-with-an-essentially-undetectable-object-just-outside-its-event-horizon is a very good approximation to a black hole of a slightly larger mass.
(At this point I want to note in passing that any "real" black hole will emit Hawking radiation until it eventually evaporates away to nothing.  Since our clock will still not have passed the event horizon by the time this happens, it must eventually escape - although presumably the Hawking radiation interacts with it on the way out. Presumably, from the clock's perspective all those billions of years of radiation will appear in the split-second before 12:00, so it won't come out looking much like a clock any more. To my mind the resolution to the black hole information paradox lies along this line of reasoning and not in any specifics of string theory.  But of course that's just my opinion.)
Now, this idea seems a bit weird (to me and I think to you as well) because if nothing ever passes the event horizon, how can there ever be a black hole in the first place?  My friendly cosmologist's answer boiled down to this: the black hole itself is only ever an approximation.  When a bunch of matter collapses in on itself it very rapidly converges towards something that looks like a black-hole solution to Einstein's equations, to the point where to all intents and purposes you can treat it as if the matter is inside the event horizon rather than outside it.  But this is only ever an approximation because from our perspective none of the infalling matter can ever pass the event horizon.


Question:
Not to be confused with what is the mechanism of acid-catalyzed ring opening of epoxides.

What is the correct order of regioselectivity of acid-catalyzed ring-opening of epoxides: $3^\circ$ > $2^\circ$ > $1^\circ$ or $3^\circ$ > $1^\circ$ > $2^\circ$? I am getting ready to teach epoxide ring-opening reactions, and I noticed that my textbook has something different to say about the regioselectivity of acid-catalyzed ring-opening than what I learned. My textbook does not agree with 15 other introductory texts I own, but it does agree with one. None of my Advanced Organic Chemistry texts discuss this reaction at all. Thus, I have no ready references to go read.

Edit:  My textbook is in the minority, and it is a first edition. Is it wrong, or do the other 15 texts (including some venerable ones) oversimplify the matter?
What I learned
Although the acid-catalyzed ring-opening of epoxides follows a mechanism with SN2 features (inversion of stereochemistry, no carbocation rearrangements), the mechanism is not strictly a SN2 mechanism. The transition state has more progress toward the C-LG bond breaking than an SN2, but more progress toward the C-Nu bond forming than SN1. There is significantly more $\delta ^+$ character on the carbon than in SN2, but not as much as in SN1. The transition states of the three are compared below:

In a More O’Ferrall-Jencks diagram, the acid-catalyzed ring-opening of epoxides would follow a pathway between the idealized SN2 and SN1 pathways.

Because of the significant $\delta ^+$ character on the carbon, the reaction displays regioselectivity inspired by carbocation stability (even though the carbocation does not form): the nucleophile preferentially attacks at the more hindered position (or the position that would produce the more stable carbocation if one formed). If a choice between a primary and a secondary carbon is presented, the nucleophile preferentially attacks at the secondary position. If a choice between a primary and a tertiary carbon is presented, the nucleophile preferentially attacks at the tertiary position. If a choice between a secondary and a tertiary carbon is presented, the nucleophile preferentially attacks at the tertiary position.

The overall order of regioselectiveity is $3^\circ$ > $2^\circ$ > $1^\circ$.
What my textbook says
My text agrees that the mechanism is somewhere in between the SN2 and SN1 mechanisms, but goes on to say that because it is in between, electronic factors (SN1)  do not always dominate. Steric factors (SN2) are also important. My text says that in the comparison between primary and secondary, primary wins for steric factors. In other words, the difference between the increased stabilization of the $\delta ^+$ on secondary positions over primary positions is not large enough to overcome the decreased steric access at secondary positions. For the comparison of primary and tertiary, tertiary wins. The increased electronic stabilization at the tertiary position is enough to overcome the decreased steric access at the tertiary position. The comparison between secondary and tertiary is not directly made, but since $3^\circ$ > $1^\circ$ and $1^\circ$ > $2^\circ$, it is implied that $3^\circ$ > $2^\circ$.

If this pattern is true, then other cyclic "onium" ions (like the bromonium ion and the mercurinium ion) should also behave this way. They don't.
Typical of introductory texts, no references are provided. A Google search did not yield satisfactory results and the Wikipedia article on epoxides is less than helpful.
Since I 15 other introductory texts on my bookshelf, I consulted all of them on this reaction. The following is a summary of my findings. Only two of the texts (the one I am using and one other) describe the regioselectivity as $3^\circ$ > $1^\circ$ > $2^\circ$. All of the other books support the other pattern, including Morrison and Boyd (which lends credence to the pattern that I learned).
Books that have $3^\circ$ > $2^\circ$ > $1^\circ$

Brown, Foote, Iverson, and Anslyn
Hornsback
Ege
Wade
Bruice
Smith
Fessenden and Fessenden
Volhardt and Schore
Solomons and Fryhle
Jones
Baker and Engel
Ouellette and Rawn
Carey
Morrison and Boyd
Streightweiser and Heathcock

Books that have $3^\circ$ > $1^\circ$ > $2^\circ$

Klein (the text I am using)
McMurray

I also surveyed my various Advanced Organic texts (March, Smith, Carey and Sundberg, Wyatt and Warren, Lowry and Richardson, etc.). Interestingly, none of them even mention acid-catalyzed ring-opening of epoxides (either by Brønsted or Lewis acids). I suspect that these omissions mean that this reaction 1) has difficult to predict regioselectivity (despite the predominance of introductory books that suggest otherwise), and thus 2) is synthetically useless. If #2 is true, then why is this reaction in introductory organic texts?

First part
It won't decide the issue but the Organic Chemistry text by Clayden, Greeves, Warren and Wothers also mentions that the matter might not be as clear-cut as the majority of your textbooks make it seem. This might strengthen the position of the textbook you're using a bit. But again, there are no references given. Here is the relevant passage (especially the last two paragraphs):

Second Part
I have found the following passage on the formation of halohydrins from epoxides in the book by Smith and March (7th Edition), chapter 10-50, page 507:

Unsymmetrical epoxides are usually opened to give mixtures of regioisomers. In a typical reaction, the halogen is delivered to the less sterically hindered carbon of the epoxide. In the absence of this
structural feature, and in the absence of a directing group, relatively equal mixtures of
regioisomeric halohydrins are expected. The phenyl is such a group, and in 1-phenyl-2-
alkyl epoxides reaction with $\ce{POCl3}/\ce{DMAP}$ ($\ce{DMAP}$ = 4-dimethylaminopyridine) leads to
the chlorohydrin with the chlorine on the carbon bearing the phenyl.${}^{1231}$ When done in an
ionic liquid with $\ce{Me3SiCl}$, styrene epoxide gives 2-chloro-2-phenylethanol.${}^{1232}$ The
reaction of thionyl chloride and poly(vinylpyrrolidinone) converts epoxides to the corresponding
2-chloro-1-carbinol.${}^{1233}$ Bromine with a phenylhydrazine catalyst, however,
converts epoxides to the 1-bromo-2-carbinol.${}^{1234}$ An alkenyl group also leads to a
halohydrin with the halogen on the carbon bearing the $\ce{C=C}$ unit.${}^{1235}$ Epoxy carboxylic
acids are another example. When $\ce{NaI}$ reacts at pH 4, the major regioisomer is the 2-iodo-3-
hydroxy compound, but when $\ce{InCl3}$ is added, the major product is the 3-iodo-2-hydroxy
carboxylic acid.${}^{1236}$
References:
${}^{1231}$  Sartillo-Piscil, F.; Quinero, L.; Villegas, C.; Santacruz-Juarez, E.; de Parrodi, C.A. Tetrahedron Lett. 2002,
43, 15.
${}^{1232}$  Xu, L.-W.; Li, L.; Xia, C.-G.; Zhao, P.-Q. Tetrahedron Lett. 2004, 45, 2435.
${}^{1233}$  Tamami, B.; Ghazi, I.; Mahdavi, H. Synth. Commun. 2002, 32, 3725.
${}^{1234}$  Sharghi, H.; Eskandari, M.M. Synthesis 2002, 1519.
${}^{1235}$  Ha, J.D.; Kim, S.Y.; Lee, S.J.; Kang, S.K.; Ahn, J.H.; Kim, S.S.; Choi, J.-K. Tetrahedron Lett. 2004, 45, 5969.
${}^{1236}$  Fringuelli, F.; Pizzo, F.; Vaccaro, L. J. Org. Chem. 2001, 66, 4719. Also see Concellón, J.M.; Bardales, E.;
Concellón, C.; García-Granda, S.; Díaz, M.R. J. Org. Chem. 2004, 69, 6923.


Question: Lots of chips nowadays require smoothing capacitors between VCC and GND for proper function. Given that my projects run at all sorts of different voltage and current levels, I was wondering if anyone had any rules of thumb for a) how many and b) what size capacitors should be used to ensure that power supply ripple doesn't affect my circuits?

You need to add a couple of more questions -- (c) what dielectric should I use and
(d) where do I place the capacitor in my layout.
The amount and size varies by application. For power supply components
the ESR (effective series resistance) is a critical component. For example the MC33269 LDO datasheet lists an ESR recommendation of 0.2Ohms to 10Ohms. There is a minimum amount
of ESR required for stability.
For most logic ICs and op-amps I use a 0.1uF ceramic capacitor. I place the capacitor
very close to the IC so that there is very short path from the capacitor leads
to the ground. I use extensive ground and power planes to provide low impedance
paths.
For power supply and high current components each application is different.
I follow the manufacturer recommendations and place the capacitors very close
to the IC.
For bulk filtering of power inputs coming into the board I will typically use a
10uF ceramic X7R capacitor. Again this varies with application.
Unless there is an minimum ESR requirement for stability or I need very large
values of capacitance I will use either X7R or X5R dielectrics. Capacitance
varies with voltage and temperature. Currently it is not difficult to get
affordable 10uF ceramic capacitors. You do not need to over specify the voltage
rating on ceramic capacitors. At the rated voltage the capacitance is within
the tolerance range. Unless you increase the voltage above the dielectric breakdown
you are only losing capacitance. Typically the dielectric strength is 2 to 3 times
the rated voltage.
There is a very good application note about grounding and decoupling
by Paul Brokaw called "An IC Amplifier User's Guide to Decoupling,
Grounding,. and Making Things Go Right for a Change".


Question:
I need to design a moving average filter that has a cut-off frequency of 7.8 Hz. I have used moving average filters before, but as far as I'm aware, the only parameter that can be fed in is the number of points to be averaged... How can this relate to a cut-off frequency?
The inverse of 7.8 Hz is ~130 ms, and I'm working with data that are sampled at 1000 Hz. Does this imply that I ought to be using a moving average filter window size of 130 samples, or is there something else that I'm missing here?

The moving average filter (sometimes known colloquially as a boxcar filter) has a rectangular impulse response:
$$
h[n] = \frac{1}{N}\sum_{k=0}^{N-1} \delta[n-k]
$$
Or, stated differently:
$$
h[n] = \begin{cases}
\frac{1}{N}, && 0 \le n < N \\
0, && \text{otherwise}
\end{cases}
$$
Remembering that a discrete-time system's frequency response is equal to the discrete-time Fourier transform of its impulse response, we can calculate it as follows:
$$
\begin{align}
H(\omega) &= \sum_{n=-\infty}^{\infty} x[n] e^{-j\omega n} \\
&= \frac{1}{N}\sum_{n=0}^{N-1} e^{-j\omega n}
\end{align}
$$
To simplify this, we can use the known formula for the sum of the first $N$ terms of a geometric series:
$$
\sum_{n=0}^{N-1} e^{-j\omega n} = \frac{1-e^{-j \omega N}}{1 - e^{-j\omega}}
$$
What we're most interested in for your case is the magnitude response of the filter, $|H(\omega)|$. Using a couple simple manipulations, we can get that in an easier-to-comprehend form:
$$
\begin{align}
H(\omega) &= \frac{1}{N}\sum_{n=0}^{N-1} e^{-j\omega n} \\
&= \frac{1}{N} \frac{1-e^{-j \omega N}}{1 - e^{-j\omega}} \\
&= \frac{1}{N} \frac{e^{-j \omega N/2}}{e^{-j \omega/2}} \frac{e^{j\omega N/2} - e^{-j\omega N/2}}{e^{j\omega /2} - e^{-j\omega /2}}
\end{align}
$$
This may not look any easier to understand. However, due to Euler's identity, recall that:
$$
\sin(\omega) = \frac{e^{j\omega} - e^{-j\omega}}{j2}
$$
Therefore, we can write the above as:
$$
\begin{align}
H(\omega) &= \frac{1}{N} \frac{e^{-j \omega N/2}}{e^{-j \omega/2}} \frac{j2 \sin\left(\frac{\omega N}{2}\right)}{j2 \sin\left(\frac{\omega}{2}\right)} \\
&= \frac{1}{N} \frac{e^{-j \omega N/2}}{e^{-j \omega/2}} \frac{\sin\left(\frac{\omega N}{2}\right)}{\sin\left(\frac{\omega}{2}\right)}
\end{align}
$$
As I stated before, what you're really concerned about is the magnitude of the frequency response. So, we can take the magnitude of the above to simplify it further:
$$
|H(\omega)| = \frac{1}{N} \left|\frac{\sin\left(\frac{\omega N}{2}\right)}{\sin\left(\frac{\omega}{2}\right)}\right|
$$
Note: We are able to drop the exponential terms out because they don't affect the magnitude of the result; $|e^{j\omega}| = 1$ for all values of $\omega$. Since $|xy| = |x||y|$ for any two finite complex numbers $x$ and $y$, we can conclude that the presence of the exponential terms don't affect the overall magnitude response (instead, they affect the system's phase response).
The resulting function inside the magnitude brackets is a form of a Dirichlet kernel. It is sometimes called a periodic sinc function, because it resembles the sinc function somewhat in appearance, but is periodic instead.
Anyway, since the definition of cutoff frequency is somewhat underspecified (-3 dB point? -6 dB point? first sidelobe null?), you can use the above equation to solve for whatever you need. Specifically, you can do the following:

Set $|H(\omega)|$ to the value corresponding to the filter response that you want at the cutoff frequency.
Set $\omega$ equal to the cutoff frequency. To map a continuous-time frequency to the discrete-time domain, remember that $\omega = 2\pi \frac{f}{f_s}$, where $f_s$ is your sample rate.
Find the value of $N$ that gives you the best agreement between the left and right hand sides of the equation. That should be the length of your moving average.


Question: These two seem very similar and have almost an identical structure. What's the difference? What are the time complexities for different operations of each?

Heap just guarantees that elements on higher levels are greater (for max-heap) or smaller (for min-heap) than elements on lower levels, whereas BST guarantees order (from "left" to "right"). If you want sorted elements, go with BST.

Source:

Heap is better at findMin/findMax (O(1)), while BST is good at all finds (O(logN)). Insert is O(logN) for both structures. If you only care about findMin/findMax (e.g. priority-related), go with heap. If you want everything sorted, go with BST.

Source:


Question: How are PCA and classical MDS different? How about MDS versus nonmetric MDS? Is there a time when you would prefer one over the other? How do the interpretations differ?

Classic Torgerson's metric MDS is actually done by transforming distances into similarities and performing PCA (eigen-decomposition or singular-value-decomposition) on those. [The other name of this procedure (distances between objects -> similarities between them -> PCA, whereby loadings are the sought-for coordinates) is Principal Coordinate Analysis or PCoA.] So, PCA might be called the algorithm of the simplest MDS.
Non-metric MDS is based on iterative ALSCAL or PROXSCAL algorithm (or algorithm similar to them) which is a more versatile mapping technique than PCA and can be applied to metric MDS as well. While PCA retains m important dimensions for you, ALSCAL/PROXSCAL fits configuration to m dimensions (you pre-define m) and it reproduces dissimilarities on the map more directly and accurately than PCA usually can (see Illustration section below).
Thus, MDS and PCA are probably not at the same level to be in line or opposite to each other. PCA is just a method while MDS is a class of analysis. As mapping, PCA is a particular case of MDS. On the other hand, PCA is a particular case of Factor analysis which, being a data reduction, is more than only a mapping, while MDS is only a mapping.
As for your question about metric MDS vs non-metric MDS there's little to comment because the answer is straightforward. If I believe my input dissimilarities are so close to be euclidean distances that a linear transform will suffice to map them in m-dimensional space, I will prefer metric MDS. If I don't believe, then monotonic transform is necessary, implying use of non-metric MDS.

A note on terminology for a reader. Term Classic(al) MDS (CMDS) can have two different meanings in a vast literature on MDS, so it is ambiguous and should be avoided. One definition is that CMDS is a synonym of Torgerson's metric MDS. Another definition is that CMDS is any MDS (by any algorithm; metric or nonmetric analysis) with single matrix input (for there exist models analyzing many matrices at once - Individual "INDSCAL" model and Replicated model).

Illustration to the answer. Some cloud of points (ellipse) is being mapped on a one-dimensional mds-map. A pair of points is shown in red dots.

Iterative or "true" MDS aims straight to reconstruct pairwise distances between objects. For it is the task of any MDS. Various stress or misfit criteria could be minimized between original distances and distances on the map: $\|D_o-D_m\|_2^2$, $\|D_o^2-D_m^2\|_1$, $\|D_o-D_m\|_1$. An algorithm may (non-metric MDS) or may not (metric MDS) include monotonic transformation on this way.
PCA-based MDS (Torgerson's, or PCoA) is not straight. It minimizes the squared distances between objects in the original space and their images on the map. This is not quite genuine MDS task; it is successful, as MDS, only to the extent to which the discarded junior principal axes are weak. If $P_1$ explains much more variance than $P_2$ the former can alone substantially reflect pairwise distances in the cloud, especially for points lying far apart along the ellipse. Iterative MDS will always win, and especially when the map is wanted very low-dimensional. Iterative MDS, too, will succeed more when a cloud ellipse is thin, but will fulfill the MDS-task better than PCoA. By the property of the double-centration matrix (described here) it appears that PCoA minimizes $\|D_o\|_2^2-\|D_m\|_2^2$, which is different from any of the above minimizations.
Once again, PCA projects cloud's points on the most advantageous all-corporal saving subspace. It does not project pairwise distances, relative locations of points on a subspace most saving in that respect, as iterative MDS does it. Nevertheless, historically PCoA/PCA is considered among the methods of metric MDS.


Question:
I was making pasta, and I noticed the pasta boiling over. I thought about it some more, and I realized I had no idea why this was happening. When the lid is on, the foam rises. When the lid is off, the foam dies back. Clearly there's some surfactant at work allowing bubbles to form, and the bubbles are mostly full of steam. If you remove the lid, they cool and condense down to a tiny size. This article is honestly just not specific enough. Why is the starch important?(It also happens with potatoes) How does a polysaccharide, a hydrophilic molecule, become a surfactant(if indeed it does)? Is it phospholipids from the cells that became pasta? Do starch molecules form a polymer and trap steam underneath like a balloon? Is it some kind of hybrid where bubbles are stabilized by viscosity? What's going on here?
This question on seasoned advice tries to tackle it but gets surface tension wrong(I think) so that makes me a little wary of it. Surfactants like soap reduce the surface tension, allowing bubbles to form by letting water molecules spread out into thin films. They also keep your alveoli in your lungs from collapsing. If starches increased the surface tension, wouldn't that reduce the likelihood of forming bubbles by increasing the energetic penalty? High surface tension materials act like mercury.
This answer is all over the internet but doesn't make any sense to me. You need less surface tension for bubbles, surely?
If it's just phospholipids acting as detergent, could I 'boil over' pasta in cold water with a whisk? (I tried this, you can't.)
I considered putting this on seasoned advice, but I'm not interested in how to prevent boil-over(or really any practical results), and the supplied answer there lacks scientific rigor.

The starch forms a loosely bonded network that traps water vapor and air into a foamy mass, which expands rapidly as it heats up.
Starch is made of glucose polymers (amylopectin is one of them, shown here):

Some of the chains are branched, some are linear, but they all have $\ce{-OH}$ groups which can form hydrogen bonds with each other.
Let's follow some starch molecules through the process and see what happens. In the beginning, the starch is dehydrated and tightly compacted - the chains are lined up in nice orderly structures with no water or air between them, maximizing the hydrogen bonds between starch polymers:

As the water heats up (or as you let the pasta soak), water molecules begin to "invade" the tightly packed polymer chains, forming their own hydrogen bonds with the starch:

Soon, the polymer chains are completely surrounded by water, and are free to move in solution (they have dissolved):

However, the water/starch solution is not completely uniform. In the middle of the pot of water, the concentration of starch is low compared to water. There are lots and lots of water molecules available to surround the starch chains and to keep them apart. Near the surface, when the water is boiling, the water molecules escape as vapor. This means that near the surface, the local concentration of starch increases. It increases so much as the water continues to boil, that the starch can collapse back in on itself and hydrogen bond to other starch molecules again. However, this time the orderly structure is broken and there is too much thermal motion to line up. Instead, they form a loosely packed network of molecules connected by hydrogen bonds and surrounding little pockets of water and air (bubbles):

This network is very weak, but it is strong enough to temporarily trap the air as it expands due to heating - thus, the bubbles puff up and a rapidly growing foam forms. Since they are very weak, it doesn't take much to disrupt them. Some oil in the water will inhibit the bubbles from breaking the surface as easily, and a wooden spoon across the top will break the network mechanically as soon as it touches it.
Many biomolecules will form these types of networks under different conditions. For example, gelatin is a protein (amino acid polymer) that will form elastic hydrogen-bonded networks in hot water. As the gelatin-water mixture cools, the gel solidifies, trapping the water inside to form what is called a sol-gel, or more specifically, a hydrogel.
Gluten in wheat is another example, although in this case the bonds are disulfide bonds. Gluten networks are stronger than hydrogen-bonded polysaccharide networks, and are responsible for the elasticity of bread (and of pasta).
DISCLAIMER:

pictures are not remotely to scale, starch is usually several hundred glucose monomers long, and the relative size of the molecules and atoms isn't shown.
there aren't nearly enough water molecules - in reality there would be too many to be able to see the polymer (1,000's).
the starch molecules aren't "twisty" enough or showing things like branching - the real network structure and conformations in solution would be much more complicated.

But, hopefully you get the idea!


Question:
I have noticed that I find it far easier to write down mathematical proofs without making any mistakes, than to write down a computer program without bugs.
It seems that this is something more widespread than just my experience. Most people make software bugs all the time in their programming, and they have the compiler to tell them what the mistake is all the time. I've never heard of someone who wrote a big computer program with no mistakes in it in one go, and had full confidence that it would be bugless. (In fact, hardly any programs are bugless, even many highly debugged ones).
Yet people can write entire papers or books of mathematical proofs without any compiler ever giving them feedback that they made a mistake, and sometimes without even getting feedback from others.
Let me be clear. this is not to say that people don't make mistakes in mathematical proofs, but for even mildly experienced mathematicians, the mistakes are usually not that problematic, and can be solved without the help of some "external oracle" like a compiler pointing to your mistake.
In fact, if this wasn't the case, then mathematics would scarcely be possible it seems to me.
So this led me to ask the question: What is so different about writing faultless mathematical proofs and writing faultless computer code that makes it so that the former is so much more tractable than the latter?
One could say that it is simply the fact that people have the "external oracle" of a compiler pointing them to their mistakes that makes programmers lazy, preventing them from doing what's necessary to write code rigorously. This view would mean that if they didn't have a compiler, they  would be able to be as faultless as mathematicians.
You  might find this persuasive, but based on my experience programming and writing down mathematical proofs, it seems intuitively to me that this is really not explanation. There seems to be something more fundamentally different about the two endeavours.
My initial thought is, that what might be the difference, is that for a mathematician, a correct proof only requires every single logical step to be correct. If every step is correct, the entire proof is correct. On the other hand, for a program to be bugless, not only every line of code has to be correct, but its relation to every other line of code in the program has to work as well.
In other words, if step $X$ in a proof is correct, then making a mistake in step $Y$ will not mess up step $X$ ever. But if a line of code $X$ is correctly written down, then making a mistake in line $Y$ will influence the working of line $X$, so that whenever we write line $X$ we have to take into account its relation to all other lines. We can use encapsulation and all those things to kind of limit this, but it cannot be removed completely.
This means that the procedure for checking for errors in a mathematical proof is essentially linear in the number of proof-steps, but the procedure for checking for errors in computer code is essentially exponential in the number of lines of code.
What do you think?
Note: This question has a large number of answers that explore a large variety of facts and viewpoints. Before you answer, please read all of them and answer only if you have something new to add. Redundant answers, or answers that don't back up opinions with facts, may be deleted.

Let me offer one reason and one misconception as an answer to your question.
The main reason that it is easier to write (seemingly) correct mathematical proofs is that they are written at a very high level. Suppose that you could write a program like this:
function MaximumWindow(A, n, w):
    using a sliding window, calculate (in O(n)) the sums of all length-w windows
    return the maximum sum (be smart and use only O(1) memory)

It would be much harder to go wrong when programming this way, since the specification of the program is much more succinct than its implementation. Indeed, every programmer who tries to convert pseudocode to code, especially to efficient code, encounters this large chasm between the idea of an algorithm and its implementation details. Mathematical proofs concentrate more on the ideas and less on the detail.
The real counterpart of code for mathematical proofs is computer-aided proofs. These are much harder to develop than the usual textual proofs, and one often discovers various hidden corners which are "obvious" to the reader (who usually doesn't even notice them), but not so obvious to the computer. Also, since the computer can only fill in relatively small gaps at present, the proofs must be elaborated to such a level that a human reading them will miss the forest for the trees.
An important misconception is that mathematical proofs are often correct. In fact, this is probably rather optimistic. It is very hard to write complicated proofs without mistakes, and papers often contain errors. Perhaps the most celebrated recent cases are Wiles' first attempt at (a special case of) the modularity theorem (which implies Fermat's last theorem), and various gaps in the classification of finite simple groups, including some 1000+ pages on quasithin groups which were written 20 years after the classification was supposedly finished.
A mistake in a paper of Voevodsky made him doubt written proofs so much that he started developing homotopy type theory, a logical framework useful for developing homotopy theory formally, and henceforth used a computer to verify all his subsequent work (at least according to his own admission). While this is an extreme (and at present, impractical) position, it is still the case that when using a result, one ought to go over the proof and check whether it is correct. In my area there are a few papers which are known to be wrong but have never been retracted, whose status is relayed from mouth to ear among experts.


Question:
We have a multivariate normal vector ${\boldsymbol Y} \sim \mathcal{N}(\boldsymbol\mu, \Sigma)$. Consider partitioning $\boldsymbol\mu$ and ${\boldsymbol Y}$ into
$$\boldsymbol\mu
=
\begin{bmatrix}
 \boldsymbol\mu_1 \\
 \boldsymbol\mu_2
\end{bmatrix}
$$
$${\boldsymbol Y}=\begin{bmatrix}{\boldsymbol y}_1 \\
{\boldsymbol y}_2 \end{bmatrix}$$
with a similar partition of $\Sigma$ into
$$
\begin{bmatrix}
\Sigma_{11} & \Sigma_{12}\\
\Sigma_{21} & \Sigma_{22}
\end{bmatrix}
$$
Then, $({\boldsymbol y}_1|{\boldsymbol y}_2={\boldsymbol a})$, the conditional distribution of the first partition given the second, is
$\mathcal{N}(\overline{\boldsymbol\mu},\overline{\Sigma})$, with mean
$$
\overline{\boldsymbol\mu}=\boldsymbol\mu_1+\Sigma_{12}{\Sigma_{22}}^{-1}({\boldsymbol a}-\boldsymbol\mu_2)
$$
and covariance matrix
$$
\overline{\Sigma}=\Sigma_{11}-\Sigma_{12}{\Sigma_{22}}^{-1}\Sigma_{21}$$
Actually these results are provided in Wikipedia too, but I have no idea how the $\overline{\boldsymbol\mu}$ and $\overline{\Sigma}$ is derived. These results are crucial, since they are important statistical formula for deriving Kalman filters. Would anyone provide me a derivation steps of deriving $\overline{\boldsymbol\mu}$ and $\overline{\Sigma}$ ?

You can prove it by explicitly calculating the conditional density by brute force, as in Procrastinator's link (+1) in the comments. But, there's also a theorem that says all conditional distributions of a multivariate normal distribution are normal. Therefore, all that's left is to calculate the mean vector and covariance matrix. I remember we derived this in a time series class in college by cleverly defining a third variable and using its properties to derive the result more simply than the brute force solution in the link (as long as you're comfortable with matrix algebra). I'm going from memory but it was something like this:

It is worth pointing out that the proof below only assumes that $\Sigma_{22}$ is nonsingular, $\Sigma_{11}$ and $\Sigma$ may well be singular.

Let ${\bf x}_{1}$ be the first partition and ${\bf x}_2$ the second. Now define ${\bf z} = {\bf x}_1 + {\bf A} {\bf x}_2 $ where ${\bf A} = -\Sigma_{12} \Sigma^{-1}_{22}$. Now we can write
\begin{align*} {\rm cov}({\bf z}, {\bf x}_2) &= {\rm cov}( {\bf x}_{1}, {\bf x}_2 ) +
{\rm cov}({\bf A}{\bf x}_2, {\bf x}_2) \\
&= \Sigma_{12} + {\bf A} {\rm var}({\bf x}_2) \\
&= \Sigma_{12} - \Sigma_{12} \Sigma^{-1}_{22} \Sigma_{22} \\
&= 0
\end{align*}
Therefore ${\bf z}$ and ${\bf x}_2$ are uncorrelated and, since they are jointly normal, they are independent. Now, clearly $E({\bf z}) = {\boldsymbol \mu}_1 + {\bf A}  {\boldsymbol \mu}_2$, therefore it follows that
\begin{align*}
E({\bf x}_1 | {\bf x}_2) &= E( {\bf z} - {\bf A} {\bf x}_2 | {\bf x}_2) \\
& = E({\bf z}|{\bf x}_2) -  E({\bf A}{\bf x}_2|{\bf x}_2) \\
& = E({\bf z}) - {\bf A}{\bf x}_2 \\
& = {\boldsymbol \mu}_1 + {\bf A}  ({\boldsymbol \mu}_2 - {\bf x}_2) \\
& = {\boldsymbol \mu}_1 + \Sigma_{12} \Sigma^{-1}_{22} ({\bf x}_2- {\boldsymbol \mu}_2)
\end{align*}
which proves the first part. For the covariance matrix, note that
\begin{align*}
{\rm var}({\bf x}_1|{\bf x}_2) &= {\rm var}({\bf z} - {\bf A} {\bf x}_2 | {\bf x}_2) \\
&= {\rm var}({\bf z}|{\bf x}_2) + {\rm var}({\bf A} {\bf x}_2 | {\bf x}_2) - {\bf A}{\rm cov}({\bf z}, -{\bf x}_2) - {\rm cov}({\bf z}, -{\bf x}_2) {\bf A}' \\
&= {\rm var}({\bf z}|{\bf x}_2) \\
&= {\rm var}({\bf z})
\end{align*}
Now we're almost done:
\begin{align*}
{\rm var}({\bf x}_1|{\bf x}_2) = {\rm var}( {\bf z} ) &= {\rm var}( {\bf x}_1 + {\bf A} {\bf x}_2 ) \\
&= {\rm var}( {\bf x}_1 ) + {\bf A} {\rm var}( {\bf x}_2 ) {\bf A}'
+ {\bf A} {\rm cov}({\bf x}_1,{\bf x}_2) + {\rm cov}({\bf x}_2,{\bf x}_1) {\bf A}' \\
&= \Sigma_{11} +\Sigma_{12} \Sigma^{-1}_{22} \Sigma_{22}\Sigma^{-1}_{22}\Sigma_{21}
- 2 \Sigma_{12} \Sigma_{22}^{-1} \Sigma_{21} \\
&= \Sigma_{11} +\Sigma_{12} \Sigma^{-1}_{22}\Sigma_{21}
- 2 \Sigma_{12} \Sigma_{22}^{-1} \Sigma_{21} \\
&= \Sigma_{11} -\Sigma_{12} \Sigma^{-1}_{22}\Sigma_{21}
\end{align*}
which proves the second part.
Note: For those not very familiar with the matrix algebra used here, this is an excellent resource.
Edit: One property used here this is not in the matrix cookbook (good catch @FlyingPig) is property 6 on the wikipedia page about covariance matrices: which is that for two random vectors $\bf x, y$, $${\rm var}({\bf x}+{\bf y}) = {\rm var}({\bf x})+{\rm var}({\bf y}) + {\rm cov}({\bf x},{\bf y}) + {\rm cov}({\bf y},{\bf x})$$ For scalars, of course, ${\rm cov}(X,Y)={\rm cov}(Y,X)$ but for vectors they are different insofar as the matrices are arranged differently.


Question:
I have a DNA sample which I know doesn't quite match my reference genome - my culture comes from a subpopulation which has undergone significant mutation since the reference was created.
The example I have in mind is E.coli. We've tried assembly using a couple of different tools and the de-novo assembly isn't as high quality as we would like, despite having tonnes of data. Approaching this from a Bayesian point of view, the reference genome provides a very good prior if we could use it wisely
From visual inspection with IGV, a significant number of both SNPs and SVs appear to be present, but an assembly built entirely from my own sequencing data is not high enough quality for my purposes.
How can I modify this reference genome to match my sample with new sequencing data (preferably with Oxford Nanopore Technologies long reads, but I can also use these to scaffold short reads if necessary), taking advantage of my knowledge that the existing reference is mostly very good, without having to access the reads which were originally used to construct the reference genome?
The goal of the project isn't to determine where the SVs are, I just need a reference that accurately represents my sample in order to use the data for downstream analysis (as the training set for machine learning.) So by a high quality reference, I mean one which represents as well as possible the sample that was sequenced. To make matters worse, this may not be the one which has the highest alignment identity if there are systematic sequencing errors, as in nanopore sequencing!

One approach to this is to use whatever data you have to iteratively update the reference genome. You can keep chain files along the way so you can convert coordinates (e.g. in gff files) from the original reference to your new pseudoreference.
A simple approach might be:

Align new data to existing reference
Call variants (e.g. samtools mpileup, GATK, or whatever is best for you)
Create new reference incorporating variants from 2
Rinse and repeat (i.e. go to 1)

You can track some simple stats as you do this - e.g. the number of new variants should decrease, the number of reads mapped should increase, and the mismatch rate should decrease, with every iteration of the above loop. Once the pseudoreference stabilises, you know you can't do much more.


Question:
I am searching for some groups, where it is not so obvious that they are groups.

In the lecture's script there are only examples like $\mathbb{Z}$ under addition and other things like that. I don't think that these examples are helpful to understand the real properties of a group, when only looking to such trivial examples. I am searching for some more exotic examples, like the power set of a set together with the symmetric difference, or an elliptic curve with its group law.

Homological algebra. Let $A,B$ be abelian groups (or more generally objects of an abelian category) and consider the set of isomorphism classes of abelian groups $C$ together with an exact sequence $0 \to B \to C \to A \to 0$ (extensions of $A$ by $B$). It turns out that this set has a canonical group structure (isn't that surprising?!), namely the Baer sum, and that this group is isomorphic to $\mathrm{Ext}^1(A,B)$. This is also quite helpful to classify extensions for specific $A$ and $B$, since $\mathrm{Ext}$ has two long exact sequences. For details, see Weibel's book on homological algebra, Chapter 3. Similarily many obstructions in deformation theories are encoded in certain abelian groups.
Combinatorial game theory. A two-person game is called combinatorial if no chance is involved and the ending condition holds, so that in each case one of the two players wins. Each player has a set of possible moves, each one resulting in a new game. There is a notion of equivalent combinatorial games. It turns out that the equivalence classes of combinatorial games can be made into a (large) group. The zero game $0$ is the game where no moves are available. A move in the sum $G+H$ of two games $G,H$ is just a move in exactly one of $G$ or $H$. The inverse $-G$ of a game $G$ is the one where the possibles moves for the two players are swapped. The equation $G+(-G)=0$ requires a proof. An important subgroup is the class of impartial games, where the same moves are available for both players (or equivalently $G=-G$). This extra structure already suffices to solve many basic combinatorial games, such as Nim. In fact, one the first results in combinatorial game theory is that the (large) group of impartial combinatorial games is isomorphic to the ordinal numbers $\mathbf{On}$ with a certain group law $\oplus$, called the Nim-sum (different from the usual ordinal addition). This identification is given by the nimber. This makes it possible to reduce complicated games to simpler ones, in fact in theory to a trivial one-pile Nim game. Even the restriction to finite ordinal numbers gives an interesting group law on the set of natural numbers $\mathbb{N}$ (see Jyrki's answer). All this can be found in the fantastic book Winning Ways ... by Conway, Berlekamp, Guy, and in Conway's On Numbers and Games. A more formal introduction can be found in this paper by Schleicher, Stoll. There you also learn that (certain) combinatorial games actually constitute a (large) totally ordered field, containing the real numbers as well as the ordinal numbers. You couldn't have guessed this rich structure from their definition, right?
Algebraic topology. If $X$ is a based space, the set of homotopy classes of pointed maps $S^n \to X$ has a group structure; this is the $n$th homotopy group $\pi_n(X)$ of $X$. For $n=1$ the group structure is quite obvious, since we can compose paths and go paths backwards. But at first sight it is not obvious that we can do something like that in higher dimensions. Essentially this comes down to the cogroup structure of $S^n$. There is a nice geometric proof that $\pi_n(X)$ is abelian for $n>1$.


Question:
Generally speaking, I've heard numerical analysts utter the opinion that

"Of course, mathematically speaking, time is just another dimension, but still, time is special"

How to justify this? In what sense is time special for computational science?
Moreover, why do we so often prefer to use finite differences, (leading to "time-stepping"), for the time dimension, while we apply finite differences, finite elements, spectral methods, ..., for the spatial dimensions? One possible reason is that we tend to have an IVP in the time dimension, and a BVP in the spatial dimensions. But I don't think this fully justifies it.

Causality indicates that information only flows forward in time, and algorithms should be designed to exploit this fact. Time stepping schemes do this, whereas global-in-time spectral methods or other ideas do not. The question is of course why everyone insists on exploiting this fact -- but that's easy to understand: if your spatial problem already has a million unknowns and you need to do 1000 time steps, then on a typical machine today you have enough resources to solve the spatial problem by itself one timestep after the other, but you don't have enough resources to deal with a coupled problem of $10^9$ unknowns.
The situation is really not very different from what you have with spatial discretizations of transport phenomena either. Sure, you can discretize a pure 1d advection equation using a globally coupled approach. But if you care about efficiency, then the by far best approach is to use a downstream sweep that carries information from the inflow to the outflow part of the domain. That's exactly what time stepping schemes do in time.


Question:
Male and female brains are wired differently according to this article:

Maps of neural circuitry showed that on average women's brains were highly connected across the left and right hemispheres, in contrast to men's brains, where the connections were typically stronger between the front and back regions.

But since learning in the brain is associated with changes of connection
strengths between neurons, this could be or not the result of learning.
What about physical differences from birth? Are there differences in size, regions, chemical composition, etc. from birth?

Short answer
Yes, men and women's brains are different before birth.
Background
First off, learning effects versus genetic differences is the familiar nature versus nurture issue. Several genes on the Y-chromosome, unique to males, are expressed in the pre-natal brain. In fact, about a third of the genes on the Y-chromosome are expressed in the male prenatal brain (Reinius & Jazin, 2009). Hence, there are substantial genetic differences between male and female brains.
Importantly, the male testes start producing testosterone in the developing fetus. The female hormones have opposing effects on the brain as testosterone. In neural regions with appropriate receptors, testosterone influences patterns of cell death and survival, neural connectivity and neurochemical composition. In turn, while recognizing post-natal behavior is subject to parenting influences and others, prenatal testosterone may affect play behaviors between males and females, whereas influences on sexual orientation appear to be less dramatic (Hines, 2006).
The question is quite broad and I would start with the cited review articles below, or if need be, the wikipedia page on the Neuroscience of sex differences.
References
- Hines, Eur J Endocrinol (2006); 155: S115-21
- Reinius & Jazin, Molecular Psychiatry (2009); 14: 988–9


Question:
Power supplies are available in a wide range of voltage and current ratings.  If I have a device that has specific voltage and current ratings, how do those relate to the power ratings I need to specify?  What if I don't know the device's specs, but am replacing a previous power supply with particular ratings?
Is it OK to go lower voltage, or should it always be higher?  What about current?  I don't want a 10 A supply to damage my 1 A device.

Voltage Rating
If a device says it needs a particular voltage, then you have to assume it needs that voltage.  Both lower and higher could be bad.
At best, with lower voltage the device will not operate correctly in a obvious way.  However, some devices might appear to operate correctly, then fail in unexpected ways under just the right circumstances.  When you violate required specs, you don't know what might happen.  Some devices can even be damaged by too low a voltage for extended periods of time.  If the device has a motor, for example, then the motor might not be able to develop enough torque to turn, so it just sits there getting hot.  Some devices might draw more current to compensate for the lower voltage, but the higher than intended current can damage something.  Most of the time, lower voltage will just make a device not work, but damage can't be ruled out unless you know something about the device.
Higher than specified voltage is definitely bad.  Electrical components all have voltages above which they fail.  Components rated for higher voltage generally cost more or have less desirable characteristics, so picking the right voltage tolerance for the components in the device probably got significant design attention.  Applying too much voltage violates the design assumptions.  Some level of too much voltage will damage something, but you don't know where that level is.  Take what a device says on its nameplate seriously and don't give it more voltage than that.
Current Rating
Current is a bit different.  A constant-voltage supply doesn't determine the current: the load, which in this case is the device, does.  If Johnny wants to eat two apples, he's only going to eat two whether you put 2, 3, 5, or 20 apples on the table.  A device that wants 2 A of current works the same way.  It will draw 2 A whether the power supply can only provide the 2 A, or whether it could have supplied 3, 5, or 20 A.  The current rating of a supply is what it can deliver, not what it will always force thru the load somehow.  In that sense, unlike with voltage, the current rating of a power supply must be at least what the device wants but there is no harm in it being higher.  A 9 volt 5 amp supply is a superset of a 9 volt 2 amp supply, for example.
Replacing Existing Supply
If you are replacing a previous power supply and don't know the device's requirements, then consider that power supply's rating to be the device's requirements.  For example, if a unlabeled device was powered from a 9 V and 1 A supply, you can replace it with a 9 V and 1 or more amp supply.
Advanced Concepts
The above gives the basics of how to pick a power supply for some device.  In most cases that is all you need to know to go to a store or on line and buy a power supply.  If you're still a bit hazy on what exactly voltage and current are, it's probably better to quit now.  This section goes into more power supply details that generally don't matter at the consumer level, and it assumes some basic understanding of electronics.

Regulated versus Unregulated
Unregulated
Very basic DC power supplies, called unregulated, just step down the input AC (generally the DC you want is at a much lower voltage than the wall power you plug the supply into), rectify it to produce DC, add a output cap to reduce ripple, and call it a day.  Years ago, many power supplies were like that.  They were little more than a transformer, four diodes making a full wave bridge (takes the absolute value of voltage electronically), and the filter cap.  In these kinds of supplies, the output voltage is dictated by the turns ratio of the transformer.  This is fixed, so instead of making a fixed output voltage their output is mostly proportional to the input AC voltage.  For example, such a "12 V" DC supply might make 12 V at 110 VAC in, but then would make over 13 V at 120 VAC in.

Another issue with unregulated supplies is that the output voltage not only is a function of the input voltage, but will also fluctuate with how much current is being drawn from the supply.  A unregulated "12 volt 1 amp" supply is probably designed to provide the rated 12 V at full output current and the lowest valid AC input voltage, like 110 V.  It could be over 13 V at 110 V in at no load (0 amps out) alone, and then higher yet at higher input voltage.  Such a supply could easily put out 15 V, for example, under some conditions.  Devices that needed the "12 V" were designed to handle that, so that was fine.

Regulated
Modern power supplies don't work that way anymore.  Pretty much anything you can buy as consumer electronics will be a regulated power supply.  You can still get unregulated supplies from more specialized electronics suppliers aimed at manufacturers, professionals, or at least hobbyists that should know the difference.  For example, Jameco has wide selection of power supplies.  Their wall warts are specifically divided into regulated and unregulated types.  However, unless you go poking around where the average consumer shouldn't be, you won't likely run into unregulated supplies.  Try asking for a unregulated wall wart at a consumer store that sells other stuff too, and they probably won't even know what you're talking about.

A regulated supply actively controls its output voltage.  These contain additional circuitry that can tweak the output voltage up and down.  This is done continuously to compensate for input voltage variations and variations in the current the load is drawing.  A regulated 1 amp 12 volt power supply, for example, is going to put out pretty close to 12 V over its full AC input voltage range and as long as you don't draw more than 1 A from it.

Universal input
Since there is circuitry in the supply to tolerate some input voltage fluctuations, it's not much harder to make the valid input voltage range wider and cover any valid wall power found anywhere in the world.  More and more supplies are being made like that, and are called universal input.  This generally means they can run from 90-240 V AC, and that can be 50 or 60 Hz.

Minimum Load
Some power supplies, generally older switchers, have a minimum load requirement.  This is usually 10% of full rated output current.  For example, a 12 volt 2 amp supply with a minimum load requirement of 10% isn't guaranteed to work right unless you load it with at least 200 mA.  This restriction is something you're only going to find in OEM models, meaning the supply is designed and sold to be embedded into someone else's equipment where the right kind of engineer will consider this issue carefully.  I won't go into this more since this isn't going to come up on a consumer power supply.

Current Limit
All supplies have some maximum current they can provide and still stick to the remaining specs.  For a "12 volt 1 amp" supply, that means all is fine as long as you don't try to draw more than the rated 1 A.

There are various things a supply can do if you try to exceed the 1 A rating.  It could simply blow a fuse.  Specialty OEM supplies that are stripped down for cost could catch fire or vanish into a greasy cloud of black smoke.  However, nowadays, the most likely response is that the supply will drop its output voltage to whatever is necessary to not exceed the output current.  This is called current limiting.  Often the current limit is set a little higher than the rating to provide some margin.  The "12 V 1 A" supply might limit the current to 1.1 A, for example.

A device that is trying to draw the excessive current probably won't function correctly, but everything should stay safe, not catch fire, and recover nicely once the excessive load is removed.

Ripple

No supply, even a regulated one, can keep its output voltage exactly at the rating.  Usually due to the way the supply works, there will be some frequency at which the output oscillates a little, or ripples.  With unregulated supplies, the ripple is a direct function of the input AC.  Basic transformer unregulated supplies fed from 60 Hz AC will generally ripple at 120 Hz, for example.  The ripple of unregulated supplies can be fairly large.  To abuse the 12 volt 1 amp example again, the ripple could easily be a volt or two at full load (1 A output current).  Regulated supplies are usually switchers and therefore ripple at the switching frequency.  A regulated 12 V 1 A switcher might ripple ±50 mV at 250 kHz, for example.  The maximum ripple might not be at maximum output current.


Question:
I have a FASTA file:
> Sequence_1
GCAATGCAAGGAAGTGATGGCGGAAATAGCGTTAGATGTATGTGTAGCGGTCCC...
> Sequence_2
GCAATGCAAGGAAGTGATGGCGGAAATAGCGTTAGATGTATGTGTAGCGGTCCC....
....

I want to generate a BED file for each sequence like:
Sequence_1 0 1500
Sequence_2 0 1700

The BED regions will simply be the size of the sequences.
Q: I did that before with a one-line command. I don't remember what that is, it was on Biostars. I can't find the post now. What's the simplest way to do the conversion?

You can do this easily with bioawk, which is a version of awk with added features facilitating bioinformatics:
bioawk -c fastx '{print $name"\t0\t"length($seq)}' test.fa

-c fastx tells the program that the data should be parsed as fasta or fastq format. This makes the $name and $seq variables available in the awk commands.


Question: Especially when drinking water after the fact, mint can give a sharp cold sensation inside one's mouth.  What process causes the sensation to occur?

Menthol it self gives a cold feeling in the mouth because it is active at the same receptor (an ion channel) on the tongue that cold temperature triggers. Interestingly, although they act at the same receptor, they act at different sites, so that provides the intensified response when eating a mint and then drinking water. This reference gives an excellent detailed answer, with references to the original papers, which I'll  summarize here.
Menthol acts at the TRPM8 protein which forms an ion channel that allows $\ce{Na+}$ and $\ce{Ca^2+}$ ions to flow into cells and this sends a signal saying "cool" to the brain. (As an aside, this protein monitors temperature across the body and not just on the tongue.) Cold temperatures actually change the confirmation of this protein, which allows the ions to flow more freely, and sends the signal to the brain. Menthol, on the other hand, stabilizes the open channel (allowing ions to flow even more freely) and also...

“menthol shifts the voltage dependence of channel activation to more negative values by slowing channel deactivation”.  This is very significant to my question because it supports a claim made by the first web page I visited which stated that menthol acts on the receptors, leaving them sensitized for when the second stimulus is applied (i.e. cold water) resulting in the enhanced sensation.  This mechanism of binding is very clearly different from the mechanism of cold affecting the TRP channels.  This is why the sensation is increased when both stimuli are applied, yet is not affected after addition stimulation from the same stimuli (i.e. eating another mint).

All in all, pretty cool.


Question:
When treated with hot, concentrated acidic $\ce{KMnO4}$, arenes are oxidised to the corresponding carboxylic acids. For example, toluene is oxidised to benzoic acid.
I've tried to examine how this happens, using the mechanism of oxidation of double bonds via cyclic intermediate as a reference, but I can't manage to cook up a satisfactory one.
In an older book, I have read that there is no (known) mechanism for many organic oxidation reactions. I'm inclined to think that this may have changed.
So, is there a mechanism for this? If so, what is it?
If not, what are the hurdles in finding this mechanism? For example, what problems are there with other proposed mechanisms (if they exist)?

Some general information on side-chain oxidation in alkylbenzenes is available at Chemguide:

An alkylbenzene is simply a benzene ring with an alkyl group attached
  to it. Methylbenzene is the simplest alkylbenzene.
Alkyl groups are usually fairly resistant to oxidation. However, when they are attached to a benzene ring, they are easily oxidised by
  an alkaline solution of potassium manganate(VII) (potassium
  permanganate).
Methylbenzene is heated under reflux with a solution of potassium
  manganate(VII) made alkaline with sodium carbonate. The purple colour
  of the potassium manganate(VII) is eventually replaced by a dark brown
  precipitate of manganese(IV) oxide.
The mixture is finally acidified with dilute sulfuric acid.
Overall, the methylbenzene is oxidised to benzoic acid.

Interestingly, any alkyl group is oxidised back to a -COOH group on
  the ring under these conditions. So, for example, propylbenzene is
  also oxidised to benzoic acid.

Regarding the mechanism, a Ph.D. student at the University of British Columbia did his doctorate on the mechanisms of permanganate oxidation of various organic substrates.1 Quoting from the abstract:

It was found that the most vigorous oxidant was the permanganyl ion ($\ce{MnO3+}$), with some contributing oxidation by both permanganic acid ($\ce{HMnO4}$) and permanganate ion ($\ce{MnO4-}$) in the case of easily oxidized compounds such as alcohols, aldehydes, or enols.

The oxidation of toluene to benzoic acid was one of the reactions investigated, and a proposed reaction mechanism (on pp 137–8) was as follows. In the slow step, the active oxidant $\ce{MnO3+}$ abstracts a benzylic hydrogen from the organic substrate.

$$\begin{align}
\ce{2H+ + MnO4- &<=> MnO3+ + H2O} & &\text{(fast)} \\
\ce{MnO3+ + PhCR2H &-> [PhCR2^. + HMnO3+] & &\text{(slow)}} \\
\ce{[PhCR2^. + HMnO3+] &-> PhCR2OH + Mn^V} & &\text{(fast)} \\
\ce{PhCR2OH + Mn^{VII} &-> aldehyde or ketone} & &\text{(fast)} \\
\ce{aldehyde + Mn^{VII} &-> benzoic acid} & &\text{(fast)} \\
\ce{ketone + Mn^{VII} &-> benzoic acid} & &\text{(slow)} \\
\ce{5 Mn^V &-> 2Mn^{II} + 3Mn^{VII}} & &\text{(fast)}
\end{align}$$

The abstraction of a benzylic hydrogen atom is consistent with the fact that arenes with no benzylic hydrogens, such as tert-butylbenzene, do not get oxidised.

Reference

Spitzer, U. A. The Mechanism of Permanganate Oxidation of Alkanes, Arenes and Related Compounds. Ph.D. Thesis, The University of British Columbia, November 1972. DOI: 10.14288/1.0060242.


Question:
It's a hilarious witty joke that points out how every base is '$10$' in its base. Like,
\begin{align}
    2 &= 10\ \text{(base 2)} \\
    8 &= 10\ \text{(base 8)}
\end{align}
My question is if whoever invented the decimal system had chosen $9$ numbers or $11$, or whatever, would this still be applicable? I am confused - Is $10$ a special number which we had chosen several centuries ago or am I missing a point?

Short answer: your confusion about whether ten is special may come from reading aloud "Every base is base 10" as "Every base is base ten" — this is wrong; not every base is base ten, only base ten is base ten. It is a joke that works better in writing. If you want to read it aloud, you should read it as "Every base is base one-zero".

You must distinguish between numbers and representations. A pile of rocks has some number of rocks; this number does not depend on what base you use. A representation is a string of symbols, like "10", and depends on the base. There are "four" rocks in the cartoon, whatever the base may be. (Well, the word "four" may vary with language, but the number is the same.) But the representation of this number "four" may be "4" or "10" or "11" or "100" depending on what base is used.
The number "ten" — the number of dots in ".........." — is not mathematically special. In different bases it has different representations: in base ten it is "10", in base six it is "14", etc.
The representation "10" (one-zero) is special: whatever your base is, this representation denotes that number. For base $b$, the representation "10" means $1\times b + 0 = b$.
When we consider the base ten that we normally use, then "ten" is by definition the base for this particular representation, so it is in that sense "special" for this representation. But this is only an artefact of the base ten representation. If we were using the base six representation, then the representation "10" would correspond to the number six, so six would be special in that sense, for that representation.


Question:
I'm developing neural networks comprised of just 3 to 10 layers of virtual neurons and I'm curious to know if there are any insect brains out there with fewer than a thousand neurons?

Are there any tiny creatures with small numbers of neurons?
Do neuronal maps exist for those simple nervous systems?

Short answer
As far as I know, a complete neural map (a connectome) is only available for the roundworm C. elegens, a nematode with only 302 neurons (fig. 1).

Fig. 1. C. elegans (left, size: ~1 mm) and connectome of C. elegans (right). sources: Utrecht University & Farber (2012)
Background
Looking at the least complex of animals will be your best bet and nematodes (roundworms) like Caenorhabditis elegans are definitely a good option. C. elegans has some 300 neurons. Below is a schematic of phyla in Fig.2.
You mention insects; these critters are much more complex than roundworms. The total number of neurons varies with each insect, but for comparison: one of the lesser complex insects like the fruit fly Drosophila already has around 100k neurons, while a regular honey bee has about one million (source: Bio Teaching).
Complexity of the organism is indeed an indicator of the number of neurons to be expected. Sponges, for instance (Fig. 1) have no neurons at all, so the least complex of animals won't help you. the next in line are the Cnidaria (Fig. 2). The Cnidaria include the jelly fish, and for example Hydra vulgaris has 5.6k neurons.
So why do jelly fish feature more neurons? Because size also matters. Hydra vulgaris can grow up 15 mm, while C. elegans grows only up to 1 mm. See the wikipedia page for an informative list of #neurons in a host of species.
A decent neuronal connectivity map (a connectome) only exists for C. elegans (Fig. 1) as far as I know, although other maps (Drosophila (Meinertzhagen, 2016) and human) are underway.
References
- Farber, Sci Am February 2012
- Meinertzhagen, J Neurogenet (2016); 30(2): 62-8

Fig. 2. Phyla within the kingdom of animalia. source: Southwest Tennessee University College


Question:
The following is a quote from Surely you're joking, Mr. Feynman.  The question is: are there any interesting theorems that you think would be a good example to tell Richard Feynman, as an answer to his challenge?  Theorems should be totally counter-intuitive, and be easily translatable to everyday language.  (Apparently the Banach-Tarski paradox was not a good example.)

Then I got an idea.  I challenged
  them: "I bet there isn't a single
  theorem that you can tell me - what
  the assumptions are and what the
  theorem is in terms I can understand -
  where I can't tell you right away
  whether it's true or false."
It often went like this: They would
  explain to me, "You've got an orange,
  OK? Now you cut the orange into a
  finite number of pieces, put it back
  together, and it's as big as the sun.
  True or false?"
"No holes."
"Impossible!
"Ha! Everybody gather around! It's
  So-and-so's theorem of immeasurable
  measure!"
Just when they think they've got
  me, I remind them, "But you said an
  orange! You can't cut the orange peel
  any thinner than the atoms."
"But we have the condition of
  continuity: We can keep on cutting!"
"No, you said an orange, so I
  assumed that you meant a real orange."
So I always won. If I guessed it
  right, great. If I guessed it wrong,
  there was always something I could
  find in their simplification that they
  left out.

Every simple closed curve that you can draw by hand will pass through the corners of some square.  The question was asked by Toeplitz in 1911, and has only been partially answered in 1989 by Stromquist.  As of now, the answer is only known to be positive, for the curves that can be drawn by hand. (i.e. the curves that are piecewise the graph of a continuous function)
I find the result beyond my intuition.

For details, see   (the figure is also borrowed from this site)


Question:
I was discussing with a colleague about using dark-mode vs. light mode and remembered an article arguing that humans vision is more adapted to light-mode rather than dark-mode:

I know that the trend “du jour” is to have a dark mode for pretty much
everything, but look around the world is not dark with a bit of light,
it’s actually the contrary. And as the human has evolved its vision to
adapt to this reality, it’s asking extra efforts on many people.

Unfortunately, no reference is provided to support this claim, so I am wondering if this is just an opinion or there are some studies to support this.
Wikipedia seems to confirm this somewhat since we are adapting much faster to "light mode" transition than to dark mode one:

This adaptation period is different between rod and cone cells and
results from the regeneration of photopigments to increase retinal
sensitivity. Light adaptation, in contrast, works very quickly, within
seconds.

Also, some studies confirm that working using light mode is on average more efficient than using dark mode:

light mode won across all dimensions: irrespective of age, the
positive contrast polarity was better for both visual-acuity tasks and
for proofreading tasks.

I am looking for arguments coming from evolutionary biology to confirm (or not) the assumption that human evolution favors light mode.

A question that requires quite a lot of guts to ask on this site :) Nonetheless, and risking sparking a debate, there are a few arguments that spring to (my!) mind that can support the notion that we thrive better in 'day mode' (i.e., photopic conditions).

To start with a controversial assumption, humans are diurnal animals, meaning we are probably, but arguably, best adapted to photopic (a lot of light) conditions.
A safer and less philosophical way to approach your question is by looking at the physiology and anatomy of the photosensitive organ of humans, i.e., the retina. The photosensitive cells in the retina are the rods and cones. Photopic conditions favor cone receptors that mediate the perception of color. Scotopic (little light) conditions favor rod activity, which are much more sensitive to photons, but operate on a gray scale only. The highest density of photoreceptors is found in the macular region, which is stacked with cones and confers high-acuity color vision. The periphery of the retina contains mostly rods, which mediate low-visual acuity only. Since highest densities of photoreceptors are situated at the most important spot located at approximately 0 degrees, i.e., our point of focus, and since these are mainly cones, we apparently are best adapted to photopic conditions Kolb, 2012).
An evolutionary approach would be to start with the fact that (most) humans are trichromats (barred folks with some sort of color blindness), meaning we synthesize our color palette using 3 cone receptors sensitive to red (long wavelength), green (intermediate) and blue (short). Humans are thought to have evolved from apes. Those apes are thought to have been dichromats, which have only a long/intermediate cone and a blue cone.  It has been put forward that the splitting of the short/intermediate cone in our ape ancestors to a separate red/green cone was favorable because we could better distinguish ripe from unripe fruits. Since cones operate in the light, we apparently were selected for cone activity and thus photopic conditions (Bompas et al, 2013).

Literature
- Bompas et al., Iperception (2013); 4(2): 84–94
- Kolb, Webvision - The Organization of the Retina and Visual System (2012), Moran Eye Center
Further reading
- Why does a light object appear lighter in your peripheral vision when it's dark?


Question:
It is well known that when you add salt to ice, the ice not only melts but will actually get colder. From chemistry books, I've learned that salt will lower the freezing point of water. But I’m a little confused as to why it results in a drop in temperature instead of just ending up with water at 0 °C.
What is occurring when salt melts the ice to make the temperature lower?

When you add salt to an ice cube, you end up with an ice cube whose temperature is above its melting point.
This ice cube will do what any ice cube above its melting point will do: it will melt. As it melts, it cools down, since energy is being used to break bonds in the solid state.
(Note that the above point can be confusing if you're new to thinking about phase transitions. An ice cube melting will take up energy, while an ice cube freezing will give off energy. I like to think of it in terms of Le Chatelier's principle: if you need to lower the temperature to freeze an ice cube, this means that the water gives off heat as it freezes.)
The cooling you get, therefore, comes from the fact that some of the bonds in the ice are broken to form water, taking energy with them. The loss of energy from the ice cube is what causes it to cool.


Question:
I'm trying to implement various binarization algorithms to the image shown:
Here's the code:
clc;
clear;
x=imread('n2.jpg');     %load original image

%   Now we resize the images so that computational work
  becomes easier later onwards for us.
size(x);
x=imresize(x,[500 800]);
figure;
imshow(x);
title('original image');

z=rgb2hsv(x);       %extract the value part of hsv plane
v=z(:,:,3);
v=imadjust(v);

%now we find the mean and standard deviation required for niblack and
%sauvola algorithms
m = mean(v(:))
s=std(v(:))
k=-.4;
value=m+ k*s;
temp=v;

%   implementing niblack thresholding algorithm:
for p=1:1:500
    for q=1:1:800
        pixel=temp(p,q);
        if(pixel>value)
            temp(p,q)=1;
        else
            temp(p,q)=0;
        end
    end
end
figure;
imshow(temp);
title('result by niblack');
k=kittlerMet(g);
figure;
imshow(k);
title('result by kittlerMet');

%   implementing sauvola thresholding algorithm:
val2=m*(1+.1*((s/128)-1));
t2=v;
for p=1:1:500
for q=1:1:800
    pixel=t2(p,q);
    if(pixel>value)
        t2(p,q)=1;
    else
        t2(p,q)=0;
    end
end

end
figure;
imshow(t2);
title('result by sauvola');

The results I obtained are as shown:

As you can see the resultant images are degraded at the darker spots.Could someone please suggest how to optimize my result??

Your image doesn't have uniform brightness,so you shouldn't work with a uniform threshold. You need an adaptive threshold. This can be implemented by preprocessing the image to make the brightness more uniform across the image (code written in Mathematica, you'll have to implement the Matlab version for yourself):
A simple way to make the brightness uniform is to remove the actual text from the image using a closing filter:
white = Closing[src, DiskMatrix[5]]

The filter size should be chosen larger than the font stroke width and smaller than the size of the stains you're trying to remove.
EDIT:
I was asked in the comments to explain what a closing operation does. It's a morphological dilation followed by a morphological erosion. The dilation essentially moves the structuring element at every position in the image, and picks the brightest pixel under the mask, thus :

removing dark structures smaller than the structuring element
shrinking larger dark structures by the size of the structuring element
enlarging bright structures

The erosion operation does the opposite (it picks the darkest pixel under inside the structuring element), so if you apply it on the dilated image:

the dark structures that were removed because they're smaller than the structuring element are still gone
the darker structures that were shrunk are enlarged again to their original size (though their shape will be smoother)
the bright structures are reduced to their original size

So the closing operation removes small dark objects with only minor changes to larger dark objects and bright objects.
Here's an example with different structuring element sizes:

As the size of the structuring element increases, more and more of the characters is removed. At radius=5, all of the characters are removed. If the radius is increased further, the smaller stains are removed, too:

Now you just divide the original image by this "white image" to get an image of (nearly) uniform brightness:
whiteAdjusted = Image[ImageData[src]/ImageData[white]*0.85]

This image can now be binarized with a constant threshold:
Binarize[whiteAdjusted , 0.6]


Question:
I have heard anecdotaly that sampling complex signals need not follow Nyquist sampling rates but can actually be gotten away with half Nyquist sampling rates. I am wondering if there is any truth to this?
From Nyquist, we know that to unambiguously sample a signal, we need to sample at least higher than double the bandwidth of that signal. (I am defining bandwidth here as they do in the wiki link, aka, the occupancy of the positive frequency). In other words, if my signal exists from -B to B, I need to sample at least > 2*B to satisfy nyquist. If I mixed this signal up to fc, and wished to do bandpass sampling, I would need to sample at least > 4*B.
This is all great for real signals.
My question is, is there any truth to the statement that a complex baseband signal (aka, one that only exists on one side of the frequency spectrum) need not be sampled at a rate of at least > 2*B, but can in fact be adequately sampled at a rate of at least > B?
(I tend to think that if this is the case this is simply semantics, because you still have to take two samples (one real and one imaginary) per sample time in order to completely represent the rotating phasor, thereby strictly still following Nyquist...)
What are your thoughts?

Your understanding is correct. If you sample at rate $f_s$, then with real samples only, you can unambiguously represent frequency content in the region $[0, \frac{f_s}{2})$ (although the caveat that allows bandpass sampling still applies). No additional information can be held in the other half of the spectrum when the samples are real, because real signals exhibit conjugate symmetry in the frequency domain; if your signal is real and you know its spectrum from $0$ to $\frac{f_s}{2}$, then you can trivially conclude what the other half of its spectrum is.
There is no such restriction for complex signals, so a complex signal sampled at rate $f_s$ can unambiguously contain content from $-\frac{f_s}{2}$ to $\frac{f_s}{2}$ (for a total bandwidth of $f_s$). As you noted, however, there's not an inherent efficiency improvement to be made here, as each complex sample contains two components (real and imaginary), so while you require half as many samples, each requires twice the amount of data storage, which cancels out any immediate benefit. Complex signals are often used in signal processing, however, where you have problems that map well to that structure (such as in quadrature communications systems).


Question:
I have looked at other questions on this site (e.g. "why does space expansion affect matter") but can't find the answer I am looking for.
So here is my question: One often hears talk of space expanding when we talk about the speed of galaxies relative to ours. Why, if space is expanding, does matter not also expand? If a circle is drawn on balloon (2d plane), and the balloon expands, then the circle also expands. If matter is an object with 3 spatial dimensions, then when those 3 dimensions expand, so should the object.
If that was the case, we wouldn't see the universe as expanding at all, because we would be expanding (spatially) with it.
I have a few potential answers for this, which raise their own problems:

Fundamental particles are 'point sized' objects. They cannot expand because they do not have spatial dimension to begin with. The problem with this is that while the particles would not expand, the space between them would, leading to a point where the 3 non-gravity forces would no longer hold matter together due to distance
Fundamental particles are curled up in additional dimensions a la string theory. These dimensions are not expanding. Same problems as 1, with the added problem of being a bit unsatisfying.
The answer seems to be (from Marek in the previous question) that the gravitational force is so much weaker than the other forces that large (macro) objects move apart, but small (micro) objects stay together. However, this simple explanation seems to imply that expansion of space is a 'force' that can be overcome by a greater one. That doesn't sound right to me.

Let's talk about the balloon first because it provides a pretty good model for the expanding universe.
It's true that if you draw a big circle then it will quickly expand as you blow into the balloon. Actually, the apparent speed with which two of the points on the circle in a distance $D$ of each other would move relative to each other will be $v = H_0 D$ where $H_0$ is the speed the balloon itself is expanding. This simple relation is known as Hubble's law and $H_0$ is the famous Hubble constant. The moral of this story is that the expansion effect is dependent on the distance between objects and really only apparent for the space-time on the biggest scales.
Still, this is only part of the full picture because even on small distances objects should expand (just slower). Let us consider galaxies for the moment. According to wikipedia, $H_0 \approx 70\, {\rm km \cdot s^{-1} \cdot {Mpc}^{-1}}$ so for Milky way which has a diameter of $D \approx 30\, {\rm kPc}$ this would give $v \approx 2\,{\rm km \cdot s^{-1}}$. You can see that the effect is not terribly big but the given enough time, our galaxy should grow. But it doesn't.
To understand why, we have to remember that space expansion isn't the only important thing that happens in our universe. There are other forces like electromagnetism. But most importantly, we have forgotten about good old Newtonian gravity that holds big massive objects together.
You see, when equations of space-time expansion are derived, nothing of the above is taken into account because all of it is negligible on the macroscopic scale. One assumes that universe is a homogenous fluid where microscopic fluid particles are the size of the galaxies (it takes some getting used to to think about galaxies as being microscopic). So it shouldn't be surprising that this model doesn't tell us anything about the stability of galaxies; not to mention planets, houses or tables. And conversely, when investigating stability of objects you don't really need to account for space-time expansion unless you get to the scale of galaxies and even there the effect isn't that big.


Question:
I have a PyMol session file I was using to create my figures.  It contains a protein and ligand broken into several groups of atoms with a fair bit of overlap.  There are also a few meshes built from a density map for a few figures.
Unfortunately, I wasn't quite done with refinement, and now Refmac has given me shiny new PDB and MTZ files with subtly different coordinates and terms.  Is there a way to "update" my coordinates (despite the myriad groups, all the atoms still have the same name) with the new PDB?  With all the groups I made that are shown/hidden/colored differently for several scenes to produce all the figures, I'd rather not recreate it all manually.
I'm more pessimistic about the map/mesh, but I created them via a script so I can repeat that.  Should I also script the coordinate to figure stuff in the future if it's not finalized?

Until someone identifies an ‘update’ function in PyMol, I think the next best thing is to use scripting. (See the pymol wiki) It is an imperfect solution, but it may work for the situation presented in the original post if the session may be reproduced.
To begin capturing the commands in PyMol, including menu selections to a script file, select:
File -> Log File -> Open -> myscript.pml

When done with creating the display panels, select:
File -> Log File -> Close

The input data files and the script itself may then be updated or replaced. In a fresh PyMol session, execute the script with:
File -> Run Script -> myscript.pml

To test the above, I generated a PyMol session where I captured a script as above. I loaded the atomic coordinates of a small protein, a ligand and a 2mFobs-DFcalc electron density map. Then I displayed some panels along with mesh surface around the compound. The co-structure was then re-refined, thus generating modified atomic coordinates and electron density maps. I replaced the original files with the updates and executed the script in a fresh PyMol session. The display panels were updated accordingly.
I recommend the Advanced Scripting Workshop.


Question:
I cook frequently with aluminum foil as a cover in the oven.  When it's time to remove the foil and cook uncovered, I find I can handle it with my bare hands, and it's barely warm.
What are the physics for this?  Does it have something to do with the thickness and storing energy?

You get burned because energy is transferred from the hot object to your hand until they are both at the same temperature. The more energy transferred, the more damage done to you.
Aluminium, like most metals, has a lower heat capacity than water (ie you) so transferring a small amount of energy lowers the temperature of aluminium more than it heats you (about 5x as much). Next the mass of the aluminium foil is very low - there isn't much metal to hold the heat, and finally the foil is probably crinkled so although it is a good conductor of heat you are only touching a very small part of the surface area so the heat flow to you is low.
If you put your hand flat on an aluminium engine block at the same temperature you would get burned.
The same thing applies to the sparks from a grinder or firework "sparkler", the sparks are hot enough to be molten iron - but are so small they contain very little energy.


Question:
Does DNA have anything like IF-statements, GOTO-jumps, or WHILE loops?
In software development, these constructs have the following functions:

IF-statements: An IF statement executes the code in a subsequent code block if some specific condition is met.
WHILE-loops: The code in a subsequent code block is executes as many times as specified, or as long as a specific condition is met.
Function calls: The code temporarily bypasses the subsequent code block, executing instead some other code block. After execution of the other code block the code returns (sometimes with some value) and continues the execution of the subsequent block.
GOTO-statements: The code bypasses the subsequent code block, jumping instead directly to some other block.

Are constructs similar to these present in DNA? If yes, how are they implemented and what are they called?

Biological examples similar to programming statements:

IF : Transcriptional activator; when present a gene will be transcribed. In general there is no termination of events unless the signal is gone; the program ends only with the death of the cell. So the IF statement is always a part of a loop.
WHILE : Transcriptional repressor; gene will be transcribed until repressor is not present.
There are no equivalents of function calls. All events happen is the
same space and there is always a likelihood of interference. One can
argue that organelles can act as a compartment that may have a
function like properties but they are highly complex and are
not just some kind of input-output devices.
GOTO is always dependent on a condition. This can happen in case of certain network connections such as feedforward loops and branched pathways. For example if there is a signalling pathway like this:  A → B → C and there is another connection D → C then if somehow D is activated it will directly affect C, making A and B dispensable.

Logic gates have been constructed using synthetic biological circuits. See this review for more information.

Note
Molecular biological processes cannot be directly compared to a computer code. It is the underlying logic that is important and not the statement construct itself and these examples should not be taken as absolute analogies. It is also to be noted that DNA is just a set of instructions and not really a fully functional entity (it is functional to some extent). However, even being just a code it is comparable to a HLL code that has to be compiled to execute its functions. See this post too.
It is also important to note that the cell, like many other physical systems, is analog in nature. Therefore, in most situations there is no 0/1 (binary) value of variables. Consider gene expression. If a transcriptional activator is present, the gene will be transcribed. However, if you keep increasing the concentration of the activator, the expression of that gene will increase until it reaches a saturation point. So there is no digital logic here. Having said that, I would add that switching behaviour is possible in biological systems (including gene expression) and is also used in many cases. Certain kinds of regulatory network structures can give rise to such dynamics. Co-operativity with or without positive feedback is one of the mechanisms that can implement switching behaviour. For more details read about ultrasensitivity. Also check out "Can molecular genetics make a boolean variable from a continuous variable?"