Author Archives: mathscinotes

Excel VBA Code to Center a Shape in a Cell

I recently finished a job where the customer wanted an Excel dashboard that displayed metrics for test case completion and various success metrics. This dashboard contained many control shapes that I wanted to be centered in cells. I do not like to manually adjust objects so I googled for a VBA routine that would center a shape. I soon found a nice piece of code by HipGecko on the Mr. Excel forum that centered pictures in the active cell. A simple modification of this code allows it to center shapes, an object type that includes pictures and controls. Continue reading

 
Posted in Uncategorized | Leave a comment

Tensions and Angles in a Simple Rope Rigging

I have been tutoring math and physics at the local library for the last few months. As part of this tutoring, I have been looking for good graphics that illustrate basic science concepts. One common high-school physics problem involves computing the tension in ropes tied to an anchor by a pulley. Figure 1 is a graphic that nicely illustrates the tension relationship between two ropes connected to an anchor point by a carabiner. Continue reading

 
Posted in Uncategorized | 10 Comments

Measuring Countersink Angle Using Gage Balls

This post will cover how to measure a countersink angle using gage balls. Figure 1 shows how a countersink is normally specified on an engineering drawing. I frequently use countersinks in my wood and metal working hobbies. In addition, using gage balls to measure the countersink angle provides a good example of how to apply basic geometry concepts to a practical problem.  I use this example in my role as a volunteer adult math tutor at our local library. Continue reading

 
Posted in General Mathematics, Metrology | Leave a comment

US and Canada Aircraft Production During WW2

While looking for some good summer history reading, I found the book America's Hundred Thousand: U.S. Production Fighters of World War II. This book covers the production miracle associated with scaling up up the US aircraft industry to supply planes for every front during WW2. Its title refers to the fact that the US produced ~100K fighter aircraft during WW2, which lasted for 44 months for the US (Figure 2). I decided that I would look at the numbers for all forms of aircraft produced by the US during WW2. Fortunately, the Hyperwar website has put the Army Air Forces Statistical Digest online, which gives me easy access to the data. The Digest contains aircraft production data for both the US and Canada. Figure 1 shows the production numbers for the 11 categories of aircraft production listed in the Statistical Digest. In addition to 100K fighter aircraft, there were nearly 200K of other aircraft manufactured as well. Continue reading

 
Posted in History Through Spreadsheets | Leave a comment

Using Excel to Compute Effective Tax Rate

I have been working as a contractor for the last few months and it is now time for me to make a quarterly tax payment to the folks at the Internal Revenue Service (IRS). This involves using some tables listed on Form 1040ES (see Appendix A). The US tax code uses has a graduated tax rate; the tax rates on higher amounts of income are higher than on lower amounts. As I calculated my tax payment, I became curious as to my effective tax rate. I am going to use Excel to duplicate a graph that I saw on the Wikipedia. My version of the graph is shown in Figure 1. Continue reading

 
Posted in Excel, Financial | Leave a comment

Using Excel Custom Formatting To Hide Redundant Table Information

I currently am doing some contract work as a system engineer. In this role, I am working on generating and managing lists of requirements to drive the engineering design work. The requirements are stored in a database that I query to generate requirements lists for specific subsystems, like a receiver or transmitter assembly. These requirements are disseminated to the engineers in various subsystem documents (Figure 1). Continue reading

 
Posted in Excel | Leave a comment

Web Scraping WW2 Landing Ship Data

I have been working on improving my web scraping abilities by analyzing WW2 data. I have focused on topics related to how the US took the 14th largest military in the world and in roughly 18 months turned it into a military that could fight anywhere in the world. In this post, I want to look in detail at how war materials were delivered to beaches around the world using a vessel called a Landing Ship Tank (LST). I have wanted to write about the LST for a while, but the web data was distributed on about 1200 separate pages – one for each ship. While a Python script would have worked nicely, I wanted to try gathering the data without doing any programming. I found some software that did a good job automating this task, which I will discuss later in this post. Continue reading

 
Posted in History Through Spreadsheets, Military History, Naval History | Leave a comment

1968 Vietnam War Statistics

It has been 50 years since 1968, and I have been seeing quite a few retrospectives on television about that tumultuous year. I was in 6th-grade in 1968 and the chaos of that year is still very clear in my memory – I remember spending quite a bit of class time on the Paris peace talks. One lesson was about how the Paris Peace negotiators argued about the shape of the table at which they would sit. Arguing about the shape of a table while people were dying seemed ridiculous to a 12-year boy. After hearing all these recent discussions about 1968, I decided to look at the US Vietnam casualty data (Figure 1) to see what insights I could gain on that year. All my work is done in Excel and my workbook is here. Continue reading

 
Posted in History Through Spreadsheets | 4 Comments

I Forgot – VLOOKUP is Not Case-Sensitive

I almost sent out a spreadsheet today that contained a VLOOKUP error – I forgot that VLOOKUP is not case sensitive. Fortunately, I caught my error seconds before I hit send. Today's post is about how I chose to perform a case-sensitive lookup in an ancient version of Excel. Continue reading

 
Posted in Excel | Leave a comment

Evenly Spaced Points on Logarithmic Graphic Using Excel

I am doing some testing at an Electromagnetic Compatibility (EMC) facility this week. Part of the test specification requires that we inject audio frequency interference on the power supply lines at discrete frequencies that range from 10Hz to 100+KHz, with 30 frequencies selected from each decade of frequencies (e.g. 10 Hz to 100 Hz, 100 Hz to 1 kHz, etc.). Figure 1 shows a specification similar to the one I am performing. My test facility that has chosen the discrete frequencies to be evenly spaced on a logarithmic axis. I started to wonder how the frequencies were selected – let's work through it. Continue reading

 
Posted in Excel, General Mathematics | 1 Comment