Questions tagged [efficiency]

Using as few resources (e.g. time, space) as possible while solving a problem. Use this tag if your question is specifically about resource usage, not for generic algorithm questions that happen to mention running times.

287 questions
31
votes
7 answers

Are algorithms (and efficiency in general) getting less important?

Since buying computation power is much affordable than in the past, are the knowledge of algorithms and being efficient getting less important? It's clear that you would want to avoid an infinite loop, so, not everything goes. But if you have better…
Quora Feans
  • 873
  • 1
  • 9
  • 14
4
votes
2 answers

Limiting memory usage while keeping score

For an assignment we are asked the following(simplified) : A function F(a) has a non-negative integer as a result. This result is reused in the function itself. Like this, and where the first a is given: new_a = (c1 * (previous_a or first_a) + c2)…
g_uint
  • 143
  • 4
2
votes
1 answer

Efficiently compute a complete set of representatives of cyclotomic cosets of $2$ modulo $2^n-1$

Let $n > 1$. For an integer $k$ with $0 \leq k \leq 2^n-2$ the cyclotomic class $C_k$ of $2$ modulo $2^n-1$ is the set given by $$C_k = \{k, k\cdot 2, k \cdot 2^2 , \ldots, k\cdot 2^{n-1} \pmod {2^n-1}\},$$ where the entries are reduced modulo…
user29915
  • 21
  • 1
1
vote
2 answers

Are their problems that we can not even approximate efficiently?

Most hard problems can either be solved efficiently in average time, or an approximation can be efficiently found. Are there any natural problems for which this is not the case? In particular, is there a natural problem that can not be solved in…
Christopher King
  • 778
  • 1
  • 5
  • 19
1
vote
3 answers

Faster computation of $ke^{-(x - h)^2}$

The question is quite simple; almost every computer language today provides the $\exp(x)$ function in their standard library to compute expressions like $ke^{-(x - h)^2}.$ However, I would like to know whether this function is the fastest way to…
0
votes
0 answers

Shortcut for multiple highly-redundant dot-products?

In statistical computing, we often have linear models that involve computing multiple vector dot products, but there's a high amount of redundancy in the operations when you break them down. As an example, let X be the following 12x3…