Integer Complexity: Exploring an Interesting Notion

In summary, the concept of complexity for a given number involves finding the minimum number of 1's needed in an arithmetic expression using only addition, multiplication, subtraction, and division to represent that number. This concept has been around since the 1950s and has been studied extensively. The complexity of a number can be found by counting the number of 1's in the expression. It has been shown that the complexity of a number is proportional to its logarithm and there are some interesting inequalities related to this concept. However, it is also possible to express all numbers with a finite set of square roots and logarithms, making the complexity function bounded.
  • #1
SSequence
555
95
Not a question as such, but an interesting notion that I came upon (maybe some other people would find it interesting too). It seems to have been introduced in 1950's and seems a good amount of work has been done on it.
For example:
12=(1+1+1)*(1+1+1+1)
So the complexity of 12 is 7 since it can be represented by a minimum of seven 1's in an arithmetic expression (that only uses 1's). Similarly:
6=(1+1+1)*(1+1)
So the complexity of 6 is 5 since it can be represented by a minimum of five 1's in an arithmetic expression (that only uses 1's).

============================

I don't know how well this notion is known. I guess it would depend on interest/knowledge of specific area (e.g. someone with interest/knowledge of combinatorics would have more likely heard of it).
 
  • Like
Likes r731 and Delta2
Mathematics news on Phys.org
  • #2
Isn't this just the sum of the prime factors of each number?
 
  • Like
Likes Delta2
  • #3
Drakkith said:
Isn't this just the sum of the prime factors of each number?
The sum of the prime factors of ##2^{82,589,933}-1## is ##2^{82,589,933}-1##, but its complexity is at most ##2*82,589,933+1## or ##165,179,867##.
I suppose OP could have given more illuminative examples, though 😁
 
  • Love
Likes Delta2
  • #4
What exactly is allowed in the arithmetic expression? Addition and multiplication obviously, I guess subtraction and division as well. Something else?
There is some complexity in choosing that expression on its own.

If you allow all common mathematical symbols then numbers have a bounded complexity, because it's possible to express all of them with a suitably long combination of square roots and similar things using a fixed set of "1".
 
  • #5
suremarc said:
The sum of the prime factors of ##2^{82,589,933}-1## is ##2^{82,589,933}-1##, but its complexity is at most ##2*82,589,933+1## or ##165,179,867##.
I suppose OP could have given more illuminative examples, though 😁
Is this the largest known prime number of the form ##2^n-1##?
 
  • Like
Likes suremarc
  • #6
mfb said:
What exactly is allowed in the arithmetic expression? Addition and multiplication obviously, I guess subtraction and division as well. Something else?
There is some complexity in choosing that expression on its own.
As I have been able to understood the definition, valid arithmetic expressions with the following five alphabet (base symbols):
{ ( , ) , *, +,1 }

So for a given number ##n \in \mathbb{N}^+##, we would write all the expressions which evaluate to the value ##n## and count the number of ##1##'s in each of those expressions. There will be one or more expressions containing the smallest number of ##1##'s. That would be the (integer) complexity of ##n##.

==============================

Good point w.r.t. minus and division. I am wondering how much things would change with allowing minus and division.

mfb said:
If you allow all common mathematical symbols then numbers have a bounded complexity, because it's possible to express all of them with a suitably long combination of square roots and similar things using a fixed set of "1".
I didn't understand this. Any example?

===============================

With regards, to more non-trivial examples, here are few I found in a paper (in the introduction part). I am just copying the examples (and assuming these are expressions with minimal number of 1's):
## 75025 = (1 + 2^2)(1 + 2^2)(1 + 2(1 + 2^2)(1 + 2^2)(2^2.3(1 + 2^2)))##

complexity=1+4+1+4+1+2+5+5+7+1+4=35

and:
##2^{27}−1 = 134217727 = (1 + 2·3)(1 + 2^3·3^2)(1 + 2^9·3^3(1 + 2·3^2))##

complexity=1+5+1+6+6+1+18+9+1+2+6=56
 
Last edited:
  • Like
Likes Delta2
  • #7
Upon inspection, it felt to me as if the lowest possible complexity should be proportional to ##\log n##. I assumed the best possible case was ##2^n## with a complexity of 2n. Actually, this has been solved according to the Wikipedia article, which gives upper and lower bounds that are proportional to ##\log n##. Turns out the lower bound is ##3n\log_3(2)\approx 1.89n##, which is just shy of ##2n##. Neat stuff.

Delta2 said:
Is this the largest known prime number of the form ##2^n-1##?
Affirmative.

mfb said:
If you allow all common mathematical symbols then numbers have a bounded complexity, because it's possible to express all of them with a suitably long combination of square roots and similar things using a fixed set of "1".
After thinking about it, I don’t know if this is true. Addition, subtraction, multiplication, addition, and exponentiation are all binary operations, so you can only express a finite amount of numbers using them. And the square root can be applied only a finite amount of times if the codomain is restricted to the integers, so I think adjoining a square root would not change this.
If the complexity were bounded, there would have to be some ##k## for which there are infinitely many numbers with complexity ##k##.
 
  • #8
SSequence said:
I didn't understand this. Any example?
If I would have rememberd the exact method I would have posted it. Anyway, I found it again:

$$n = \frac{-2}{\ln(4)} \ln\left( \frac{\sqrt{\sqrt{\dots\sqrt{4}}}}{ln(4)} \right)$$
where you need n square roots and 2 and 4 can be expressed with 1s in the trivial way. This is coming from the challenge to express natural numbers with 4 "4", you can probably convert this to use 2 instead of 4 to reduce the number of "1"s. Anyway, it's a finite set if square roots and logarithms are allowed.

@suremarc: There are more common mathematical symbols and no one required the expression to operate purely in the integers.

I don't understand why the author chose such a confusing notation for 75025.
75025 = 5*5*(1+2*2*2*3*5*5*5).
Writing 5 as 1+22 does nothing to make things simpler and writing identical factors in different places isn't going to help either.
 
  • Like
Likes suremarc
  • #9
For the sake of reference, here is the paper I copied the examples from: https://arxiv.org/abs/1404.1850
(the examples can be found at the beginning of second page)
 
  • Like
Likes Delta2
  • #10
So the domain and co-domain of the complexity function ##C## is the set of positive integers and (among other properties) it satisfies
1) ##C(1) = 1##
2) ##C(x + y) \le C(x) + C(y)##
3) ##C(xy) \le C(x) + C(y)##

Does it satisfy any interesting inequalities of the form ##C(x) \ge## ...? or ##C(x+y) \ge##...? or ##C(xy) \ge##...?
 
  • #11
https://oeis.org/A005245

There is the trivial ##C(x) \geq 3 floor(\log_3(x))## with equality for powers of 3.

I don't have a tool to explore this numerically, but I could imagine that C(xy)>C(x) is not always true. Good candidates would be x=(3n+1)/2 and y=2 (with n>4).
Edit: C(1486)=22, C(743)=22
743 is a prime, instead of multiplying it by 2 we write 1486 as 1485+1 and 1485 = 33*(1+2*33) has a nice composition.
This is the only counterexample up to 1600 that I found looking for a factor 2.

Edit: How could I forget that.
C(x)=min(C(z)+C(y)|z+y=x ##\lor## z*y=x)
 
Last edited:
  • Like
Likes suremarc
  • #12
mfb said:
Edit: How could I forget that.
C(x)=min(C(z)+C(y)|z+y=x ∨ z*y=x)
I wrote this down too, but don’t know how to get anything useful out of it.
 
  • #13
It's a fast method to calculate C(x) for all x from 1 to N.
 

1. What is integer complexity?

Integer complexity is a mathematical concept that measures the minimum number of steps required to represent an integer using basic mathematical operations, such as addition, subtraction, multiplication, and division.

2. How is integer complexity calculated?

Integer complexity is calculated by finding the shortest sequence of basic mathematical operations that can be used to represent a given integer. This sequence is known as the integer's "complexity." For example, the integer 12 has a complexity of 4 because it can be represented as (1+1+1+1)+(1+1+1+1)+(1+1+1+1)+(1+1+1+1).

3. What is the significance of integer complexity?

Integer complexity is a useful tool in understanding the complexity of mathematical operations and in analyzing the efficiency of algorithms. It also has applications in cryptography and coding theory.

4. Can integer complexity be calculated for all integers?

Yes, integer complexity can be calculated for all integers. However, as the integers get larger, the complexity also increases, making it more difficult to calculate.

5. How is integer complexity related to prime numbers?

There is a correlation between integer complexity and prime numbers. Generally, prime numbers have a higher complexity compared to non-prime numbers. This is because prime numbers can only be represented as themselves, while non-prime numbers can be broken down into smaller factors.

Similar threads

Replies
3
Views
1K
Replies
4
Views
426
Replies
11
Views
2K
Replies
1
Views
747
Replies
6
Views
1K
Replies
1
Views
947
  • Precalculus Mathematics Homework Help
Replies
5
Views
798
  • Linear and Abstract Algebra
Replies
1
Views
767
Replies
1
Views
2K
Back
Top