Forth Application Techniques
Who & What
Elizabeth D. Rather, president of Forth, Inc., would appear to be the second Forth programmer in the universe. This distinction came about in 1971 when she was brought in at the Kitt Peak NRAO to maintain code written in a quirky language developed by Chuck Moore. Running on a DDP-116 and a H316, this code was responsible for controlling the telescope, data acquisition, and graphical display. After a few years, Moore and Rather, along with Edward K. Conklin, formed Forth, Inc. to attempt commercialization of the language.
Forth Application Techniques attempts to provide a comprehensive introduction to the language for the neophyte Forth programmer. I would say that it pretty much succeeds as such, quietly plodding away through each primitive and feature. It is written in workbook style with various sample problems for the reader to complete. You might not be a Forth coder after reading the book cover to cover; however, you will have a working knowledge of the language and should be able to walk through legacy code with a minimum of difficulty.
If I might step aside from my role as unbiased book observer for a moment, I would like to make a few comments about the state of programming languages in general. It seems that quite often we take for granted essential, but practically invisible, tradesmen such as plumbers and garbage collectors. (Fire your janitor and your web designer -- guess which one you will miss first. Guess which one will still be employable 15 years from now.) Yet, without their services, our daily quality of life would certainly fail to meet our expectations.
Likewise, Forth seems to be an invisible language. No flash, no e-commerce, and no glamour. Such is the nature of embedded systems -- even though every Federal Express delivery driver carries a Forth-based device on his belt. This appears to have resulted in a dearth of quality books dealing with Forth. Search your favorite online book retailer and note the dozens of Forth books that are no longer in print.
While Scheme is from the ivory tower and Forth might be said to be from the machine shop, they do have something in common that is a possible deterrent to the popularity of Forth. Like Scheme, you either get Forth -- or you don't. Stack-based languages leave some programmers dazed and confused. And, as with most languages, it is possible to write some truly obfuscated code. Any language that will allow you to define the number 4 as a word that places the number 3 on the stack can be a frightening weapon in the hands of the contrary.
KudosForth Application Techniques can be commended on its consistency. Careful attention has been given to typefaces to distinguish interpreter output from user input. All primitives and defined words are covered in a clear and unambiguous manner. The book is spiral bound in a plastic binding, and this lay-flat binding is great when using it at your computer or while eating lunch.
QuibblesThe same lay-flat spiral binding that is such a boon when working at the computer can be somewhat of a nuisance when when attempting to hand-hold the book -- the book tends to flop about and feels very insubstantial.
While Forth Application Techniques is very complete and accurate, it is also extremely passionless. You might compare it to a biology textbook discussion of sexual reproduction with no mention of romance. There is no discussion or examples of using Forth in ways that will bring enlightenment. To be fair, in the preface it states that the purpose of the book is to support Forth classes taught at Forth, Inc. This is something that is not entirely clear when examining online retailers' display of the book.
Also of note is that there are occasional features specific to Forth Inc.'s SwiftForth product documented in the book. I would not consider this a real issue as all instances are clearly denoted with an icon. With the exception of chapter 9, which is entirely Forth Inc. specific, the readability is not affected in any way.
CrimesForth Application Techniques has no index. With its workbook styling, most will not consider this to be a tragedy. All the same, it would be convenient to look up primitives and defined words.
ConclusionsShould you buy this book? That depends on your desired end result. It is adequate for a quick introduction to Forth. If you are intending to write production code I believe Forth Programmer's Handbook (from the same publisher, review forthcoming) would be a better choice. If possible, I would supplement either with a used copy of Leo Brodie's Starting Forth -- an out-of-print classic.
Where I foresee this book to be a great benefit is in ordering a half-dozen copies for your programming team prior to taking on a legacy project or when considering Forth as a new development platform. The members of your team that "get it" can then enlighten the others with this invisible language.
Table of Contents
- Preface: About This Book
- Introduction
- Simple Forth Primitives
- Structured Programming In Forth
- Data Storage
- Strings And Characters
- Number Conversion
- Vectored Execution
- Advanced Concepts
- Multitasking
- Style Recommendations
I received a review copy of this book from the publisher. Thus, my loyalties and opinions may be completely skewed. Caveat Lector.
Forth Application Techniques is available from Forth, Inc. and from some online merchants like Amazon. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.
If you have any questions for Elizabeth Rather, she can be found on Usenet. When I asked for an "introductory book for modern Forth" I believe she recommended her own book! :-)
Threaded Interpretive Languages (TILs) such as Forth have very elegant inner workings. I even wrote one as a kid. And I actually used it for a few months. Although my Forth-inspired TIL was limited to 16 bit integer math (on an 8086 I think it was), I still managed to get it to draw 3d wireframe graphics in real time on a PLUTO graphics card :-)
RB
Back in the days of yore, when the world was still mostly in black and white, and strange man-eating beasts wandered the land, a small British company brought out a cute little computer called the Jupiter Ace.
It was basically a Sinclair ZX-80, but with Forth in ROM, instead of BASIC. It was a fun little thing to play with.
I may still have mine in a box in the attic. Must go check.
668: Neighbour of the Beast
Apple uses a variant of OpenBoot called Open Firmware for all power macs released since the 7200/75. It, too, runs off of f-code.
Postscript is based on Forth. You can "program" Postscript...
Don't know why a non-printer driver person would want to, but you can...
-LG
Forth seems to keep hanging on. Here is a port to the Palm Tried figuring it out a full times, but it never stuck (pages, etc.) ...
Forth is still in heavy use, actually, as the language for Apple's Open Firmware (IEEE-1275) implementation:
:-)
http://developer.apple.com/hardware/pci/
Oh, huh? I was supposed to make a point? Whoops.
-/-
Mikey-San
Mikey-San
Karma: +Eleventy billion (mostly affected by watching Celebrity Jeopardy)
Trolling using another account since 2005.
OK, so things are sluggish at work.
A quick trawl came up with the following 'Nix based
emulator
Reginald Molehusband. Edinburgh, Scotland
Yep. Sun use Open Firmware, as do Apple Macs. Open Firmware (or IEEE-1275 - those wacky IEEE names) uses Forth. Even if the rest of the machine is hosed you'll still be able to use forth. Err - great :-/
Slashdot looked deep within my soul and assigned
me a number based on the order in which I joined
There's a nice FAQ and emulator on this site here
I just went through amazon.com web site and I regret that most (if not all) Forth books written by Leo Brodie are out of stock...
I remember waiting until 4 months to get a copy of "thinking forth", by the way.
Now, if you want to learn forth, there seem to be the gforth manual, at least...
Trolling using another account since 2005.
Some of Moore's trial runs for Forth ran on Burroughs mainframes and were actually implemented as card decks.
She now works with Forth, Inc. Check out forth.com. They have an excellent history of the language here. BTW, there are free Forth interpreters for just about every platform out there. It's a cool language.
Chuck Moore's own site is here
Alison
"It is a miracle that curiosity survives formal education." - Albert Einstein
If you want to fool around with FORTH
on your own and for free, take a look at
Phil Burk's
public domain pForth
Wait a minute. Didn't I say that on the other side of the record? I'd better check
Chuck Moore's home page:
http://www.colorforth.com
Leo Brodie's is one of the best books to learn Forth with. And the cartoons in it are the funniest/best in a manual that I have seen since the first Wizardry Manual!
ttyl
Farrell
CAN-CON 2019 - Ottawa's only book oriented Science Fiction Convention! October 18-20, Sheraton Hotel, Ottawa, Canada h
I used to work for a company that deals with real time equity market data web sites: all runs on a custom Forth back end and web application server. CNBC ran on Forth for a year. Fortune Investor, Citibank, American Expresss -- all ran on Forth. www.wallstreetcity.com -- still running on Forth. Reason