HP Forums
tri-graphs - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: General Forum (/forum-4.html)
+--- Thread: tri-graphs (/thread-4575.html)



tri-graphs - tigger - 08-25-2015 05:16 PM

Where can I find trigraphs?
What are trigraphs?

I am not too familiar to this page...


RE: tri-graphs - Joe Horn - 08-25-2015 06:12 PM

(08-25-2015 05:16 PM)tigger Wrote:  Where can I find trigraphs?
What are trigraphs?

I am not too familiar to this page...

Short answer: Look up "translation codes" in your calculator's manual. It's all there.

Long answer: When sending programs to/from an HP 48, 49, and 50 in ASCII mode, they encode unusual characters (such as the angle symbol) as "trigraphs" which consist of a backslash character \ followed by two ordinary characters. The trigraph for the angle character is \<) because <) looks sorta kinda like the angle character. The trigraph for infinity is \oo. And so on.

This translation happens when the "TIO" (Translate I/O) mode is at its default. The extent of translation can be changed by adjusting the TIO setting in the IO settings on your calculator.

The complete TIO table can be found here: http://holyjoe.net/hp/tiotable.htm

Since most museum members are familiar with these trigraphs, you'll often see RPL characters and commands spelled with them in postings here. For example, you'll see RPL programs surrounded with \<< and \>>. When typing them into your calculator, mentally perform the "translation" from trigraph to the real character. Trigraphs are used because they are easier to type on ordinary computer keyboards.

By the way, despite the name, not all trigraphs are three characters long. The trigraph for a carriage return is "\010", and in general any character can be encoded as a backslash followed by its three-digit decimal code.


RE: tri-graphs - tigger - 08-26-2015 06:59 AM

I am so to say a Newcomer with this HP50g, though the calculator already is old.

What would you recommand to me? Is it better to begin with ti-Graphs? Would it help to understand programming in a better way? Still I am not at the Level of programming but more at the Level of understanding programs.

So far I have not programmed on my own.

Are the any program examples for the HP50g for beginners.

tigger


RE: tri-graphs - Joe Horn - 08-26-2015 12:03 PM

(08-26-2015 06:59 AM)tigger Wrote:  What would you recommand to me? Is it better to begin with ti-Graphs? Would it help to understand programming in a better way? Still I am not at the Level of programming but more at the Level of understanding programs.

Trigraphs are merely a way of representing unusual characters, not a style of programming. Whether you write
« 1 2 + » (using actual program quotes)
or
<< 1 2 + >> (using common shorthand)
or
\<< 1 2 + \>> (using trigraphs)
is a matter of personal preference. When you key the program into the actual machine, you will use the actual program quotes, not shorthand nor trigraphs.

(08-26-2015 06:59 AM)tigger Wrote:  Are the any program examples for the HP50g for beginners.

There are MANY excellent programming examples, complete with explanations, in the programming section of the Advanced User's Reference Manual, which every good programmer should have. It's freely available here: http://www.hpcalc.org/details.php?id=7141


RE: tri-graphs - rprosperi - 08-26-2015 01:32 PM

(08-26-2015 06:59 AM)tigger Wrote:  Are the any program examples for the HP50g for beginners.

Another excellent source of small but clever RPL programs can be found here, the collection of "One Minute Marvels"