General Exactly like my previous post from 14 years ago, these are random jots that I took as I set up a QEMU/KVM-based virtual machine on my Linux Mint 19 computer. This time, the purpose was to prepare myself for moving a server from an OpenVZ container to KVM. Other version details, for the record: [...]
So what if you need to divide a \subsubsection{} into even lower subsections? LaTeX classes don’t usually support that, because if you need that feature, your document’s structure is wrong. Or so they say. You should have chopped the document with \part{} or \chapter{} at a higher level, and not cut down the sections into [...]
This is a simple utility C macro for selecting a bit range from an integer: #define bits(x, y, z) (((x) >> (z)) & ((((long int) 2) << ((y) – (z))) – 1)) This picks the part that is equivalent to the expression x[y:z] in Verilog. The cast to long int may need adjustment to the [...]
I have Google Chrome installed on a Linux machine at /opt/google as root, so the browser can’t update itself automatically. Instead, it complains with this pop-up every time the browser is started: What I really like about this pop-up is the “you’re missing out” part. I get the same thing from the silly image gallery [...]
Introduction These post contains a few technical notes of using Google Translate for translating LaTeX documents into Chinese, Japanese and Korean. The insights on the language-related issues are written down in a separate post. Text vs. HTML Google’s cloud translator can be fed with either plain text or HTML, and it returns the same format. [...]
Introduction This post summarizes my insights as I worked my way through translating some technical documents, written in LaTeX, into Chinese, Japanese and Korean. The immediate approach was to feed Google Translate with the pdf documents, but not only are the results ugly, but then there are a lot of technical terms in the documents [...]
This should have been a trivial task, but it turned out quite difficult. So these are my notes for the next time. Octave 4.2.2 under Linux Mint 19, using qt5ct plugin with GNU plot (or else I get blank plots). So this is the small function I wrote for creating a plot and a thumbnail: [...]
So I have written a function, showfile() for Octave 4.2.2 on Linux, which accepts a file name as its argument. And now I want to run it on all files in the current directory that match a certain pattern. How? So first, obtain the list of files, and put it in a variable: >> x=ls(‘myfiles*.dat’); [...]
Introduction This post examines what the Microsoft’s compiler does in response to a variety of special functions that implement atomic operations and memory barriers. If you program like a civilized human being, that is with spinlocks and mutexes, this is a lot of things you should never need to care about. I’ve written a similar [...]
Introduction Unlike Firefox, Google Chrome doesn’t allow editing passwords (at least not the version I have, and it seems like this feature will be added). One possible workaround is to enable Google Sync for passwords, and have those stored on the server: It’s possible to edit the passwords at passwords.google.com. If you have no problem [...]