KernelTrap, OS/kernel, Linux, FreeBSD, Life, NetBSD, GNU/Hurd, OpenBSD, Applications/tools, Other, Nothing, Me, Personal, Linux, FreeBSD

A Gentle Introduction to First-order Logic

Submitted by Eus
on February 6, 2010 - 7:03am

Source:
(1) Knowledge Representation and Reasoning by Ronald Brachman and Hector Levesque
(2) Artificial Intelligence: A Modern Approach (2nd Edition) by Stuart Russell and Peter Norvig

Learning by Doing: Programming Razz Simulator

Submitted by Eus
on February 4, 2010 - 10:54pm

As a final assignment in my Languages for Scientific Computing class, I develop a Razz Simulator (http://github.com/eus/razz_simulation). Basically Razz is the inverse of Poker in which you try to come up with the worst hand (http://en.wikipedia.org/wiki/Razz_(poker)). The game is well explained in the slide for the first and second lectures and in the sixth assignment foud in http://www.cs.utexas.edu/users/pauldj/lectures.html. The first problem on Razz was at the end of the first assignment: given A, 2 and 3 to start with, what is the probability of getting a hand with rank exactly 7? Well, no one answered that correctly until the professor showed an elaborate calculation in Mathematica that resulted in 0.143008. One important message is that people don't do such an elaborate calculation in reality. Rather they use a simulation (i.e., play as many Razz games as possible with the given starting cards and count the number of times you score 7). So, the last assignment is about developing the simulator that can simulates as many games as possible in the shortest time possible. The most interesting thing about the assignment is that the program is neat enough to show some interesting software engineering principles in action beside telling you that Razz is not as simple as it seems to be.

Seeing It as a Relationship: <-> beta-reduction

Submitted by Eus
on January 29, 2010 - 5:36pm

Last week I got a question that asks me to show that the following statement about Y combinator (http://en.wikipedia.org/wiki/Fixed_point_combinator#Y_combinator) in LaTeX is correct:

Y z \leftrightarrow^{*}_{\beta} z (Y z)

where \leftrightarrow{\beta} = \rightarrow{\beta} \bigcup \leftarrow{\beta}

What does mrproper in "make mrproper" stand for?

Submitted by Eus
on January 23, 2010 - 2:44pm

Last Friday the morning session of my Languages for Scientific Computing class was about Makefile. Well, largely there was nothing interesting since I know how Makefile works already. But, still the teaching assistant could surprise me with: make mrproper.

The Difference between LEA and MOV OFFSET

Submitted by Eus
on January 23, 2010 - 1:33pm

The other day a friend of mine asked me to code a decimal-to-hex-converter in MASM using DOS ISRs (Interrupt Service Routine) for I/O. Well, I just gave her the equivalent C code since I am not into proprietary software. But, anyway I googled for some materials related to MASM syntax and DOS ISRs for I/O [0]. Upon reading some examples of using DOS ISR 21h, I stumbled upon the use of LEA dx, var and MOV dx, OFFSET var. So, I decide to have a look into them and come up with the following conclusion.

Alternative power for LED head light

Submitted by olecom
on January 19, 2010 - 10:09am

I've bought a LED head light some time ago. Battery turned to be absolutely useless. It runs only 15 minutes instead of 12 hours. It has two holes inside, but there’s no liquid. Maybe all went off, and thus there’s no power… Even if had something, I don’t know what to put there, acid, alkali, water?..

monitoring "Smart Array" line of hardware raids with solaris 10 on HP servers

Submitted by mator
on January 11, 2010 - 8:49am

Recently discovered, that it is possible to monitor "Smart Array" controllers under solaris 10 OS. You need to install HPQacucli solaris package, which can be downloaded from hp.com site, read carefully "RELEASE NOTES" about support of your server hardware and controllers, also make sure that you have a recent version of CPQary3 driver installed (2.1.0 or later). Here's an example output:

Selling Copy-lefted Free Software Encourages More Copy-lefted Free Software

Submitted by Eus
on January 9, 2010 - 9:39am

Free software does not mean public distribution. Free software means that the licensees have all of the four essential freedoms (http://www.fsf.org/licensing/essays/free-sw.html) with the software. Selling free software means that you license the software with a fee to a buyer under a free software license.

Android ListView Selection Problem

Submitted by Eus
on December 31, 2009 - 6:55pm

About some weeks ago I got the chance to fiddle with Android (http://www.android.com) that is used in mobile service discovery research in Mobile Communication System Engineering Lab (http://ds.informatik.rwth-aachen.de/teaching/ws0910/mcse/). The assignment was to create a simple ToDo list (http://github.com/eus/android_todo). But, it turned out that programming Android's ListActivity to highlight a ToDo item was not that simple.

Massively Distributed Systems I (Updated: 2009-12-27 17:21)

Submitted by Eus
on December 27, 2009 - 12:22pm

This is just to help me study for my Massively Distributed Systems class at RWTH Aachen (http://ds.informatik.rwth-aachen.de/teaching/ws0910/p2p-mds/) since if you can teach something to somebody else, you really know something about it.

Your CPU Peak Performance

Submitted by Eus
on December 24, 2009 - 4:43pm

I am following an interesting class on Languages for Scientific Computing (http://www.cs.utexas.edu/users/pauldj/lectures.html) taught by Prof. Bientinesi (http://www.cs.utexas.edu/users/pauldj/). Just a week ago he explained about the theoretical peak performance of a processor that is none other than: n_cores * frequency * ops_per_cycle_per_cpu. But, that is not the practical one.

ASUS WL-500W Router Internals

Submitted by Eus
on December 24, 2009 - 2:42pm

Some weeks ago I had the chance to fiddle with OpenWRT (http://openwrt.org) on ASUS WL-500W router because I got an assignment to extend Screamer (http://github.com/eus/screamer/) further: assignment 4 (http://github.com/eus/screamer/blob/master/doc/assignment4/assignment4.txt). The OpenWRT wiki was sufficient to get everything up and running (http://nuwiki.openwrt.org/oldwiki/openwrtdocs/hardware/asus/wl500w), but the network configuration was not right for the task at hand that required that traffic from and to each LAN port and the WLAN interface has to be filtered.

FOSS.in 2009

Submitted by Kedar Sovani
on December 5, 2009 - 1:57pm

FOSS.in 2009, Dec 1-6
{long read}

I just attended FOSS.in. I presented a talk there on Fedora-ARM

Here are few of my impressions...

ubuntu is useless for servers

Submitted by mator
on December 1, 2009 - 8:25am

Going to describe this entry a bit later, but in short "ubuntu server edition can't be plain installed on a server via serial console connection, but with custom made iso/cdrom, which is not always an option".

1) https://bugs.launchpad.net/null/+bug/489215
don't discuss this entry here, better go to bug-report URL and put your thoughts there.

new language: programming that can speak to modern hardware easily

Submitted by olecom
on November 27, 2009 - 11:10am

Now i'm doing some kind of translator (to C), that can turn second to its functional equivalent -- first:

void handle_mcucsr(void) __attribute__((section(".init3"))) __attribute__((naked));
void handle_mcucsr(void)
{
    mcucsr = MCUCSR;
    MCUCSR = 0;
}

handle_mcucsr: sect[ion] .init3, naked!
	mcucsr = MCUCSR
	MCUCSR = 0