The Death of Publishing

I had the chance to try self-publishing with Amazon’s create space and KDP. The book itself, while readable is a bit of fluff. What was impressive was the quality of the automated setup and publishing tools. There may have been one manual step, other than mine, a last review before generating proofs, but that was all.

So the cost of assembling a professional-looking book is almost zero.

This strongly suggests that page charges and all of those sorts of things are a bit of a con-job. It also suggests that textbooks are highly over-priced.

On a pedagogical note, this means that writing a low-copy-number course specific text book would be feasible.

Written by Rob in: engineering,pedagogy,rant,science |

That hypothesis is not necessary.

There is a petition on the Whitehouse petition site asking that “Creation Science” and “Intelligent Design” be banned from public school science classes. Since they are thinly disguised religion, this ought to be a “no brainer” in the good ol’ USA where – despite the “in god we trust” on our currency religion and government are supposed to be separate.

It isn’t. There are plenty of people (and some of my extended family) who are worried about science promoting atheism. This misses the point of science completely.

Science is non-theistic.  If a devious “sky monkey”  plays tricks with our experiments, then we cannot possibly learn anything from experience – since the ideas we deduce will have changed by the time we try them again. To paraphrase Einstein – “God doesn’t play dice with reality” – well if she does, then she doesn’t load the dice.  Laplace – quoted in the title – was asked by king Louis the somethingth – why God didn’t show up in his ground-breaking work on Celestial Mechanics. His response captures the relationship – “I didn’t need that hypothesis”.

Creation Science and Intelligent Design are so bad that they’re “not even wrong” – There is no part of modern biology that they can predict, which is completely different from natural selection (a major part of the mechanism of evolution), genetics, and evolution.  (I already did write about this in depth).

Even the most difficult question for an evolutionary theory of life, “how did it start?” is not suited to a theistic answer. If we believe that divine intervention was absolutely necessary for life to start, then we cannot ask questions about minimal conditions for life or “what is living?” or “how did it start?” because, not being God, we can’t answer them. Of course, if we don’t have a prior hypothesis of “the sky monkey did it”, then we can try. Science is about trying to understand the world, based on the general hypothesis that “if we know what is going on, then maybe we can make life better for people”.

If theists thought hard about it, they would thank Thor that we’re not mixing science and religion. Imagine a science experiment on the efficacy of different religions. We take 16 or so religions, and to be correct have to include a control like “the church of the flying spaghetti monster” as well as some of the less salubrious forms of voodoo, paganism  or Wicca as well as more mainstream ones like Christianity or Islam. Remember, though, that if you’re doing “scientific religion” you have to take the results as what you will practice – even if it does involve nailing chicken entrails to your wall.

We then design a set of binary outcome things to pray for so that on average half of the religions are praying against the other half all the time. If we use Hadamard matrix to schedule the prayer objectives then we can balance out the trials and make sure that we get an unbiased estimate.

Well, almost. We can’t do infinitely many trials, so given the null hypothesis of “no effect”, we can estimate a probability of observing a given outcome. It isn’t pretty.

  1. Somebody has to do best (Mean value theorem – either they are all the same or else someone has to be better than everyone else). It might not be the religion you like. In fact with 16 random choices of religion, the odds that you’re the best are 1/16 with the null hypothesis.
  2. With a small n of trials (say 16) where each has a prior probability of 0.5, the cumulative probability of someone getting 75% response is non-trivial. ( the odds of  having exactly 0,1,2,3,or 4 negative outcomes is  1*(1/2)^16+ (1,16)*(1/2)^16 + … + (4,16)*(1/2)^16 ) where (n,m) is the binomial coefficient for n things taken from m things.) When you do the math – that’s 4% or so, and 75% response would qualify you as a saint.  If you’re willing to accept only being blessed, with say a 66% out come – that’s about 23% of the time.

Any bets?

    Written by Rob in: rant,science,Wildlife |

    What is the length of a trail?

    Last weekend, I went with the scouts to pine mountain.  We did a loop I’d done before . I expected about a twelve mile loop based on an old GPS track I’d made. The new GPS gave 10.1!  We stayed at the new Jenkins Spring campsite which was excellent.  One the chief volunteers in the Pine Mountain Trail association came by and said that there were a lot of Eagle projects to be done on the trail (which is entirely built and maintained with volunteer labor).

    new map of the loop

    new map of the loop

    What’s going on?

    The new GPS uses both the Russian and US satellite systems as well as having a more sensitive antenna and thus simply more satellites.  Therefore the distances are more accurate – with less wobble. Also the two systems have different and less correlated systematic errors so that the estimated precision is more accurate with the combination than with either. Thus the ruler used to measure the distance was smaller than before.

    On the surface this is sort of an “anti-fractal”. It’s well known, or at least should be, that as rulers get smaller the distances measured gets larger. One simply measures more of the little in and outs on the curve and hence arrives at a longer distance. With the GPS estimates, which depend on point measurements, the idea is a little different. Here there is a swarm of (we can pretend in the limit of large numbers) normally distributed points drawn around a true track. Hence the calculated distance includes the sum of a bunch of random “wobble vectors”. The spread of the wobble is smaller with the new system and so the distance is more accurate. So the fractal measure in this case is actually in the statistics of the sampling and not the curve being measured.


    Molecular Lego

    I’ve been re-writing the graphical version of AMMP to use the Qt API.  Qt is a powerful, multiplatform framework for interface designs, which uses C++ and other vaguely modern ideas in software engineering.  AMMP is a virtual machine simulator for calculations about molecules, written in C but using an object-based design.

    The original time I wrote a graphical interface, it was tightly bound to windows. This was good, as windows is a popular family of OS’es, and bad as the framework was not highly portable.  Windows also tends to be notionally compliant with POSIX, which means I had to reverse engineer the occasional POSIX API call or Clib call (toupper, read, tmpfile, strcmp just to name a few).

    I’ve tried a few other API interface libraries – Gtk, FLTK, and motif.  There were always headaches involved in having an animated process in the background (to handle molecular dynamics or watching energy minimization).  I’d found solutions, but they were, to put it gently, fragile.  (there is a gtk/linux version on asterix, but it is not easy to compile or run).  Qt seems to fit the bill.

    Screenshot of the new interface

    Screenshot of the new interface

    A screenshot of the new interface shows what can be done.  There is now a command editor – with a menu that suggests scripts for various common things.  The display window is under development, but the picture shows what it will look like (mostly).  It uses openGL and gives decent, robust performance on modern machines.

    I spent part of today putting in the Povray output methods.  Since Povray is a scripting language it is both fun to write programs that write programs, and to play with alternative styles.  One that is sort of fun is to make the atoms smallish, while increasing the size of the bonds (0.3, 1.2 times vdw radii).

    Mellitin (2mlt), lego style

    Mellitin (2mlt), lego style

    Sort of looks like I’ve snapped it together with lego, doesn’t it?

    Written by Rob in: engineering,science |

    Virtual Machines with QEMU

    Linux KVM (kernel virtual machine) is now part of the current kernel – including Ubuntu. One of the classes I teach involves computer security and it is always hard for the students to have their own “root” or “administrator” machine. There is no way on this earth that I will let them use mine – because I want the machine to still work.

    So I’m investigating QEMU/KVM. I followed the instructions from http://qemu-buch.de/cgi-bin/moin.cgi/QuickStartGuide, which seem to be quite good. On a quad core AMD machine, I’ve been able to create images for windows XP sp2, and windows 2000. I’ll shortly try windows XP sp4. I have a copy of Red Hat 2.0 – wonder if that’ll work too?

    You have to create a boot disk with qemu-img and install the operating system into that. (qemu -cdrom /dev/dvd ….). The reason for this is that the QEMU virtual hardware isn’t the same as the real hardware so the drivers on disk may not work. You also can run into complications if the file system is being accessed by two operating systems at the same time without a locking mechanism. Once done you have a disk image that can be examined and modified from the Linux partition. It is a regular file so it can be created once and then copied for each new experiment. So we could move beyond simple virus-like constructions to real viruses in a controlled environment. (windows viruses do not, in general, infect linux). I could even demonstrate the killer double fork script on a linux machine with some chance of not actually harming the original hardware.

    It seems to fit the bill on a single machine. Our computer lab is already somewhat virtual in that the individual workstations are virtual images so there may be complications. I doubt they are insoluble. In any case it will work on the instructor’s workstation which is not virtual

    A couple more notes:

    1. Create the disk images with the raw mode if you want to examine them. Qcow2 is QEMU specific. Qcow2 is better for general use as you can resize it.
    2. Make sure virtualization is enabled on your hardware. (kvm-ok, run as system will tell you)
    3. Big raw images can be difficult to move. There are ways to mount qcow2 images in loopback mode.
    4. windows 95 seems difficult. I’ve installed Dos622 from a boot image (copy the files to c:, then use sys c: to make it bootable). Windows gets about half-way through starting up then crashes. ARGH!
    Written by Rob in: pedagogy,science,security |

    Cumberland Island

    My son’s troop had a trip to Cumberland Island over the MLK weekend.  We braved the traffic and ice in Atlanta to drive down on a Friday night to arrive in time to meet a 9am ferry Saturday morning (stayed at the KOA in St. Mary’s – which graciously let us check in late at night).

    The ferryboat
    The gear is piled on the deck in the bow – so if rain is likely it is critical that the packs are properly weather proofed. We were lucky on the way out and had beautiful weather, but on the way back, well that was another story.

    Because of the ice there were a large number of cancellations and our scoutmaster was able to arrange for a campsite in the seacoast site. This was probably good as we had some fairly young scouts and a couple of fairly old scouters along as well.

    Cumberland island is a live oak/ palmetto forest (or at least the southern half where we were is), with a beautiful beachEast Coast Beach on the east coast and swamp on the west coast.Along the central road There are wild horses wild horses, amadillos
    armadillo, racoons, deer, and an assortment of birds, including the ubiquitous turkey vulture.

    Indeed we were warned to use a “minibear” bag to keep the racoons out of our food, and I used the chance to teach about the PCT method of hanging bear bags.

    The trail map shows a short walk by the Dungenous ruinsThe Ruins out to a place were fill dirt is placed. This fill dirt is full of fossil sharks teeth and fish bones. Since it is disturbed soil and will be used on the road, you are allowed (indeed encouraged) to keep the teeth you find.

    Rain was predicted for Monday morning, and as I’d brought a tarp as well as my tent, I thought it might be fun to set up a “Taj Mahal”
    my Taj Mahal We hurried back in the rain to catch the 10am ferry and after a 6 hour drive (interrupted by a stop in Brunswick for seafood) were home.

    Written by Rob in: outdoors,science,scouting,trail map |

    Night pictures with the A480 & CHDK

    Had a chance to try the a480 and chdk to take some star pictures.  The results are mixed.  At low resolution a 512S exposure

    looking nearly due north

    looking nearly due north

    looks pretty good.  (the line is an airplane).  There are many more stars in the image than were easily visible by eye – so the sensitivity of the detector was very good.

    A longer picture slightly to the west:

    1200 s exposure

    1200 s exposure

    What is neat is how much the stars move during the time frames.   You can also see some of the color differences for the stars.  The sky was clear enough to see some of these color differences with eyes only (especially one of the arms of orion and one of Taurus’s horns).

    There are a couple of problems with this experiment though, which can be seen in the details

    detailed section

    detailed section

    There is some shot noise (probably using raw mode with bad pixel correction would help), and it is slightly out of focus (there was nothing for the autofocus system to work on).   There is supposed to be a way to use CHDK to set the focus to a defined location – just have to find out how to use it.

    Using long exposures quickly depletes the batteries, but it’s clear that a shorter exposure will work – so those scripts that take many shorter exposures would probably be best to get the long term circular images.

    Written by Rob in: engineering,outdoors,science |

    Fun with CHDK – getting real results from a digital camera

    I’ve been intrigued by the Cannon Hack Development Kit (CHDK) for a while and since GSU, in its infinite wisdom, decided to shut over Christmas and new years I decided to play around with some optical processing. I picked up a relatively inexpensive camera (A480) – don’t bother going to a discount store as they will have the latest models that don’t yet have a CHDK release, so this is from a well-known online store- and downloaded the appropriate release of CHDK. Surprisingly it actually booted quite easily – the trickiest bit is to turn the camera on after booting into CHDK display mode – just hold the mode or alt key down rather than give it a touch.

    CHDK is rather cool – for example shutter speeds of 1/100,000 second or so on this camera. I couldn’t quite catch a good picture of a water drop hitting, but came close. I’m still exploring what it can do.
    www.britishideas.com is a site that I found extremely helpful in this process.

    One really critical thing it does, though is to save raw images from the ccd detector. (the best way is to use the badpixel.lua script and save as DNG files). With the raw files you actually see grain in the image. You will need specialized software to read these files and I used UFRaw

    standard image of Jasimine

    standard image of Jasimine

    The same image generated via the pseudo HDR process shows a great deal more detail and is actually more like what the human eye sees.

    pseudo HDR Jasimine

    pseudo HDR image of Jasimine

    Written by Rob in: engineering,science |


    I think it was Arthur Clarke who pointed out that any sufficiently advanced technology is indistinguishable from magic. I didn’t think I’d live to see that happen. But the Republican candidate for senator in Delaware had “dabbled in witchcraft”, and many (but certainly not all) of the conservatives as well as a fair number of the “green left” show an abysmal lack of understanding of science and technology.

    While I certainly can’t claim to understand all of the details of every bit of semiconductor technology, the ‘gentleman’s acquaintance’ with material physics I had as an undergraduate is still valid and I can appreciate the mechanism of solid state electronics – including the rather complex ones that run our computers. However, if I didn’t have that it would be easy to drift into magical thinking about the most interesting machines people have built.

    Technology must be scary to the ignorant.

    Written by Rob in: rant,science |

    DIRECT optimizer and its cousins

    Back after a busy summer with trips and other sorts of diversions. (not all pleasant ones).

    There is a class of function-value only optimizers which build a tree and use Lipschitz continuity to ensure global convergence. DIvided RECTangle algorithms recursively build a tree of rectangles. With a bit of cunning, based on Lipschitz continuity (the statement that iff it is continuous then there is a finite derivative (delta F is bounded by some K delta x)), this approach quickly finds global optima over a bounded region.

    The cunning bit of this is how it searches for candidate optima for further expansion. Basically, if a box is of size X then if the function value is the lowest of all boxes of size X or bigger, then that box is a candidate for search.

    It is immediately obvious that such an algorithm could efficiently search many problems that are thought to be NP complete (but aren’t really) like well protein folding, and other problems that are simply a pain – like image modeling from incomplete Fourier data.

    I’ve generalized the algorithm with an amortized generic tree based on Delaunay triangulations, and get both a simpler program and somewhat better convergence (or at least what looks like better convergence). It certainly handles some very painful challenge problems quite well. The reason to use a generic tree is to handle seeding the optimizer with known potential solutions and/or to avoid having to encode the search space and function in a fairly complex manner.

    So now to try more interesting problems.

    Written by Rob in: science |

    Powered by WordPress | Aeros Theme | TheBuckmaker.com WordPress Themes