Javascript calculators

Here you'll find hopefully an ever-increasing collection of little pages that can do mostly fairly trivial calculations right in your web browser using Javascript. It's something almost any web browser can do (unless you Javascript off), and it works the same way whether you're running Linux, or OpenBSD, or a Mac, or even Windows. This was created under Linux, but you'd probably find it hard to tell. I like unix-like operating systems in general, but there's not much for easy-to-use GUI programming environments (like Borland/Inprise Delphi under Windows). At least 75% of the work in writing most GUI programs is just to make the user interface work, and by the time you get that written you're too tired or out of time to devote much energy to writing the actual program. Using a web page as the user interface takes some of the work out of it. I like writing CGI programs in compiled C too, but you won't find any of those here because it's not my server.

Javascript is fairly limited on speed, partly because it's a scripting language, not a compiled one. Some modern web browsers like Firefox 6 and later seem to precompile, making it a run-time compiled language like Perl. It's still not as fast as a native compiled or assembled executable, but it runs under any operating system and without the overhead of installing real Java.

For starters, here's a little random password generator that I wrote back in 2008. It's good if you need to make a high-strength password for something and your imagination's a little tired. Dial in the length and number of passwords, then click Generate. Look over the results to see if anything can be slightly altered to make it easier to remember. If not, keep clicking the Generate button. I'm not sure how accurate the calculation of the number of guesses to guess the password at the end is, but it's probably close. Your spellchecker will love it.

Here's an antique that I dug up from 1998, a wind chill calculator. I'm not a big fan of wind chill: I'd rather know the temperature and wind speed, but for some reason I wrote this back 2/2/1998. I don't remember where I got the formula, it might have come from the Old Farmer's Almanac but probably somewhere on the web (this was before Google existed). This required Netscape 2.0 (!) or later. It still works fine in Firefox 6.

This one is adapted from a C program I wrote. I wanted to play around with DRM and software defined radio using Spectrum Laboratory so I needed to build a downconverter to convert a 455 KHZ IF to about 11 KHZ which then gets fed into a soundcard. I needed a stable 466 KHZ injection signal, but about the only crystal I had handy was 3.579545 MHZ so I concocted this scheme of multiplying the crystal frequency then dividing back down with a PIC. This works out the best harmonic and divisor to get closest to the frequency you want.

Not a Javascript calculator but an idea I had back around 1998 for dealing with faded color photos.

Moxon Rectangle Calculator as featured in QST for October 2011, this antenna is relatively small and inexpensive to build, giving performance roughly equivalent to a 2-element Yagi in slightly less space. This uses coefficients worked out by L.B.Cebik and is modelled after his BASIC program to make a calculator that's operating system independent and requires no installation.

Units table, not a calculator, just a table of units (about 300 of them) transplanted from BSD units.lib into an html page. Some are useful, some obscure, some hard to take seriously. You have to set up a unix box to use the real program.

A converter for MMANA-GAL/NEC antenna modeling files between the two formats, also has Povray output. Not 100% of the features of the files are translated, but the wire data is all there.

An OpenBSD kernel "roughing in" tool

An OpenBSD library lister for finding functions

A turns ratio table for baluns (with C source)

Trim Space, a little utility for other people out there who use the Joe editor. Trims trailing spaces off lines in text files.

A little Palette viewer for looking at the colors defined in a gifclrmp palette file.

Verbosity patches to make OpenBSD's dhclient into a tool for diagnosing DHCP and WiFi Access Points.

backdir, a little program to back up the program you're working on by just typing "bd". Saves different versions with the date and time as part of the filename. Works with almost any documents.

Improving contrast in pictures with The Gimp, Photoshop, Paint Shop Pro, etc. by simple statistical methods (semi-unfinished)

Obama Cares bumper sticker

Modeling a piece of hardware cloth for a parabolic reflector (failure)

Plot parabola in Postscript

dirdat reads a directory tree into relational database files

dt Disk Thumbs makes thumbnails of CD/DVDs full of JPEG pictures from digital cameras

It's not exactly a calculator but the page at is a photo gallery implemented entirely in Javascript contained within the page, look at the page source.

Oh, and most of my photo pages here like Burnt Hill have a Javascript option to change the page background color.

Focus Stacking photographic images under unix (8/28/2016)

lcext, a tiny Unix utility to convert all the filenames in a directory to have lowercase extensions. Useful sometimes when they came from Windows, but it renames up to 12,000 (by default) of them at once.

The distinction between what should be in "toys" and what should be here in calculators is beginning to get a little fuzzy, but mostly I put the more fun stuff there.