Archive for January, 2006
Rapid PDF Splitting/Joining
I had need this afternoon of a rapid way to take parts of preexisting PDF files and stitch them together without the possibility of quality loss. I found joinPDF, a tiny java program (and appropiate script) which does both of these things from the command line very, very fast.
All I ended up typing was:
./splitPDF Commendation.pdf
./splitPDF Resume.pdf
./joinPDF all.pdf Resume_page1.pdf Commendation_page2.pdf Resume_page2.pdf
and … bam! Resume PDF with a letter in between the body and the references.
I fiddled with LaTeX and GhostScript to do the same thing before finding joinPDF but the results I was getting were ugly, while textually correct. That’s my system’s fault, some font is not copied to a location where GhostScript could find. Rather than fix that I found joinPDF. So… enjoy.
No commentsWilliam, your neighborhood Sith Lord
April and I (with James as a witness) batted around ideas for another Star Wars-inspired Fan Film last weekend, much narrower in scope than Pizza Delivery Jedi. My working title is “William, your neighborhood Sith Lord”. The idea is to make a short about a day (or so) in the life of the guy down the street who happens to be a Dark Lord of the Sith.
I have in my mind his house appearing to be a normal every-day sort of one story house, but when you enter the back yard you find a giant Massassi step-temple being constructed.
I’m imagining short clips where William uses the Power of the Dark Side for personal gain. Like:
- Force Lightning
- Using Force Lightning to recharge a camera battery
- Using Force Lightning to power A/C (or a TV, or something) after a hurricane
- “Rock, Paper, Scissors… FORCE LIGHTNING!”
- Telekinesis
- Force throw/choke/grip to rescue/remove a cat from a tree
- Force Pull to acquire a beverage (too obvious, methinks)
- Modify the roll of dice in D&D
- Other Powers(?)
- Life drain to LARP Vampire: The Masquerade in very… authentic ways
Consider this my solicitation for further suggestions. If things start looking entertaining enough, hell… who knows, maybe I’ll actually film it. I’m crazy, man, crazy!
No commentsThe Pirate Problem
I spent last night at the Swamp with a team of folks from Ultimate Software, a group from Weston, FL, and a few other prospective hires. They… read this blog (Hi!) and I have an interview with them in a few hours. At any rate, the last things we talked about last night were various logic puzzles and riddles. I offered to bring an entertaining one along to my interview with them this afternoon and I thought I’d post it here for your entertainment.
I’ll put up solutions in a few days. Note that “political” solutions aren’t valid answers since these are “logic” puzzles.
Also, googling for the answer isn’t a valid solution method, either.
These were given to the ACM Programming Team last year by Dave Small.
The Hard Problem
You have 1000 pirates who are all extremely greedy, heartless, bloodthirsty and perfectly rational. They’re also aware that all the other pirates share these characteristics. They’re all ranked by the order in which they joined the group, from pirate one down to a thousand.
They’ve stumbled across a huge horde of treasure and they have to decide how to split it up. Every day the lowest ranked pirate proposes a (not necessarily equal) way to divide the booty and then the other pirates vote on whether to follow this method. If more than 50% of them vote to split it the treasure gets split. Otherwise, they kill the lowest ranking pirate and repeat the process until more than half of the pirates decide to split the treasure.
The question is: if you are pirate N, what solution do you propose to ensure that you do not walk the plank?
The Easier Problem
You have 1000 pirates who are all extremely greedy, heartless and perfectly rational. They’re also aware that all the other pirates share these characteristics. They’re all ranked by the order in which they joined the group, from pirate one down to a thousand.
They’ve stumbled across a huge horde of treasure and they have to decide how to split it up. Every day they will vote to either kill the lowest ranking pirate or split the treasure up among the surviving pirates. If 50% or more of them vote to split it the treasure gets split. Otherwise, they kill the lowest ranking pirate and repeat the process until half or more of the pirates decide to split the treasure.
The question is: at what point will the treasure be split and what will the precise vote be?
Skype
I picked up a Logitech USB Headset 350 today from Best Buy with some Christmas money and now I have a very sweet teleconferencing/gaming voice solution. And to go along with this I installed Skype, what is probably the premiere Voice over IP telephone program (it’s also free to use). I’m looking for people to chat with, so if you’re Skype-enabled (or have a microphone and want to download it), try giving me a ring. My Skype name is “Pugtor“.
The headset also has volume control buttons in-line with it which I’ve been trying to make function here in Linux. There’s an existing project to do this for an older headset model by Philipp Kolmann, but it doesn’t work on the 350. I’ve spent a little time trying to get it to work, but things aren’t going so hot on that regard.
5 comments‘Stupid In America’
I ran across an ABC story titled “Stupid In America” which echos many negative things about our public school system which I’ve been saying for some years. Many of which can be summed up by crying, “Competition, please!”
I like one of the final points brought up in this article in particular. In response to a teacher claiming competition is bad for human beings, children and education, the author makes a nice free-market reply quoted below in context for your humor:
“To say that competition is going to improve education? It’s just not gonna work. You know competition is not for children. It’s not for human beings. It’s not for public education. It never has been, it never will be,” [Ruth Holmes Cameron, a Florida teacher] said.
Why not? Would you keep going back to a restaurant that served you a bad meal? Or a barber that gave you a bad haircut? What if the government assigned you to “your” grocery store. The store wouldn’t have to compete for your business, and it would soon sell spoiled milk or stock only high profit items. Real estate agencies would sell houses advertising “neighborhood with a good grocery store.” That’s insane, and yet that’s what America does with public schools.
At any rate, I hope this article proves fairly influential since, of course, it’s preaching a viewpoint I favor. Feel free to post your own comments in reply to this post, of course.
On an unrelated note, this journalist doesn’t know the difference between a yard and an inch whilst reporting about a Japanese rat snake befriending its meal…
5 commentsVice City and Jedi Academy
I splurged today. I looked through the list of Windows games which are supported on Linux by Transgaming’s Cedega and saw two that I’ve wanted: Grand Theft Auto: Vice City and Star Wars: Jedi Academy. Both of which are from 2003, actually. Anyway, I had a lightbulb moment and visited Half.com, purchasing both for $29, after shipping.
Even if I don’t play them in the very near future, I’ll have the option. That’s always a pleasant feeling.
2 commentsPEBS: Pug’s Extensible (Remote) Backup System
I had a hard drive on my computer here have a complete head crash last weekend. Luckily, I’m a paranoid freak who runs his desktop with a RAID array, so no important data was lost. However, I realized over the week (while waiting for the replacement drive to arrive) that I have several places on the Internet to where I could do offsite backups of my most critical data if only I trusted them with the data.
Well, I had a bit of a brainstorm yesterday and I wrote a series of BASH scripts which I am actually rather impressed with which I’m titling PEBS: Pug’s Extensible Backup System.
Features:
- Written in BASH with minimal dependencies
- Provides a simple scripting language for defining what you’d like backed up
- Can be used on a multi-user system with each user defining what files they would like backed up via the scripting system (this is unsecure, presently, though)
- Uses GPG and your public key to encrypt the final backup archive before transmitting it to the remote host
Executive Summary for Interested Parties (Read!)
PEBS provides an infrastructure for remote, encrypted backups. Proper use of PEBS is going to require you to be comfortable with the “tar” command and have a basic knowledge of how to edit a shell script.
What PEBS does is takes care of backup naming, data encryption, data transfer to the remote server and verification of successful transfer. It also provides some logging of the results. If you’ve questions, look at the script example below for an idea of how to use this tool.
Download:
No commentsThe Flying Spaghetti Monster, soon in paperback!
Everybody’s favorite alternative Intelligent Design theory, Flying Spaghetti Monsterism, is soon to have its gospel published. Yes, boys and girls, you can pre-order The Gospel of the Flying Spaghetti Monster from Amazon. All profits from book sales will, apparently, go to purchasing a missionary pirate ship (complete with cannon).
Who else is amazed?
3 commentsDarwinia
I’ve bought a new video game from the makers of Uplink and, like Uplink, it’s entertaining, addicting and available for Linux. The game’s graphics are actually quite excellent - you’ll have to give it a try (demo) to see what I mean. Everything is blocky, reminiscent of Galaga, Centipede and Space Invaders and decidedly charming. The gameplay interface stays out of the way and lets you do your thing: saving the Darwinians from the Virus, all the while bringing Darwinia’s systems back online and finding new engines of war.
Maybe that was too fast. Game’s backstory: Dr. Sepulveda, renowned game developer, created the much-hyped Protologic 68000 in 1986. Unfortunately, the game console had major flaws resulting in warehouses full of unsold and returned machines. Sepulveda started to experiment with the machines, creating a virtual world called Darwinia.
Unfortunately, Darwinia contracted a virus-like infection that rapidly spread among the Darwinian colonies. Dr. Sepulveda has attempted to protect the Darwinians by isolating areas, but large portions of the world have been overrun. You managed to hack your way into the network, which surprises Dr. Sepulveda, but he is desperate and requires help. You must destroy the viral infection and save the Darwinians.
It’s just challenging enough to be fun, has a modding community which has been making add-ons and saves progress automagically so that you can come and go into Darwinia as you please. Useful.
So, I’m playing that a bit now that I’m back in Gainesville. I also put executables for SCHUA online for downloading, so if you want to try it out on your own computer you can do that now. I’m having problems with the Linux executable, but the Windows one seems to work. If you can, try the MacOSX version and report back - I have no method of testing it myself.
No comments