File:Binade.svg
From Wikimedia Commons, the free media repository
Jump to navigation
Jump to search
Size of this PNG preview of this SVG file: 218 × 59 pixels. Other resolutions: 320 × 87 pixels | 640 × 173 pixels | 1,024 × 277 pixels | 1,280 × 346 pixels | 2,560 × 693 pixels.
Original file (SVG file, nominally 218 × 59 pixels, file size: 18 KB)
File information
Structured data
Captions
Summary
[edit]DescriptionBinade.svg |
English: An axis with ticks marking the floating-point numbers between 0 and 1 with 3 bits of precision and a minimum exponent of -5, with the binade of exponent -2 highlighted |
Date | |
Source | Own work |
Author | Taylor Riastradh Campbell |
Source code
[edit]\documentclass{standalone}
\usepackage{tikz}
\usetikzlibrary{decorations.pathreplacing}
\newcommand{\emin}{-5}
\newcommand{\eminplusone}{-4}
\newcommand{\emax}{6}
\newcommand{\p}{3}
\newcommand{\fmax}{3} % 2^(\p - 1) - 1
\begin{document}
\begin{tikzpicture}[x=15em,y=2em]
% zero
\draw (0,0) -- (0,1.5ex) node[above] {$\mathstrut 0$};
% subnormal
\foreach \f in {1, ..., \fmax} {
\pgfmathsetmacro\x{(0 + \f/2^(\p - 1)) * 2^\emin}
\draw (\x,0) -- (\x,1ex);
}
% normal
\foreach \e in {\emin, ..., -1} {
\pgfmathsetmacro\x{(1 + 0/2^(\p - 1)) * 2^\e}
\draw (\x,0) -- (\x,1.5ex);
\foreach \f in {1, ..., \fmax} {
\pgfmathsetmacro\x{(1 + \f/2^(\p - 1)) * 2^\e}
\draw (\x,0) -- (\x,1ex);
}
}
% label tick at 1/2
\node[above] at (0.5,1.5ex) {$\mathstrut 1/2$};
% one
\draw (0.5,0) -- (0.5,1ex);
\draw (1,0) -- (1,1.5ex) node[above] {$\mathstrut 1$};
% axis
\draw[<->] (-0.0625,0) -- (1.1,0);
% highlight binade [2^{-2}, 2^{-1})
\draw[decorate, decoration={brace}, below=1ex, thick]
({(1 + \fmax/2^(\p - 1) + 1/2^(\p + 1))*2^(-2)}, 0)
-- ({(1 + 0/2^(\p - 1) - 1/2^(\p + 1))*2^(-2)}, 0)
node[pos=0.5, below=0.5ex] {$\mathstrut {+}1.xy \times 2^{-2}$};
\end{tikzpicture}
\end{document}
Licensing
[edit]I, the copyright holder of this work, hereby publish it under the following license:
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
- You are free:
- to share – to copy, distribute and transmit the work
- to remix – to adapt the work
- Under the following conditions:
- attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
- share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
File history
Click on a date/time to view the file as it appeared at that time.
Date/Time | Thumbnail | Dimensions | User | Comment | |
---|---|---|---|---|---|
current | 19:33, 24 October 2023 | 218 × 59 (18 KB) | Taylor Riastradh Campbell (talk | contribs) | Uploaded while editing "Binade" on en.wikipedia.org |
You cannot overwrite this file.
File usage on Commons
There are no pages that use this file.
File usage on other wikis
The following other wikis use this file:
- Usage on en.wikipedia.org
Metadata
This file contains additional information such as Exif metadata which may have been added by the digital camera, scanner, or software program used to create or digitize it. If the file has been modified from its original state, some details such as the timestamp may not fully reflect those of the original file. The timestamp is only as accurate as the clock in the camera, and it may be completely wrong.
Width | 174.123pt |
---|---|
Height | 47.311pt |
Structured data
Items portrayed in this file
depicts
some value
24 October 2023
image/svg+xml
c0e01b9dfed7eb89a82d5b35b501c6aa8c5f13d9
18,938 byte
59 pixel
218 pixel
Hidden categories: