Monday, October 27, 2014

Pizza Sauce Recipe

Halloween is almost upon us, and that means that it's time to invite over your cool young friends and have a party.  And what young person doesn't like pizza?  It's great party food, because you can carry a slice around (on a plate) as you circulate, and nibble it while you converse.  Even vegans like pizza, if you don't put animal products on it, and you can make sure your pizza is vegan-safe by making it yourself--or even make it interactive, by inviting your guests to pick out their favorite toppings, let the guests arrange the toppings on a sauced pizza crust, and bake the pizza in your oven.

However you decide to throw your pizza party, you need a kick-ass pizza sauce to set a flavor foundation for whatever toppings you (or your guests) arrange.  Sure, you could just buy a sauce out of a jar, but you'll totally miss out if you don't try out this recipe, which you can prepare the day before the party:

Anton's Pizza Sauce


Makes enough sauce for several pizzas.  Requires about an hour of work.

2 T or more olive oil

Vegetables:
1 28-oz. can of tomatoes
2 medium onions (chopped)
7 or more cloves of garlic
1 6-oz can of black olives

Herbs and Spices:
2 T oregano
2 T basil
1 T fennel seeds
1 T mixed Italian-style herbs
1 T paprika
1 tsp ground chipotle

Get a sauce pan with a lid (DO NOT SKIP THE LID).  Put the oil in the sauce pan.  Set it aside, 'cause we're going to do all the hard work with the blender.

Run the vegetables through the blender.  If your blender is like mine, you will need to use the watery tomatoes to help the onions, garlic, and olives flow in the blending chamber.  Otherwise, you will need to stir a lot in the blender to get the unblended vegetables to circulate to where the blades are.  Also, unless you have a 2-quart blender, you will need to blend the vegetables in batches.

Anyway, put the blended vegetables in the sauce pan.  Stir it up gently, to mix the vegetable puree with the olive oil.  The olive oil helps the sauce taste "richer" and serves as a vehicle for the essential oils in the spices.  Maybe it helps keep the sauce from burning on the bottom of the sauce pan.

Put the lid on the sauce pan and turn on the heat.  Bring the sauce to a boil, then let it simmer until the onions no longer taste "sharp."  You will really appreciate that lid, because the thick bubbling sauce will spatter red all over your kitchen if you don't use the lid.  In fact, the bubbling sauce can be so messy, that I recommend you remove the sauce pan from the heat and wait for the bubbling to subside before you check to make sure the onions are cooked.

The cooking process should take enough time for you to set up the herbs and spices.

Anyway, once the onions are cooked, remove from heat, wait for the bubbling to quiet down, and stir in the herbs and spices.  Let the herbs and spices reconstitute and mingle in the sauce pan; I usually let this happen overnight.

Monday, October 20, 2014

Mazes

Ever since I was a kid, playing on my 16KB TI-99/4A, I've loved creating randomly-generated mazes on the computer.  I started with square rooms, then I worked up to triangular rooms, then hexagonal rooms.  It was only recently that I realized a very simple algorithm for solving mazes without recursion.

I present here simple algorithms for creating and solving mazes, with illustrations.  Although presented for square mazes, the algorithms can be adapted to any regularly or even irregularly tiled regions, and 3-D mazes.

Generation Algorithm


We generate this maze using a "random walk" through the maze space, skipping visited locations (rooms).  If/when we get stuck, we look from left-to-right, top-to-bottom (and back) for visited locations with unvisited adjacent locations.

Set up a 2-dimensional array with the dimensions of the desired maze.  Initialize each array element as a cell with no doors.

Here we have visualized an example 5-by-5 array of cells; each cell has no doors.

Pick a random element in the array.

Step A. Examine each adjacent location; if the adjacent location has no doors, add it to a list of potential new locations.


Choose a random new location from the list.

Add a door from the current location to the new location, and vice versa.

Move to the new location.

Return to Step A.

If the list of potential new locations is empty, we are in a "dead end."


Choose a new location, moving left to right, top to bottom, and repeating at the top.  Skip any unvisited locations.  Return to Step A.


When all the locations in the array are visited, we are done.


Solution algorithm


The resulting maze has a dendrite topology.  If we set the start and end locations of the maze to have doors leading outside the array, we can solve the maze by repeatedly eliminating all "dead ends" (locations with only one door) from the array.

First, set the start and end locations to have doors leading outside the array.


Step B.  Moving from left-to-right, top-to-bottom, find a dead end.


Step C.  Seal the one door from the dead end.  The dead end leads to only one location; seal the corresponding door in that location, and move to that location.


Repeat Step C until we are no longer in a dead end.


Return to Step B.  If we cannot find a dead end, we are done, and the entire maze is reduced to a single path from the start to end locations.




Saturday, October 11, 2014

Microsoft Buys MineCraft; Long Live Voxelands!

In other Microsoft news, Microsoft has purchased MineCraft.  Technically, they bought the company that makes MineCraft, including MineCraft as part of the deal.

I can't run MineCraft on my computer; I discovered this when I tried to run the free MineCraft Classic application.  Unfortunately, MineCraft is written in Java, an interpreted bytecode language which brings my 2GHz 64-bit computer to its knees.

What is MineCraft?


MineCraft is basically "blocks" on the computer.  Remember when you were a kid, and you would get your wooden blocks (or plastic bricks) out and build structures out of them, like little houses and buildings, with little roads for your toy cars?  Maybe you would integrate other toys, like plastic army men or farm animals or dinosaurs to knock the buildings over.  And then your mom made you put your blocks away, because it was time for dinner.

MineCraft is like that, except you don't need to put the blocks away.  You shut down your computer, but all of your blocks and structures are where you left them when you come back.  Also, you don't just build little houses you view from above, you build full-scale houses you can inhabit, because the blocks are all 1-yard cubes.

Of course, your house can be as big as you want it to be.  You are not constrained by how many blocks you can fit in your toybox, or even how many you can purchase, because they are all virtual.  If you want more blocks, you can dig them out of the (virtual) ground.

The variety of blocks is wider, too.  In the desert or beach, you find blocks of sand.  In the plains, blocks of dirt.  In the forest, blocks of wood.  Underground, blocks of stone.  Take blocks of sand, heat them in a furnace, and you have blocks of glass for windows.  And there are metals, minerals, fluids, animals, and even monsters; creating an interactive environment.

For architects, the ability to walk through a building without actually constructing the thing out of wood and concrete is new; 40 years ago it couldn't be done.  30 years ago it was very, very expensive and time-consuming.  Today, little children are doing this for fun, on Mom's smartphone while killing time at the Department of Motor Vehicles.

MineCraft Stems from Infiniminer


The game MineCraft actually was inspired by an earlier game called Infiniminer, which had explicit objectives along the lines of competing teams of miners.  But the creator of MineCraft had plenty of fun just mining and building, as we all did when we played with blocks as kids, and MineCraft is the result.

The touchstone of InfiniMiner has inspired numerous other games very much like MineCraft, such as MineTest.

MineTest


MineTest is written in C++ and compiled into machine code.  As a result, it runs more efficiently than MineCraft, and can be played on older, slower computers than MineCraft can.  Play is very much like MineCraft, except that MineTest caters to the Do It Yourself hobbyist crowd and allows casual programmers to add fundamental features to the game world via "mods" (software patches which "modify" the game world).  As such, the basic MineTest game is much simpler than the feature-rich MineCraft experience.

Voxelands


Voxelands stems from an early branch of MineTest.  It is also compiled from C++ source code, and is similarly efficient.  Unlike MineTest, Voxelands is intended as a more monolithic game, instead of a framework for modification.

The name may be confusing to some.  A "voxel" is a 3-D "volume pixel:" whereas a pixel is a "picture element," or a single irreducible dot from an image; a voxel is a single irreducible unit of volume, typically a cube.  Thus, "Voxelands" refers to lands made of voxels.  This name is accurate, as these virtual worlds are all largely composed of voxels.

As of this writing, the latest release of Voxelands is version 1409, and it is entirely playable.  Version 1410 has not yet released, but promises to include various animals such as deer, wolves, and sharks.

It's Free


Unlike MineCraft, both MineTest and Voxelands are free and open source.  If you are curious about the amazingly popular and largely nonviolent gameplay of MineCraft, or you want to find out what this thing is your kids are spending their time on, but you don't want to risk your hard-earned money on it, I encourage you to give Voxelands a try.  You have nothing to lose but your nostalgia for playing with blocks, and you have entire (virtual) worlds to gain.

Sunday, October 5, 2014

What Customers Want from Windows 10

By now, you may have heard that Microsoft has announced Windows 10.  Gosh, it seems like Windows 8 came out only 2 years ago.  What happened to 9?  I thought they were avoiding association with Ed Wood's "Plan 9 From Outer Space."  Someone opined that they needed to skip a number to basically get away from the stink of Windows 8.  But in fact, Microsoft is skipping 9 because they fear programs written by lazy programmers will find the string "Windows 9" and assume your new 4 GHz 64-bit 8-core PC is running "Windows 95" or "Windows 98."

The fear of connection with Windows 8 is plausible.  Windows 8 may be one of the most unpopular Windows releases ever; it's even less popular than Windows Vista was on their respective timelines.  Market share numbers suggest that users are buying Windows 8, using it, then uninstalling it after they can't 'get used to it.'  Why is Windows 8 so unpopular?  Didn't the press say it was wonderful?  Aren't there ads on TV showing potential customers how users are literally dancing with joy over Windows 8?

Apparently Microsoft people were shocked that users don't like Windows 8.  Presumably they use this OS quite a lot in-house.  Maybe these people are paid to like it.  I am willing to believe the people at Microsoft are smart--smarter than I am--and perhaps they are able to adapt to a UI that's a pain in the butt for most people.  Perhaps they know special "cheat codes" and settings to make Windows 8 more tolerable.  Or maybe the smart people at Microsoft are all like poor Doctor Frankenstein, unable to control the corrupted monster they created, only to watch in horror as users tear it apart and burn it with pitchforks and torches.

How much do users prefer Windows XP?  Windows XP was released in 2001; Windows Vista came out and flopped, and users overwhelmingly stayed with Windows XP.  Windows 7 (which can be made to look and act very much like Windows XP) came out in 2009, and users still stayed with Windows XP for 3 years before Windows 7 barely eclipsed Windows XP's market share in 2012.  At this point, Windows XP was 11 years old.

11 years is a long time in the world of computers.  The 8-bit Apple II was only 7 years old when Apple released the groundbreaking 32-bit Macintosh.  The 8088-based IBM PC was only 4 years old when IBM released its 80286-based PC AT.  The original Microsoft Windows 1.0 was released in 1985, and Microsoft Windows was largely a waste of time until 1995, when Microsoft released Windows 4.0, popularly known as Windows 95--a long time, but still only a 10 year span.  But Windows XP has been going strong for 11 years.  Microsoft gave up on it in April, but it's still popular now.

Why?  There are many good reasons so many people have not switched from Windows XP, and the price tag is low on the list (otherwise, the free Linux OS would have better than a 2% market share).

My experience with Windows 8.1 has been like a school bullying; I want to do something legitimate, and suddenly my taskbar screen has been replaced with the active panel display.  Or some other display I don't recognize.  Suddenly my textbooks are smacked out of my hands.  'Hey, nerd!  We changed the rules on you!  Looks like you're gonna have to find a new way to walk to school!'

Windows 8 apologists might be quick to tell me that if I don't want to use it, I don't have to use it.  More and more users are responding to this by not using it, and dumping Windows 8.  Unfortunately many cubicle-dwellers are not given the option of what OS they want to use: their employers provide them with computers, and the employees can either put up with them or quit.  If these employees had actual people upending their workspaces, they could lodge a workplace harassment lawsuit.  But unfortunately, the problem is the equipment they're required to use.  Granted, it's not like losing an arm in an industrial accident; but if it's disruptive, hinders their ability to work, and makes them less productive, it's analogous to harassment.

With Windows 10, Microsoft has promised us the opportunity to provide feedback on their OS.  Although this seems like a nice gesture, it sounds like another annoyance in my life; like taking a survey over the phone, or filling out a form to submit an opinion, or registering software I've paid good money for.  Who has the patience?  And unless I get some indicator that changes I've suggested have been implemented, how can I be sure my time hasn't been wasted?  How can I be sure that the people I'm giving feedback to are even paying attention?

I use Windows at home and I use Windows at work, all day long.  I have used Windows for decades.  I could go on about my qualifications, but for now I will ask you to please accept that I am something of a Windows expert.

Most desktop users don't want flashy distractions like Vista's transparent 3D windows or Windows 8's active panels.

In contrast, video game console users want sizzle.  If you want to make a flashy user interface, put it on the XBox.  Put it in applications where users like some excitment, like a shoot-'em-up game or music-mixing DJ software.  Put it on a smart phone.  And leave it there.

But please don't make my workday operations a regular hassle.

Microsoft, with your next desktop OS release, please try to embrace the gentle virtues of simplicity.  Please support the latest hardware, fix notorious problems, and feel free to implement whatever internal OS improvements you want; but give your customers back their familiar, comfortable, clean Windows XP user interface.

Saturday, September 27, 2014

Sweet & Sauerkraut

Looking for something festive to do between Labor Day and Halloween?  Why not try a holiday Germans have been enjoying for (two) centuries: Oktoberfest!

Yes, it's an excuse to drink beer like you do already, but it's also an opportunity to cook and eat... sauerkraut!

No, wait!  Come back!  As a prepared dish, sauerkraut is much more than just the shredded stuff you dump out of the jar and heat up.  No, that would be like boiling lasagna noodles, pouring them in a bowl, and calling them lasagna.  The sauerkraut in the jar is only the foundation for a swell casserole-like dish.

You need to accept that sauerkraut is sour and salty, and add ingredients to round it out with all the flavors the mouth can enjoy, for a complete dining experience.  Some people add wine to their sauerkraut, some people add sugar, but I use apples, which are awesome, healthy, high in fiber, and contribute to the autumnal theme.

Here is my recipe:
Serves: 4 hungry people, probably more
Time: About an hour

Ingredients (in order of appearance):
cooking oil
4 sweet apples, chopped (maybe more), and you can leave the skins on
2 medium onions, chopped
chopped bacon, or other pork product like sausages (if you're not vegetarian)
apple cider or water, as needed
vegetarian sausages (if you are vegetarian), maybe cut into short sections
1 32-oz. jar of Sauerkraut
1 T caraway seeds (if your wife will let you)
1 T peppercorns (if your wife will let you)
1 T dill
1 T paprika (sweet and/or spicy)

Directions:
First, get a big pot.  Put some cooking oil in it; I like to use olive oil.

Okay, the only hard parts about this are chopping up the apples and onions.  You chop those up, throw them in the pot, crank up the heat, and wait for the apples and onions to basically go mushy.  Stir occasionally to make sure your apples don't stick to the bottom of the pot and burn.  Add some apple cider (if you want your dish sweeter) or water as necessary to keep your stuff from sticking, but try not to make soup.  Add your bacon or other pork at this stage, if you're using them; they're just for flavoring the overall dish.

You've got some time, now.  Stir the pot occasionally to prevent burning and sticking, but take this moment to chat with your friends in the kitchen over drinks.  Kiss your spouse.  Maybe prepare a side dish (see below).

When the apples are nice and mushy, they should be releasing their yummy sugars into the pot, and we can add the sauerkraut.  Yes, do it.  Unleash the sauerkraut!  Mix it up!  Add your vegetarian sausages if you have them.  If you have really expensive refrigerated sauerkraut, you can take some time to let the sauerkraut cook.  If you got the regular shelf kind, it's already cooked, and we're just letting the flavors mingle so the sweet apples and savory onions blend with the sour and salty sauerkraut.

This is also a good time to mix in the caraway seeds and peppercorns; these seeds are pretty solid, and they will need some time to let the warm liquid in the pot draw out their spicy essential oils.

Stir occasionally to prevent sticking and facilitate flavor mixing.

During the last few minutes of cooking, mix in the dill and paprika.  These shouldn't need too much time to mingle or cook.

And once the dill and paprika reconstitute and the flavors mingle, it's ready to serve.

You can pair this with beer or cider (sweet or hard).  If you want to add a starch as a side dish, consider soft pretzels (popular at Oktoberfest), cheesy spaetzle (a swiss cheese-and-egg noodle casserole), or salted boiled potatoes.

In closing, have a great Oktoberfest meal, and enjoy showing all your friends a great new way to enjoy this wholesome and healthy food.

Sunday, September 21, 2014

Keyboard manufacturer forgot to cross a T

At work, I use a Dell L100 keyboard.  It has nice tactile feedback, and I always know where the Enter key is.  For my home, I wanted something just like it, but Dell (foolishly) doesn't seem to sell the L100.  I tried another keyboard; I soon discovered that the function keys are uncomfortably small, and the Enter key is too far away to use comfortably.

I went to the computer store and I discovered a keyboard by Vivitar which looked more comfortabe, with full-size keys and deeper key travel.  The Enter key seems to be in the right place.  I touch-typed on it with no problems.

And then I looked at it closely, and I discovered that the T was missing!  Accidentally replaced by another letter!  I asked myself how this could happen; but mostly I had to qwery: y?


I exchanged the keyboard two days later for an identical unit, except this one has a T key.  The guy at the store was very sympathetic ("I thought I was buying a 'QWERTY' keyboard, but instead..." I explained).  Always keep the receipt and packing materials!

Thursday, September 11, 2014

Kids today have way better toys

One Christmas in the 1980s when I was growing up, my parents brought home an amazing gift: a Texas Instruments TI-99/4A home computer.  This computer had a built-in keyboard and a cartridge slot for software (mostly games); you could write programs in BASIC, and save these programs and data to tape with a household cassette recorder.  For a display, you could screw some connectors down to the back of your family's color TV set.  It came with all of 16K of memory (enough to hold over 100 tweets! or several emoji! or almost 4 copies of this essay!).

I learned to program with it, figuring out basics of animation, sound, and numerical computation.  I played a lot of charming arcade-style games on it.  We hooked up a printer, and we found a painful text editor to use with it; if only we had something as capable as Windows Notepad!

There are lots of bad things I could say about the TI-99/4A, and I loved the thing.  My family moved on to other computers, but I still love the idea of a cheap computer you could plug into the family TV.

Today, there are several cheap small computers originally designed for education, but which have been adopted by numerous hobbyists and hackers.  I'm most inspired by the Raspberry Pi, which has wide support.  This fanless single-board computer is about as big as a deck of cards, built around a smart phone CPU, and typically does not even come with a case, power supply, storage (a flash memory card), or keyboard.  The computer itself costs about $35; but add on that other stuff and it comes to about $70.  You can buy a monitor for it at about $100, or (wait for it...) you can hook it up to the family TV (yes!).  And you can download a full 32-bit windowed OS (some form of Linux) and lots of other software for FREE!  Forget BASIC; with this, you can program in C, Java, Perl, and Python!

It sounds great, right?  I mean, I'm sure it is great.  But I don't have one.  It's been observed that Linux is not free-as-in-free-beer, but free-as-in-free-puppies: yes, the price tag is low, but the time required is high.  If this thing takes me more than 2 hours to fiddle with (with no end in sight), I'm worried that I will have to abandon it, and it will sit in a box of wires and gather dust, like my many other projects I started and then gave up on.  My budget is too limited for that, I don't have that much spare time, and I'm at the age where I don't know if I can handle the prospect of another failed hobby haunting me.  Ideally I'd like to hire a 14-year-old (someone I could pay in CD money, or Pokemon money, or whatever kids spend money on now, as long as it's not drugs) to do the purchasing, downloading, configuring, and testing of this thing, and then I could just hook it up and switch it on when I want to play an MP3 through my stereo, or a YouTube video on my TV.

Well, I don't have kids of my own; that's poor planning on my part.  A neighbor just had a baby, but even with the great parenting I'm sure it will receive, I suspect it will be more than a decade before I can expect Linux skills out of it.  I might have seen flyers for baby sitters at the coffee shop, but I definitely never saw any for system administrators.  Also, I'm concerned about possibly violating the child labor laws.

What I really want is to give this thing to myself back in the 1980s.  And that's the real tragedy of the fact that kids today have way better toys: I have the money to buy the toys, but I can't play with them like I used to.  Because that's all I'd really be doing with this gadget: playing with it, just like I used to play with that 16K home computer, experimenting with BASIC code for hours and hours.  I work and I exercise and I try to create art (if this blog can be considered art), and if I have a spare hour today, I'd much rather spend it as quality time with my family than twiddling bits all alone.  Would I be wasting my life, wasting what little youth I have left if I did anything else?