instruction
stringlengths
35
29.1k
I have a system that takes in 'm' inputs and provides a cost value as an output. The system is a "black box" to me. The inputs can be varied and the corresponding output can be observed, however, I have no prior knowledge of the function that this box implements. Given that I can fiddle with the input values(all real v...
A context-free language is defined by its description: $L=(a^{2k} \space b^n \space c^{2n} \mid k \geq 0, \space n > 0)$ For example: $bcc, aabcc, aabbcccc, bbcccc$ How to build a context-free grammar for this context-free language? I suppose that the order for generating any chain in this problem matters: 'b' will al...
I have a complex function, which looks something like this: $$f(x) = \sum_{k=0}^x{\frac{g(k)}{h(k)}} + l(x)$$ Now, $g(k) = O(\log k)$ and $h(k) = O(k)$, the sum iterates $k$ from $0$ to the parameter $x$ and $l(x)$ is meant to provide a decimal correction, but its form is $\dfrac{a^{b-x}}{h(k)} (a,b - const)$. How can ...
The problem is as follows: Given $k$ strings of size $n$, propose a data structure to support the following operations: Return the maximum of a string. Given an index $i$, and $2$ strings $a$ and $b$, create 2 strings to replace them: One of them is compised of the $i$ first elements of $a$ and $n-i$ of the last eleme...
recently I've started thinking about caching problems in modern CPUs, where they struggle to adequately fetch program data (not instructions) in time, so that it can be computed further. So then I came up with the idea, why don't we restrict random access on program data and make it all as a continuous stream (inpu...
.{5} would match any string of 5 symbols (excluding newline). Suppose I wanted to define "a 5-character repetition of a single character." The immediate way that comes to mind is (.)\1{4}, but this relies on a back reference. Using a subset of regex which is dependent only on |,(),*,concat any regex expression of patte...
Given a Tree and pointers to two of it's nodes A and B (a key value of each node is positive). Find an algorithm that sums up all the values on the path between A and B, when preproccessing is allowed.
Given a graph $G = (V,E)$, assume that we have two disjoint vertex sets $N = \{n_1, n_2 ...\} \subset V$ and $P = \{p_1, p_2, ...\} \subset V$ such that $N \bigcup P \neq V$. I want to find if there exists an edge subset such that $\{<n_i,p_l>, <n_j,p_l>, <n_k, p_l>\}$ i.e. three nodes from $N$ and one node frpm $P$. S...
An array $A[1...n]$ is said to be k-ordered if $$A[i - k] \leq A[i] \leq A[i + k]$$ for all $i$ such that $k < i \leq n - k$. For example, the array $A = [1, 4, 2, 6, 3, 7, 5, 8]$ is 2 ordered. Q1. In a 2-ordered array of 2n elements, what is the maximum number of positions that an element can be from it's position if...
Given Array $A$ of size $n$ that contains all the integer values $[0,n]$ except one. In this question we assume that the time we need to check one bit $j$ in number $A[i]$ is $O(1)$,and to check the number $A[i]$ is $O(\log n)$. Find an algorithm that finds the missing number in $O(n)$. So creating a trivial counter ar...
I am trying to find a graph in which both s-t minpaths and min cuts are exponential. Individually I found examples in which s-t minpaths and s-t min cuts are exponential. Can some one provide me an example of graph which has both min paths and min cuts in exponential size.
A sequence of $N$ operations is performed on a certain data structure. The $i$-th operation costs $i$ if $i$ is a power of 2, else it costs 1. How can I calculate the amortized cost for every operation using the potential function method?
I have a very generic question to ask. It is related to research. I'm interested in Graph theory. I have done a course in it. I have done some topics related to both graph theory as a point of view of doing it as a mathematics student and also studied some graph algorithms. I'm going for research internship in gra...
I'm studying KMP algorithm and I'm stuck on an example. Suppose my text is "I am queen." and my pattern is "q". The sp table will have only one value, q and it's sp index will be 0. Mismatch will occur at the very first index. According to the formula: i - ( spi-1 + 1) ; the right shift will be 0. And so the algorithm ...
Better explained with examples, I need a programming system with the following characteristics: f = λ a b c -> a + b + c g = apply f 1 2 3 = 6 h = unapply g _ 2 _ = λ b -> 4 + b Or, to explain with words, f is a function, g is that function applied to 3 arguments, and h is g "unapplied" to one argument. That is, I nee...
I'm not nearly at the experience level in computer science to be able to properly determine the number of instructions involved in basic ALU calculations, and I'm interested in a certain software concept where the difference is important. Multiplication 1011 (this is 11 in decimal) x 1110 (this is 14 i...
On SuperUser, I asked a (possibly silly) question about processors using mathematical shortcuts and would like to have a look at the possibility at the software application of that concept. I'd like to write a simulation of Japanese Multiplication to get benchmarks on large calculations utilizing the shortcut vs tradit...
I'm trying to draw a DFA graph for the regular language where every chain: * consists of symbols from the set {1,a,b}. * starts with the subchain '1a'. * includes at least one subchain 'aa'. Output chains: $1aa, 1abaa, 1aaba, 1aaa, 1aaab, 1aab1a, \space ..., \space etc.$ There's no problem with checking the $'1a'$ s...
Defunctionalization is nice for higher order functions where it is completely necessary to avoid runtime support, but in some cases it's favourable to use function pointers instead (since they don't generate huge code bloat for certain scenarios, i.e.): data Foo a = Foo (a -> Int) Under what conditions is it safe to i...
I have a B-Tree of order 5. So the keys are between $\lceil n/2 \rceil- 1 \leq keys \leq n - 1$ and children are between $\lceil n/2 \rceil \leq children \leq n $. Am I doing it right? So a full node would be of 4 keys, how do I split that, because when I split that full node, I get uneven keys in any of the children. ...
While reading the paper Effective Data-Race Detection for the Kernel by John Erickson and Madanlal Musuvathi. I was stuck on a slightly tricky sentence. "Similarly, a range of kernel-address space, called session memory, is mapped to different address spaces based on the session the process belongs to. When a sampled ...
On-line handwriting recognition is the task of converting a series of $(x(t),y(t))$ coordinates to symbols and words. In contrast to off-line handwriting recognition, where you only have a bitmap of the written symbols, you have the way it was written in on-line recognition. The paper Npen++: An On-Line Handwriting Rec...
Or maybe also a combination of the two, but not something else, whether numeric, nor symbolic. Do they cover the whole field?
My question is specifically about $\emptyset$, but more generally about any language that can be decided in (deterministic or nondeterministic doesn't really make a difference here) constant time. Obviously, $\emptyset$ cannot be $\mathsf{NP}$-hard since there is nothing to map "yes"-instances to, but I'd prefer a one ...
I'm studying KMP Algorithm. In the failure function (or the sp table), why do we always assign the value 0 to the first element (character) of the pattern? I understand about the later elements of the pattern, as we assign the sp values according to length of correctly matched suffixes and prefixes, but why does the sp...
This code is taken from wikipedia: // left is the index of the leftmost element of the subarray // right is the index of the rightmost element of the subarray (inclusive) // number of elements in subarray = right-left+1 function partition(array, left, right, pivotIndex) pivotValue := array[pivotIndex] ...
Is it possible to prove that for a flow network, there always exists a maximum flow which assigns an integer value to every edge?
While creating an algorithm, the following question came up: In uniform cost, what is the time cost of a process that creates a thread? Is there a difference between creating a thread in a thread pool vs creating a thread in runtime? I know these questions should be self-explanatory, but I cannot seem to find an answ...
As the title says, my question is whether the set of $\mathsf{NP}$-hard languages is closed under set inclusion, i.e. whether for any $\mathsf{NP}$-hard language $L$, all subsets of $L$ are also $\mathsf{NP}$-hard. This question is related since $\emptyset$ is not $\mathsf{NP}$-hard as there is nothing we could map "ye...
I'm studying the basics of security in computers. The doubt I have is that the access control matrix is presented as a matrix whose rows are the subjects and the columns are the objects. Also subjects are defined both in Windows and Unix (and Multics for that matter) as processes, threads, not users, but processes. My...
I am looking for an efficient algorithm that can partition an area $B \subset \mathbb{R}^2$ into disjoint subsets $B = \bigoplus_i U_i$ such that a test function is constant on each of the subsets, $f \vert_{U_i} = \mathrm{const.}$ For example, consider the following partitioning: The indicated numbers are the return ...
I have points represented as sparse high-dimensional binary vectors, or put another way, I have a list of groups that each point belongs to. For two points, the edge weight between them is $\sum_i 1/|B_i|$ where $|B_i|$ is the number of points that belong to group $i$, and the summation is over all shared groups that b...
In the gas station problem we are given $n$ cities $\{ 0, \ldots, n-1 \}$ and roads between them. Each road has length and each city defines price of the fuel. One unit of road costs one unit of fuel. Our goal is to go from a source to a destination in the cheapest possible way. Our tank is limited by some value. I try...
I have been recently studying Lie theory. I discovered that there is a family of Lie theoretic error correcting codes. I did not find any information except this paper: “Representations of Lie Algebras and Coding Theory“ by Xiaoping Xu So, my question is: why isn't there a further development of this research? Are th...
I need to give an algorithm to show that the word problem in the group $\langle x,y \mid \mid x^{1984} = y^{2014} = 1 \rangle$ is decidable. How do I show this? I'm not too sure where to start.
Does the following recursive algorithm have a name? If so, what is it? procedure main(): myFilter = new Filter( myPrime = 2 ) //first prime number print 2 //since it would not otherwise be printed for each n in 3 to MAX: if myFilter.isPrime(n): print n object Filter: integer myPrime PrimeFilter nextFilter = ...
I have been struggling in the search for a modern fast "consequence finder". That is, an implementation based on state-of-the-art theory; things of the ilk of Z3, Prover9, OTTER, etc. To describe what I mean by "consequence finding" (and please correct my term usage if it's inappropriate): Given a satisfiable and consi...
I'm studying LR(0) parser. But I don't understand how sets of items corresponding to states can be calculated. I think The author would miss some information readers must know. Given the following LR(0) automaton, How the set of items corresponding to I1, I2, I3, ... , and I11 can be calculated? In addition, is closur...
this is a new/advanced paper on OR and AND compression of SAT formulas, a newer area of research that seems not covered in any textbooks so far. A simple proof that AND-compression of NP-complete problems is hard (Dell) can follow it generally, but not in detail. so: how would this theory be described to undergradua...
Can this problem be solved in poly time? Input: $S_i \subset \{1,\cdots,n\}$ for $i=1,\cdots, n$. Question: Is it possible to select an $a_i \in S_i$ for each $i=1,\cdots,n$, such that $\{a_1,\cdots,a_n\}=\{1,\cdots,n\}$? Informally, the problem asks for selecting one element from each subset $S_i$ such that the sele...
Construct grammar given the following language! $ L = \{(ab)^{n+1}u(ba)^n|n>0, l_c(u) = 1, u\in\{a,c,d\}^* \}$ My interpretation in a less accurate way: $(ab)^{n+1}$ says we need to concatenate $(ab)$ at leat one time with itself (since $n > 0$) $u$ represents one word from the set of $\{a,c,d\}^*$, (except the words,...
Consider this problem: $\qquad\displaystyle \mathsf{FPATH} = \{\langle G, a_1,\dots,a_n\rangle \mid G \text{ is a digraph with directed path } (a_1,\dots,a_n)\}$ It's allowed to visit nodes outside the sequence, but a1 must be visited before a2 and so on. I am having big trouble trying to show that this language is NL-...
I'm wondering about the relationship between computational complexity and the Chomsky hierarchy, in general. In particular, if I know that some problem is NP-complete, does it follow that the language of that problem is not context-free? For example, the clique problem is NP-complete. Does it follow that the language c...
I'm trying to interpolate a logarithmic function but it always reaches a singularity due to $\log(0)$ being $-\infty$ is there a correct way to interpolate logarithmic functions? (as in correct parameters) What i'm currently going for is $y=a+b \log(cx)$ with initial values $a=0$, $b=1$, $c=0$
I'm looking for a persistent data structure similar to array (but immutable), allowing for fast indexing, append, prepend, and iteration (good locality) operations. Clojure provides persistent Vector, but it's only for fast append. Scala's Vector has effectively constant-time append and prepend, but I can't get how it'...
CNF H = {<ø>|ø is a satisfiable cnf-formula where each clause contains any number of literals, but at most one negated literal} I want to show that CNF H is in P, but I'm having some trouble finding an algorithm. My first idea was to check for each clause c in P if that clause contained at most one negated literal. I...
Is there any sorting algorithm that takes order of $\log n!$ in the worst case? I know that this is the lower bound for sorting algorithms using comparison based sorting. I know that there are algorithms of order $n\log n$, but since $n!$ grows much slower than $n^n$, I wish to know of there is any algorithm of this or...
I often see syntax like expression = term | expression, "+" , term; term = factor | term, "*" , factor; factor = constant | variable | "(" , expression , ")"; variable = "x" | "y" | "z"; You see, all the rules produce an arithmetic value. Each can replace the other. Why not just declare aexpr = var | num ...
Given some abstract problem how can I prove that this problem is not in P. I mean, what is the method for proving such thesis?
Recently I was asking about the algorithm to solve The Gas Station Problem and I got useful answer. Unfortunately solution with transforming a graph to complete graph and then preparing another one to find the shortest path (as described in paragraph 4) is really slow in case of my constraints. I figured out how to im...
I've seen a lot couple of questions regarding the pumping lemma that are pretty similar to each other and this one is unfortunately not the exception. Most likely will be this question marked as a duplicate. But I guess there's no harm in asking. I was trying to show using the pumping lemma that this language is not re...
I have noticed that a lot of problems that are in L and NL use binary numbers. I don't understand why this is the case. Does a TM use less space by storing a binary number, than a "normal" one. In my head, it uses less space to store the number 0, than the binary ecquivalent number 0000. Hope someone can help me unders...
I have tried for the last few days to prove that any bipartite graph of maximal degree d may be broken into (at most) d matchings. My main approach is to prove this inductively over the maximal degree d. This would require me to show that there must exist a matching which contains an edge for every one of the maximal d...
I am currently working through Tiernan's paper, "An efficient search algorithm to find the elementary circuits of a graph" (published 1970), and I am stuck on point 3 of the following excerpt: The algorithm is named EC for "elementary circuit." The function blocks of EC are denoted EC1, EC2, etc. EC requires that ther...
I have been looking at the wikipedia page for steiner trees, and I don't quite understand their 4-point solution. If the four vertices are arranged in a rectangle shape wouldn't there be only one steiner vertex required in the middle to create the shortest length graph? The solution shows two vertices S1 and S2, but i...
Is there research or are there results that discuss graph isomorphism in the context of spectral graph theory? Two known theorems of spectral graph theory are: Two graphs are called isospectral or cospectral if the adjacency matrices of the graphs have equal multisets of eigenvalues. Almost all trees are cospectral. T...
The Wikipedia description has way too much math.
Its kind of a weird question to ask but I have been asking myself this: Is there a limit to number of ways to find a solution to a particular problem. Take the simplest problem: sorting a sequence of numbers. Now there are a lot of algorithms to sort. Is there a limit to such algorithms? Technically, you can always fli...
Consider a group of five processors implementing three-phase commit protocol. During the execution of the protocol, the coordinator and one other process crash. Two of the remaining processes are waiting in "READY" state for the coordinator while the third process is in "PREPARE COMMIT" state. Can they continue and com...
On wikipedia's page on P vs NP it says that think that of 151 researchers surveyed, their thoughts were as follows: "126 (83%) believed the answer to be no, 12 (9%) believed the answer is yes, 5 (3%) believed the question may be independent of the currently accepted axioms and therefore is impossible to prove or ...
If $\qquad\displaystyle L_p = \{ \langle M \rangle : p \in P(L(M)) \text{ s.t. } p \text{ is a specific trivial property} \}$, where a trivial property is a property that is shared by all recursively enumerable languages or is not a property of any recursively enumerable language, is it implied that $L$ is decidable?...
So I fully understand the how the RSA algorithm works, but now I am trying to reason with the formula. I want to know: why the public key e and the private key d in the RSA encryption have to satisfy the equation ed = 1 mod (p − 1)(q − 1)? Is it because of the standard modular arithmetic rule where 1 mod anything ...
I am having trouble giving the description of a Turing machine that goes for $L = \{0^n 1^m 0^n 1^m \mid m,n \geq 0\}$. What I have so far is: If we start with a blank, the string is empty and it should accept, if not, start reading $0$s and I thought marking the $0$s with $X$ and the $1$s with $Y$ would be OK. After w...
In Sipser's Theory of Computation book, it is stated while reducing ATM to REGULARTM We let R be a TM that decides REGULARTM and construct TM S to decide ATM. Then S works in the following manner. S = “On input , where M is a TM and w is a string: Construct the following TM M2. M2 = “On input x: If x has the form...
I'm trying to design an algorithm for the following optimization problem. Suppose that $G=(V, E)$ is a digraph where $V$ and $E$ are sets of vertices and edges of $G$, respectively. $|V| = n$ and $|E| = m$. $c$ is the cost vector; $c_{ij}$ is the cost of edge $(i,j)$. Costs can be negative and $G$ may have cycles (nega...
I am helping design a CS-related activity for a Let's Talk Science competition, which promotes STEM amongst high school students. In the competition, teams of six students will move from station to station, trying to complete each as quickly as possible. One station might give the team a metre stick, then ask them to m...
I studying the related question. https://stackoverflow.com/questions/13500560/number-of-ways-to-create-an-avl-tree-with-n-nodes-and-l-leaf-node but it's not so general. In-fact, We want to know with N keys, how many different AVL Tree, we can make? we know with N=1 key is 1 AVL Tree. with N=2 key we have 2 different ...
What is a bicriteria approximation algorithm? This keeps coming up in the case of data stream clustering. Is this related to multi-objective optimization? This is where I came across it: cis.upenn.edu/~sudipto/mypapers/datastream.pdf. The paper is about a streaming version of the k-means algorithm. There are references...
Unrolling an iso-recursive μ-type expression such as, say, one isomorphic to natural numbers: μα.1+α using unroll : μα.T → T[μα.T / α] by three steps, for example, gives: μα.1+α μα.1+(1+α) μα.1+(1+(1+α)) ... If I instead have a polymorphic list, such as: λα.μβ.1+αβ is there a necessary relative order to the expansi...
It's hard to look up the meaning of a symbol if you don't know what it is called in the context that it is written. That apostrophe-type symbol in the sequence notation - what is that?
All decision problems (i.e.language membership problems), which are verifiable in polynomial time by a deterministic Turing machine are called NP problems. Further, these problems can be solved by a non-deterministic Turing machine in a polynomial time and in exponential time by a deterministic Turing machine. Do we ha...
I need help with the following: Let $k\in \mathbb{N}$, define: $L^k=DSPACE(O(log^k(n)))$ $NL^k=NSPACE(O(log^k(n)))$ and: $PolyL=\bigcup_{k=1}^{\infty}L^k$ $PolyNL=\bigcup_{k=1}^{\infty}NL^k$ I need to prove, disprove or to determine if it is an open question: 1. For every $k\in \mathbb{N}$ it holds that $NL^k\subsete...
Given an undirected and connected graph $G=(V,E)$ and two vertices $s,t$ and a vertex $d \in V- \{s,t\}$, we would like to define a legal path as a path from $s$ to $t$, passes through $d$ (at least once) and is of even length (regarding number of edges). We need to find such a path that is the shortest in $O(V+E)$ t...
Alan Turing proposed a model for a machine (the Turing Machine, TM) which computes (numbers, functions, etc.) and proved the Halting Theorem. A TM is an abstract concept of a machine (or engine if you like). The Halting Theorem is an impossibility result. A Carnot Engine (CE) is an abstract concept of a heat engine and...
My professor has asked this (exam) question and it actually makes no sense to me: TCP offers a reliable, bidirectional byte stream over the best effort packet delivery in IP. For reliability, a sender in a TCP connection re-transmits a possibly lost packet. One of the methods with which TCP guesses the loss of a packe...
It is rather easy to see that every cellular automaton can be simulated by a Turing machine: We can simulate a cellular automaton with an appropriate C program and every C program can be simulated by a Turing machine. But how would a concrete TM look like which simulates a CA?
We are given an initial set of tuples $S_0=\{(x_i,y_i)|i\in [n], \forall i:x_i,y_i\in \mathbb{N}\}$ and a number $B\in \mathbb{N}$. At time $t$ we are allowed to remove ($S_t := S_{t-1} \setminus \{(x_i,y_i)\}$) a pair $(x_i,y_i)\in S_{t-1}$: if $$x_i + \Sigma_{j:(x_j,y_j)\in S_{t-1}, j\neq i} y_j \geq B$$. (That is ...
I'm currently reading about functional dependencies. I've read Armstrong's axioms about: Relexivity: $if$ $B\subseteq A$ $then$ $A\to B$ Augmentation: $if A\to B$ $then$ $AC\to BC$ Transitivity: $if A\to B$ $and$ $B\to C$ $then$ $A\to C$ and also about: Union Rule: $if A\to B$ $and$ $A\to C$ $then$ $A\to BC$...
I'm doing a course in Computational Number Theory and am currently looking at algorithms such as Euclid's algorithm, Square-roots modulo a prime, LLL reduction algorithm, McKee's method, Pollard's $p-1$ method, the elliptic curve method and a couple of others. In an assignment, I'm asked the following question: Which o...
In the late 1990s, when I was in graduate school, the paper JH Saltzer; DP Reed; DD Clark: End-to-end arguments in system design. ACM Trans. Comput. Syst. 2(4):277-288, 1984. DOI=10.1145/357401.357402 was pretty much required reading in every operating systems class at every university, and it still seems to be one ...
What is the best demonstration that show that "Every finite set is computable"? thanks
Context: I have 100 speech sentences that I asked my friend to speak. The vocabulary in the sentences are same but only the order of words are changed. My friend says that he spoke exactly what was asked for each sentence. But I don't know whether he spoke exactly that sentence or something else. What I have here is th...
I want to train a support vector machine with some features. The problem is, one of the features is 1-dimensional (only an angle) and the other is an LBP Histogram, an 58-dimensional vector. Therefore if I concatenate them, like this (in MATLAB) : f = [lbp_histogram; angle]; I got a 59x1 vector, I can train SVM with ...
I'm trying to prove that the following recurrence relation has a runtime of O(n): fac(0) = 1 fac(n+1) = (n + 1) * fac(n) I think that I can use induction in the following manner: Base case If n=0 then fac(n) = fac(0) = 1 Inductive case Assume that fac(n) has a runtime of O(n) fac(n+1) = (n + 1) * fac(n) Therefore...
Hi I have two question about this language: L = {a^i b^j c^k | i = 2*j OR j=2*k } 1)Finding a CFG 2)If in condition part we put AND instead of OR , is this language remains CONTEXT FREE or not ?? thanks.
I am a bit confused on the theory of the pumping lemma. As I know is used to decide if a language is regular or not. This is what I have understood so far though For a regular language $L$, there exists a $p > 0$ such that for all $w ∈ L$ where $|w| ≥ p$, there exists some split $w = vxu$, for which the following holds...
A Boolean function is a function $f:\{0,1\}^n\rightarrow\{0,1\}$. The boolean basis $(\vee,\wedge)$ is known to be Turing complete as it allows any sequence $s\in\{0,1\}$ to be flipped or to be left unchanged. The same can be said of $\mathrm{XOR}$ gates. In this sense we can start with an initial machine configuration...
So every process has its own Page Table, the page table references the frame where the page is in physical memory and also has a valid-invalid bit that tells whether it is in physical memory or in secondary memory. But how does the S.O. knows exactly where the page is saved when the valid-invalid bit it's off? Is the...
Question: If an AVL tree has height h (assume h ≥ 2), what is the maximum possible difference between the number of nodes in its two subtrees? Prove your answer. Your answer should not use big-Oh or big-Theta. I drew six trees and drew the max number of nodes I could on one tree and the min number of nodes on the other ...
Say we have two proposers (P1, P2), one acceptor (A), and two learners (L1, L2). What would prevent this sequence of events from occurring? P1 initiates a round numbered 1. A agrees to participate, and reports that is has not voted on any proposals. P2 initiates a round numbered 2. A agrees to participate, and reports...
I am struggling with understanding the proof of shortest-paths optimality conditions. Let $G$ be an edge-weighted digraph. Then values in $distTo[]$ are the shortest path distances from $s$ iff: For each vertex $v$, $distTo[v]$ is the length of some path from $s$ to $v$. For each edge $e = v \rightarrow w$, $distTo[w]...
In my programming languages course we are reviewing type inference, i didnt get very well how to make this task. I all ready search at the bibliography of my course (PLAI by Shriram krishnamurthi) which actually sucks big cock since he jump lots of steps in the few examples he expose. Does anybody know how to make the ...
I am having a lot of trouble simplifying my circuit using boolean algebra. I am very new to this and any explanation would be greatly appreciated. I have y'+z+w'x+wx' I feel like I could use DeMorgan's law and somehow omit the last 2 terms but when I run my circuit I cannot seem to get the same result. Also for clarifi...
I have a language DPATH that I'm trying to complete is NP-complete. DPATH = {<G, a1,...,an>|G is a digraph with a directed path that covers the sequence a1,...,an} All of the nodes in the sequence has to be visited exactly one time, but it doesn't matter in which order they are visited. I am trying to show a reducti...
The language of all words over the alphabet {a,b,c} such that the number of as in the word minus the number of cs in the word is divisible by three. How is this language regular? Lecturer notes says that it is, and then provides no explanation at all. I tried drawing a DFA for it, but it just seems that the long...
I've read in a few places (like here that the throughput - that is, the amount of good useful messages relative to capacity - of the ALOHA protocol for networks is roughly 0.18%. But its not clear how we arrived at that number. Can someone explain it?
I've read that the throughput - that is, the amount of good useful messages relative to capacity - of the Slotted ALOHA protocol for communication networks is roughly 0.36%. But its not clear how we arrived at that number. Can someone explain it?
Suppose the L1 cache is filled up with data from some process. Now CPU loads another process. Does the new process share cache contents? Or the cache has to be invalidated completely in each context switch?
The length of the shortest program in a given (fixed) programming language that produces a given output is that output's Kolmogorov complexity, which is not a computable function on the set of possible outputs. This is a classical result and is easily proven; a proof outline appears in the Wikipedia article on Kolmogor...
It is obvious that the representational power of graphs are huge. Is there a problem that cannot be represented using graph? I have recently asked this question to my students and no answers came up. I could not answer this either. For instance: Problem: Finding the shortest path between two given cities in a country. ...