instruction stringlengths 35 29.1k |
|---|
Assume that there are n students, who have to be evenly assigned to m groups. For every student, a preference ranking of of the m groups is given.
I partially order assignment by pointwise preference, i.e. one is better or equal to another if for every student, the assigned group is ranked higher or equal.
What algorit... |
I know that the decidable are close under: complementation, union, intersection and concatenation?
What about the undecidable languages? I think they are close under complementation, but not under concatenation, union and intersection. But I don't know how to prove it...
My prove
"Lets say L is undecidable lang. Becau... |
I have a space with obstacles I wish to find a path through. What I can do is discretize the space into a grid and use A* (or D* or whatever) to find a path through it. I wish to now add orientation to the algorithm. So the node location now becomes a 3d vector (x, y, phi). You can go from one node to another one only ... |
Does it make sense for a Turing machine to have infinite number of states ? I had previously asked a question Can Turing machines have infinite length input. From which I came to know about Type-2 Turing machines. If there can be infinite states, encoding of such a Turing machine would be infinite ( but again I am not ... |
What do I need to learn dense correspondence?
I am a newbie in Image processing/CV.
Please help me by suggesting a kind of syllabus or show me a way to learn about Dense Matching. What are the things I really need to work on it.
|
Is there a way to check LTL properties in a bounded model checker?
As an example, consider a liveness property ($G F p$ - always eventually $p$)? Suppose we have the following trivial program
#include <pthread.h>
int a = 0;
void * f(void * x)
{
a = 1;
return x;
}
int main()
{
pthread_t t;
pthread_create(&t, 0, ... |
I need to find out the fastest way to count nested loops. I am adding 3 numbers , the final number is wanted result. For better explanation here is example
read number 1
read number 2
read final number 3
There are 17 ways how to achieve 500 with those two numbers e.g
10*2 + 15*32
and so on , the code for th... |
I came across a new list data structure called GlueList that claims faster than classic list implementations.
How does it work ?
How can it be faster than ArrayList and LinkedList ?
|
Hi, what should be the regular expression for this language ? My guess was
r = (a
∗
a(a + b)
∗
(a + b) + (a
∗
b + c))(a + b
∗
)
∗
But the arrow from C to B is making it tough . If it was B to C then my answer would have bee correct.
|
In the data structure field, what is the (best) term used to identify (designate) a subtree covering a subset of contiguous leaves?
|
Since planar TSP with n nodes is NP-hard, we cannot simply find an optimal solution with n-1 nodes and then insert the remaining node at one of the solution's edges to find the optimal solution of the original TSP problem. So, is there a planar graph with an optimal solution, such that when we add a certain extra node,... |
I'm making a compiler using LLVM and LLVM's shadow-stack. I thought I might easy the load of the GC by using escape analysis and allocate some variables on the stack. Can I use my typed AST for this algorithm, or must I use a graph data-structure?
|
I understand type systems like the simply typed lambda calculus, system F and the calculus of constructions include a different subset of all lambda terms. But what, precisely, are the terms each of those systems include/exclude? Is it possible to express the intuition behind the criteria with words?
|
I have Master theorem for finding complexities but the problem is Master theorem says
For a recurrence of form
$T(n) = aT(n/b) + f(n)$ where $a \geq 1$ and $b > 1$,
there are following three cases:
if $f(n) = Θ(n^c)$ where $c < \log_ba$, then $T(n) = Θ(n\log_ba)$;
if $f(n) = Θ(n^c)$ where $c = \log_ba$, then $T(n) = Θ... |
Algorithm must be in place.
I would like to find lower bound for comparison algorithm. Algorithm will sort array with only two elements - without loss of generality let assume that there are only $1s$ and $0s$.
Decision tree give us lower bound $\log(n+1)$. It is to weak, because we know lower bound for findiing min... |
I was reading about the halting problem recently, there is a video on youtube where it tries to explain the halting problem easily (since it is complicated to explain).
So, (A,C & H) have different inputs, if we suppose that we can run the three inputs on a machine (x) using one encoding scheme (i.e encoding for chess... |
I want to show that
$\qquad L = \{\langle M \rangle \mid \text{TM $M$ will write a $z$ to the tape at some point for some input}\}$
is undecidable.
I'm really not sure how to show this is undecidable. I know that a language is undecidable if M would not be able to determine if 'z' is or is not in the language.
|
I have a directed, colored graph (each node has a color), and I want to find if a path from node A to node B exists such that the path goes through each color at MOST once.
I think this problem can be formulated using network flow. Somehow a penalty can be placed on nodes of the same color that makes the flow 0 or infi... |
One of the interesting results of Number Theory is the theory of quadratic reciprocity. One finds that it is possible to determine whether an equation $x^2 \equiv a \pmod p$ has a solution $x$ without computing its solution.
Is it possible to do the same with the equation $x^2=a$, determine whether $a$ is a perfect squ... |
Wikipedia says
A model of computation is a formal description of a particular type of computational process. The description often takes the form
of an abstract machine that is meant to perform the task at
hand.
What other forms can a model of computation take than an abstract
machine?
What are the difference a... |
I started studying Design Concepts in Programming Languages by Turbak, Gifford and Sheldon. In the first chapter, they define a language called POSTFIX, similar to a postfix calculator's input language. This one also has a conditional command and a subroutine-like struct. So, it seemed like it could implement a looping... |
I'm ok following the passages generally used to prove this theorem, like in this question concerning the same subject. Anyway i've the unpleasant feeling that the proof lacks something to be completely understood, perhaps because considered obvious by many people.
We know that a binary tree corresponding to the optima... |
For a certain maximization problem, a "constant-factor approximation algorithm" is an algorithm that returns a solution with value at least $F\cdot \textrm{Max}$, where $F<1$ is some constant and $\textrm{Max}$ is the exact maximal value.
What term describes an algorithm in which the approximation factor is a function ... |
I am trying to figure out which language does the following NFA (taken from a Sipser's book "Introduction to theory of computation") recognise
From my understanding, this NFA accepts strings that contain at least two $1$s, but this is not precise, because, e.g., between the two ones we could have a $0$ or nothing ($\e... |
while userinput != "yard" or userinput != "gym" or userinput != "basement" or userinput != "cell" or userinput != "showers" or userinput != "outside":
print "Enter 'yard' or 'gym' or 'basement' or 'cell' or 'showers' or 'outside' to search them."
if userinput == "yard":
Rooms.yar... |
Hi I'm new to RBM and machine learning/computer vision in general, and I'm using the code from: http://blog.echen.me/2011/07/18/introduction-to-restricted-boltzmann-machines/ while reading on https://en.wikipedia.org/wiki/Restricted_Boltzmann_machine for some theories. But right now i'm totally confused. In the code th... |
the DFA-intersection computation problem, given two DFAs specified on the input, compute the intersection DFA, or the decision problem to determine its emptiness, turns out to have wider/ deeper significance in computational complexity theory.[1][2] it is O(n2) time with no better lower bounds known, and tight bounds p... |
I want to ask about Petri net (PN) boundedness. When I have a state s1 = (2 0 0), then I find state s2 = (2 0 1), so since s1 < s2 can I declare the net as not bounded ? Because when I have this PN:
the PN is bounded but you can find there (2 0 0) < (2 0 1).
Am I wrong about boundedness of Petri nets or is something w... |
In trying to understand the relationships between Huffman Coding, Arithmetic Coding, and Range Coding, I began to think of the shortcomings of Huffman coding to be related to the problem of fractional bit-packing.
That is, suppose you have 240 possible values for a symbol, and needed to encode this into bits, you would... |
I'm working on practice problems for a test I have, and every example of loop variant decreased with every iteration of the loop. On this one, the values remain the same when a < b. My attempts also got me a loop variant that has a chance of a negative since occasionally a becomes larger than b and vice versa. Any advi... |
Are there any techniques that can be used to determine whether a digital logic circuit is optimal, or if it has extraneous operations that don't contribute to the output?
I'm especially curious in the case where the circuit is defined in terms of XOR and AND gates.
I know I could make a karnaugh map and create a circui... |
I am from ECE background and trying to solve channel allocation problem. Let's assume I have three users and three available channels. I would like to allocate channel among them in such a way that average BER would be minimum.
For example, consider BER matrix for each user for each frequency allocation
\begin{bmatrix... |
My research is mainly focused on generating test sequences automatically using Colored Petri net.CFG provides techniques for generating test sequences. But some papers says that, test sequence generation methods based on a control flow graph sometimes suffers from a feasibility problem (i.e. some paths in a CFG may not... |
Given a subset of a cartesian product $I \times J$ of two finite sets, I wish to find a minimal cover of it by sets which are cartesian products themselves.
For example, given a product between $I=\{A,B,C\}$ and $J=\{1,2,3\}$, I may observe the subset $\{(A,2), (B,3), (B,2)\}$ and try to cover it with a minimal number ... |
I'm reading Types and Programming Languages and trying to understand the solution to exercise 5.2.4 on untyped lambda calculus / Church numerals:
Define a term for raising one number to the power of another.
The proposed solution says:
$\textrm{power2} = \lambda m. \lambda n. m~n$
In an attempt to understand how th... |
Assuming you have a balanced tree, without parent-pointers, with $n$ nodes, and a height $H = \mathcal O(\log n)$.
I know you can traverse the tree in level order in $\mathcal O(n)$ time using a queue. However, even in a balanced tree, the queue can grow to $\mathcal O(n)$ in size.
So the best I came up with is essenti... |
Let us consider the following scenario,
The cpu started executing a program, which is in secondary memory with n lines of code, so, it brings m ( < n ) lines of code in to main memory and started executing.
We can call the m lines of code, which are in main memory as process.
But my doubt is that, what about the remai... |
Set S is a set consisting of all string of one or more a or b such as "a, b, ab, ba, abb, bba..." and how to prove set S is a infinity set.
I have tried proving set S as one to one corresponding to natural number set in binary form. like a = 0, b = 1. However, I am stuck in proving it since there are more than one "1",... |
I'm only a layman therefore only discuss stuff naïvely.
I read some introductory articles about halting problems with a scenario that if there were such a decider accessible to us, we should be able to solve some unsolved mathematical problems. We could write some brute-force programs to check Goldbach conjecture, say,... |
If $NP=coNP$ does it hold that $P/Poly=PH/Poly$ and/or $NP\subseteq P/Poly$ and/or $VNP=VP$?
What can we legitimately say if $NP=coNP$?
|
If I modify a 3-COL problem (with colors A, B, C) in a way that I now demand that at most, say, 50 vertices may be colored with color A, does the problem still remain NP-complete?
I've been thinking of a reduction from a standard 3-COL, but there is no way that I can solve a standard 3-colorability using the problem de... |
Suppose we have a graph $G = (V, E, w:e\in E \to x \in \{0,1\})$. That is, a set of vertices, a set of edges and a weight function that assigns edges weights of 0 or 1.
Suppose we also have a subset of vertices $S \subset V$ and that we want to find a minimum-weight tree that spans the vertices in $S$. Since the vertic... |
The following is an excerpt from OS concepts by galvin.Here is the book.
Multithreading Models
Our discussion so far has treated threads in a generic sense. However,
support for threads may be provided either at the user level, for user
threads, or by the kernel, for kernel threads. User threads are
supported above th... |
Say I have the following grammar:
E -> TE'
E' -> +TE'| -TE' | λ
T -> (E) | id
I need to build the finite state machine with the LR(0) items,
But I know in order to do this I have to remove the λ.
How to I accomplish this ?
Also, after I have the SLR(1) table, how to I prove is valid ?
Thanks, I'm studying for a... |
Given $n$ points with integer coordinates in the plane, determine the maximum number of points that lie on the same circle (on its circumference, not its interior).
This can be done in $O(n^3)$ easily by trying $\binom{n}{3}$ combinations of points and counting the number of occurrences of all circles found with hash... |
I'm trying to understand how to create a DFA on the language $\{a,b\}$ that accepts strings where the number of $a$s is not a multiple of n.
Creating a DFA with no. of $a$s divisible by $n$ is easy. One simply makes $n$ states such that the string ends into the accept state per every $n$ of e.g. $a$s.
I've figured out ... |
I've had to come up with a traversal order/algorithm for a project, and I am wondering if it has a name.
The requirements of the algorithm are:
it visits the parent before the children.
it visits all the children in one group.
it is otherwise depth-first.
I basically modified a pre-order to visit the siblings all tog... |
I'd like to preface this question by saying that it is not a homework question. However, it is a question regarding the course material. In the rod-cutting example an equation is presented to determine the maximum possible revenue attainable for give rod length:
$r_{n} = max(p_{i} + r_{n-i})$ (15.2)
I'm trying to prove... |
I am solving an exercise from the book of Cormen et al. (Introduction To Algorithms). The task is:
Show that solution of $T(n) = T(\lceil n/2\rceil) + 1$ is $O(\lg n)$
So, by big-O definition I need to prove that, for some $c$,
$$T(n) \le c\lg n\,.$$
My take on it was:
$$\begin{align*}
T(n) &\leq c\lg(\lceil n/2\... |
Why does the following DFA have (to have) the state $b_4$?
Shouldn't states $b_1,b_2,b_3$ already cover "exactly two 1s"?
Wouldn't state $b_4$ mean "more than two 1s", even if it doesn't trigger an accept state?
|
I have the following python code
x = [100.0 for _ in range(1000)]
for i in range(1, len(x)):
x[i] = x[i-1] + (2*randint(0, 1)-1)*step_size
import numpy as np
print np.corrcoef(x[:-1], x[1:])
I am getting extremely high correlation values, over 99.9%, more precisely
[[ 1. 0.99785636]
[ 0.99785636 1. ... |
I'm planning to teach a winter course on a varying number of topics, one of which is going to be compilers. Now, I came across this problem while thinking of assignments to give throughout the quarter, but it has me stumped so I might use it as an example instead.
public class DeadCode {
public static void main(Strin... |
I came across the question Is there an algorithm that provably exists although we don't know what it is? I was able to follow the example "Given an integer $n\ge0$ is there a run of $n$ or more consecutive 7s in the decimal expansion of $\pi?$" given in one of the answers. The answer shows that the problem in example i... |
I have an assignment for school, in which I have to build a neural network that will play tic tac toe, using genetic algorithms for training. The thing is that I am clueless on how to connect the two. I need help in the design. Should use the GA to generate game boards, to serve as input for the neural network. Or, sho... |
I'm looking to understand how can one graph the following DFA given its mathematical definition.
Take for example this (from [1], p. 107):
Set of States: $Q = \{q_{\langle carry=0\rangle}, q_{\langle carry=1 \rangle}\}$
Alphabet: $\Sigma = \{\langle x_{i}, y_{i}\rangle \mid x_{i},y_{i}\in[0..9] \}$
Start State: $s = q... |
I am stuck on the following question.
If $L$ is regular show that $\text{even}(L)$ is also regular. Here $\text{even}(L) = \{ \text{even}(w) : w \in L \}$, $\text{even}(w)$ is the string obtained by extracting from $w$ the letters in even numbered positions. For example, if $L=\{0, 01, 02, 0202, 12120\}$, then $\text{... |
Given $T_1, T_2\colon \Sigma^* \to \Gamma^*$ ($\Gamma$ is output alphabet), let $\Delta(T_1, T_2)$
consist of all input strings $w \in Σ^*$ where $T_1(w) \neq T_2(w)$.
Prove that FSTs are not closed under this operation $\Delta(T_1,T_2)$.
What I have tried is to create two FSTs $T_1, T_2$ (as 5 tuple fu... |
In the context of the very recent talk by Lazlo Babai outlining that Graph Isomorphism (GI) is Quasi Polynomial Time, what are the broader implications of this result? (I'm assuming the claim will stand peer review)
http://people.cs.uchicago.edu/~laci/quasipoly.html
https://twitter.com/gabegaster
Apart from the inhere... |
If I am not mistaken, a tree is any graph that does not contain cycles.
However, I am currently taking a bioinformatics course where we deal a lot with algorithms on phylogenetic trees. Usually you are given a phylogenetic tree with $n$ leafs, and then you run some algorithm that can do something trivial like simple tr... |
I am intrigued by and understand the very basics of Proof Carrying Code (PCC) and I recognize that LLVM is a machine-independent intermediate language. LLVM is the intermediate form of many languages, including the new Rust language. Typed Assembly is another style of intermediate form which can be used to generate P... |
Does the concept of the array (a sequence of equally-sized elements accessible in O(1) time, occupying O(n) space) pre-date physical computer memory implementations?
I am trying to gauge whether computer memories were designed for the array or whether the array concept was designed to work with computer memories.
|
I was reading this article on gperf.
In it they claim that the use of nested if statements for parsing command line input of $N$ options ends up making $O(N^2)$ comparisons. (If I had just made one if for each option would it not be $O(N)$?)
Later on, they say that if instead the perfect hash function that gperf provi... |
True or false:
An intersection of a Turing-recognizable and a regular language is always Turing-decidable.
This was asked on a practice test and the answer is False. Why? I thought regular languages were a subset of decidable languages. So if you intersect regular and recognizable the result would also have to be a sub... |
I'm trying to make a pattern that looks like this:
And am given this code to start:
import static java.lang.System.*;
class TriangleWord
{
private String word;
public TriangleWord()
{
word = "";
}
public TriangleWord(String w)
{
setWord(w);
}
public void setWord(String w)
{
word = w;
}
public String t... |
I need some help with a program that will fill in objects that pop out from the background. For example I have this picture and would like to get an output like this. I don't know how to do this though (obviously otherwise I wouldn't be asking). And I was wondering if there was some way of filling in objects that don'... |
Is there any way to find generalized formula to calculate the number of paths of different length between two nodes of the network connected in mesh topology, given that the network contains n nodes?
|
(pseudocode)
f(x,y,z)
{
if (x < y)
{
return 1 + f(x + 1, y, z)
}
else if (y < z)
{
return 2 + f(x, y + 1, z)
}
else
{
return z
}
}
The function call f(12,14,20) returns $40$. Why is this the case? As the final statement is return z, should it not simpl... |
Let $A$ be a DFA and $q$ a particular state of $A$, such that
$\delta(q, a) = q$ for all input symbols $a$. Show by induction on the
length of input that for all strings $w$, $\delta^* (q, w) = q$.
I'm completely new to the subject. But this is what I have done. Can someone please tell me if this is the correct s... |
In my book:
The set {abb, a, b, bba} is said to be converted into regular expression abb + a + b + bba.
The set {01, 10} to regular expression 01 + 10
Does the +'s here represent concatenation or union?
|
It is said that any term on the calculus of construction halts. I am studying it through Morte, which is a bare bone implementation of the coc available on github. Is there any simple proof of normalization for the calculus of constructions? If the proof isn't simple, is there an simple intuition behind the result?
|
Let $P$ be an $m \times m$ antisymmetric matrix of the form:
$$
\begin{bmatrix}
0 & p_{1,2} & ... & p_{1,m} \\
-p_{1,2} & 0 & ... & p_{2,m} \\
\vdots & \vdots & \ddots & \vdots \\
-p_{1,m} & -p_{2,m} & \dots & 0 \\
\end{bmatrix}$$
with $p_{i,j} \in [+1,-1]$, how can I find a set $I^*$ of matrix rows that maximizes the ... |
$\Sigma=\{a,b\}$, $L=\{w\in \Sigma^* \Big| |w|=3n+5m, \ n,m\ge 0 \}$.
I need to build NFA automaton for $L$....
Now, I try it for hours but I don't have any idea how to solve it.
I know that any $x\ge 8$ can be written as $3n+5m, \ n,m\ge 0 $
So, the automaton accepts any word the her length is 8 or higher, but it does... |
I have the language
$\qquad L=\{ a^s b^t c^m \mid s,t,m \; \in \; \mathbb{N^{+}} \text{ and } t<4, s \cdot t=m\}$.
How do I go about designing a PDA for it ?
I can't figure out a way to deal with $m$.
|
$ALL_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\Sigma^*\}$
$E_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\emptyset\}$
I can't find reduction of $ALL_{TM}$ to $E_{TM}$. But I can't proof that it does not exist.
Is there is such a reduction?
|
For an assignment, I need to draw a diagram of Von Neumann architecture, and explain each part of it.
All the diagrams and explanations I've seen have a distinct "Memory" block that holds both the code and the program data of running processes. What I can't find information on however is if this memory refers to only p... |
Why is the language $A=\{wtw^r: w,t\in\{0,1\}^*\text{ and }|w|=|t|\}$ not a context free language?
It is turning out to be really tricky. Is there an easy way to show this?
|
Let's suppose I have two functions $F$ and $G$ and I'm interested in determining whether
$$F(x) = \int G(x)dx.$$
Let's suppose that my functions are composed of elementary functions (polynomials, exponentials, logs, and trigonometric functions), but not, say, Taylor series.
Is this problem decidable? If not, it is it s... |
How do I solve the recurrence relation $T(n)=n+T(n/2)+T(n/4)+\cdots+T(n/2^k)$, for constant $k$?
I am told that the answer does not depend on $k$.
|
Some problems such as sorting have famous complexity lower bounds (ex: $O(n \log (n))$ in this case) but I feel that doesn't totally remove the possibility of improving algorithms by shaving constants. Are there any really non trival, perhaps not practical sorts, that have excellent constant performance? For example do... |
What is the relation and difference between a programming model and
a programming paradigm? (especially when talking about the
programming model and the programming paradigm for a programming
language.)
Wikipedia
tries to answer my question in 1:
Programming paradigms can also be compared with programming models that... |
I know this is a fairly poorly worded question, but I can't think of a better way to phrase it in the title.
So in Radix Sort, you go digit by digit from least significant to most significant, and along the way you are swapping elements around. When considering the case where two digits are the same, do you look at th... |
Can someone explain how exactly Successive Shortest Paths (SSP) is a generalization of the Ford–Fulkerson algorithm? I've found this stated in a few papers and websites as well as the Wikipedia page for the Minimum-cost flow problem. But none of them go any further than that statement or explain how exactly they differ... |
In a $k$-way set associative cache, the cache is divided into $v$ sets, each of which consists of $k$ lines. The lines of a set are placed in sequence one after another. The lines in set $s$ are sequenced before the lines in set $(s+1)$. The main memory blocks are numbered 0 onwards. The main memory block numbered $j$... |
An array $a[1,\ldots,n] \subseteq \{1,\ldots, k\}$ is given, where $k < \sqrt{n}$.
Our goal is a project algorithm which sorts it in place and in time $O(n\log k)$.
We assume that $k < \sqrt{n}$ - otherwise $O(n\log k) = O(n\log n)$ - then we may use HeapSort.
We may assume that we know $k$. I try to do it. The on... |
Consider a cashier machine that takes payments in coins. We feed the machine coins one by one until the value is more than the amount we should have paid. Then the machine returns the extra amount in coins in the least number of coins possible. So we have k type of coins and a limited amount of each type. Also the mach... |
Given that some shapes overlap in an image, are there any papers or articles or code which can infer the original shapes from the overlapping?
I am thinking to apply some machine learning to this since I can generate overlapping shapes using code and use a neural network to try to work out the original shapes. Perhaps... |
I don't want to binarize a certain image through another program, I want to know how to binarize things myself. All I know is that there is something to do with a threshold and if it is above the threshold it is either 1 or 0 and the opposite if below. My images are using RGB but I can also use HSB or HSV. I just want ... |
Lets say we have $L_1$, which is a regular language and $L_2$ which is not. Are $L_1 \cap L_2$, $L_1 \cup L_2$ , $L_1$ \ $L_2$ and $L_1 \cdot L_2$ are always non-regular languages?
We know that two regular languages always gives us a regular language under all of the above. I can't find anywhere any proof that combina... |
I'm trying to figure out if:
$\log^2n = O(n)$ and
$ n = O(\log^2n)$
are true or if one or both are false.
So far I've concluded that both are false because if $n = 8$ for the first one, then $\log^2 8 = O(8)$ which is false since it simplifies to $9 = O(8)$ which does not belong to $O(n)$.
For the second one, I belie... |
Are there any problems apart from chromatic number, which is $FPT$ when parametrized by (the size of a minimum) vertex cover, and that does not admit a polykernel when parametrized by (the size of a minimum) vertex cover (under standard complexity assumptions)?
|
I have two questions as in the title:
TM M accepts some string of length greater than 100
TM M accepts some string of length at most 100
Since 1. is infinite, we can rephrase question as "does TM accept a string", which is clearly undecidable and there are many proofs for that.
2nd question on the other hand is fini... |
Is the variation of partition problem where instead the sum of the sets only be equal to a value $B$, they could also differ by two ( i.e., the sum of one set could be $B-1$ and the other $B+1$ ) still $NP$-complete?
|
If the question appears vague, I'll gladly clarify. It's not tied to a programing language. If there is a language dependency in the answer, one can place it in the context of Python, R, VB, Mathematica, Matlab, or seek clarification.
Are there situations when a vectorized (aka element-wise application of a function or... |
This is a homework problem I've been given and I've been raking my brain for hours (so I'm satisfied with some pointers). I know already that the approximation ratio cannot be worse than $2$. I have a wheel graph, where each edge has cost $1$ and the distance between all nodes which are not connected by edges is $2$. T... |
This semester I was introduced to finite automata (FSM), then pushdown automata (PDA), and now the Turing machine (TM). Granted that there're many possible implementations of these abstractions (electrical, mechanical, whatever...), I find the terms used in describing these machines rather extravagant. It's as if the t... |
The refinement order on partitions of an integer $n$ can be defined as follows: $\lambda=(\lambda_1,\dots,\lambda_k)\leq\mu=(\mu_1,\dots,\mu_\ell)$ if there is a partition of the parts of $\lambda$ into blocks whose sums are the parts of $\mu$.
It is known that the problem of deciding whether $\lambda\leq\mu$ is NP-com... |
I was trying to code the Ullman subgraph isomorphism agorithm. With respect to the Ullman subgraph isomorphism, there are two matrices, M and M'. How is M' being formed from M?
Matrices M' are generated by systematically changing to 0 all but one of the l's in each of the rows of 0 M, subject to the definitory condit... |
Before I'll ask my question, let me start with my understanding of the definitions, to prevent myself with further confusion, as well as giving some background.
Huffman Code is the binary-code induced from a binary tree, constructed by Huffman's Algorithm.
Hu–Tucker Code is the binary-code induced from an alphabetical ... |
Consider a directed graph. I need to find a path that visits maximum number of strongly connected components in that graph. If there are several such paths the desired path is the path that visits minimum number of nodes (shortest path).
I have created a DAG from the directed graph and performed a topological sort on... |
I want to find the minimal period of any state of an LFSR (except the initial state of all zeroes) whose characteristic polynomial is the product of two primitive polynomials.
In particular, $f(x),g(x) \in GF(2)[x]$ are primitive polynomials of order $n$, and the characteristic polynomial of the LFSR is given by:
$$c(x... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.