GNU bug report logs - #35608
26.2; Calc temperature conversions

Previous Next

Package: emacs;

Reported by: "Harris, Bill" <wsharris <at> snopud.com>

Date: Mon, 6 May 2019 20:10:01 UTC

Severity: minor

Tags: notabug

Found in version 26.2

Done: npostavs <at> gmail.com

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 35608 in the body.
You can then email your comments to 35608 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#35608; Package emacs. (Mon, 06 May 2019 20:10:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Harris, Bill" <wsharris <at> snopud.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 06 May 2019 20:10:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "Harris, Bill" <wsharris <at> snopud.com>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: 26.2; Calc temperature conversions
Date: Mon, 6 May 2019 19:33:28 +0000
[Message part 1 (text/plain, inline)]
I started Emacs from Cygwin with

$ /cygdrive/c/emacs/emacs-26.2-x86_64/bin/runemacs.exe  -Q

I typed C-x * * to start Calc.

I entered '10 degC' and then

u c degF

I got 18, not the expected 50.

From *Calc Trail*:

Emacs Calculator Trail
alg' 10 * degC
cvun 18. * degF



In GNU Emacs 26.2 (build 1, x86_64-w64-mingw32)
of 2019-04-13 built on CIRROCUMULUS
Repository revision: fd1b34bfba8f3f6298df47c8e10b61530426f749
Windowing system distributor 'Microsoft Corp.', version 10.0.17134
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Defining kbd macro...
C-x *  (Type ? for a list of Calc options)
Welcome to the GNU Emacs Calculator!  Press '?' or 'h' for help, 'q' to quit
Working...
Building units table...done
Quit [4 times]
Configured using:
'configure --without-dbus --host=x86_64-w64-mingw32
--without-compress-install 'CFLAGS=-O2 -static -g3''

Configured features:
XPM JPEG TIFF GIF PNG RSVG SOUND NOTIFY ACL GNUTLS LIBXML2 ZLIB
TOOLKIT_SCROLL_BARS THREADS LCMS2

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: cp1252

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
 menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny seq byte-opt gv
bytecomp byte-compile cconv cl-loaddefs cl-lib dired dired-loaddefs
format-spec rfc822 mml mml-sec password-cache epa derived epg epg-config
gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils calc-units calccomp calc-arith
calc-misc calc-alg calc-ext calc-aent calc-menu easymenu calc
calc-loaddefs calc-macs kmacro elec-pair time-date mule-util tooltip
eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel
dos-w32 ls-lisp disp-table term/w32-win w32-win w32-vars term/common-win
tool-bar dnd fontset image regexp-opt fringe tabulated-list replace
newcomment text-mode elisp-mode lisp-mode prog-mode register page
menu-bar rfn-eshadow isearch timer select scroll-bar mouse jit-lock
font-lock syntax facemenu font-core term/tty-colors frame cl-generic
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray minibuffer
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote threads w32notify w32
lcms2 multi-tty make-network-process emacs)

Memory information:
((conses 16 134957 10618)
(symbols 48 23863 1)
(miscs 40 39 130)
(strings 32 37413 1399)
(string-bytes 1 950048)
(vectors 16 16436)
(vector-slots 8 524751 12824)
(floats 8 52 211)
(intervals 56 275 3)
(buffers 992 13))
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#35608; Package emacs. (Mon, 06 May 2019 21:20:02 GMT) Full text and rfc822 format available.

Message #8 received at 35608 <at> debbugs.gnu.org (full text, mbox):

From: Mauro Aranda <maurooaranda <at> gmail.com>
To: "Harris, Bill" <wsharris <at> snopud.com>
Cc: 35608 <at> debbugs.gnu.org
Subject: Re: bug#35608: 26.2; Calc temperature conversions
Date: Mon, 6 May 2019 18:19:26 -0300
[Message part 1 (text/plain, inline)]
tags 35608 notabug
quit

"Harris, Bill" <wsharris <at> snopud.com> writes:

> I entered '10 degC' and then
> u c degF
> I got 18, not the expected 50.

Hello.

That's because ‘u c’ treats temperature units as relative, and not as
absolute.  The result you got means that a change of 10 degrees Celsius
equals to a change of 18 degrees Fahrenheit.

You need to use ‘u t’ (calc-convert-temperature) to convert an absolute
temperature from one scale to another.  With that command, you'll get
the expected 50 degF.

Best regards,
Mauro.

>
[Message part 2 (text/html, inline)]

Added tag(s) notabug. Request was from Mauro Aranda <maurooaranda <at> gmail.com> to control <at> debbugs.gnu.org. (Mon, 06 May 2019 21:20:04 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#35608; Package emacs. (Mon, 06 May 2019 21:28:01 GMT) Full text and rfc822 format available.

Message #13 received at 35608 <at> debbugs.gnu.org (full text, mbox):

From: "Harris, Bill" <wsharris <at> snopud.com>
To: Mauro Aranda <maurooaranda <at> gmail.com>
Cc: "35608 <at> debbugs.gnu.org" <35608 <at> debbugs.gnu.org>
Subject: RE: bug#35608: 26.2; Calc temperature conversions
Date: Mon, 6 May 2019 21:27:21 +0000
[Message part 1 (text/plain, inline)]
Thank you, Mauro.  I thought it gave absolute temperatures in previous versions (26.1, for example), but I just checked on version 25.1, and it, too, does as you say.

Bill

From: Mauro Aranda <maurooaranda <at> gmail.com>
Sent: Monday, May 6, 2019 2:19 PM
To: Harris, Bill <wsharris <at> snopud.com>
Cc: 35608 <at> debbugs.gnu.org
Subject: Re: bug#35608: 26.2; Calc temperature conversions

CAUTION: THIS EMAIL IS FROM AN EXTERNAL SENDER.
Do not click on links or open attachments if the sender is unknown or the email is suspect.
________________________________
tags 35608 notabug
quit

"Harris, Bill" <wsharris <at> snopud.com<mailto:wsharris <at> snopud.com>> writes:

> I entered '10 degC' and then
> u c degF
> I got 18, not the expected 50.

Hello.

That's because ‘u c’ treats temperature units as relative, and not as
absolute.  The result you got means that a change of 10 degrees Celsius
equals to a change of 18 degrees Fahrenheit.

You need to use ‘u t’ (calc-convert-temperature) to convert an absolute
temperature from one scale to another.  With that command, you'll get
the expected 50 degF.

Best regards,
Mauro.
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#35608; Package emacs. (Mon, 13 May 2019 14:51:01 GMT) Full text and rfc822 format available.

Message #16 received at 35608 <at> debbugs.gnu.org (full text, mbox):

From: npostavs <at> gmail.com
To: "Harris\, Bill" <wsharris <at> snopud.com>
Cc: Mauro Aranda <maurooaranda <at> gmail.com>,
 "35608 <at> debbugs.gnu.org" <35608 <at> debbugs.gnu.org>
Subject: Re: bug#35608: 26.2; Calc temperature conversions
Date: Mon, 13 May 2019 10:50:01 -0400
close 35608
quit

"Harris, Bill" <wsharris <at> snopud.com> writes:

> Thank you, Mauro.  I thought it gave absolute temperatures in previous
> versions (26.1, for example), but I just checked on version 25.1, and
> it, too, does as you say.

Right, see also (info "(calc) Basic Operations on Units") or
<https://www.gnu.org/software/emacs/manual/html_node/calc/Basic-Operations-on-Units.html>,
which has exactly this example conversion:

       The ‘u c’ command treats temperature units (like ‘degC’ and ‘K’) as
    relative temperatures.  For example, ‘u c’ converts ‘10 degC’ to ‘18
    degF’: A change of 10 degrees Celsius corresponds to a change of 18
    degrees Fahrenheit.  To convert absolute temperatures, you can use the
    ‘u t’ (‘calc-convert-temperature’) command.  The value on the stack must
    be a simple units expression with units of temperature only.  This
    command would convert ‘10 degC’ to ‘50 degF’, the equivalent temperature
    on the Fahrenheit scale.





bug closed, send any further explanations to 35608 <at> debbugs.gnu.org and "Harris, Bill" <wsharris <at> snopud.com> Request was from npostavs <at> gmail.com to control <at> debbugs.gnu.org. (Mon, 13 May 2019 14:51:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#35608; Package emacs. (Mon, 13 May 2019 14:53:01 GMT) Full text and rfc822 format available.

Message #21 received at 35608 <at> debbugs.gnu.org (full text, mbox):

From: "Harris, Bill" <wsharris <at> snopud.com>
To: "npostavs <at> gmail.com" <npostavs <at> gmail.com>
Cc: Mauro Aranda <maurooaranda <at> gmail.com>,
 "35608 <at> debbugs.gnu.org" <35608 <at> debbugs.gnu.org>
Subject: RE: bug#35608: 26.2; Calc temperature conversions
Date: Mon, 13 May 2019 14:52:15 +0000
RTM, as they say.  Thanks!

-----Original Message-----
From: npostavs <at> gmail.com <npostavs <at> gmail.com> 
Sent: Monday, May 13, 2019 7:50 AM
To: Harris, Bill <wsharris <at> snopud.com>
Cc: Mauro Aranda <maurooaranda <at> gmail.com>; 35608 <at> debbugs.gnu.org
Subject: Re: bug#35608: 26.2; Calc temperature conversions

CAUTION: THIS EMAIL IS FROM AN EXTERNAL SENDER.
Do not click on links or open attachments if the sender is unknown or the email is suspect.
________________________________

close 35608
quit

"Harris, Bill" <wsharris <at> snopud.com> writes:

> Thank you, Mauro.  I thought it gave absolute temperatures in previous 
> versions (26.1, for example), but I just checked on version 25.1, and 
> it, too, does as you say.

Right, see also (info "(calc) Basic Operations on Units") or <https://www.gnu.org/software/emacs/manual/html_node/calc/Basic-Operations-on-Units.html>,
which has exactly this example conversion:

       The 'u c' command treats temperature units (like 'degC' and 'K') as
    relative temperatures.  For example, 'u c' converts '10 degC' to '18
    degF': A change of 10 degrees Celsius corresponds to a change of 18
    degrees Fahrenheit.  To convert absolute temperatures, you can use the
    'u t' ('calc-convert-temperature') command.  The value on the stack must
    be a simple units expression with units of temperature only.  This
    command would convert '10 degC' to '50 degF', the equivalent temperature
    on the Fahrenheit scale.





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 11 Jun 2019 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 319 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.