Subject: bug#16706: emacs 24.3.1; calc/A command

From: Bart Nielsen <[email-masked]>
Date: Mon, 10 Feb 2014 06:15:07 -0500

calc - single variable statistics tells me:

   Another commonly used mean, the RMS (root-mean-square), can be
computed for a vector of numbers simply by using the `A' command.

So:

I believe the RMS value for the vector [21 23 25 25] is 23.5584379788.  (RMS means ‘the root, of the mean, of the square — so 

<ret>
vM*
uM
Q

(returns that value)

A returns
47.1168759576

q1:  How do I figure out what A is doing?

q2: Isn’t this wrong?

Thanks

=====
Here’s the standard form for an error report: (the above just seemed cleaner. Maybe not.)
23.5584379788  

his bug report will be sent to the Bug-GNU-Emacs mailing list
and the GNU bug tracker at debbugs.gnu.org.  Please check that
the From: line contains a valid email address.  After a delay of up
to one day, you should receive an acknowledgment at that address.

Please write in English if possible, as the Emacs maintainers
usually do not have translators for other languages.

Please describe exactly what actions triggered the bug, and
the precise symptoms of the bug.  If you can, give a recipe
starting from `emacs -Q':

M-x calc
'[ 21 23 25 25 ]
<ret>
vM*
uM
Q

'[21 23 25 25 ]
A

leaves
2:  23.5584379788
1:  47.1168759576

on the stack.  Shouldn't A return 23.5584379788?

If Emacs crashed, and you have the Emacs process in the gdb debugger,
please include the output from the following gdb commands:
    `bt full' and `xbacktrace'.
For information about debugging Emacs, please read the file
/usr/local/Cellar/emacs/24.3/share/emacs/24.3/etc/DEBUG.

In GNU Emacs 24.3.1 (x86_64-apple-darwin13.0.0)
 of 2014-01-24 on bmac.home
Configured using:
 `configure '--prefix=/usr/local/Cellar/emacs/24.3' '--without-dbus'
 '--enable-locallisppath=/usr/local/share/emacs/site-lisp'
 '--infodir=/usr/local/Cellar/emacs/24.3/share/info/emacs'
 '--without-gnutls' '--without-x' 'CC=clang''

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Info

Minor modes in effect:
  display-time-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  buffer-read-only: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
" H SPC DEL DEL DEL DEL DEL DEL SPC - SPC C a l c SPC
V e c t o r SPC M e d i a n " C-e C-@ - - - SPC s o
r t SPC DEL , SPC a v e r g DEL a g e SPC t h e SPC
m i d d l e DEL DEL DEL l DEL d l e C-n C-n C-n C-n
C-n C-n C-n C-n C-n C-p C-@ - SPC a r i t h m e t i
c SPC m e a n ESC O A ESC O A ESC O A ESC O A ESC O
A ESC O A ESC O A C-x o ESC x c a l c RET ' 2 1 * 2
1 SPC + SPC 2 3 * 2 3 SPC + SPC 2 5 * 2 5 * 2 C-a (
s DEL DEL s q r t ( ( C-e ) / 4 ) RET C-y A C-h a C-g
C-h k A C-x o C-x o a A DEL C-x o C-x o SPC - - - SPC
n o , SPC i t ' DEL SPC o u g h t SPC t o SPC b e SPC
2 3 . 5 5 8 4 C-x o C-x o C-x o C-h C-g ' Y DEL C-y
C-a C-d C-d C-d C-d C-e RET RET v M * u + S U C-h k
S C-g C-x o C-x o ' s q r t ( C-g 4 / L 2 / E C-x o
C-x o C-x o C-x o C-s A ESC x r e p o r t SPC e m a
c s SPC b SPC RET

Recent messages:
Working...
Map: (Press ? for help):
Working... [3 times]
Undo!

Quit
Auto-saving...done
Quit
Working... [4 times]
Mark saved where search started

Load-path shadows:
/usr/local/share/emacs/site-lisp/gnuplot hides /usr/local/share/emacs/site-lisp/gnuplot-2012-11-04/gnuplot
/usr/local/share/emacs/site-lisp/gnuplot-gui hides /usr/local/share/emacs/site-lisp/gnuplot-2012-11-04/gnuplot-gui

Features:
(shadow sort gnus-util mail-extr emacsbug message format-spec rfc822 mml
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev
gmm-utils mailheader sendmail regexp-opt rfc2047 rfc2045 ietf-drums
mm-util mail-prsvr mail-utils help-fns help-mode apropos calc-forms
calc-frac calc-mode calc-math calc-arith calc-units calc-misc jka-compr
info tool-bar calc-undo calc-map calc-stat calccomp calc-alg calc-vec
calc-aent calc-menu easymenu calc-yank calc-ext calc calc-loaddefs
calc-macs misearch multi-isearch time-date edmacro kmacro time image
ediff-hook vc-hooks lisp-float-type tabulated-list newcomment lisp-mode
register page menu-bar rfn-eshadow timer jit-lock font-lock syntax
facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese
tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak
czech european ethiopic indian cyrillic chinese case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces
cus-face macroexp files text-properties overlay sha1 md5 base64 format
env code-pages mule custom widget hashtable-print-readable backquote
make-network-process multi-tty emacs)