Saturday, April 12, 2014

TikZ: Putting it all together

I have been working on TikZ a bit and finally got a result, which can be used for displaying time series:

Scaling one scope to another scope was key to succeeding with this. In the above image, the circles would be replaced by images of a timeseries, whereas the smaller squares show a more detailed view on the selected region of interest within this image. The only remaining challenge is a way of making the bounding box ignore the fake scope.

The code for above image can be found on github.

Thursday, April 10, 2014

Scale one TikZ scope to the width of another scope

I came across the problem that I needed to have two TikZ scopes scaled to the same width. Apparently, there is no option to scale a scope to an absolute width (or even better to another scope). In general, one could use two separate tikzpictures and use resizebox to get these tikzpictures to the same width. This works well as long as one does not refer to coordinates of one of these two tikzpictures, e.g. in order to draw a line from a node in one of the tikzpictures (or originally scope) to a node in the other one, as resizebox obviously cannot change the coordinates within a tikzpicture.

This problem frustrated me quite a while, but I came up with a somewhat hacky solution today, which includes "manually" determining the ratio of the two scopes in question and scaling one of the scopes accordingly. tex code is included on the corresponding tex.stackexchange post.

In the following image, the original scopes had a ratio as shown in the image and are scaled to the same width. There is no problem with drawing a line from circle1.east to circle2.east, as all scopes are within the same tikzpicture and there cannot be any confusion about the coordinates.

Wednesday, February 12, 2014

C++11: Initialize non-static data members

As I just found out, C++11 allows you to initialize non-static data members. This comes in handy for defining default values for member variables, which can be overridden by specific constructors.
Check out https://blogs.oracle.com/pcarlini/entry/c_11_tidbits_non_static for more details.

Monday, December 30, 2013

Framebuffer and Vigra running on Raspberry Pi

I just had some spare hours that I could spend working on my Raspberry Pi. I finally got the framebuffer running in conjunction with vigra:
http://www.youtube.com/watch?v=tcMQd5eSeLA&feature=youtu.be

Friday, December 13, 2013

C+=

From now on, I will dump C++ and use this new progamming language: https://github.com/FeministSoftwareFoundation/C-plus-Equality Apparently, the content has been deleted from github. You can still find it on bitbucket: https://bitbucket.org/FeministSoftwareFoundation/c-plus-equality/overview

Thursday, December 12, 2013

classicthesis.sty

Just found this in the latex package classicthesis (classicthesis.sty):

% Disable single lines at the end of a paragraph (Hurenkinder)

Friday, November 29, 2013

Detexify - Easily find the LaTeX command you are looking for

Have you ever been searching for hours when you needed just a simple LaTeX command for a symbol? Well, this might be over now:
Check out Detexify: Just draw the symbol you need and the applet will give you possible matches for your query.