As I previously wrote, I’ve discovered the Beamer class for LaTeX some months ago and I really like it! It’s very easy and straightforward to use (provided you know a little bit of LaTeX, of course). I’ve also noticed it forces me to actually prepare my slides and illustrations before beginning to create the slide show. This is a good point since 1) it forces me to stress the structure (rather than doing it as one goes along the slides) and 2) it allows me an easier and better re-use of illustrations and slides previously shown (in Powerpoint or Impress, you had to think of what objects you have to copy ; here, you have only text to copy).
I have to prepare a small seminar for tomorrow (well, technically, it’s today but I need some sleep before going to work). Because this seminar is the continuation of a previous one, it’s very easy to re-use the structure and some slides. Now I see the power of LaTeX and Beamer 🙂
Since I use LaTeX on my laptop, I’ve always noticed that the pdflatex command is fast but uses a lot of CPU ressources and turn on the fan. Tonight, I was curious on how this was possible. I wrote this small-and-dirty bash script to try to see what whas happening:
#!/bin/bash c=1 while [ $c -lt 120 ] do ps aux | grep [p]dflatex >> proc.dat ps aux | grep [p]dflatex >> tmp.dat cat /proc/acpi/thermal_zone/THRM/temperature >> temp.dat cat /proc/acpi/thermal_zone/THRM/temperature >> tmp.dat sleep 0.5; c=$((c+1)) done
It’s not optimised and it certainly uses a small amount of ressources by itself. I am not sure each line is written exactly 0.5 second after the previous one. And it needs some post-processing in order to be ready for Gnuplot. But, anyway, here is the result:
After 7 seconds, the pdflatex command is launched but we can already see that the script in itself increases the temperature. For a 20 slides presentation, we see that pdflatex is using up to a bit more than 50% of the CPU and its duration is about 7 seconds. And, as it can be expected, the temperature has a small delay compared to CPU usage (temperature increases only some time after the rise of CPU usage). Temperature is increased above 60Â°C ; this turns on the laptop fan.