Neo4j and Dijkstra’s SSSP

The workday is starting to wind down slowly. I have been doing some cosmetic changes and running tests on a medical storage server. No matter what you change you must always run tests to make sure all is well.

On my last post I covered Dijkstra’s algorithm for shortest path. Shortest path implies distance and not number of vertices traversed.

Continue reading “Neo4j and Dijkstra’s SSSP”

Graphs – Shortest Distance Paths

The motivation for this post is the Coursera class “Graph Analytics for Big Data” by the University of California San Diego I am currently taking. One of the algorithms that we briefly touched was shortest path between two nodes by Edsger Dijkstra.

The algorithm comes in different flavors. One can compute the shortest path between two nodes, the shortest paths between all nodes, among others. In this case I just went with the first approach. Continue reading “Graphs – Shortest Distance Paths”

Odd Occuring Number in Array

It is Sunday again, seems like last week came and went by faster than usual.

When I browse YouTube videos on my phone, I tend to run into some that I would like to watch and if possible experiment with the subject. This post is associated with a video by Irfan Baqui. It is nice to get a challenge, understand what it is required, solve it and see how a fellow developer comes to the same solution using a different and in some cases the same approach. Continue reading “Odd Occuring Number in Array”

Queue implemented with Stacks

Yesterday I was talking with a coworker about the time it takes (me) to produce a post in this blog. Towards the end of the day, after a nice walk with my wife, I developed the code for this post. My inspiration came from a YouTube video by Irfan Baqui.  I am a firm believer that in order to verify you understand some subject, you need to write about it. The reason for writing is that one explains the subject to the reader. Continue reading “Queue implemented with Stacks”

More than a List of Words

When indexing text based word frequency / relevance which may be applicable for web searches, one of the procedures used is to create a term frequency (tf) array followed by an inverse document frequency (idf) one. You can read more about this here.

In a previous post I experimented with some text in order to build hashmaps with the words of sentences (to keep things in perspective for a blog post). In that post I used a string that I copied from a course I took some years ago. The sting was already preprocessed. The text had already been stripped off punctuation marks. Continue reading “More than a List of Words”

Echo Server and Client

This past winter was quite long but not too cold. A few weeks ago we received a one two punch with two winter storms. After that the temperatures went up and we had a day with temperatures in the mid 80s. In the past week the temperatures were down. Last night we were in the lower 40s. We turned off the central heating system at home for the season. We have already been using the air conditioner for a few days. This morning the inside temperature upstairs was 66 F. My home office is downstairs. The temperature has been at a solid 60 F so far. My wife and I are planning on going for a walk in a couple hours. Continue reading “Echo Server and Client”

Running MySQL on Windows 10

In my previous post I mentioned that I was going to be spending some time experimenting with MongoDB. So why would I be dealing with MySQL at this time? Good question! The reason for it is that I want to store, among different things, Java objects in MongoDB. I am interested in comparing how the same Java object may be stored and retrieved using a SQL and a NoSQL databases. I could have used a different SQL database (e.g., SQL Server), but decided on MySQL. It happens that I have a few databases installed on my Windows 10 computer. With that out of the way; let’s experiment with MySQL. Continue reading “Running MySQL on Windows 10”

Radix Sort

Earlier this week I ran into a description of Radix Sort. This sorting algorithm has been around for a few centuries (yes; that is not a typo). The algorithm dates back to 1887 to the work of Herman Hollerith (and yes; he was the inventor of the Hollerith Card Code for punched cards used in the past century).

This sorting algorithm is not the fastest, it requires additional space, but has been around for a long time. When you read about it, seems like it should not work; but it does. Continue reading “Radix Sort”

Two Dimensional Array

A few days ago a group of software engineers were discussing how the order in which the numbers of rows versus columns in a two dimensional array affect performance. That is; if an array has more rows than columns as opposed to more columns than rows, the time it takes to traverse the array will be affected. Continue reading “Two Dimensional Array”