Tag Archives: math

My beginning explorations about less visual alternatives to spreadsheets for screen reader users

Posted on December 12, 2018

Almost 2 weeks ago  I was listening to the Mac Power Users podcast with David Sparks and Katie Floyd, the episode had one of the best titles I’d ever seen,  “My Life Is a Subscription” this could be a blog rant all by itself, but what they wanted the listener to get out of that episode was how to be aware of and manage their subscriptions. Sadly for me, they used the sighted person’s go-to, the spreadsheet. If you can see spreadsheets are nice and visual, convenient, but not so much when using a screen reader. Especially if using Apple’s Numbers program, because there is no go to cell keyboard shortcut  command. Beyond that, even if there was one, like in Microsoft Excel it still leaves it up to the user to figure out which cell they want to navigate to.   I’d been frustrated before by how people love their spreadsheets, and even complained about this in a speech I gave at Madison UX 2014.  David and Katie reminded me of this frustration, so I  decided to explore if there were less visual   alternatives.
My friend Kyle Borah suggested databases, so I went there first.
The mac has sqlite installed by default, and sqlite can run on just about anything. The lite really only means that it doesn’t run on a server and doesn’t allow for concurrent users, but for an individual person, it can work very well. SQL  was originally called SEQL (structured English query language) so now we know why people say sequel today. SQL is easier to learn than many other programming languages and will probably be where I play and blog about in the future, but then I remembered I had a cool little app on both macOS and iOS called Soulver, and for this case, managing my subscriptions, Soulver was more than equal to the task.
Soulver is kind of like the Microsoft program called  notepad and a calculator, so you can write things in a sort of natural language and it will do the math for you. lines beginning with // are comments so you can write notes to yourself. I didn’t feel like putting my real subscriptions into a public blog though, so I made some up. Besides, that way I could show currency conversions.

//fictitious subscriptions

//say that 3 times fast

//subscription 1 renews on January 1

sub1Annual = 100 GBP in USD = 125.69 USD

sub1month = sub1Annual/12 = $10.47

//subscription 2 renews on the 10th of the month

sub2month = $5 = $5.00

//subscription 3 renews on the 21st of the month

sub3month = $2.99 = $2.99

sub1month + sub2month + sub3month = $18.46

 

Here’s what the developers of Soulver call “back of the envelope calculations”.

 

//my fictitious  day trip to Chicago

//oh wait, I actually did something almost like this back in 2015

//some of these prices are also  fictitious, though I tried to be somewhat accurate The bus roundtrip from Madison was $62 = $62.00

Tickets to the Shedd aquarium and 2 other museums cost $65 = $65.00

Transportation on the L cost $15 = $15.00

two  meals and a snack cost $30 = $30.00
//that Chicago pizza was worth it.

$172.00

 

In this last example I didn’t use variables, I just wrote how someone might write down notes on the fly. Most reviews I’ve seen unfortunately showoff Soulver with screenshots, but that would be disingenuous of me, so I exported my examples from Soulver into .txt files and then pasted them into this post. Soulver can export to html and PDF as well as text, which is great if you want to share calculations with others who don’t have it.

 

Soulver also has your ensemble of basic scientific functions, it can do quite a bit; so  let’s go further. Wisconsin can get pretty cold  in the winter, and I’ve actually heard some people wonder why heated air inside houses and buildings is so dry then, so here’s a bit of what you might learn in meteorology 101. Depending on the temperature, air can only hold so many grams of   moisture per cubic meter; The warmer the air, the more it can hold. This is usually told to us as relative humidity, but to the meteorologist what’s more important is the dew point. The dew point is the temperature at which the air is totally saturated, e.g. at 100% humidity. So your furnace sucks in a bunch of cold air from outside heats it up to 70 degrees F or 21.1 C and keeps your house warm; but without adding extra moisture to the air, it only has what it could hold when outside. Let’s use Soulver to figure out a real life example. As I write this the current temperature outside my window is 24 F the dew point is 19 F and the relative humidity is 79%Let’s see what the humidity is when that air gets  warmed up to a much more acceptable 70 degrees.
First let’s calculate with the original outside temperature of   24

 

//calculating relative humidity from air temperature and dew point

//b is a constant used for calculating vapor pressure is in degrees C

b = 237.7 = 237.7

//air temperature and dew point must be converted to Celsius

//with no interface to input data, here’s where we do it

atf = 24 = 24

dpf = 19 = 19

//temperature conversions

atc = (atf-32)/1.8 = -4.4444444444

dpc = (dpf-32)/1.8 = -7.2222222222

//calculating saturation vapor pressure svp,  and actual vapor pressureavp

svp = 6.11*10.0^(7.5*atc/(b+atc)) = 4.3967971796

avp = 6.11*10.0^(7.5*dpc/(b+dpc)) = 3.5564947151

//returning relative humidity

round(avp/svp*100) = 81

 

I know, it’s 2% off, this formula seems to lose a bit of accuracy when the temperatures go below 0 C.
Now’ with just changing the atf from 24 to 70 I get 14. Now we know. This also demonstrates one thing databases are not so good at that spreadsheets are, what-ifs. When I was talking about this last week with my friend Fintan, he said he uses what-ifs all the time in his spreadsheets at work,  and that was not so convenient with a database; Soulver can easily do what-ifs also, we just saw one above. I also realized something else cool about Soulver.Being a programmer as I am, instead of using Soulver for more advanced calculations like calculating relative humidity, I had already written a function to do it in a python math environment I put together 2 years ago, more blogs about that later. Soulver besides being notepad and being a basic spreadsheet at least in functionality, it can also fill in as a basic programmable calculator. You can’t do if-then, or loops but still a fair amount, more than a TI36 which can do just about anything numerical but has no programmability at all. Soulver could also be useful for someone who wants to figure  out some math but doesn’t  know any   actual programming language at all. As we have found, Soulver is quite useful.
The big down side though is it’s only on Apple devices, but there is a similar program called Calca that works on both Apple and  Microsoft Windows. It seems quite a bit more powerful even able to do some symbolic math including linear algebra, playing with that is probably one of my January projects. Calca’s downside I can see thus far though, is that   Soulver’s way of performing calculations is more convenient, closer to natural language,   and for that  still  keeps a place   in my tool box.

Advertisements