Saturday, November 10, 2007

Musical Instruments


In the fifth grade, my mother wouldn't let me take up an instrument. I think that that was a good choice but still, it would be nice to be able to make music with my hands and not just my voice. So, when we got a piano, I taught myself how to play some. I'm not a concert pianist, but I can play parts and things like Canon and Auld Lang Syne. Of course, I'll never be as good as these people playing a new instrument that was developed in Japan called Tenori-On.

The name means "sound in your hand" in Japanese, for a good reason. The instrument looks a little bit like a Light Bright with the face of it covered in led lights. Each light is a button, which makes a sound. The longer you press the button, the longer the note plays. Its a bit like a reformatted key board.

The instrument appeals specifically to techno musicians and has lots of features. Songs, stored in blocks, can be composed on the instrument itself or can be transferred to it from a computer using an SD card. Up to 16 blocks can be stored on the Tenori-on, each block having 16 layers to play with.

I think this is a really cool idea and plays a lot on how musicians can be. My choir friends and I used to get together with our pianist and just read through lots of random music, making some of it up as we went a long. The instrument has an option so that many can be played together so that lots of people can jam together. It's a really cool instrument. And it glows, so of course it gets extra points in my book.

Thanks to Popular Science and Tenori-on for the content and Tenori-on for the picture of it's own product.

Matlab VIII

If You Were to Read This Article...





Hello everyone, how are we all doing this evening? If you answer good, then I would have to output a "I'm glad" statement. Else if you were to answer bad, then I would probably output a "That's really too bad" statement. My else would just be "Try again". Yes yes, I did just write that opening with poor, incomprehensible English. But I was speaking in terms of Matlab language. This week on Matlab Tutorial, I was going to focus on talking about If, Elseif, and Else commands while working on Matlab programs.



The basic function of an If, Elseif, or Else statement chain of commands is to give the program some options of what exactly it will be computing. Based on what is inputted and what certain variable values are, the if statements help filter and sort these values based on parameters that you set within the code so that the program runs through different choices of computations. Basically if you want the program to do a certain calculation when an arbitrary variable has a certain value, then you write an if statement there along with what the program does when it meets those needs specified.



For example: Lets say you have the user input (back from Matlab II) a value for the variable X. You then have a line of code squaring the value of X. Now you want to have two separate chain of commands depending on what the new value Y (X^2) is. Write the "if" command on the first line followed by a condition. For this example, the condition will be when Y = 4. You must use double equal signs when writing conditional arguments. So now if Y does indeed fit the statement it will do whatever follows that code. So this example will then have Y be divided by 2 to equal the variable Z. Now that is one option. If you finish the if statement with an "end", then you have a simply if statement. But you usually want an if statement to have outputs for every possibility. So you can either write the "else" syntax after your first computation followed by a line telling it to simply make Y = Z, or I will take it one step further and add the "elseif" statement in this example program. After the if statement and the equation for Z, a line of code should start with an "elseif", telling Matlab, "if Y didn't equal 4, see if it equals this". Let's just say if Y = 5. If this is true then our next line with ask the program to multiply Y by 2 to get Z. If Y doesn't equal either, then Y will just equal Z. End your if statements with the end command and output Z. Whew, that was a little rough. Lets see this example in the correct syntax:

X = input('Value for X= ')
Y = X^2
if Y == 4
Z = Y/2
elseif Y == 5
Z = Y * 2
else
Z = Y
end
Z



As you can see, the syntax and the process of the if statement is simpler to that of a loop. the only difference is that an if statement won't loop around multiple times. It will only go through the statements once. Unless of course it is nested in a for loop! Not only does it go through once, but understand that it goes through in sequential order. So make sure that the more important arguments and decisions you want the program to make be the first if statements in your chain of commands. Slowly but surely we are putting all the pieces together.....Good luck and stay tune for more exciting adventures of BATMAN AND -...oops, I mean MATLAB TUTORIAL!



Ok, I'm done.....



Resources: While Loop Help with Cyclismo, HTML Tags at Web Source

brainfuck

Have you ever needed a programming language that's incredibly difficult to understand, has an extremely small compiler, and is still Turing complete? That's brainfuck.

Brainfuck has only 8 commands.
<> Move pointer right
+ Increment the number the pointer points to
- Decrement the number the point points to
, Store input in where the pointer points
. Print the ASCII representation of the number the pointer points to
[ ] Repeat the commands in the loop while the number the pointer points to is not zero
Any other character is considered a comment.

For the non-programmers, here's an analogy. Imagine, you have a very, very long line of boxes, arranged left to right. Each box holds a number, and you can only look at one box at a time. When you begin, all boxes hold zero.
<> Means you look in the box to the immediate right of the box you're at now.
+ Means you add one to the number in the box you're at.
- Means you subtract one from the number in the box you're at now.
, Means someone else tells you what number to put in the box you're at.
. Means you tell that other person what number is in the box you're at.
(Note that input and output use ASCII, so if the input is A, the number stored is 65, and if the number stored is 49, the character output is 1.)
[ ] Do everything within these until the box you're at is zero.

Here's an example of the "Hello, world!" program in brainfuck:
++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<+++++++++++++++.>.+++.------.--------.>+.>.

Here's a program that takes two numbers from the user, adds them and gives the answer.
,>,[-<+>]<.
Here's what happens:
, Stores user input in the first box
> Moves to the second box
, Stores user input in the second box
[-<+>] while the second box is not zero, subtract one from the second box, move to the first box, add one to the first box, move back to the second box.
< Move to the first box
. Output result.

Obviously, complicated programs quickly become extremely difficult to understand. Brainfuck really doesn't have any point, except for its very small compiler. But it's fun anyway.

The Legend of Zelda: Twilight Princess


I'll say it right upfront: I am far from the best person to be reviewing a Zelda game. I'd only played Ocarina of Time before yesterday, and I never even finished it. Nonetheless, I got the chance to play Twilight Princess last night, and I have some opinions.

I was only able to play for a couple hours, so I didn't get very far, but here's the plot as far as I got. Link is a young man in a small village, where he works on Ordon ranch, herding goats, and in his free time plays with the village children and, being an adventurer to be, helps fellow villagers with their problems. At the beginning of the game, another villager gets summoned to go to Hyrule. There's a reference to a delivery, but I didn't get far enough to find out what it is. Link gets a day off work, which he spends solving problems in the village. He finds a lost cradle, gives a cat a fish, and knocks down a bothersome bee's nest. Over the course of the day, he collects traditional Link accoutrements, such as a fishing rod, a slingshot and a (wooden) sword. After he gets his sword, he teaches some children sword fighting techniques. Just as he finishes, a monkey appears, and the kids chase it, oh so eagerly, to practice what Link taught them. Link chases after them, and it quickly becomes apparent something is amiss. He kills various enemies, and frees them from a cage. And that was as far as I got.

The unique interface of the Wii makes the game interesting. Sword fighting with the wiimote is much more satisfying than hitting A. But as cool as that is, I think they should have done more with that. Without pushing buttons, the only attack you can make is the basic horizontal slash. If you try to move the wiimote to slash vertically, or stab, it just does the horizontal slash. I think it would be even better if Link held the sword however you held the wiimote.

Some other small things: Link is right-handed. I imagine this is because most people using the Wii would be right-handed, but Link is left-handed. It's just not right for Link to be right-handed. Also, as far as I got, Link never had his trademark green tunic and floppy hat. I've seen pictures of him with them, so presumably he gets them later in the game.

Unsung Technology: The Lens


Without the lens, there would be no Neil Armstrong Hall of Engineering. Without the lens, your car wouldn't be able to give you live directions. Without the lens, millions of people would die yearly from smallpox. Without the lens, I couldn't be writing this.

Although lenses have been used for more than 2500 years, they took a while to take off. The were first used to start fires, though it's not known if they used them to burn ants. Some emperors used them for sight correction.

It wasn't until the 17th century that the lens got its day in the sun. That was when telescopes and microscopes were invented. Telescopes aided in astronomy, allowing astronomers to verify the heliocentric theory and defined astronomy as we now know it. Accurate knowledge of astronomy was necessary for the space program, which led to commercial satellites and GPS. Microscopes allowed the first glimpses at microbiology and led to cell theory and germ theory. These form the foundation of modern medicine, and allowed the development of antibiotics and vaccines.

Of course, just because lenses gained all these new roles, doesn't mean it ever gave up its original uses. Without lenses, I wouldn't be able to see two feet in front of my face.

Friday, November 9, 2007

Guitar Hero III


Bringing Back the Old and Mixing in the New




So I know someone has already posted about Guitar Hero III, but I am not here to ask who wants to go head-to-head with Slash or anything. I am not here to give you a review of the game. I am simply here to discuss, if you will, the publicity that the artists get from having there music on such a popular game. Not only does it let old school rockers reminisce on some old school tunes, but it broadens their horizons to the new and up coming bands. All three of the Guitar Hero installments have new songs from the garage bands and indy bands alike, trying to get a name for themselves. Having their song come after Bark at the Moon or More Than a Feeling really makes them look good. I know when I played Guitar Hero I and saw Freezepop for the first time, I was like, "WTF, who are they?" After you hear them, you can't help but love them. My friends actually went and saw them in concert just after Guitar Hero came out. Now who saws that Guitar Hero doesn't sell? It helps all bands just like Freezepop gain popularity and some name recognition goes a long way.



Who can't forget some of the best classics that they brought into the 3 Guitar Hero games. Some of my favorites are Frankenstein by Edgar Winter Group, Carry On My Wayward Son by Kansas, Free Bird by Lynyrd Skynyrd, School's Out by Alice Cooper, and Cities on Flame and Rock and Roll by Blue Oyster Cult.



Overall, I love the games. I'm not that great on them just yet, still have to play on a Medium and Hard difficulty, but it is fun and exciting and the music is the best picked. Rock on!



Resources: Wikipedia

Monday, November 5, 2007

Pandora: A Closer Look At Genius

I have previously mentioned the website pandora. At the time I had mentioned it, it was very new to me, and I was just discovering the amount of genius put into this website.

Once again, pandora is a website where you create your own radio station to your preference of music. You can register for pandora with an email address, and then you can either listen for free, or subscribe to pandora. I registered as a free listener two day s ago and I haven't stopped listening to 5 different radio stations I have created yet. With Pandora, you either enter an artist or a song, and it generates a radio station for you to listen to playing music similar to what you selected. I have found this to be a great way to listen to the music you like, plus more music like your music.

With something this great, you may be wondering how it is even legal, and if there are any limitations. The only limitation I have came across so far, is that you can't skip too many songs on the same radio station because of the song copyright agreement. But the way to get around this is to simply create a new radio station.

With this station you get to listen to all the music you enjoy for free. Someone could perhaps argue that this isn't as good because pandora generates the radio station for you. However, if anyone says that, they are very picky, and most likely listen to the trends of whats popular, instead of the actual music. So if you life music, for the art it is, you will like pandora.