Friday, December 18, 2009

No dark matter, yet...

So, what happened with all this CDMS fuzz? The collaboration reports 3 events out of a expected background of 0.5. Nonetheless, one of the events was out of the "box", so lets forget about it. So, with 2 events we have a 1.06 sigma signal and with 3 events we have a 1.7 sigma signal.

It is just a ridiculously low signal, and by no means can be considered a discover. Nonetheless, it is rather interesting and intriguing. Experiments using liquid targets have a significantly bigger mass and can catch up this signal in one, maybe two years to a level where it can actually be considered a detection, but, until then, the coin is still in the air regarding dark matter.

Thursday, December 17, 2009

CDMS results in a few hours!

As most of you know, there is a rumor about CDMS getting some of sort of signal from its dark matter search. Well, in a few hours we will know if all the fuzz around it was justified.

CDMS stands for cryogenic dark matter search. It is a solid state detector designed to "listen" the sound made by dark matter particles when they interact with the nucleus of the atoms in the detector. These interactions cause the nucleus to recoil, as a result of that the atoms in the detector (which are arranged in a lattice) vibrate and produce phonons (some sort of quanta of sound). This signal can be measured and used to detect the interactions of weak interacting particles.

Now, this is only a very simplified description of the experiment. The practical difficulties are huge. First of all, random thermal vibrations can wash away very easily any signal, so the detector must be kept at really low temperatures. Then, collisions with cosmic rays will also spark the detector as fireworks, for this reason the detector is located underground in a deep mine in Minessota. But, how about other "backgrounds" like nuclear decay of particles in the rocks surrounding the detector? Well, the study of systematic backgrounds is really an art. One way to calibrate the detector is to place it close to some radioactive source and use the signal gathered this way to callibrate the detector.

Early in the year, I saw the results of the CDMS collaboration and there was no signal (or hint of it), so it is hard to think that the results that are about to be announced will have 5-sigma signal (the usual threshold accepted as a detection), but maybe they got some sort of provocative signal at a smaller sigma level. Or maybe all the fuzz was just that, fuzz.

Anyway, we will know the answer in a few hours!

Wednesday, September 23, 2009

Fixing unrecognized File Type extensions in Ubuntu

I've had a little 'bug' in my Ubuntu for the past month that was annoying me a bit. I use TeXmacs for creating/editing small LaTeX documents. The problem is that Nautilus was incorrectly detecting the file type of .tm files, thinking they were plain text documents (see image below). The consequence is that TeXmacs files would be opened in gedit (or the default text editor) when opening them through the Nautilus file browser.



The first solution attempt was right-clicking a .tm file, going to "Properties -> Open With" and changing the default application to GNU TeXmacs. This was a disaster, since now *all* plain text files would be opened in GNU TeXmacs, since Nautilus genuinely believed a .tm to be the same as a .txt and thus changed the default application for all text files.

My second attempt at a solution (after googling a bit) was checking the MIME file type associations, which is the way Ubuntu associates an extension to a file type. The info is all in the file /etc/mime.types. However, to my disappointment, this file already contained a mime type for TeXmacs documents, indicated by the entry
"text/texmacs tm ts". So even though the mime type was correctly recognized, it seems Nautilus wasn't picking it up. This could be further deduced from the fact that running the command file on a .tm document in the terminal returned the correct mime type.

After more googling, I finally discovered that this is in fact a bug and found a fix for it:

http://savannah.gnu.org/bugs/?25938#discussion

Essentially, you manually create an xml file describing the TeXmacs mime type to /usr/share/mime/packages and then manually update the mime database of the system (setting an icon for the file type is optional, but may be useful).

NOTE:
the original poster of the above bug fix made a small typo: an extra semicolon (;) at the end of the line containing "mime-info xmlns=" Remove it before trying to update the mime database.

After this is done, logout / re-log (or simply kill / restart nautilus from the terminal) and the new file extension should now be recognized:



The nice thing about this is that it should conceivably work for any other file type that has a correct mime type in /etc/mime.types but is not being recognized by Nautilus.

Hope this was helpful ;).

Friday, September 18, 2009

Goodbye MP3s!

The story - skip to the end if you only want the scripts and could spare my self-righteous opinion.

I've used MP3 as my music compression format for years, as I'm sure most people have, without thinking too much about it. But my relatively recent ascension into Free Software has changed my perspective on many things related to software. Especially, it has given me the awareness that, in general, as a user I am the one in charge and I have the power to choose what I want to use and how I use it - or at least I should.

MP3 entered the equation when I learned that Apple iPods do not play any other music format except WAV, MP3 and ACC related codecs (such as M4A). The reason for this is simple: these are patented, proprietary compression formats that Apple supports in order to introduce DRM (copy protection), using iTunes as a centralizing vehicle. While I can't deny their right to do so, I do believe this sort of policies go against the realization I exposed in the previous paragraph.

I don't own an iPod. I have this small, very practical, albeit ugly, 2GB iBit music player that I bought at Sam's Club for under $80 that will play MP3, M4A, FLAC, OGG and pretty much any format I've thrown at it. Why would this small company support OGG while Apple does not? Would Apple lose business if they did?

So, exercising my right of decision, I've abandoned the MP3 format in favor of free alternatives: OGG for standard music compression and FLAC if I ever need lossless compression. Converting all my music to OGG is no easy task, however, mainly due to the size of my music collection. In Windows, I'd probably have to find a small utility that can do the batch conversion, and it probably would cost me something.

Fortunately, Linux is rooted at the most fundamental level on the basic premise that the power belongs to the user (as opposed to Apple's diametrically opposed mindset), and it provides countless tools that allow you to perform complex tasks with a minimum effort. So I took this as an opportunity to learn a bit about bash scripting and wrote a small script to handle the conversion for me.

The script

Here's the link to the source code. Copy/paste to your favorite text editor, save and set execute permission (chmod +x mpeg2ogg.sh).

mpeg2ogg.sh

The script assumes you have two programs installed in your system: mpg321 and oggenc. The former handles MP3 decoding and the latter compression to OGG. If you don't have them, you can most certainly get them through your favorite package manager (in Debian/Ubuntu, all you need to do is a sudo apt-get install mpg321 vorbis-tools).

Using the script is simple. Navigate to the root directory of your music library (in my case this was /home/meithan/Music), copy the script there (or put it in a dir in your path), and run it . It will find all MP3s in the directory tree rooted in the current directory, and convert them all to OGG. The script builds a list of all the files that it finds and uses it as a queue: every time a file is converted, it removes that entry from the list. Thus, you can stop the script whenever you want, and just run it again at a later time and it will resume where it had stopped (reading from the file list.txt).

A note: since I still don't trust my bashing abilities enough, the script won't delete your original MP3 files. You should first try the OGG files first, and then, if you're confident the conversion was successful, manually delete your old MP3s. Now, since "manually" means something completely different in Linux, here's a minimal script that will batch remove all MP3s in the current directory and its subdirectories:

mp3del.sh

Hope my ranting and/or bash hacking are useful to someone.

Wednesday, February 25, 2009

Coolest fish ever

The world is full of surprises and this amazing fish is certainly one of them. This 6 inch wonder is called Macropinna microstoma and features a transparent head!

The fish, discovered alive in the deep water off California's central coast by the Monterey Bay Aquarium Research Institute (MBARI), is the first specimen of its kind to be found with its soft transparent dome intact.

Now, that small orifices in the front of the fish are not its eyes but a smelling organ. The barrel eyes are inside the green barrels and can be rotated inside the transparent head, giving this fish a quite wide visual range.

The barreleye lives about 2000 feet under the surface, where it just stays floating with the eyes looking upward, when a prey arrives they usually have to steal it from siphonophores (jellies that can grow to more than 33 feet). To make this feat it rotate its eyes and goes straight for its prey! Quite amazing.



Monday, February 09, 2009

The universe, yours to discover

As probably all of you know by now, 2009 is the "year of astronomy", a sort of celebration of the 400th anniversary of the first astronomical observations using a telescope by Galileo (of course it is arguable if he was the first to do it, nevermind).

Of course this blog will join this, so you may expect more posts here, it has been rather complicated posting to this site, it is always hard to grab some time specially since many posts that are intended to be just "quick posts" end up consuming a significant amount of time. It also seems to me that you can do lots of nice posts that will be quickly erased of everyones mind but you are always dangerously close to make some comment that might annoy someone, of course that will change when I get tenure!

Anyway, lets see how this year unfolds!