Archive for School

Lines of Code

My last, last school term is over. All that is left now are exams. So I thought I would take a minute to reflect on the last 5 years in terms of lines of code written as part of my Computer Science major:

brett@brie:~/Documents/UBC$ find -regex '.*\.\(cpp\|c\|java\|cs\|php\)' -exec cat '{}' \; | wc -l
107090

107090 lines.

Comments

Down On the South Side

Since the opening of the new Hugh Dempster Pavillion and so-called “CS/2″ buildings at the south side of campus, I’ve spent much more time down this way. Thanks to the provincial government’s Double the Opportunity program, the computer science department has undergone a huge expansion. Apart from some class size issues (which perhaps has less to do with the expansion, and more to do with class size policy at UBC), it has worked out quite well. Dempster (DMP) is the home of 2 big lecture halls, plus 1 very large lecture hall, and 2 tutorial rooms. And it’s all for computer science. And the expansion to the original department building, CICSR, has opened up much more lab space, student study and social space, as well as a much needed UBC Food Services outlet (which has limited hours, but we can only wish for so much, can’t we?).

Having the new space in the “new wing” of CICSR (now called ICICS — don’t ask me what it stands for) is great. The lounge area is terrific. Before, there really was nowhere in the CS building to sit around and talk, eat, or anything else really. Sure there were labs, but being the good students we are, we obeyed the signs, and never ate food in there. There’s also many new labs, which I haven’t yet fully explored, despite the fact they’ve been open since September, as well as small rooms and study space you can randomly drop-in on and use for group study.

It’s odd — in my last year at UBC, I’m enjoying spending time around the department. It makes the 10 minute walk from the Student Union Building seem like less of a chore.

Comments (1)

Term 1

Term 1 has come to end. 5 courses: 2 computer science, 1 statistics, and 1 microeconomics. This term had one of the fewest number of computer science courses, yet had one of the heaviest work loads I’ve had. I’ve also had a lot other stuff going on which kept me busy — trips to see Harvey Danger, near weekly climbing, and yoga whenever I woke up early enough.

At UBC, this marked a number of changes. The first Shopper’s Drugmart opened on campus. Not just by campus, but officially on campus, in the new dentistry building. The workers are of course non-union. I wonder how CUPE is liking this.

Speaking of the village, it continues to grow. We now have a Vera’s burger place, among other things.

And unsurprisingly, the temporary bus loop has not changed and construction on the old one hasn’t even begun. It is still a parking lot for the Super Rich(tm).

Comments

Computer Graphics Project

My computer graphics project is done. Well, it was done last week. But I’ve only now gotten around to making a few screenshots and combining it into an animated gif.

The first project was to draw and animate a dinosaur using only ellipsoids (stretched spheres). In this last project, I worked with 2 people. We each included our dinosaur in the making of this project. Everything you see has been hand drawn using basic geometric shapes. Grass, water, sky/cloud and dirt textures were borrowed from the Internet. Each dinosaur may be moved independently. Each has a shadow that is geometrically correct, but does not match the light source (and it’s also slightly skewed…). Shadows are tough! The water is transparent and specular (reflective). And there are multiple light sources in the world. When a dinosaur is selected to be moved, a spotlight appears over it. As the t-rex moves closer to either of the other two, it shades to red; the other two dinosaurs also turn automatically such that they are always facing the t-rex. They animate at all times, either performing some arbitrary idle motion (tail wagging, neck bending, etc.), and their legs move when they walk. Very simple animation, but it works.

Here are some screenshots scaled down:

Comments

Dumb DNS Problems on Linux

Okay, so I’ve had the most bizarre problems with name resolution on Linux since I moved to SUSE. Okay, well, it’s not actually in terms of resolution. It’s odd. Previous problems aside that I’ve already blogged about, this one is new and recently discovered.

It seems that name lookup is fine and quick. Everything is fine in Mozilla, Konquerer, and just about every other application, including ncftp. But if I try and use telnet to connect to some random ftp server by hostname (ie., telnet ftp.suse.com 21), it takes about 20-30 seconds to establish the connection. Same goes for any service that I try to connect to via the command line using telnet. Or the native ftp client (and as I note, ncftp is also fine).

My network set-up has all DNS going through my NAT box which provides DNS forwarding. This works quite nicely and I haven’t had problems with it in the past. I do note, however, that I’m quite certain that the DNS forwarder included in my cruddy NAT software does not support IPv6 calls, which SUSE tries to spit out, despite it being disabled. This *may* be part of the current problem.

To test it, I booted with Knoppix. Boom. Same problem. This isn’t unique to SUSE. Is it something weird with my NIC? Nope. I booted with Knoppix on my laptop, and the same issue occured.

So I upgraded my NAT software and fiddled a little, and now everything is fine.

The moral of the story? Don’t use old NAT software. No, wait — I’ve got a better one: don’t do NAT on Windows. I’m still doing it on Windows because I need that box to run Windows for various legacy hardware I run off it. But I seem to have fixed the problem.

Okay. That’s my ramble. No more.

Comments

« Previous entries ·