Questions tagged [number-representation]

Questions about interpretation of numeric input or how Mathematica stores and manipulates numbers internally.

29 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
8 votes
0 answers
238 views

How would one add Hyperreals as a new type to Mathematica?

Hyperreals are an extension to the real numbers; they formalise the concepts of infinities and infinitestimals as numbers, rather than the named limit points outside of the system of reals and form ...
Julian Moore's user avatar
  • 2,560
5 votes
0 answers
307 views

NMinimize seems to call function with the same values multiple times

I have to minimize a function where the evaluation of one parameter set takes very long (around 5sec) and discovered alongside, that NMinimize seems to call this ...
Frederik Ziebell's user avatar
4 votes
0 answers
49 views

Why does an integer index inside a symbol become real when entering a ChebyshevT function with floating point arithmetic?

When I enter an indexed symbol into a ChebyshevT function with integer arithmetic like this: ChebyshevT[1, 3 * a[4]] I get the expected result: ...
Danel's user avatar
  • 173
4 votes
0 answers
130 views

How does Mathematica evaluate N[π, 30] == π?

I want to know how N[π, 30] == π works. The result is True. I wonder whether the exact number ...
FRANCESCO's user avatar
4 votes
0 answers
186 views

RealDigits and functional style

So while thinking about Replacing numbers of which you only know certain digits I have faced, again, a problem that I find hard to extract from RealDigits' output ...
Kuba's user avatar
  • 137k
3 votes
0 answers
146 views

Check the data of representations of Lie groups

Is there a way in Mathematica to check the data of representation of Lie groups? For example, the number of generators. the rank (or the dimension) of the representation matrices. and a list of all ...
wonderich's user avatar
  • 913
3 votes
0 answers
173 views

Rationalize error

The docs state that "Rationalize[x,dx] yields the rational number with smallest denominator that lies within dx of x." However, testing this out it appears to be false. ...
sn6uv's user avatar
  • 565
2 votes
0 answers
94 views

On numbers with N digits after comma in Mathematica

Consider a table tabb={{1.233546576,2.454546565},{22334.46687875465,6787233.3565665655}} I want to convert it into a table where all the numbers are only with 4 ...
John Taylor's user avatar
  • 5,407
2 votes
0 answers
97 views

PaddedForm - DigitBlock only respected for non-padding

I'm trying to pad some binary and hexadecimal numbers using PaddedForm, and also to separate the digits into blocks of 4. For example, I'd like a number like ...
Sean's user avatar
  • 645
2 votes
0 answers
52 views

Question to developers: what are the actual or potential difficulties in implementing split-complex unity $j$ out of the box?

I wonder, what are some real or potential and purely theoretic difficulties you may face if you decided to implement the split-complex unity $j$ such that $j^2=1$ along with already existing complex ...
Anixx's user avatar
  • 3,575
1 vote
0 answers
73 views

Extracting digits of a real number with RealDigits produces unexpected result

I have a list of real numbers, each of which has two decimal places. I'm trying to extract the second digit after the decimal point. The function I'm using is ...
user45937's user avatar
  • 1,291
1 vote
0 answers
113 views

Implementing the Binary GCD algorithm in Mathematica

Well, I have $n\in\mathbb{N}$ and I want to transform $n$ to a binary number which can be done using FromDigits[IntegerDigits[n, 2]]. I want to compute the ...
Jan Eerland's user avatar
  • 1,941
1 vote
0 answers
111 views

How to Shape Text?

Imagine I have a certain number 23819657294172004194219023914217958273128471531429470113 If I convert it to a string with ...
sam wolfe's user avatar
  • 4,553
1 vote
0 answers
70 views

How does this FromDigit module work?

I am entering the following input: ...
titanium's user avatar
  • 181
1 vote
0 answers
45 views

Why does this reduce evaluate with exact numbers but not numbers specified to 20/50/200 decimals of precision?

Consider the following lines of code: ...
user106860's user avatar
1 vote
0 answers
1k views

How to work with large numbers

How do I browse very large numbers in mathematica, say $10^{{10}^{{10}^{1.414\ldots}}}$? By browse I mean finding the $k$th decimal place before or after the decimal point. Everything I have tried ...
user85798's user avatar
0 votes
0 answers
54 views

Combining numbers with fractional powers together

I get lots of numerical answers that have integers raised to fractional powers multiplying each other. A simple example: 2^(1/3) 3^(2/3) which is of course 18^(1/3). How do I get Mathematica to do ...
1729taxi's user avatar
  • 767
0 votes
0 answers
84 views

When there is decimal number in N[], how can ensure digits more than machine precision?

We know that N[3/7,100] will keep 100 digits after decimal point. But N[3.1/7,100] will Keep only machine precision fewer ...
Y. zeng's user avatar
  • 537
0 votes
0 answers
51 views

Alternative for PowerRepresentations[n, x, 1]

I am looking for numbers $n$ that can be written as the sum of other numbers. So: PowersRepresentations[n, x, 1]. But is there a faster way of finding these numbers?...
Jan Eerland's user avatar
  • 1,941
0 votes
0 answers
105 views

How to copy and paste numbers with "`" mark and use them in calculations, without using N or setting precision every time

Suppose we have run a calculation and get a number like 2.758952615889003` If we then copy-paste this number and do a calculation like ...
user106860's user avatar
0 votes
0 answers
69 views

Correct way to format numbers

I have defined the following function: randvec[mag_]:= mag Normalize[Table[RandomReal[], {j, 1, 4}]] I would like to format the numbers in the list so that they ...
Sid's user avatar
  • 977
0 votes
0 answers
46 views

How to control the visible area (up and down the line) in NumberLinePlot?

How can you control the up and down line visible part of the graph? The target if view arrosw and text below the line (purple arrow) and if it´s posible make great the upper area ...
Mika Ike's user avatar
  • 3,241
0 votes
0 answers
47 views

Arrange the output by 3-adic valuation

I have a number that has the form $x=\sum_{k=1}^n c_k3^{q_k}$, where $q_k\in\mathbb{Q}$ and $0\neq c_k$ is in $\mathbb{Z}$ or $i\mathbb{Z}$. We may define the $3$-adic valuation of $c_k3^{q_k}$ as $...
Yijun Yuan's user avatar
0 votes
0 answers
104 views

Handling underflows

I am trying to implement an algorithm described for example in this paper, Section III, or referenced here, from where numerical parameters have been taken. I added the snippet I use to compute the ...
Smerdjakov's user avatar
0 votes
0 answers
96 views

Return the precision of the first non zero digit in a number for measurement error representation function

I'd like to return the precision of the first non zero digit in a number. The motivation is so that I can quickly construct my error notation which is the bracketed notation, e.g. $x = 1.234$ with ...
user27119's user avatar
  • 2,490
0 votes
0 answers
136 views

Solving a system of linear equations in Mathematica regarding the errors of different methods

I have a system of equations, i.e. 0.62243x + 0.51824y = 0.70524 0.71497x + 0.59496y = 0.80996 I have 3 ways to solve this system (there are more but I am ...
Alex's user avatar
  • 55
0 votes
0 answers
75 views

Decimal representation in Mathematica 10

I am using a slider to assign the value for a dynamic variable x, and want to display the value of y=10^Dynamic@x in decimal ...
Sven's user avatar
  • 101
0 votes
0 answers
112 views

Maintaining working precision in my program

I am badly stuck with this program I am writing. I want output of program below to be precise up to 25 digits after decimal point. I am supplying all inputs with precision 25. But after each iteration ...
Amey Deshpande's user avatar
0 votes
0 answers
167 views

How to parse fraction to a number?

Considering a fraction: val = "F \!\(\*FractionBox[\(1\), \(1\)]\)"; I extract the part of interest: ...
SuTron's user avatar
  • 1,708