Saturday, January 14, 2017

On the Benefits of Social Media

Today's Soup to Nutz comic strip by Rick Stromoski is definitely blog worthy...
http://www.gocomics.com/soup-to-nutz/2017/01/14

If you can't follow the link, it's simply that Babs remarks to her brother Roy-boy,
I'm so glad I live in a time when there's social media...  In the old days it took weeks, even months...  before finding out that someone was an idiot."
Naturally I posted it to Facebook.

Saturday, October 29, 2016

Traffic Light Improvements For the Age of Mobile Communications

I have an issue with traffic lights.

When I'm stuck right behind an inattentive driver at a red light, I get annoyed when the driver doesn't go right after the light turns green.  I get infuriated when the driver waits so long to go that the light turns back to red again before I can get across the intersection.

That's pretty much the only time I use the horn.  And it occurred to me that the traffic light itself should be equipped with its own horn.  It would beep whenever it turns green, relieving other drivers of the effort of doing so.

Inattentive drivers annoy me even when I'm not behind them.  When they remain stopped at a green light while I'm at the red light for the crossing traffic, they cause the signal to take longer to cycle.  The light stays green longer for them and stays red longer for me.  I say aloud, “Go already, so I don't have to stay here forever!”

A few towns have installed traffic light cameras, which take a picture of the license plates of cars that go through red lights.  But I say that these cameras should be used to monitor the faces of drivers who wait at red lights.  Face recognition would be used to determine whether the driver is paying attention to the light, or whether they are reading e-mail or texting.  The light would stay red until the driver's gaze was focused on driving.

What do you think about this?

Friday, September 30, 2016

Presidential Candidates' Answers to the 2016 Top 20 Science and Technology Questions

For this election cycle, ScienceDebate has included the Green and Libertarian party candidates in its list of 20 questions regarding the most pressing "... Science, Engineering, Tech, Health & Environmental Issues in 2016."

You can read it all here: http://www.sciencedebate.org/20answers

Thursday, August 25, 2016

Fitting Data in Excel and OpenOffice Calc

I've stopped installing Microsoft Office onto my home computers. Instead, I installed OpenOffice on my latest two computers. It does everything I need it to do. Or so I thought.

One day I decided I wanted OpenOffice Calc to perform a polynomial fit to some measurements I'd been taking. So I did what I always do in Excel: create a Scatterplot of the data, add a Trendline, choose Polynomial and its order, and then click the checkboxes to display both the equation and the R2 value on the chart. Except there was no polynomial Trendline!

According to the OO help forums, there really is no built-in polynomial trendline in Calc. But there is an extension called CorelPolyGUI that does the trick.

Unfortunately, I wasn't too thrilled with this extension. My measurements were accumulating every week. With Excel, I'd be able to add new data and watch the scatterplot update the polynomial. But CorelPolyGUI doesn't work that way. The result from CorelPolyGUI essentially is a snapshot that's disconnected from the input data. To get it to update, I found that I had to delete the result and then re-invoke the extension with new data ranges. And that was a big problem – I wasn't sure over what extent of my data I wanted to fit. Perhaps I could get a better fit if I omitted some measurements. So I needed to alter the input range a few times and compare the results.

There is another method, that if you're clever, you can program yourself. It's based on the following set of equations (for a second-degree poly fit):



To get the values of A, B and C, you simply matrix multiply the vector on the left side of the last equation with the inverted 3 x 3 matrix on the right hand side. Once you program this into your spreadsheet, you can alter the data and instantly get the polynomial function to update.

But it turns out there's an even easier way. I found it accidentally in the results from my search for how to fit a polynomial in OpenOffice. It involves using LINEST to operate on array data. The web page^3 describes using LINEST in Excel to perform non-linear curve fitting. It turns out that the OpenOffice Calc LINEST function works the same way, albeit with slightly different syntax. And the syntax is different because of how you define an array in Calc, separating the elements with semi-colons instead of commas.

In retrospect, I see now the same solution in the OO help forums. The user Villeroy attached a spreadsheet with an example that uses LINEST. But instead of raising the range of independent values to {1;2}, he added the X2 column and referenced it in LINEST. Same thing, really, but perhaps a bit less elegant.

Wednesday, April 13, 2016

Must-Have Extensions For FireFox and Chrome

FireFox is my favorite browser.  It beats Chrome in terms of usability.  But I'm curious to see if I could live with Chrome for a while.  So I'm taking it for a test drive.

First for safe browsing, I like to have...
NoScript (FireFox) // ScriptNo/ScriptSafe (Chrome)
Blocks all scripts from running.  Allows the user to add exceptions for scripts on any given domain, either just for the current session (temporarily) or also for future sessions (permanently).  I think I like ScriptSafe on Chrome better than NoScript on FireFox.  Why?  Because NoScript will reload the page each time a single host is enabled, whereas ScriptSafe will let you enable multiple host before reloading the page.  And ScriptSafe features color-coded buttons while NoScript differentiates between temporary and permanent whitelist with italics.

WOT (FireFox) // WOT (Chrome)
WOT, or Web Of Trust, warns you in advance when a link leads to a dangerous website, before you even click on it.  The database of dangerous links is maintained by the community of WOT users.  But this sometimes can lead to sites getting blocked when a user disagrees with a site's ideology.  Still, you can get more detail on each website's rating and decide for yourself.


For usability, try these extensions...
FBPurity (FireFox, Chrome, Safari, Opera)
Facebook could be useful if only _______ (fill in the blank).  Well, FBPurity fills in the blanks by filtering out the elements that you don't want to see.  I use it to block "food pron" (plus other annoying and recurrent topics), to keep videos from auto-playing, to hide the reactions bar, to always sort posts in Most Recent order, to hide the newsfeed, etc.

LastTab (FireFox) // CLUT (Chrome)
N either FireFox nor Chrome cycle through tabs with Ctrl-Tab the way Windows cycles through active programs with Alt-Tab.  These extensions alter how these browsers behave when you press Ctrl-Tab.  So rather than cycling tabs from left to right, Ctrl-Tab cycles in Most Recently Used order.  There is one caveat, though.  Chrome extensions are not allowed to redefine default keystrokes (such as Ctrl-Tab), so none of the MRU-type tab managers on Chrome can fix Ctrl-Tab.  However, you can bind CLUT to Ctrl-q and Ctrl-Shift-Q, which is just to the right of Ctrl-Tab and Ctrl-Shift-Tab.

Password Management
Both Chrome and FireFox come out-of-the-box with the ability to remember the username and password needed to log in at each unique website.  However, FireFox can remember multiple usernames and passwords for any given site.  After looking for a Chrome extension to get Chrome to work this way (and failing), I thought I stumbled across an experimental option to enable the behavior.  But perhaps not, since the setting I thought I discovered doesn't affect this at all.  Rather, Chrome (at version 49) just started behaving the way I wanted it to!

View Selection Source
In FireFox, you can select content, right click on it and then choose a command to view the source code for that extension.  Chrome provides an "Inspect" command, but it reveals only the CSS details and not the complete HTML.  The View Selection Source extension for Chrome (or its equivalent) is necessary to see the snippet of HTML that's rendered by the browser for that selected content.  Yes, you can press Ctrl-U to view the source of the entire page in a new tab.  But then you have to search for the content you're interested in.  That's awkward, and it works only if the content can be pasted into the search bar.  The weird thing about the View Selection Source extension is that it doesn't come up if you search for it on Google Play.  I found the link in a post on the Help Center.

Save As... / Print To... PDF
Chrome has a built-in PDF printer that it calls "Save to PDF."  It works great, and there's no need to install a separate printer driver.  But you'll have to choose at least one of these three options to get FireFox to save a page as PDF, too.
  1. Install on your computer a PDF Printer Drive, such as PDFCreator or CutePDF.  (Both are free to download and use.)
  2. Install in FireFox a PDF printer extension.
  3. Use an online Web page to PDF service.
I like the first option, since the extensions I've come across either save the web page as a image or send the HTML over the internet to a server to perform the conversion.  I like the ability to select and copy text from the PDF, which is not possible with an image.  And when I generate PDF, it's usually to record a financial transaction, the details of which I'd rather keep on my local hard drive.

At one point I couldn't get the PDF printer drivers to work with FireFox.  Before giving up and switching to Chrome, I came across this Mozilla support page.  It turned out that resetting the print_printer setting fixed it.  As well, I've had to delete the prefs.js in order to solve a problem with the PDF coming out with all blank pages.

What are your favorite Extensions / Add-ons?


2016-07-09 LG Added the section "Save As... / Print To... PDF"
2016-06-13 LG Added "View Selection Source" paragraph.





Tuesday, April 12, 2016

Notes on Setting Up Windows 7

Recently I had to set up fresh installations of Windows 7 on two computers.  Here are some tips to make that process go a bit smoother...

1. Windows Update #1 -- Microsoft has released hundreds of recommended and important updates for Windows 7 since it was introduced.  All that data is a burden for Windows Update, and the update process can bog down on slower computers.  To remedy this, you'll want to download the update associated with KB3102810 first before you even check for updates.  Adjusting your computer's Power Options so it stays awake during the long update process may also help.

2. Windows Update #2 -- I wrote about this before.  Unless you want to upgrade to Windows 10, you'll want to hide the update KB3035583, or uninstall it if it already got onto your system.

3.  Gadgets -- Third party gadgets are no longer supported due to "serious vulnerabilities" in the Windows Sidebar.  You'll still be able to add the default Microsoft ones, such as "Clock," "Calendar," "Slide Show" and "CPU Usage" (my favorites).  But I also liked the third party "Network Meter," which I'd use often to verify download rates.  Since Network Meter is no longer available, I figured out that I can use ResMon to do something similar.  To have ResMon (almost) mimic Network Meter I minimize the various components in the left pane of ResMon and resize the window so that only the network graphs show up.  And I add a shortcut to ResMon.exe in my StartUp folder.

Do you have any tips for setting up Windows 7?  Please share them!