There are a few things that form the common canon of education in (quantitative) finance, yet everybody knows they are not exactly true, useful, well-
Continue ReadingC++: Happy Numbers
From Wikipedia, the free encyclopedia: A happy number is defined by the following process. Starting with any positive integer, replace the number
Continue ReadingC++: Hostname
Find the name of the host on which the routine is running. #include <stdlib.h> #include <stdio.h> #include <limits.h> #inclu
Continue ReadingEfficiently Storing Real-Time Intraday Data in an Application Agnostic Way
What would be the best approach to handle real-time intraday data storage? For personal research I've always imported from flat files only into mem
Continue ReadingC++: Multiplicative Digital Root
The multiplicative digital root (MDR) and multiplicative persistence (MP) of a number, n, is calculated rather like the Digital root except digits are
Continue ReadingC++: JSON
Load a JSON string into a data structure. Also create a new data structure and serialize it into JSON. Use objects and arrays (as appropriate for y
Continue ReadingIs Java “Pass-by-Reference” or “Pass-by-Value”?
I always thought Java was pass-by-reference; however I’ve seen a couple of blog posts (for example, this blog) that claim it’s not. I don’t thin
Continue ReadingWhy Is Subtracting These Two Times (In 1927) Giving a Strange Result?
If I run the following program, which parses two date strings referencing times one second apart and compares them: public static void main(String[]
Continue ReadingC++: Black Scholes Put Option Theta
// Calculate the Black Scholes European put option Theta double BS_Put_Option_Theta(double S, double K, double r, double v, double T) // Parame
Continue ReadingC++: Sample Covariance
double sample_covariance(double A[], double B[], int length) // Function calculates the sample covariance the array A and array B, whose lengths
Continue Reading




