The following warnings occurred:
Warning [2] Undefined array key 108815 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108816 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108819 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108821 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108852 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108857 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108881 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108940 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108970 - Line: 275 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 275 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $thread - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $fid - Line: 295 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 295 errorHandler->error_callback
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108816 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108821 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108852 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined array key 108970 - Line: 331 - File: inc/plugins/threaded_mode.php PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php 331 errorHandler->error_callback
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 332 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 304 ThreadedMode::buildtree
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $theme - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Trying to access array offset on value of type null - Line: 3 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 3 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Undefined variable $lang - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks
Warning [2] Attempt to read property "messages_in_thread" on null - Line: 5 - File: inc/plugins/threaded_mode.php(305) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/inc/class_error.php 153 errorHandler->error
/inc/plugins/threaded_mode.php(305) : eval()'d code 5 errorHandler->error_callback
/inc/plugins/threaded_mode.php 305 eval
/inc/plugins/threaded_mode.php 23 ThreadedMode::showthread_threaded
/inc/class_plugins.php 142 threaded_mode_showthread_threaded
/showthread.php 918 pluginSystem->run_hooks





Difference between Voyager and HP-48G



#2

Guys,
I've recently got back into HP calculators after owning an HP-41 for over 20 years. Since then I've acquired a few off ebay, but have a question concerning a percentage calculation, for example, on the HP-41 and 48G:

Example calculation:

100 Enter 15 % +

produces and answer of 115 on the HP-41 and Voyager models, but an error on the 48G as the 100 seems to be removed from the stack after the percentage calculation. Can anyone explain why this is different and if there is some kind of 'trick' in performing this on the 48G without entering 100 twice.

Thanks, James.


#3

Hi James.

The 42S (Pioneer) operates as you say on the Voyagers.

I'd say the different behaviour of the 48G is related to its being an RPL model rather than a "pure" RPN...

But I'd expect some deeper suggestions from more knowledgeable forum people :)

Just my two cents.

Best regards.

Giancarlo

#4

Quote:
(..) as the 100 seems to be removed from the stack after the percentage calculation.
True, it does. The 48G %-operator needs (and consumes) two arguments and leaves just one result.

Quote:
Can anyone explain why this is different
Not me, sorry.

Quote:
and if there is some kind of 'trick' in performing this on the 48G without entering 100 twice.

100
Enter
Enter
15
%
+
but I bet you have guessed this yourself as well

(o well, it does enter the 100 twice, but at least you don't have to type it twice)

Edited: 22 Feb 2007, 7:32 a.m.


#5

For the older calculators it's for convienient as you already know. For the 48, it's for consitency.

#6

Quote:
Can anyone explain why this is different

I'm pretty sure it's down to RPL being designed to be as "pure" and orthogonal as possible. The % operator is designed to consume two levels of the stack and return its result in one, just like all other binary operators. Leaving a copy of an original value behind might be convenient, but it's not mathematically kosher - a function can't return two values.

To my mind, the 41C, like all the other RPN calcs, is an arithmetic tool. The 48 and the other RPL calcs are mathematical tools, which is what makes them awkward for those back-of-envelope calculations.

Best,

--- Les

[http://www.lesbell.com.au]

#7

Quote:
Can anyone explain why this is different...

The behaviour of ENTER WRT stack lift differs between RPN
and RPL calculators. On RPN machines, ENTER terminates
digit entry and duplicates X into Y. If the very next thing
you do is press a digit key, the value in X is overwritten.
However if the very next thing you do is invoke a function
that consumes the value in X, the stack will drop, leaving
your original value in X.

The RPL calculators terminate digit entry when ENTER is
pressed and copy the content of the input buffer into X (AKA
level 1). If the next thing you do is press a digit, the value
in the input buffer is overwritten. If however you invoke a
function that consumes the level 1 value, the stack will drop
leaving whatever was in level 2 in level 1.

I believe that the % function consumes the level 1 value on
both architectures.

HTH

Cameron

Edit: no sooner had I posted than I realised that % must consume
two stack levels. Which renders my explanation irrelevant. What
I describe above explains why 100 ENTER sqrt + produces 110 on
an 11C and an error on a 48 (if both start with an empty stack).
Unfortunately that's not what we were discussing here.

Sorry for the noise. <red face>


Edited: 22 Feb 2007, 7:34 p.m.


#8

I guess this means that

with RPN the display and register X are the same, and while inputting a number we're affecting both; pressing Enter pushes the number down 1 position to Y (keeping the value in X); as a side effect, we have two copies of the input number.

with RPL, the display is not the same as register X, it's kind a level higher so, when we're inputting a number, we are not affecting register X, but only the input buffer; pressing Enter pushes the number again down 1 position to X (clearing the input buffer).

Right?

-- Antonio

Edited: 23 Feb 2007, 2:44 a.m.


#9

Quoting Bill Wickes:

Quote:
The fundamental definition of the HP 48 operation ENTER is:

Take the text in the command line, check it for correct syntax, then treat it as a program and execute the objects defined there.


With RPL, when you're typing in source code (for a number, other object, series of objects, whatever), you're inputting it to an "editor" (command line, equation writer, matrix writer, etc.), which could be considered a "buffer"; it has no effect on the stack until an ENTER operation is invoked. In the case of the command line editor in particular, when you press ENTER, ordinarily the source code is parsed and checked for syntax errors, and assuming no errors, all objects from the command line are combined into a compiled "secondary" (SysRPL program) which is placed on the stack and executed, and when finished, the display is updated.

In "immediate entry" mode (neither PRG nor ALG displayed in the status area), pressing an immediate entry key effectively appends the key object to the command line and then invokes an "implicit ENTER".

In the case of just a data class object such as a number, the effect of pressing ENTER is to put the object (or actually, a pointer to the object in temporary memory) on stack level 1 (moving anything already on the stack up one level), and then update the display.

But suppose that you open the command line with RightShift ENTRY (over the ALPHA key) to invoke PRM entry mode, then type in 1 2 +, and then press ENTER. In this case the number 3 is placed on the stack before the display is updated.

Or if you type 1 2 into the command line and then press + (which invokes an implicit ENTER), 3 is also placed on the stack.

Or if you already have 1 on the stack, then type in 2 and then press +, the 1 is replaced by a 3 before the display is updated.

In general, the command line could be considered source code for a program to be executed immediately.

Note that when in the standard stack display (no command line or other "special environment" active), pressing the ENTER key doesn't invoke the ENTER operation; it invokes a DUP command instead.

For more details, see section 4.3 (pages 83-90) of HP 48 Insights Part I: Principles and Programming HP48G/GX Edition, available on the current MoHPC CD-ROM set / DVD-ROM.

Regards,
James

Edited: 23 Feb 2007, 10:20 p.m.


#10

Thanks, James

bill


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP Prime Collect/Factor difference bluesun08 3 1,445 10-29-2013, 09:36 AM
Last Post: Eddie W. Shore
  Voyager keyboard issue John Richards 2 1,440 09-27-2013, 07:43 PM
Last Post: John Richards
  Concern about Voyager keyboard test Matt Agajanian 2 1,402 08-30-2013, 07:56 PM
Last Post: Matt Agajanian
  wp34s Emulator (-Infinity Difference) Barry Mead 1 1,156 07-24-2013, 03:52 PM
Last Post: pascal_meheut
  Riemann's Zeta Function update (HP-28S, HP-48G/GX/G+, HP-49G/G+/50g) Gerson W. Barbosa 0 1,047 06-30-2013, 01:01 AM
Last Post: Gerson W. Barbosa
  OT: DIFFERENTIAL EQUATIONS using the HP-48G/GX Ivan Rancati 2 1,358 06-04-2013, 04:11 AM
Last Post: Frank Boehm (Germany)
  Voyager Self Test Mike (Stgt) 5 1,913 05-16-2013, 03:28 PM
Last Post: Mike (Stgt)
  Voyager reproduction logos ? John Robinson 2 1,349 02-25-2013, 05:19 PM
Last Post: John Robinson
  Able to set HP 48G axis tick marks at integers? Randal B 1 1,035 01-24-2013, 12:40 AM
Last Post: Chris Dreher
  HP 48G -- entering more than one equation into the PLOT application Randal B 1 1,039 01-24-2013, 12:25 AM
Last Post: Chris Dreher

Forum Jump: