Tuesday, October 29, 2013

Optimization

This week at my school there are "comp" exams, which are basically midterms.  I'm still not exactly sure whether "comp" means "comprehensive" or "competency," but the former sounds much nicer.

And right after, I get to take SAT subject tests!  (throws ticker tape)
It's going to be a long short week...

Anyhoo enough ranting, now for today's featured presentation.
-----------------------------------
I'm part of the school's Robotics Club as a programmer.  When I got there and how is a completely different story I'll save for later (I'd say for another rainy day, but it's already raining here this week, and I know I won't be able to get to it this week).

The programming platform that I use is ROBOTC, which, as you can guess, is based on C.  I haven't actually programmed in real C, but only in Java.  There's a bunch of differences between the two, but all I'm pointing out is essentially, C is not my first programming language and I needed help with it.

I needed to find the syntax of how to create an array, which is a list of objects (whether it be text, numbers, true/false statements, etc).  Searching the Internet I stumbled upon a nifty, unrelated related tutorial: "How To Have a Robot Maze Solve."

Two little points I'd like to highlight:
"What are the steps In maze solving?
There are basically 2 steps. The first is to drive through the maze and find the end of it. The second is to optimize that path so your robot can travel back through the maze, but do it perfectly with out going down any dead ends.

How does the robot find the end of the maze?I use a technique called the left hand on the wall. Imagine you are in a maze and you keep your left hand on a the edge of the wall at all times. Doing this would eventually get you out of a non-looping maze. This tutorial will only deal with mazes that do not loop back on themselves."
These made me think: the relationship between a programmer and a robot is like that between a teacher and a student.  No, I'm not saying that students are mindless slaves.  But rather, programmers give robots sets of instructions to carry out tasks.  They need to translate what they know are the right moves to code for the robots.  Isn't this an example of teaching and learning in its most primitive form?

Now, programmers could just stop at giving instructions to move to X and turn to Y to get to Z.  Teachers could just give students the basics: a routine of calculations to memorize, the definition of words they need to understand a book, the recipe for an experiment.
But they don't.
The first goal in learning is to drive through the maze and find the end; to finish the task at hand correctly.  The next goal is to optimize the path that was taken, but do it perfectly; to learn from mistakes.

It seems to many that the main point of school is the first.  Learn how to do something, and get it over with.  But sometimes we miss the second.  Simply put, there is just not enough time in the curriculum to spend on error analysis.  This is not anybody's fault; it just naturally takes up a lot of time.  To remedy that, teachers assign homework to complete that second step; to help you work towards recognizing the dead ends in the maze.  Too often as students we downplay homework as an extension of the first goal; as a repetitive waste of time.

And as teachers, it is difficult to teach optimization.  You could tutor each student one-on-one to catch all of their mistakes, or you could teach students how to catch their own.  In the robotics world, this is the field of artificial intelligence.  It all comes back to this: teaching how to learn.  Catching all the mistakes for your students won't nearly benefit them as much as teaching them how to catch their mistakes.  Next year or in a couple of years, when they revisit the subject you taught, how would they manage if you weren't their teacher?

The difference between students and robots in this context is that if given the "left hand on the wall" technique for solving a looping maze, which cannot be handled by the technique, the students will eventually learn how to adapt that for loops using common sense.  Robots, on the other hand, rely on the programmer's word and are not capable of extrapolating from what was taught.

Optimizing learning takes place outside of the classroom.  To truly learn, you have to experiment with your own ideas--"in this maze, if I keep turning in the same direction too many times, I might be traveling in the same square."  They may or may not be right; take the time to talk over them with your teacher (alliteration!).  Doing so is active learning; the intention of education.

No comments:

Post a Comment