Memory errors come in different forms and they are not the easiest to find. They do not usually showup in compile time and creep up during runtime. Even static analysis tools have a hard time finding memory errors. Most memory errors can be of two types: 1) Memory leaks 2) Out of bounds array access …
Jul 26
Embedding a matplotlib plot on a PyQt GUI
Matplotlib (http://matplotlib.sourceforge.net/) provides a great range of plotting tools and functionality. It is a nice alternative for Matlab. Making a plot with matplotlib in Python is not that difficult. But often you need to be able to embed a plot into a GUI with other components like push buttons and text fields and so on. This …
Mar 11
C++ Object File, Symbol Table and Name Mangling
In my previous post I looked at how a C++ compiler and linker act on source codes. This post I want to take one small step further and look in to an C++ object file. An object file in C++ is generated by the compiler. As was mentioned in the previous post, an object file …
Mar 04
C++: Compilers and Linkers Job on Functions and Function Templates.
It’s important to know the role of the compiler and the linker. This helps not only in understanding errors but also in implementing many programming strategies. Unfortunately the roles of compilers and linkers are not uniform across compiler vendors but they are close. Here we will look at what a compiler and a linker do in …
Dec 14
JAXB: An alternative serialization for Java
Java Architecture for XML Binding (JAXB) is method to convert your class objects in to XML files. I came across this concept while looking for a way to share the architecture of exchanges and queues in an AMQP system. Although Java object serialization would’ve worked I wanted a much more ‘standard’ way to share this …
Oct 02
Theory behind Doppler frequency shift
Doppler frequency shift plays a major part in wireless communications, radar and many other systems. Sometimes Doppler shift is useful, like in radar detection systems, but sometimes it’s harmful, like in mobile wireless communications systems. Calculating the Doppler shift is very trivial. , where v is the relative speed between transmitter and receiver, and the …
Sep 17
Introduction to Virtual functions, Virtual Tables and Virtual Pointers in C++
If coming from Java to C++, it could be slightly confusing how function inheritance works in C++. C++ uses the notion of “virtual” functions. In C++, unless a function is declared as virtual, polymorphism will not work. Lets see how this works with a simple Base class and a Derived class. #include <iostream> #include <string> …
Sep 25
Android Activity lifecycle demo code – with Intents and multiple Activity switching
It can be a little confusing to understand where Android Activities are started and which methods are invoked and what happens when Intents are sent and returned, restarted, etc. So in this code I overrode all the Activity lifecycle methods and put a Toast so I can see which methods are invoked at what time. …
Jan 28
How the Cyclic Prefix (CP) works in OFDM – Part II – The Theory.
This is a follow up to the Cyclic Prefix (CP) I did here. There I gave a graphical explanation and here I will discuss how it happens theoretically. I recently came across the derivation in a text [1]. So here goes. Considering an N-point FFT system, a block of data points , is to be transmitted …
Dec 20
How the Cyclic Prefix works in OFDM
This column will briefly explain how cyclic prefix (CP) in OFDM works by illustration. I decided to add this topic because the I seldom found a text that simply discussed the operation of CP and its usage. First, lets define a property of Discrete Fourier Transform (DFT) : If x(n) and h(n) time-domain signals, circular …






Recent Comments