« Posts by MadRocketSci

Shapelib

So, I was thinking one day when working on this scheme I have for this unstructured finite difference PDE thing that is one of these never-ending ongoing programming projects of mine.

Wouldn’t it be great if you could take shapes and operate one them as if they were data-types?

Well now you can! At least in 2d. This is pretty much still a work in progress on my part. I intend to add the 3d version of this same logic after I work up the plane-projection and point identification nonsense.

This library has some limitations, but it basically provides you with some shape classes and binary operators (union, intersect, difference). (fairly wide-open ones at that – I’ve tried the whole keeping data private thing, and it just introduces a lot of rigidity IMO. Eventually you want to feed these to some other algorithm, or pry them apart to do something else with, and doing that through entirely redundant set and get members is a waste of time. Why is this part of OO coding practice?)

The shape classes can have arbitrary holes. It’s based on oriented planar straight-line graph stuff.

Anyway, what do you think? Does this sound useful to you guys? I can post the code when it’s properly commented and cleaned up if so. It’ll be useful to me when I finally get the 3d stuff working, so I can build arbitrary 3d shapes.

First Java Applet

So, I just finished looking through some example code from a Java Applet games contest, and managed to wrap my head around their AWT windowing and event system. (It was hard though – the guy who wrote the applet I was parsing a few minutes ago had all sorts of helpful variable names like i,j,sg,bl and piled everything into fifteen nested levels of loops in a single method. :-P)

But it was informative.

And now, I present, my very first java applet:
(For some reason, this sucker just will not display from within a wordpress page. Link to HTML:)
ColorPatch Applet

And the source code:
src

Closing the Forum

So, I thought to build and administer one of those PhPBB forum things for my friends and family to post on. It was also a good experiment in administering database-backended php/javascript applications. The whole thing was a productive learning experience.

However, none of my acquaintances used it for much. In addition, it has been absolutely flooded with spambots. CAPTCHA does nothing -apparently someone has managed to get a decent OCR attached to their spambot system. I get hundreds of registrations per day from automated spam posters. It’s pretty annoying. I don’t know why people do it either. They couldn’t possibly get any add revenue from a spew of wordsalad advertising viagra and other less mentionable things in languages that the site can’t even display properly. Seriously, why put so much skill into creating programs to do something so useless?

Grrr. Anyway, even though registrations have to be approved, I have a backlog of several thousand now that are just clogging the database. Maybe if/when I have more interest in my blog, I can try again.

I wrote a song! I wrote a song!

😛

I finished a piece of music using an interesting computer tool called Open Mod Plug Tracker. So far, I’m just using the default MIDI library for my samples – I haven’t chopped up any music I like into finely ground little single note bits to reassemble. But so far, the results are auspicious, especially since I’ve been out of practice in the musical world for almost 8 years.

Stuff in C Minor

Check it out! Let me know what you think.

Higg’s Boson Discovered

http://www.bbc.co.uk/news/world-18702455

Apparently the LHC team has discovered a new particle in the 125.3 GeV mass range that they claim is consistent with their ideas about the Higg’s Boson. If this is so, then this is a big leap for the standard model.

Attention Control

I’ve noticed that keeping my attention on task has been getting difficult in the evenings. My mind has been wandering all over the place. Unfortunately, the internet aids and abets this tendency with a vengeance. So, to keep my mind from dissolving in endless distraction, I have been engaging in some attention control exercises I’ve come up with.

One of them involves drawing a black dot on a sheet of paper. I set my kitchen timer for 5 minutes, and stare at the black dot, not allowing my field of vision or my mind to wander from it for that period of time. I don’t know about you, but I’m finding this exercise to be almost physically painful. To stop thinking about every random thing going on in my head, and only about what I am consciously choosing to focus on is an extreme effort.

Of course, attention control *is* supposed to be a mental endurance exercise – I suppose it might get easier with time. My hope is that endurance in this regard translates over into being able to direct my attention on my projects.

McAfee!!!!!!!!!!

(/Captain Kirk Scream)

I swear! McAfee is a *virus* all on it’s own. The things we do for security! It’s like the freaking TSA has set up shop in my computer. Not only does the firewall block access to the internet on startup (I have to disable the firewall, then unplug and replug my network cable), not only does it start scans which crash the computer, not only does it crash every time I try to download my e-mail, it makes everything run terribly slow.

I find myself booting into Linux more and more often, just to avoid the hideous slowdown incurred by running anti-virus software. On the plus side it’s been forever and a half since I’ve gotten infected by anything. On the negative side – is the cure worse than the disease?

Putting up a new forum

I’m putting up a new forum for family and friends. After getting my head around MySQL administration, now the only choice comes down to which server software will fit my needs best:

* PhpBB3 – this is the end-all be-all everything on it option with a billion and a half knobs to turn
* SimpleMachines – this one seems pretty straightforward. Content might have to be hosted elsewhere though (uploaded pictures and the like).

What to do, what to do … oh yes. That’s right. Study for finals.

(get’s hooked offstage)

A Brief Introduction to my Musical World

I have been surfing youtube for music for a bit over two years now, and I’ve come across a *ton* of modern music that is absolutely wonderful (as well as a lot of crap – Sturgeon’s law applies, but the diamonds are worth the dross). The rabbit hole goes much deeper than just this, and there are other styles I’ve found that I have taken a liking to, but this is a sample of some of the music I’ve come to enjoy that may be unusual or hard to find for beginners.

The modern musical world online is extremely vibrant. One interesting aspect of this (Homestuck in particular) is that a lot of this music is made by independent music fans using nothing but a computer, contributing to a shared world.

Random Stuff

Trance Violin:
Pursuit of Truth:
Dark Epic Techno:
(A bit of a misnomer, I don’t find it particularly dark, or techno. It’s sort of relaxing. Ignore the crazy background pictures, and the voices in your head :-P)
Sea of Crystal:
DreamChasers:
Beethoven Virus:
Sky Titans
Timebomb

Homestuck:
Land of Light and Rain:
Land of Frost and Frogs:
Homefree:
Dance of Thorns:
Descend:

(an anime – a lot of anime music is *very* good, engrish/japanese aside)
.HACK: The World:
,HACK: Obsession:
Synchronicity:

Gooseworks: (This guy is apparently a game music composer, and has some good stuff)

Industrial Elegance:
Gruntilda:
(a very witchy battle theme)
Ming Co.:

Assorted Music from Video-games:

FF4 Epilogue
especially
FF4 Epilogue:
Within the Giant:
Leave Time for Love:
Can you Fly Sister?:
Castlevania: Tocatta:
(*This* is how you do vampires, Twilight. :-P)

The Lunar 2 Soundtrack: All of it:
1)
2)
3)
4)
5)
6)
7)
(Seriously, just keep clicking!)

Trance:
1)
2)
3)
4)

Random Stuff

Keepalive …. keeeepalive!

I haven’t posted anything in ages. Graduate school has been eating *all* my time. But perhaps I should continue to post occasionally, even if it isn’t some epic or profound piece of deep insight, or the result of one of my never-ending projects (which seldom produce complete results :-P).

So, random fantasies as to what I might do eventually given time:

I’ve been thinking off and on of setting up my old POS dell server again. I started apache on my machine and was playing around with it, but it would be preferable to set up a gateway/server that could stay on all the time. I don’t like running my main machine constantly for two reasons:

1. Thunderstorms and brownouts – I don’t want my machine dying while I’m halfway across the city. I don’t care if the dell box fries.

2. Random suspicous port-scans from Russia – some dude in Russia keeps trying to connect to things. McAffee pitched a fit once when I had apache open and tried to connect to freenode on IRC. If somethings going to get hacked, I’d much rather it be my POS dell box.

The dell box is interesting. I bought it from a used computer store for $80 (and probably overpayed! :-P). It is a bit flaky in the way I wired the hard drive to the mother board (it’s a SATA drive going through a converter chip that occasionally shorts). On the other hand, it’s a perfect platform for messing around with esoteric server/gateway projects. I’ve currently got it running Fedora 10, and everything works well. I’ve got Apache set up and configured on it.

It would be nice to have it always connected to the internet, but I only have the one modem comcast gave me, and it only has one ethernet port. I would have to configure the dell box as a gateway, and set it up to forward traffic. Fortunately, linux apparently has all the stuff needed to do this. (Routers are internally usually linux/unix computers with certain software setups installed to boot on powerup). Unfortunately, this will require knowing more about networking than I probably do right now.

But to get me started in my pie in the sky project, the following FAQ provides some hints as to the steps required. http://www.stanford.edu/~fenn/linux/

Once I get this project done (read never) it should allow me to have an always-on internet “face” that I can log into remotely, use as a file and web-server, a platform to mess around with internet programming experiments, and forward all my traffic to my main machine which can be on or off half the day.