Thursday, March 23, 2006

The Circles and Time

Hello. I have some new development on the way (because I like to write code... be it good or bad). The first piece of code produces these images that I've been using on my page, of an entire board. Let us say, for instance, we take the fen string for the beginning board:

rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR

and we wanted to make an image of it. We would simply use the following url:

http://barney.gonzaga.edu/~psalcido/cgi-bin/php/board.php?fen=(fen)&size=(size in px).

so, for this fen, using the following code: <img src="http://barney.gonzaga.edu/~psalcido/cgi-bin/php/board.php?fen=rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR&size=200" alt="demo board" /> We see:

demo board
You also have the optional cgi variable of 'as', which will set the board to black or white point of view, just by putting &as=w or &as=b at the end of the above url data.

Now that this is covered, I am continuing on my circles, and not playing as much chess as I want. This is alright because I believe that I am learning a lot and the problems, while difficult and while I'm not very good at them yet, are getting easier. Because I haven't played as much as I want to, I don't know how good my advancement is just yet, but I'll wait until I'm done to find out because this practice is taking a lot out of me to begin with already.

Well, that's all I got for you today, other than the fact that I'm working on an online ajax wrapper for a pgndb as well, and we'll see how that goes.

Friday, March 10, 2006

Playing against the computer

Well, it comes time that I post a game, and while over the last few days, I've been doing my circles religiously (I have about 50 problems in the final problem set for Advanced100-3.pgn, and it's kicking my butt), I have just started playing chess against the computer again. This is important because it allows me to really look at the position at my own pace.

The following is a game that I recently played against my cell-phone version of ChessMaster. It really does play quite well, most of the time, and I really don't know where this game came from, but a late blunder by the computer appears to have given me the win. There were also multiple chances for the computer to draw at the end, but nonetheless, I think I played an alright game in this situation.

[White "Me"]
[Black "CellPhone ChessMaster - Skilled"]
[Result "1-0"]
[Date "6.11.03"]
[PlyCount "61"]

This game has not been annotated by Fritz. I am annotating this myself, and later I may come back to this game with Fritz's help, but that makes the annotations uninteresting, and does not really allow the reader to take a shot at finding moves that are superior at certain points in the game.

1.e4 e5 2.Bc4

I do not often play this opening. I normally go for 2. Nf3. Given that, I have noticed that I usually end up in the line 2... Nc6 3. Bb5 a6 4. Ba4 Nf6 5. O-O Nxe4, and I am terrible at the Paul Morphy. It is an opening that I have made a note to study in the future.

2... Bc5 3.Nf3 d6?!

I think that this move is weak, and better would probably be 3... Nc6, but I can't be completely certain. It just seems extremely tame. I would probably go for the more aggressive move.

4.O-O Bg4 5.d3 Nc6 6.Be3 Bxe3 7.fxe3

r2qk1nr/ppp2ppp/2np4/4p3/2B1P1b1/3PPN2/PPP3PP/RN1Q1RK1
Black to move
Just to note, I really did like the move 3... Bg4 for black. I feel that it really tightened up my position, and after Nc6, I planned to do the central trade of pieces at e3 so that I could prevent the invasion by the knight on c6. I thought that the trade and central doubled pawns were worth it. That being said, it wasn't the move Bxe3 that worried me, it was actually 6... Nd4 that I was most worried about, giving my opponent the two bishops for nothing. I would either have to trade or destroy my Kingside pawn structure. Before this move, I considered my opponents position superior. My opponents next move, though, boggles the mind.

7... Kf8? 8.Qe1 Nge7?! 9. h3 Bc8?!

r1bq1k1r/ppp1nppp/2np4/4p3/2B1P3/3PPN1P/PPP3P1/RN2QRK1
White to move
I believe that this limits the bishop unnecessarily. It's amazing, in retrospect, how many questionable moves my opponent makes. These are usually not major mistakes, and instead are slight positional errors. It gives me a chance to win this game, although it still proves difficult. The move Kf8 simply seems extremely weak, however, and with the Knight on e7 rather than f6, I believe that I am given more opportunities than I deserve.

10. Nc3 Na5 11. Bxf7?! Kxf7

r1bq3r/ppp1nkpp/3p4/n3p3/4P3/2NPPN1P/PPP3P1/R3QRK1
White to move
Playing against a computer, I'm willing to make moves like this, but I do not think that the sacrifice is sound. I believe that the best that I can do with this is possibly go up an exchange. I try my best to win this, but I believe that one move late in the game proves that the sacrifice in unsound.

12.Ng5+ Kg8 13. Qf2 Nf5! 14. exf5 Qxg5

r1b3kr/ppp3pp/3p4/n3pPq1/8/2NPP2P/PPP2QP1/R4RK1
White to move
Brutal! I had not seen Nf5, but I definitely should have. It is a very good move, and unfortunately, I miss it, and go down by a good deal as a result. However, I have more opportunities coming up, and I don't give up at this point. The King is still weak, and I have some pieces pointing down the Kingside, a battery that will eventually win me this game.

15.Nd5 c6?! 16.Nc7! Rb8 17. Ne6

1rb3kr/pp4pp/2ppN3/n3pPq1/8/3PP2P/PPP2QP1/R4RK1
Black to move
The intention with this move is to give myself the open file again with the trade. I am down material, so this does not seem like the greatest move, but I have more material to shed before I feel that I have any opportunities whatsoever to win. Like I said, it is still a real challenge for me to do anything with this game, but unless the trade occurs, I have no chances whatsoever. In addition, it will take a long time for the Knight on a5 to make it over to the Kingside.

17... Bxe6 18.fxe6 Qf6 19.Qxf6 gxf6 20.Rxf6 c5!

1r4kr/pp5p/3pPR2/n1p1p3/8/3PP2P/PPP3P1/R5K1
White to move
Brilliant defense by the computer. I'm sure that everyone here saw the immediate Nc6 as being extremely important to stopping the advance of the powerful e-pawn. It seems to me, and I have noticed this quite frequently, is that when playing comuters at lower levels, they play far better in the opening and middle game than they do in the end game. I do not understand why, but you'll see what I mean in just a second. Black will go from a winning to a drawn position to a clear loss. The next few moves are most interesting.

21. Raf1 d5?? 22.e7! Nc6 23.Rf8+!

1r3Rkr/pp2P2p/2n5/2ppp3/8/3PP2P/PPP3P1/5RK1
Black to move
Now you see. 22... Nc6 was simply too little too late. The computer needed to make the move on move 21. This guarantees a draw, at least. However, now both sides need to be on their toes. The two sides are steeped in tactical warfare from here on out, but my opponent plays sloppily. Now I can walk away with the draw with infinite check on the Kingside. My opponent decides not to give it to me, however.

23... Kg7 24. R8f7+

Offering the draw. I looked at 24. R1f7 as well, and that may have ended in draw as well as this move, but I decided to cover my advanced e-pawn with check instead, and try to see what the computer would do.

Kh6 25. R1f6+ Kg5 26. Rf5+

1r5r/pp2PR1p/2n5/2pppRk1/8/3PP2P/PPP3P1/6K1
Black to move
This is the moment that is most key for black, and the computer's final offered blunder of the game, as you will see. There are several places for the Black King to go, but he chooses the worst of all of them. I think that most people can clearly see the draw here (at least it looks like a draw to me) with Kh6 or Kg6. In fact, I do not see a win in the cards for myself here, unless I am simply blind to the tactical possibilities in the position.

26... Kh4?? 27. Kh2! Rbg8 28. e8=Q!

4Q1rr/pp3R1p/2n5/2pppR2/7k/3PP2P/PPP3PK/8
White to move
I feel that this move is worthy of an exclamation point, simply because it really puts my opponent into a lot of trouble. I cannot, of course, play g3+, because of Rxg3, but this move eliminates any possibility of a draw from my opponent, if I play sharp enough. I saw all of this immediately after Kh4 was played, and I believe that is all because of the tactical training that I have been doing. If black plays Rxe8, then I win with g3#. The hold on g3 must be held. Also, if I end up playing Qxg8 Rxg8 Rxh7# will win the game.

18... Rxg2+ 29.Kxg2 c4 30. Qxh8 cxd3 31. Qxh7#

Take a look at this game with fritz when you get the chance.

Friday, March 03, 2006

Things getting more annoying now...

I am behind by two problem sets, but that doesn't mean that I'm going to quit. I'm just going to take my time. Although I still lose games to tactics, I am catching quite a few more. I even pulled off a Queen Sac last night to snag an extra rook. Well, as I said before, I don't have to update so much here because of the automatic updates above, but thought that I might put something here just to note that I am still playing.