instruction stringlengths 35 29.1k |
|---|
Problem Statement: Given a directed graph and two vertices ‘u’ and ‘v’ in it, count all possible walks from ‘u’ to ‘v’ with exactly k edges on the walk.
My question is that, say we have a DAG (directed acyclic graph), can DFS be a solution to the problem? I understand that native DFS would fail for the original problem... |
You are given an array of n integers a0, a1, .. an and a positive integer k. Find and print the number of pairs (i,j) where i<j and i+j is evenly divisible by k (Which is i+j % k == 0). This problem has been taken from Hackerrank.
We need a solution in O(n) time.
An explanation is that we can do this by separating elem... |
looking for old tests of Language Theory, I see this exercise:
Give a PDA automata that recognize the language $L = \{w \in \{a,b\}^*,\ 2|w|_a=3|w|_b\}$
They propose this solution:
Can anyone help me to understand what strategy they used?
Sorry for my english, is not my native language.
Thanks.
|
Given integers $m,n$, I want to compute the maximum possible value of $\Phi(G)$, over all simple, connected, undirected, unweighted graphs $G$ with $n$ vertices and $m$ edges.
The objective function $\Phi$ is defined as follows. Let $v=(v_1,\dots,v_n)$ be the principal eigenvector (PEV) of the adjacency matrix for $G$... |
Please forgive me for asking a novice question, but I'm a beginner at algorithms and complexities, and it's sometimes hard to understand how the complexity for a specific algorithm has come about.
I was reading the DFS algorithm from Introduction to Algorithms by Cormen, and this was the algorithm:
G -> graph
G.... |
I've been researching the specifics of adding noise injection to my input layer to fight against overfitting. It seems as though most papers recommend a Gaussian noise vector with mean of 0 and a "small" variance, to be applied either additively or multiplicatively to the input layer. Is this the current convention f... |
Let $P$ be a boolean problem of size $n$, thus the complete solution search space tree is of size $2^n$. Applying simple tree search for the solution will have take $O(2^n)$ operations, (for simplicity let's assume we do not apply any cuts).
Let $M$ be an oracle machine able to solve a problem $P^\prime$ sub-problem of... |
Given a DFA (D1) with P1 states, that accepts a language L1.
Modify (D1) to create another DFA (D2), such that it will accept the language L2 that is defined as: All strings in L1 that are also a palindrome (of maximum length P1).
How many states would the minimized D2 have (worst case)? And time complexity?
Similarly... |
Atomic exchange instruction is given as follows:
void exchange (int *a, int *b)
{
int temp;
temp = *b;
*b = *a;
*a = temp;
}
Now consider the solution to critical section problem based on above instruction:
1 int const n = /* number of processes */;
2 int lock = 0;
3 void P(int i)
4 {
5 int ke... |
I'm learning about OBDD and I have learned that the size of a reduced OBDD (ROBDD) is dependent on the ordering of the variables, and that finding an optimal ordering is an NP hard problem.
Say I already have one ROBDD by some ordering, I can, in some cases, determine if it optimal:for example if each variable appear o... |
Problem: Consider a set of $n$ points in the plane, how could we find a strip of minimal vertical distance that contains all points?
Definitions: A strip is defined by two parallel lines and the vertical distance is defined as the distance between their intersection points with the $y$ axis.
3 variables solution: In th... |
I'm trying to see how Martin Lof Type Theory can be encoded in Monadic Second Order Logic over trees or graphs. Specifically, how can set levels (cumulative hierarchy) a la Russel or a la Tarski be represented in MSOL over trees/graphs? Namely, set of sets should be contained in universe Set_2, while sets of sets of se... |
One of my coworkers came up with a nice technique to solve a problem and I feel like it must already have a name. I just don't don't know how to figure out what it is.
It is a technique for caching easy answers for a subset of an input domain before falling back to an expensive computation. In that respect it reminds m... |
Lets take, for example this jpeg image here
The image there is 400 x 300, or 120000 pixels and The file size of the image (on my computer) is shown to be 65171 bytes.
This means the computer stores about 2 pixels in every byte. How does it do this? Is it due to the same color pixels repeating in the image, so it only ... |
For a graph $G(V,E)$, under what conditions is a minimum spanning tree of $G$ equal to a hamiltonian path on $G$?
IS there any body of literature connecting these two?
|
Question: Given a time series of stock prices, what is the maximum profit you can make if you are allowed to Buy and sell the stock twice. The second buy has to come after first sell.
Solution: There is a O(N) time and O(N) space complexity solution, that keeps track of the maximum profit that can be made when selli... |
Suppose we have unrestricted grammar but with restrictions on how rules are applied: we take first rule, search in string left to right and apply it as we go. If no match found, we proceed with second rule and so on. Else, if match(es) is found, we return to first rule and start of the string and start loop again.
I ha... |
In BFS, nodes are goal tested when they are generated.In other searches, nodes are goal tested before expanding them.what is the difference between this two statements? What is the advantage from this?
|
Definitions. Let $n$ be a natural number and $S$ be a subset of distinct natural numbers all less than $n$, and mutually co-prime. Then find the maximum sum the set $S$ can have.
Example. Let $n=10$, then the maximum sum $S$ can have is $30$ corresponding to $S=\{1,5,7,8,9\}$.
What I tried. I tried to implement the fol... |
By stack I mean the language of sequences it represents, say, a stack with data domains $N$ (natural number) is: $\{ \mbox{push(0)}, \mbox{push(1)}, \mbox{push(0).push(1)}, ..., \mbox{push(0).pop(0)}, ...\}$.
This language is not against Pump lemma of CFL, right ? But I read from some materials that this language is N... |
I'm looking for a specific variation of rank selection in genetic algorithms.
I came across a python program tailored for a specific problem that uses a variant of "rank" selection. In normal rank selection, all individuals are sorted by fitness (in descending order) so that worst chromosome gets a weight of 1 and the... |
I'm learning for my exam in theoretical computer science and I'm not sure about it, because I got different sources with different answers. So I wanted to ask here:
If I draw a NFA/DFA and I maybe don't need the transition from a state $z_k \rightarrow z_{k+1}$ with a $0$ above the alphabet $\Sigma = \{0,1\}^*$ so I... |
We have an array of $n$ positive integers $a_0,a_1\dots a_{n-1}$ and let $a_n=0$.
I need to build an array $b_0,b_1\dots b_{n-1}$ such that $b_i$ is the first integer larger than $i$ with $a_{b_i}\leq a_i$. (Note that there is no requirement that the $b_i$ be distinct.)
Does anybody know if this can be done in reason... |
Closures are functions that borrow the environment in which they are declared and can use and modify its variables at any times indipendently from where they're called, like in this example:
function createclosure(x)
return function() --Anonymous closure
print(x) --The variable x is caught and can be used a... |
In this video, a physics theorist talks with his collegues claiming to have found evidence for Simulation Theory. I'm not here to ask about the various proofs for and against ST - that's basically in the realm of philosophy at this point.
But one of the physicists claims that because of the nature of mathematics, it's ... |
I was reading a paper about the PageRank algorithm and it mentions $ 2 $ ways to compute the weighted score for each vertex: If $ M_{n \times n} $ is a positive column stochastic matrix that represents the transition state for each vertex in the graph, then we know that the sequence $ Mz, M^{2}z, \dots, M^{k}z $ conver... |
I want to design a branch predictor and then test it to see how efficient it is. The question is: how to test them? Are there data sets available?
|
My textbook has a brief explanation of how semiconductors are used in modern computer chips because they can be made to conduct (by applying enough voltage to excite electrons across the band gap) or to insulate (by dropping the voltage to a lower level or shutting it off entirely) and this conditional, binary state ca... |
In the Damas-Milner type system, type schemata can be formed in two ways:
$T$
$\forall X. S$
Where $T$ ranges over monotypes and $S$ ranges over type schemata. The type-checking algorithm for this system is well known, and explanations of it can be found in several places.
What happens if I add a third type schema fo... |
This question asks which programming languages have a syntax that cannot be described by deterministic context-free grammars - the answer is "Many [...] including Algol 60, C, and C++".
Until recently I thought Lua was an example of a language which could be described by a deterministic context-free grammar. This belie... |
Okay I am trying to understand the Heap's Algorithm from the original research paper published by B.R Heap.
The most confusing aspect I found that while Heap says that the example described on the first page takes N=12 ie. example with 12 objects to provide a permutations for them.
But yet he says that the 12 objects ... |
I'm using Grammatical Evolution for symbolic regression tasks (i.e. searching the space of mathematical expressions to find the model that best fits a given dataset).
I'm evolving solutions according to a user-specified grammar:
(0)
<expr> ::= <expr> <op> <expr> (0)
| <const> (1)
... |
Is it possible to have a single hash function output simultaneously verify a compressed block of data as well as its uncompressed counterpart?
Trivially one could just use a hash function twice (once on the uncompressed version and again on the compressed version) and concatenate the outputs, or use a hash function tha... |
In the context of information flow, when you talk about the property of variables being tainted, do you speak about "taintness" or "taintedness"? Both occur online, both sound weird to me.
An example from http://www-verimag.imag.fr/~potet/PUBLI/mdv10.pdf:
To achieve that, we propose to perform a taint dependency analy... |
Binary structures often feature length specifiers; the parser is supposed to read them and then consume the specified amount of symbols. Because of this, the grammar is context-sensitive.
What would a context-sensitve grammar for a simple binary format look like?
For example, let's consider a length-prefixed array with... |
The minimization of a given primitive recursive function $f$ is computed by the following expression:
$
\newcommand{\pr}[2]{\text{pr}^{#1}_{#2}}
\newcommand{\gpr}{\text{Pr}}
\newcommand{\sig}{\text{sgn}}
\text{Mn}[f] = \gpr[g, h] \circ (\pr{1}{1}, \pr{1}{1})
$
$g = \sig \circ f \circ (\pr{1}{1}, c^1_0)$
$h = \text{Cond... |
A "pumping" property (words of a certain length imply the existence of loops in the language-defining mechanism) are known to exist for regular and context-free languages and a few more (usually used to disprove a language's membership to a certain class).
Within the discussion around this question, Daisy's answer sugg... |
When the runtime of the GNFS is given as e^(64/9*b(log b)^2)^1/3,
what base is the log? I'm assuming its e, but other options would obviously be 10 and 2.
|
I’m developing a mutual information based classifier, the output of the classifier is {{0,4,5,6},{1,2,3},{7},{8},{9}} and the correct decision output is {{0,1,2,4,5,6,9},{3},{7,8}}. How to compute the accuracy of this classifier according to the concept of True positive, true negative, false positive and false negative... |
I suppose that counting n elements should be linear time, right? It takes double time to count double number of elements. But in the real world, it is faster and O(1) to weigh elements and find out the total weight so in the real world you can count n elements O(1) just by putting all the elements on a scale and dividi... |
From my understanding, the complexity of the algorithm is O(number of inputs * number of bits for input).
The number of bits in binary notation is obviously less than the number of bits in unary notation. Then why is it that for binary, complexity is exponential but for unary, it is polynomial?
EDIT: I think the binary... |
I am trying to train and implement a Neural Network. I was reading a few articles, learning about their principles and the math that goes behind them. However, while I was trying to understand the math, specifically the optimization part (for selecting weights), I ran into a problem: I couldn’t understand the Broyden–F... |
I have a rooted tree with $n$ vertices.
I want to be able to answer the given queries in logarithmic time after setting up some sort of data structure (preferably in time $n\log n$.
The query is given by $v$ and $k$.
I want to find the number of ancestors of $v$ of degree less than or equal to $k$.( I call ancestors of... |
Me and a friend have a opinion difference regarding a question that got asked in a previous IT test.
The short version:
2 units, n and m are connected in series but operate as one system. n has a MTBF of 200, m of 300. What is the MTBF of the entire system?
possible solutions:
200
250
300
500
I am convinced (as is t... |
Recently I have been studying the Ford-Fulkerson algorithm for determining max flow. I do not see why it is not allowed to have the source vertex be the same as the sink vertex. From what I have heard, doing this allows infinite flow. However if you take a graph where the source (which equals the sink) has no arcs lead... |
I need to do a maximum weight matching in bipartite graphs rather than maximum weight perfect matching (which means that there is no need to match all the nodes).
The nodes each side are both (at most) the level of 10^3 and are usually unbalanced in size. The graph is globally sparse while locally dense. (I don't know ... |
Title says it all. I just need to confirm that...
X.__add__(y) <==> x+y
...doesn't mean anything more than just 'same as'
The problem is Google returns zero results when you search for <==>
|
Define a triangle in undirected graph $G$ is balanced if the edge labels in the triangle are $(+1, +1, +1)$, $(-1, -1, +1)$, $(+1, -1, -1)$ or $(-1, +1, -1)$ (social balance theory).
Problem definition:
Given undirected graph $G=(V, E)$, initial edge label function $f: E \rightarrow \{+1, 0, -1\}$ and $k \in \mathbb{Z... |
I am relatively new to $\pi$-Caculus and have a doubt wrt sequential execution in In $\pi$-Calculus .
Does passing of common names over common channels shared between two Agents, represent a sequential execution ? so is the below reduction semantics correct if I have to represent a sequential execution between Agent A... |
I am wondering if some symbols such as the ones in propositional logic have precedence over others in drawing parse trees.
For example, the sentence: p ∧ q → r, would ∧ take precedence over → in becoming the root of the parse tree or vice versa?
Or is there no precedence meaning, → or ∧ could be used the root?
|
I am trying to follow this paper [1]. There is a relationship between Markov Random Fields (MRF) to max-flow-min-cut. An MRF can be represented as an undirected graph, and you can find flow through it, but what extra special properties do you get if you know the graph is Markovian? What is the point of putting these tw... |
Let $M_w$ be the DTM encoded by the binary string $w$ and let
$$L=\{w\#x\,|\,\text{all states are reached when running }M_w\text{ on }x\}.$$
I've already proved that this language is undecidable (the halting problem can be reduced to this), but is this language semi-decidable? I.e., is there an enumeration of $L$ or a ... |
This answer claims that $ LL \subseteq LR \left( 1 \right )$ where $LL = \bigcup_k LL(k)$.
But is this true? Is this grammar a valid counterexample?
$ S \rightarrow a | Aaa $, $ A \rightarrow \varepsilon $
It's easy to show that this grammar is not $LR \left( 1 \right )$, but I think that it is in $LL(2)$ - the longe... |
In an attempt to understand the efficiency of the GNFS, I've been looking at runtimes. The calculations seem to indicate the GNFS runs slower than exhaustive search for smallish n. For example: suppose I want to factor the number 247 (ie 13 * 19).
To do this I can just check all the numbers (exhaustive search) below ... |
The VC dimension is usually used in the following way. There is a space of hypotheses. There is an unknown probability distribution. We sample some training-samples from this distribution. We find the hypothesis that scores best on the training-samples. If the VC dimension is sufficiently small and the number of sample... |
I have some jobs, which calculate values. Some of these jobs require the calculated values of other jobs for their own calculation. An execution plan for these jobs can be found with a topological sort on the dependency graph.
However, these calculated values are huge and occupy a large chunk of memory. I want to find ... |
In Computational complexity: Modern Approach by Arora and Barak, it's mentioned that
We will require however that $S(n)> \log n$ since the work tape has length $n$, and we would like the machine to at least be able to remember the index of the cell of the input tape that is currently reading.
What does that exactly... |
NP can be characterized in two different ways, one of them is that it's the class of languages that can be certified by a witness in a polynomial time.
I wonder, if we consider the same notion but with space considerations to get a class $X$, Is such a class known to be of any importance? Why?
To be more precise, $L\... |
Refer to answer 1.1 of this file: http://www.dei.unipd.it/~geppo/AA/DOCS/NPC.pdf
From my understanding and this thread, https://math.stackexchange.com/a/928412, we need 3 steps for that proof.
The first case is trivial and true. Now we have assumed the same for i and going to prove that it is true for i+1. I'm unabl... |
So I am trying to figure out what kind of algorithm I would use if I wanted to implement the ISP with a predefined number of resources. Consider this example interval scheduling problem.
Say there are n requests for a lecture hall and three lecture halls are available to satisfy these requests. Each request has a star... |
I was studying a cs book for computer architecture(computer organization and design) and I found this exercise:
Program A runs on a processor with clock rate 1GHz in 10s. To improve the performance of the program we substitute each instruction(X*4) with 2 add instructions(X + X and then X + X). The CPI of multiplicati... |
CLRS Problem : 7.4
How does Tail-Recursive-QuickSort improve the efficiency of quick sort any better ?
Original quicksort
Tail recursive quicksort
Question
Modify the code for TAIL-RECURSIVE-QUICKSORT so that the worst-case stack depth is O(n log n). Maintain the O(n log n) expected running time of the algorithm... |
I would encode DFAs (Deterministic Finite State automata) as output (or input) of a neural network for a supervised learning; it is well-known [1] that efficacy of neural network training strongly depends on adopted encoding.
How can I encode DFAs for a neural network? Are there any literature works?
I've already fou... |
I am new to computer vision so please excuse me if this question is very simple.
I am trying to learn how to use the Haar Cascade creation tool provided with OpenCV to train a cascade classifier. It seems relatively easy, with the tools provided, but I was wondering if there was a way to improve the network after the ... |
When an algorithm is said to be subexponential - does this refer to the input N or the number of bits used to represent N? Consider the following: trial division for integer factorization (i.e. try all numbers less than $\sqrt N$) is subexponential in terms of N.
Note: here I'm using the definition of 'subexponentia... |
I recently read a paper about hyperuniform distributions, which mentioned that one way to generate a rectangle filled with hyperuniformly-distributed points is the following:
Choose a uniformly-random location in the rectangle.
If that location is not within distance $r$ of any previously-chosen point, add a new point... |
I recently attended my first lecture on structural induction and the professor stated that structural induction can be used to to prove that two programming languages are equivalent.
I am new to structural induction, however from what i have read so far, structural induction is used to prove properties $P$ like arithme... |
Regarding algorithms to find maximal independent set in an unweighted and undirected graph: I saw many articles online that are referring to the case of which every vertex has a maximal degree of d, and then you can find an independent set of size n/(d+1) (for each such vertex, add it to the independent set and remove ... |
This is my basic setup: I have five time slots (A, B, C, D, E; each day has these five time slots) over 60 days that all need to be filled with n people each (n must remain a variable). However, each person has a different availability (ex. ABDE, BCDE, AE, BCD, etc.). I want this to be distributed equally so all worker... |
I sketch an impractical, theoretical comparison sort.
Initialize a list of all $n!$ permutations of size $n$.
For each possible pair of indices $i, j$, count how many permutations would get rejected if we were to find out that $a_i < a_j$ or $a_i \nless a_j$ and choose the minimal of these two counts. Finally choose t... |
The exact questions states the following:
Suppose that a complete undirected graph $G = (V,E)$ with at least 3 vertices has cost function $c$ that satisfies the triangle inequality. Prove that $c(u,v) \geq 0$ for all $u,v \in V$.
I can intuitively see that $c(u,v)$ is always positive but I don't understand how to pre... |
When finding sources for certain definitions related to Petri nets, I found that there seem to be three ways of referring to "which tokens are located in each place":
Configuration (e.g. in Sequential Configuration Graph, also referred to as a reachability graph)
Marking (e.g. initial marking)
State (e.g. in State Spa... |
I understand that Dynamic Time Warping is an algorithm to find a matching between two signals with different length and speed
But is there a possible way to find the speed difference between the two signals being compared?
To clarify my question.
I am working on a project to find similarity between two motions.
The da... |
Let $A$ and $B$ be two one-dimensional, finite collections of unsigned integers (e.g. arrays). Furthermore, $card(A) = a < b = card(B)$. Both collections are sorted in ascending order. There is at least one item ${x}$ which is contained both in $A$ and $B$.
Question: what is the fastest algorithm to find the smallest ... |
Yesterday StackOverflow was down for half an hour. Later, they wrote a blog post about it, detailing that the problem stemmed from unexpectedly high complexity of regular expression matching.
In short, the regular expression a+b, when running on the string aaaaaaaaaaaaaac, runs in $O(n^2)$ time where $n$ is the number ... |
Time complexity seems rather a difficult notion for people who were not professionally trained in math or computer science. I understand it informally and can high-level compare which one is better and which one is worse (say: polynomial time algorithm is more efficient/faster than exponential time algorithm), but my q... |
Is a suitable way to prove that any given CFG generates (or not) any given language to draw its total language tree?
What if the tree is infinite? What would then be a better way to prove that a given CFG generates a given language?
|
I am a beginner in deep learning so bear with me. If I want to unfold the RNN in order to represent the relation of output to the input as a non-recursive functions I would have to know the number of time steps it takes for the RNN to make a prediction, correct? Hence it is important for me to know if the number of tim... |
There has been significant literature in solving the (Approximate) Nearest Neighbour Problem in the spherical setting in the $\mathbb{R}^n$ using Angular and Spherical LSH and other lattice sieving techniques. A proper definition of the problem is found in the image below. (The problem definition is borrowed from Fast... |
I am using a cooperative coevolutionary genetic algorithm, the algorithm is given in A cooperative coevolutionary approach to function optimization by DeJong et. al. (1994), for optimizing a 62 dimensional function. One difference being that I am minimizing instead of maximizing. I am also using roulette selection, how... |
Just as the title says: Does the fact that there exists a polynomial time quantum algorithm for integer factorization suggest that integer factorization is in P? Additionally, if one could show that a problem known to be in NP had a polynomial time quantum solution, would that be enough to show that P=NP?
|
Let's have two permutations $A$ and $B$ of $n$ numbers. What is the minimal number $m$ of transpositions to transform $A$ to B in the worst case? After analysing some algorithms my guess is that $m \sim n^2$ but I cannot find a formal proof.
|
I'm trying to understand the inapproximability of the minimum set cover problem.
The wikipedia page states that it is hard to approximate within a factor of $(1-o(1))\ln n$ and that $n$ refers to the size of the ground set. It references the work of Dinur and Steurer (2013) who state that, for every $\varepsilon>0$, it... |
Assume a simple procedural language, where statements write and read from local memory via references and procedures accept arguments of n different scalar types (say floats, ints and strings) and tuples (or records or other structured monomorphic data).
When I try to embed such a language in a type-safe host language ... |
Suppose We Applying Arc-Consistency (AC3) algorithms on one Constraint Satisfaction Problem, if domain of one variable be empty, what is the next step of this algorithm?
According to This Link and to Wikipedia's description of AC3: once one domain is empty, the algorithm stops, indicating there is no solution to the C... |
I faced a great doubt about the Complexity of two ways of calling a information.
First I have an Array, if I call an array in a program like this:
print array[0]
This process will be O(1) as I understand.
But what is the complexity of something like this:
class Obj:
value = 1
print Obj.value
Is this complexity is... |
Suppose I'm given $n$ points $x_1,\dots,x_n$ in some space $\mathcal{S}$ (think: $\mathbb{R}^d$), and probabilities $p_1,\dots,p_n$ that form a probability distribution (so $p_1 + \dots + p_n=1$). Imagine I have a source that outputs a point by choosing among the $n$ points according to the probability distribution $p... |
Papadimitriou's "Computational Complexity" states that VALIDITY, the problem of deciding whether a first-order logic (without arithmetic) formula is valid, is recursively enumerable. This follows from the completeness and soundness theorems, which equate VALIDITY and THEOREMHOOD, the latter being the problem of finding... |
I was referring to this page which defines fork, join and precedence graph as follows:
When the statement Fork(label) is executed by a thread of control, a second thread of control is started from the statement with the specified label. The two threads execute concurrently.
When the statement Join(count) is executed,... |
The intuitive informal description of two process Peterson's algorithm for process 0 can be given as follows:
flag[0]=true; //I am ready to enter my critical region
turn=1; //but you may take your turn to enter your critical section
while(flag[1]==true && turn==1) //if you ar... |
I am trying to analyse the time complexity of the fast exponentiation method,
which is given as
$$x^n=
\begin{cases}
x^\frac{n}{2}.x^\frac{n}{2} &\text{if n is even}\newline
x.x^{n-1} &\text{if n is odd} \newline
1 &\text{if n=0}
\end{cases}
$$
I tried to write it as,
$$
T(n)=\begin{cases}
T(\frac{n}{2}).T(\f... |
Question: You are given a set of events in a day. Each event has a start and end time. Find the maximum number of concurrent events
Solution:
First convert events into an array of "Event objects". Each object has a Time field and EventType(start/End) field. (O(N)
Min-heapify the array, with time as the key to o... |
Statistical closeness implies computational indistinguishability.
Is there any (simple) relationship between negligible function that is used in definition of statistical closeness and negligible function that is used in definition of computational indistinguishability?
Can we say anything about the negligible function... |
Is there a name for the following problem? Is there a measure of quality of a given solution? How can we even define what a proper solution is?
Context: I want to detect long lines (most lines over 1000 pixel long) in an image. It is known that most of the lines have similar alignment. To detect those I use the Standa... |
According to chess rules, the (undirected) graph generated from the Knight move on a keypad is the following:
$$
\begin{array}{ccccc}
3 & - & 4 & - & 9 \\
| & & | & & | \\
8 & & 0 & & 2 \\
| & & | & & | \\
1 & - & 6 & - & 7
\end{array}
$$
The question is:
Consider the uniform distribution on all $n+1$-sequences $(s_i)_... |
I'm working on an LLVM-like kit for .Net - because this is something that's lacking in .Net and I really want to learn the more advanced compilation theory.
I'm really struggling to find anything digestible for turning Phi into platform code (in this case MSIL). Consider the following SSA fragment:
inputs = a0
a1 = a0 ... |
A frequently cited definition of data type is that it is a set of values and a set of operations of those values.
I've never read any mention along the lines of a type must be capable of being identified, although the programming languages I've encountered use names to distinguish different types.
Is the use of identi... |
In ext4 file system, the files are spaced out as far apart as reasonably possible to allow for efficient reallocation. Why do we not do this in memory?
Why not allocate one memory as page 20, and the next large allocation as page 100 to allow for excess expansion before and after the current allocation? I feel that mak... |
Gödels motivation to prove his incompleteness theorems was the philosophical statement "This sentence is wrong.". Is there a philosophical counterpart to the statement P != NP? For example such statement might be "This Theorem is practically unprovable". The consequences of an existence of such theorem would be: If the... |
There is a lot in the literature about linear time constructions for suffix arrays; DC3, radixSA46, and more...
However, these, I believe, are only for suffix arrays; with a single string input.
Are there fast algorithms for generalised suffix arrays, which have multiple string inputs?
for example
strings = ["maps$", "... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.