Scriptorium
Wednesday, February 23, 2005
  Hello World
This is something I first saw years ago. It's still relevant, and it's still funny.
 
Tuesday, February 22, 2005
  Windows Annoyances
I've tried to avoid Microsoft Windows for the last decade, but now I'm finally coming to terms with having to use it professionally. So, in order to make the best of it, I'm reading Windows XP Annoyances for Geeks, 2nd Edition on O'Reilly's Safari electronic book service. I'm just in the introductory material, and I've already found a nice tool, Creative Element Powertools. Check it out if you use Windows. Also, if you don't want to pay for or dig into the book, check out the annoyances website for lots of free tips.
 
Sunday, February 20, 2005
  Ruby on Rails
Ruby on Rails is a web application framework conceived by David Heinemeier Hansson as a reaction against the complexity of J2EE. I ran across a very detailed tutorial for creating a web-based todo list using Rails and MySQL.
 
Saturday, February 19, 2005
  Ruby Hosting
Since I'm working on some Ruby software, I might want a place where I can host a Ruby web application. I've only found one so far, OCS Solutions. I still have several months on the contract with my current host, Lunarpages. I'm very happy with their service and price, but they don't support Ruby. Maybe that will change by the time I'm ready to deploy any Ruby web applications.
 
  Diceware
I watched a little bit of the first episode of the new Numbers TV show. In it, the mathematician demonstrated that when we think we are picking things at random, we still will use a discernable pattern. The Diceware Passphrase Home Page provides a system where dice are rolled to generate a random passphrase which should be much more secure than anything that we try to make up ourselves. This slashdot article talks about the need to use passphrases rather than passwords in order to have better security.
 
  Calculating the Date of Easter
I'm working on a Ruby program where I have to convert from secular calendar dates to liturgical calendar dates. Central to this is calculating the date of Easter for a given year. I found the following helpful links:
Here is the Ruby code that I wrote:

SECONDS_IN_DAY = 60 * 60 * 24

def Bcp.calcEaster(year)
goldenNumber = year % 19 + 1

solarCorrection = (year - 1600) / 100 - (year - 1600) / 400
lunarCorrection = (((year - 1400) / 100) * 8) / 25

paschalFullMoon = (3 - (11 * goldenNumber) + solarCorrection - lunarCorrection) % 30
--paschalFullMoon if (paschalFullMoon == 29) || (paschalFullMoon == 28 && goldenNumber > 11)

dominicalNumber = (year + (year / 4) - (year / 100) + (year / 400)) % 7
daysToSunday = (4 - paschalFullMoon - dominicalNumber) % 7 + 1
easterOffset = paschalFullMoon + daysToSunday

return Time.local(year, "mar", 21) + (easterOffset * SECONDS_IN_DAY)
end
 
Greg Graham's writings on software and theology.

My Photo
Name: Gregory Graham
Location: Irving, Texas, United States

Theology student and Technology Director

Archives
July 2003 / August 2003 / November 2004 / December 2004 / January 2005 / February 2005 / March 2005 / April 2005 / May 2005 / October 2005 / November 2005 / April 2006 / May 2006 / June 2006 / July 2006 / August 2006 / September 2006 / October 2006 / November 2006 / December 2006 / January 2007 / March 2009 / July 2009 / August 2009 / October 2009 /


Powered by Blogger

Subscribe to
Posts [Atom]