- Community Home
- >
- Servers and Operating Systems
- >
- Operating System - OpenVMS
- >
- Converting string to floating number in DCL
-
- Forums
-
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
- HPE Blog, Austria, Germany & Switzerland
- Blog HPE, France
- HPE Blog, Italy
- HPE Blog, Japan
- HPE Blog, Middle East
- HPE Blog, Russia
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
-
Blogs
- Advancing Life & Work
- Advantage EX
- Alliances
- Around the Storage Block
- HPE Blog, Latin America
- HPE Blog, Middle East
- HPE Blog, Saudi Arabia
- HPE Blog, South Africa
- HPE Blog, UK & Ireland
- HPE Ezmeral: Uncut
- OEM Solutions
- Servers & Systems: The Right Compute
- Tech Insights
- The Cloud Experience Everywhere
-
Information
- Community
- Welcome
- Getting Started
- FAQ
- Ranking Overview
- Rules of Participation
- Tips and Tricks
- Resources
- Announcements
- Email us
- Feedback
- Information Libraries
- Integrated Systems
- Networking
- Servers
- Storage
- Other HPE Sites
- Support Center
- Aruba Airheads Community
- Enterprise.nxt
- HPE Dev Community
- Cloud28+ Community
- Marketplace
-
Forums
-
Blogs
-
Information
-
English
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
07-14-2020 01:58 PM - edited 07-14-2020 01:59 PM
07-14-2020 01:58 PM - edited 07-14-2020 01:59 PM
Converting string to floating number in DCL
Hi,
How can I convert this string to a floating number so I can do Mathematical operations?
"9.8441676E-01"
Thanks!
MT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
07-14-2020 02:15 PM
07-14-2020 02:15 PM
Re: Converting string to floating number in DCL
I don't think you'll have much luck with just DCL. You may want to look into also using this utility that looks like it is written with easy operability with DCL symbols in mind:
http://www.eight-cubed.com/downloads.html#math
MATH
A Bison based infix calculator supporting all the one argument double precision C math functions. The calculator allows you to output local or global DCL symbols, and reads string representations of floating point numbers from DCL symbols on the right hand side.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
07-14-2020 03:03 PM
07-14-2020 03:03 PM
Re: Converting string to floating number in DCL
> How can I convert this string to a floating number so I can do
> Mathematical operations?
DCL provides no floating-point support:
HELP INTEGER
What kinds of "Mathematical operations" on what? As usual, a more
detailed description of the actual problem which you are trying to solve
might be helpful.
Possibly interesting:
http://antinode.info/dec/sw/bc.html
But those programs don't support "Exx" notation.
One could, in principle, use basic string processing to convert
"9.8441676E-01" to "0.98441676", and proceed from there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
07-15-2020 05:40 AM
07-15-2020 05:40 AM
Re: Converting string to floating number in DCL
We have a calculator executable, "calx" on our VMS 6.2 VAX.
Calx Version 5.0d
Calx is an interactive programmable scientific calculator program useful
for solving typical problems in computer engineering. Calx features
independent input and output radices in binary, octal, decimal, hex, or any
radix of base 2 through 36, as well as ascii characters and convenient "k"
(1024) notation. It allows nesting of parentheses, performs implied
multiplication, and features alternate scientific or engineering notation
outputs. Users may store data in the 10 user-assignable memories or in the
26 user-definable symbols (whose names may be up to six characters long).
Many common calculation parameters can be preset and reset through the use
of an initialization file. For more thorough information about Calx, see
the Calx Users Guide, CALX$LIBRARY:CALX.DOC, which is both a primer and a
reference guide to Calx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
07-16-2020 12:12 AM
07-16-2020 12:12 AM
Re: Converting string to floating number in DCL
Can you give some information from where this calx program can be obtained?
Hewlett Packard Enterprise International
- Communities
- HPE Blogs and Forum
© Copyright 2021 Hewlett Packard Enterprise Development LP