Tuesday, October 28, 2008

Objective-J is a seriously interesting language

I'm working my way through the Objective-J tutorials at the moment. OJ is absolutely brilliant. It has simply(!) transposed the Objective-C syntax into Javascript. And the result is stunning. In-browser apps which look and feel like Mac OS X apps. All the years of OC accumulated knowledge and the ubiquity of JS in every browser. Glad I spent some time learning OC. I thought it was wasted with my chances of getting work programming in OC being close to zero. But with the incredible popularity of the iPhone and the iTouch and now with OJ, OC(-like) programming is going to hit the charts with a bullet.

And I've already got a great (but big!) app I can develop in OJ.

A music OCR/OMR chip?

What if one were to program a SEAForth 40C18 with just the recogniser routines of Audiveris? There's some quite heavy lifting in Audiveris which could easily take advantage of the 40 cores in the chip. I've never met a 100 lines of Java that couldn't be reduced to one line in Perl. I wonder if one could get a similar reduction in Forth. I haven't looked inside Audiveris yet but I bet most of the 100,000 lines of code are the GUI and the object interfaces. Algorithms tend to be compact, for a couple of reasons: big ones are difficult to understand hence humans don't think them up; and big algorithms are slow; the fewer lines of code, the faster it runs. Anyway, now that I've received my 40C18 I will have to find something to do with it when I've got past the Hello World tutorials.

Monday, October 27, 2008

Lowering one's expenses on public transport

I was quite stunned to see a guy come through the electronic ticket barrier at my local station this morning and hand his ticket to another guy waiting there who immediately went back through the barrier to catch a train. Weekly tickets here in Sydney allow unlimited journeys through the rail system within the zone for the ticket.

I don't know how these guys linked up but I could easily see it happening via Facebook or whatever. If you could arrange your starting and stopping times at work or wherever you could share the cost of a weekly ticket amongst a crowd of people, all of it legal (well probably not within the T&C for the ticket but how are you going to check?). No doubt the rail management hate it but how are they going to stop this happening?

I wonder if there is already an online 'ticket pooling' service, like car-pooling but you share your weekly/monthly/yearly ticket. Let the computer work out how to allocate people to a ticket. It would require incredible discipline but if you are struggling for every dollar, you need such discipline to survive. (I remember the luxury when I first started to earn a pay-packet of deliberately not budgeting when I went supermarket shopping. Being from a single-parent family and not rich, my job each Wednesday night was to scan the newspaper for specials at the various supermarkets at the local shopping mall. I then worked out the shopping lists for each store and my mother, sister and I shared the shopping load. It halved our food expenses but it was very time consuming.)

Monday, October 20, 2008

Learning not to be paranoid

I worked out why colleague was so cool towards me when I started a new project. I thought he just didn't like me. But no, it's not about me. Turns out he was in the midst of job-hunting. He found the new job and is leaving this week.

I've seen this behaviour so many times in my working career but my basic paranoia always makes me think it's personal. It almost never is. Usually it's job-hunting, sometimes it's a sick or dying relative, once it was gambling.

The best time was when I was the IT manager for a company and I was fighting with the CFO who kept blaming me for the financial state of the company. (An independent auditor had blamed the GM and CFO and exonerated me.) But he decided to make me redundant (a 'nice' way of firing me) anyway. I went above his head and asked the GM to intervene but he acted as though it wasn't his problem. Once again my paranoia told me it was about me. But as I was walking to the exit on my last day there, the GM walked out with me. He'd been fired by his boss. The bastard CFO got away clean.

Sunday, October 19, 2008

A possible UBM

Better get this idea down before it gets lost in the haze. Louis Savain's UBM looks like the way computing is heading. IntellaSys' SEAForth chip looks very much like what Savain says a parallel processing CPU (MIMD) ought to look like. Are the processing elements of COSA implementable in 64 words of RAM and 64 words of ROM?

The problem is that the devel tools for the SEAForth are primitive. There's no way a non-specialist is going to write parallel programs for the SEAForth using circuit emulators and Forth. So the task, if I care to take it, is to implement a graphical COSA devel environ which targets the SEAForth. Or hosts the IDE itself? Is that feasible?

Tuesday, October 7, 2008

My continuing Forth education

To answer the question I asked in a previous post, the Perl source code is at least 10MB, on top of how many gigabytes are taken up by the OS.

A Forth interpreter could be as small as 8k. Even full-blown development versions are only a couple of hundred kilobytes. Hence Forth can go anywhere there is a CPU and some memory. One can even buy CPUs with the instruction set being Forth. So think pervasive and lots of bang per byte. Employing the principal of "learn once, use everywhere" (hence I use bash, Vim and Perl), Forth looks like a more useful tool to learn than say VHDL or Verilog for FPGAs.

And I like the look of the new SEAForth 40C18 chip: 40 CPUs(with RAM and ROM) on a chip, all with in-built Forth interpreter. $21 in quantity. Could be quite interesting.

Thoughts and feelings and House.

Was watching an episode of 'House' where House is accused of trying to biopsy a patient's spinal cord for his own benefit and not that of the patient. The whole premise of the House series is that House is constantly required to be completely objective despite his own life and that of his colleagues being in tatters.

It got me thinking about the nature of objectivity and human motivation. I remember John Macmurray's definition of objectivity being to act in terms of the thing or person one is considering. For example to act according to what someone needs, not in terms of one's own desires. An objective but tired parent will get out of bed at 3am to feed a crying baby even though every nerve and fibre wants to return to sleep. I also remember Macmurray pointing out in the light of Freud's discoveries about the unconscious, how impossible it is to know one's own motives. Aside from the simple fact that everything we do and think is the result of a whole spectrum of motivations, Macmurray pointed out that the motive(s) we are aware at any time are only the surface and almost certainly will not be the primary motivations. And I remember Macmurray's conclusion that to be a person is to be aware that every positive motivation contains within it it's own negative.

Hence the interesting House episode where we are never sure what House's motive is for seeking the biopsy. And in the end even House is not sure. But he still acts objectively. (I used to wonder why it is so hard to depict good people in drama but there obviously is no such thing as a 'good person', only people with more or less positive motivations. I'm sure there is some would-be PhD mapping out his/her thesis on 'The Christ-image in House M.D.' or whatever.)

What also triggered these thoughts was that yesterday afternoon I was walking home and a young couple passed by, hand in hand. How lovely! I thought. Then I overheard their conversation and realised both were mentally retarded or delayed learners or subnormal intelligence or whatever euphemism or politically correct term is used these days. And I then thought how difficult their lives together would be simply because of lack of understanding of how the world functions and their part in it. How would they/did they discover sex? Would anyone tell them or would they watch some awful X-rated video and get totally misled about what it's all about (speaking from experience here folks!). How would they manage a household budget?

Then I got to thinking, reminding myself that people do not need high intelligence to live well if their motivations are life seeking, not destructive. And how do people acquire life seeking motivations? The same way we acquire logical thoughts: we learn to do it. But we live in a society that is only just starting to discover that life affirming emotions are learnable and desirable. We actually live in an emotionally retarded society, intellectual giants but emotional retards.

And how do we learn life affirming emotions/motivations? Well to be honest I'm not sure. ('Emotional retards' includes me.) I do know that learning to trust one's own feelings is absolutely critical (just as being able to trust one's own thoughts is necessary for mature thinking). I also know that educating the senses is important. Seeking new experiences, discovering new tastes, hearing new sounds, seeing new colours and shapes. And so is feeling new feelings, meeting new people, loving intensely, crying in sadness and crying for joy, trusting even though frightened.

The aim of such education is to become aligned with one's life-affirming motivations and to learn to moderate one's destructive motivations. If one learns to habitually act affirmatively then we don't need to spend as much brain power trying to think our way out of dangerous, awkward, messy, unhappy situations and get on with enjoying the wonders of life on this beautiful planet. And we can still love life even if we don't think as fast or as clearly as we used to. Ultimately we can learn to feel objectively just as well as we can think objectively.

My conclusion though seems as wimpy as a wedding sermon. It just becomes more and more obvious to me that love is the only life-affirming motivation worth the effort of learning and teaching. All our other motivations are in the end self-seeking, albeit dressed up in the nicest terms. Only love acts in the interests of that which is not ourselves. Only love is truly objective.