In some recent TCP experiment that I carried in the user space, I faced the problem of generating relatively precise timer events in an asynchronous way. Furthermore, multiple timers had to be maintained simultaneously.
The timerfd mechanism in Linux (man timerfd_create(2)) allows ...Read More
Sure we have arrayfun, but it applies a function every element of a matrix. What if we want to compute the sum over each row or column for example ?
The trick that I'm presenting here lies in the use of ...Read More
I have came across this problem very often, but always ended up solving it in a different way each time. Here is what looks to me to be the most concise way of doing it.
Indexing the diagonal
>> A = magic(4)
A ...Read More
Probably one of the most useful thing that I've discovered this month:
http://sourceforge.net/projects/pidgin-latex/
Pidgin-latex lets you write Latex code normally in your chat conversation and renders the result in real time.
For both parties to be able to see the result, they will ...Read More
I was commenting on Guake in http://pierrelucbacon.com/2008/09/19/3-useful-applications/ but found that it was slightly buggy and polluting the tray in the top panel under gnome with its icon.
A few weeks ago, I stumbled upon Tilda which turned out to be at least ...Read More
PGF and Expected Value of the Poisson Distribution">
Probability Generating Function for the Poisson Distribution
Let p(y) be the probability generating function for Y.
[latex] \begin{aligned} p_y(t) = E(t^y) &= {\sum_{y=0}^{\infty}} t^y p(y) \\ &= \sum_{y=0}^{\infty} t^{y} \lambda^{y}e^{-\lambda} \\ &= e^{-\lambda}\sum_{y=0}^{\infty} {{t^{y}\lambda^{y}} \over {y!}} \\ &= e^{-\lambda}\sum_{y=0}^{\infty} {(t\lambda)^{y} \over {y!}} ...Read More
From the gs package in Ubuntu:
gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=outputMerged.pdf file1.pdf file2.pdf
jPdf Tweak, the "Swiss Army Knife for PDF files", is also a great tool and run out of the box with Java but it might be faster just ...Read More