Thursday, October 13, 2011

C and Unix

A bit of code, and a single command:

int main()
printf("Goodbye, world.");

world# echo "Thanks!" |ritchie

Thursday, May 27, 2010

Using a ruler to measure the wavelength of light.

Place a ruler on your desk--the metal kind is best, but even a wooden ruler will do--and shine a laser pointer at its finest scale at glancing incidence. A diffraction pattern should appear on the far wall. A ruler is a reflection grating.

In the November 1965 issue of the American Journal of Physics, Arthur Schawlow published a brief article describing what a "lecture demonstration" of the possibility of measuring the wavelength of visible light with a ruler and presenting without derivation the formula relating the scale spacing on the ruler and the fringe spacing on the screen to the wavelength.

The widespread availability of cheap lasers has made this feasible as a student lab, or even as cocktail-party fare. I wouldn't recommend going through the geometry needed to compute spacing between fringes at a party, at least not until everyone else has had two more drinks than you, but it's something that can be done by students in the small-angle approximation (as by Schawlow) or possibly, using a computer, exactly.

I've had students measure their laser pointer's wavelength to within a nanometer of the specified value. Not bad for metrology done with standard office supplies!

Tuesday, March 30, 2010

Can a biologist fix a radio?

This isn't a joke about biologists, but rather the title of a fun manifesto on cellular signaling and control pathways: Can a biologist fix a radio?.

Written with the characteristic Russian sense of humor, it notes the similarity between a radio and a cellular signal transduction pathway and has biologists trying to learn how a radio works and how to fix a broken one by first categorizing the components by appearance, then breaking some to see which stop the sound, smashing radios to see which parts end up near each other, etc. The author (Y. Lazebnik of Cold Spring Harbor Laboratory) argues that this approach does not apply to tunable components, that biologists couldn't fix a radio, and that a better language to describe cellular signaling is needed, so as to make the process quantitative and provide answers to the question "what to measure?"

Giving a seminar today, Andrew Capaldi noted that microarray techniques done well are like measuring voltages across the components of a radio. Things have come far since 2002, when Lazebnik's essay was first published.

Tuesday, March 23, 2010

Optical Tweezers 'Blog

A subject far closer to my interest: There's now a Blog on Optical Tweezers, reporting on interesting or exciting papers on optical micromanipulation and its applications.

It's not only a useful news source for a professional: if you're a "layperson" unfamiliar with this (not well-publicized) set of techniques, dive in. Any starting point on the 'blog will do.

Meyer's underwhelming response.

Warren Meyer, the soi-disant "Climate Skeptic", has responded to my earlier post criticizing his discussion of feedbacks. The response is largely a combination of Bart Simpson ("I didn't do it nobody saw me do it you can't prove anything") and the government of Orwell's Airstrip One ("We have always been at war with Eastasia.") but ought to be examined further. Thanks go to Meyer and whoever on the LPAZ Diss and Cuss listserv (Mike Renzulli?) pointed him here; any traffic is good traffic.

As of last week, Meyer is writing:

But in his original post (linked above), he wrote:
(Emphasis mine.) A year ago, Meyer was incorrectly claiming that climate models used a feedback fraction 1/(1-f). I have to give him credit for getting it straight between now and then, but now, in his response to me, he denies ever having had it wrong, as though I was just making things up about him. Not cool. A lawyers' trick as old as the hills, but I'd like to think that this isn't court and more gentlemanly standards apply.

He goes on.

Yes, feedback is sometimes convenient to discuss. The Roe and Baker paper--which I've probably linked from this 'blog three times already--even makes use of it as an _input_ of sorts. (An aside: Meyer calls Roe and Baker "alarmist scientists". I challenge him to point out just what is "alarmist" about their analysis, to explain where a special "alarm" assumption enters their analysis. "Alarmist" is a smear and nothing but a smear. It implies something about scientists' methodology that isn't justified by the contents of their work.) Rather than perform a Monte Carlo analysis (such as the parametric bootstrap) to estimate uncertainties of the GCMs directly, Roe and Baker take the GCMs' effective feedbacks as input for their own analysis and ask, given an assumption that the error of these feedbacks is Gaussian with certain hypothetical variances--see the paper!--what uncertainty would temperature have in an amplifier-feedback framework? But as Meyer now notes, the GCMs don't take feedbacks as inputs. He was wrong last year, he is correct now. That's OK.

Or perhaps not:

Let's call the long-term, steady-state global mean temperature anomaly "dT'" as Meyer does. Let's call the long-term, steady-state global mean temperature anomaly were the CO2 concentration to change and everything else to remain constant dT. Let's call the CO2 concentration C. The only general thing we can say about the relationship of these variables is dT'=F(C) where F denotes "function". Now clearly dT=G(C) where G is some other function. We certainly can't get as specific as Meyer and state "F(C)=(1+f)*G(C)" where f is some constant.

Meyer at some point concedes this, claiming that feedback being linear is but a useful approximation. Maybe our difference is a mere misunderstanding, caused by one of those vocabulary differences between scientist and engineer.

Nope. There's way, way more to our difference. One of us is being "slippery" about the past words of both himself and others. He continues, further down:
. The chart on his original post is taken, with attribution, directly from Lindzen, and it's all about feedback. If Meyer had trouble figuring out to what I was referring, he need only have followed the link in my post--right back to his!

When Meyer wrote that original post, he remarked:

His spider sense was really tingling there--feedbacks greater than 1 should be surprising, whether or not they are "used" by models--but he failed to come to the correct conclusion. Lindzen couldn't possibly have inferred feedbacks greater than 1 using the method discussed in the source lecture, feedbacks greater than 1 are nonphysical and Lindzen's chart was horseshit. Instead of, as a "skeptic" would, calling a pile of shit a turd, Meyer used it in the OP to claim that the GCMs are wrong. Forgive the scatology, but that's like dividing the pile in two and knocking the halves together to try to make fire.

A short digression. In the recent post, Meyer declares:
This is an attitude common among climate denialists (even of Meyer's "it's happening and anthropogenic but climatologists have it all wrong" sort): what we working scientists call "effective" theories are somehow better than those with microphysical underpinnings. "I don't trust theories with realistic foundations because there's too much going into it, too much to read, and I don't want to trust that e.g. parametrizations in the literature that have withstood the test of time or those realistic foundations themselves are reasonably good." Transplant this way of thinking to e.g. neuroscience (not my field, but it keeps coming up because it's so accessible) and you get someone who is OK with the Hodgkin-Huxley model of action potential propagation (excellent science, BTW, especially given what little was known about the membrane back then) but balks at attempting to build such things up from known behavior of voltage-gated ion channels. I guess we have stereotypes because they're approximately true, but if we take them too seriously...well, I doubt that Meyer has serious objection to models of the neuron's cell membrane built up from what is known about single ion channel behavior. It's downright wild to call the parametrizations used in GCMs "guesses", but that's a matter for another time.

Back to the point. I don't like working discussions of people's honesty into discussions of science. I really don't. But here it's only in response to being, in effect, accused of being dishonest myself. I just caught Meyer claiming--despite my link to his original post, and despite the link to Lindzen in his, that he never claimed that climate models "use" feedbacks, that I'm making a straw man argument, and that he didn't use an obviously bad analysis of feedback from a set of Lindzen slides as reference. It's "I don't know what Kalafut's talking about, it's a straw man argument!" in a way to make me seem like a liar and a loon. Again: Not cool. Mr Meyer: you've been caught. Perhaps your understanding of the science has matured in a year, but that doesn't retroactively correct your past blunders nor does that retroactively turn criticism of your past statements into straw-man arguments.

Thursday, March 18, 2010

The Homeopathy Challenge

From Encyclopedia Dramatica:

Whenever you encounter someone who buys into Homeopathic cures, you should give them the Homeopathic Challenge. Tell them to induce severe Alcohol Poisoning by chugging an entire bottle of Everclear (a 190 proof grain spirit) in one go. They should then place 1 drop of Everclear in a liter of distilled water, mix it up, and dilute it down further as necessary. If Homeopathy really works, this solution should cure the Alcohol Poisoning and save the guys life. Obviously drinking an entire liter of such potent liquor will mean death without medical treatment, so you can use this to entice the retard to prove once and for all Homeopathy works.

Sunday, December 6, 2009

On Warren Meyer and feedback







