instruction
stringlengths
35
29.1k
I'm currently studying Hoare's "Communicating Sequential Processes" (1) and I've come across a concept that I find a bit puzzling. In CSP trace semantics, a process's semantics are described by a subset of finite execution traces that is prefix-closed. The need to indicate a complete computation introduces the 'tick' e...
So ive already tried lookig at it but i just get O(nlogn) which is not correct there were some clues like using a geometric series where 1/2+2/4+3/8+i/2^i<2 but idk how to implement that what should i do. for i = 1, . . . , n do j = n while j > i do j = j/2 Do smth...
do { key=true; while(key==true) { swap(&lock,&key); } critical section lock=false; Remainder Section }while(true); void swap(boolean *a, boolean *b) { boolean temp=*a; *a=*b; *b=temp; } How do I prove if it satisfied mutual exclusion, progress and bounded waiting? The swap is built into hardware and is atomic. Mut...
I am trying to understand the pumping lemma and its instrumentation to show a certain language is not regular. My first attempt was the following problem: Let $L$ be the language of all words that have twice as many $a$s as $b$s. Is it regular? Is it context-free? I attempted the following. First, let $p>0$ be the pu...
(Note: I am posting after reading some possibly related posts because I could not find a fitting solution.) Given some finite set of nodes $S$, where each node $s_i \in S$ has a value $val(s_i) \in [0,1]$ and moreover has a pairwise similarity value to each other node, i.e $sim(s_i, s_j) \in [0,1]$, I want to find the ...
Consider the problem Show $L = \{ a^{n}b^{m}\mid m \text{ es múltiplo de } n \}$ is not regular. I attempted the following. Assume $L$ is regular. Then there is a natural number $p \geq 1$ such that any $w \in L$ of length greater or equal to $p$ can be written as $w = xyz$ , with $|xy| \leq p$ and $|y| \geq 1$, an...
I am working on the $[1,j]$-dominating set problem defined in this paper. In section 4, they study the problem complexity on degenerate graphs and prove that the problem is W[1]-hard for the parameter solution size. The reduction follows from a well-known W[1]-hard problem, multicoloured independent set (MCIS). For a p...
Problem Statement Martha is interviewing at Subway. One of the rounds of the interview requires her to cut a bread of size $\ell \times b$ into smaller identical pieces such that each piece is a square having maximum possible side length with no left over piece of bread. $\ell$ and $b$ denote the length and breadth of ...
A $k$-tree is recursively defined as follows: $K_k$ is a $k$-tree and any $k$-tree on $n+1$ vertices is obtained by joining a vertex to a $k$-clique in a $k$-tree on $n$ vertices. I have only seen some counting results for $n$-th order $k$-trees, like in the article below. A. Gainer-Dewar, Γ-species and the enumerati...
For a size N>=1 (an input variable) I need an algorithm to generate all variations (no duplicates allowed) of natural numbers greater than zero. For N=1, this is trivial: [1], [2], [3], ... For N=2, I think of having rounds with an increasing limit L where the first element starts from 1 to L and the second element i...
I understand that Time Complexity is the measure of how an algorithm scales with respect to the input size. Let us say an algorithm is having a runtime of O($3^n$) + O($n^{20}$) In order to identify the Non-Dominant term, I followed my intuition for a sample of values: $3^n$ = {1, 3, 9, 27, ...} for n={0, 1, 2, ...} ...
This problem is from Cracking the Code Interview: An array A contains all the integers from Oto n, except for one number which is missing. In this problem, we cannot access an entire integer in A with a single operation. The elements of A are represented in binary, and the only operation we can use to access them is "...
If the logical address and the page size are power of two, then we can separate the virtual address into two parts: page number and offset. Is this still valid if the virtual address is not power of two?
all, I was wondering if my intuitive understanding of why the halting problem is undecidable is actually correct? TLDR: Halting problem is undecidable because it leads to infinite recursion and never stops. Elaborating: At the bottom, I have attached an example of how I have seen the proof presented in a few books(1), ...
Let's say you have two strings: a and b with GCD c. Why is it that len(GCD) = gcd(len(a), len(b))?
We have a bipartite graph consisting of parts $A$ and $B$. Each vertex $i$ of part $A$ has weight $w_i$ and capacity $c_i$. We say a vertex $i$ in part $A$ is satisfied if at least $c_i$ adjacent edges to it are chosen. Now, the goal is to choose some edges of this graph such that each vertex in $B$ is adjacent to at m...
Problem: we have an undirected graph. Each vertex $v$ has a weight of $w_v$. For each vertex $v$, a nonnegative number $a_v$ is given, and for each edge $e$, a nonnegative number $b_e$ is given. We call an edge "activated" if both of its endpoints are chosen. Now, we want to choose a maximum weighted set of vertic...
I want to prove that a problem is in NP. I have a witness (of polynomial size), and a verifier that runs in polynomial time. However, this verifier uses exponential space, becuase it has to generate strings of exponential size. Is this allowed?
The book "Introduction to Information Retrieval" talks about term-document incidence matrix for retrieving documents that contain/not-contain certain tokens drawn from a query. This representation naturally lends itself to retrieving documents in response to a query. However, considering the document-term [boolean] inc...
Show that the second smallest of $n$ elements can be found with $n+\lceil\lg n\rceil-2$ comparisons in the worst case. (Hint: Also find the smallest element.) [1] I tried but I have no idea how to, e.g. the best I could do is //assume n>=2 //A: array of size n //returns second smallest in A //0 indexing in C++ int...
We have a bipartite graph with parts $A$ and $B$, and it is edge weighted. We have some constraints for part $B$. Each constraint is in this format: Between vertices $b_1$ and $b_2$ both from part $B$, at most one of them can be matched. The goal is to find the maximum weighted matching which qualifies these constraint...
Given that $L∈\textrm{P}$, how do we show that an arbitrary subset $L_{A}$ of $L$ is also in P?
How to use importance sampling identity to obtain the Chernoff bounds as given below? Let X have moment generating function $\phi(t)= E[e^{tX}]$. Then, for any c > 0 , $P[X\geq c ]\leq e^{-tc} \phi(t), \text{if t > 0}$ $P[X \leq c]\leq e^{-tc}\phi(t), \text{if t<0} $ Solution: Here's an example of using the importance...
TL;DR I have some ideas but am curious to know if there are existing proofs, research, etc. in this area that I can use to guide my algorithm development. Problem summary We have a population where each sample has attributes, or tags, associated with it. The cardinality of the tag set is unbounded, but if it helps, we ...
Following a previous post on the cs stack exchange (link to question), I have been searching to no avail for an implementation of a disjunctive programming solver in C# (or wrapped in C#). In this question, I'll go into more depth in regards to my specific problem in case there is a better solution. I am looking for an...
How can I create a DFA that has memory such that I could write a rule for this DFA that states transition to state B after transitioning from state A at some point (doesn't matter when. Could have been the last state or 5 states ago). I'm not even sure if creating a DFA like this is possible, hence why I'm asking here....
I'm confused on how to prove the below using induction: T(n) = 3T(n/9) + √n I have been given the base case T(1) = 1. I know using the master theorem that the time complexity is O(√n log n). However, when trying to find the inductive hypothesis (function form) of the recurrence by substituting k = 0, 1, 2, 3... into T(...
I need help with this task, so if anyone is willing to help me, I would be grateful. The task is: Given a discrete information source that generates symbols from the set {M,A,$} with probabilities {0,4;0,4;0,2} respectively. a) Determine the entropy of the source. What is the minimum mean length of lossless code words ...
First of all, obviously there is a flaw in my logic and I just want to know what it is. So here is my idea: Given a TM M and an input string ω, simulate M on ω on another TM S. For every change of state on M record the TM's configuration. On all iterations compare the new configuration to every other recorded configura...
The following theorem was proven by R.E. Tarjan in 1984: Theorem (Sequential Access Theorem). If we access each of the nodes of an arbitrary initial tree once, in symmetric order, the total time spent is $O(n)$ But if we remove the smallest element one at a time, then does it imply that we sorted the element in $O(n)...
Is it valid to have the token split up, in a parser; as shown in the below grammar: expr -> expr addop term term -> term mulop factor factor -> factor digit | digit addop -> + | - mulop -> * | / digit -> 0 | 1 | ... | 9 Say, for the arithmetic expression: 12 + 7 * 45 / 9 - 6 + 5 for the input: 12, the spl...
Is it correct to state that the below grammar can handle the expression: a - b * c, by the below two different parse trees. Grammar: Expression = Expression "-" Expression | Expression "*" Expression | Factor Factor = "a" | "b" | "c" Parse tree #1: Expression -> Expression - Expression => Factor - Expression => a -...
let n = 1 in let plus_and_print x = print (x + n) in let incrementBy2_and_print a = let n = n + 2 in plus_and_print n in (* Notice: arg a of incrementBy2_and_print is not used *) let n = 100 in (plus_and_print 5; let n = 40 in (incrementBy2_and_print 0; print n)) I would like to know what would be the output for...
I am reading this paper on RSA attacks and it describes the equation where ed = 1 mod φ(N) This confuses me because wouldn’t 1 mod of anything (not 1) just always be equal to 1?
$\{a^{2n}b^{n+k+1}a^k ∈ \{a, b\}^∗ \mid n \ge 0, k \ge 0\}$
Facing confusion due to two different texts stating different ways to show examples of ambiguous grammar, though the example exists in the first book. The second book gives a different example, as shown . The first text is: Compliers and Compiler Generators An Introduction With C++, by Patrick D. Terry. The second is t...
Since circuits and processors are heavily influenced and designed based upon boolean logic, which is itself a subset of propositional logic, could there be different interpretations of hardware or software based on another logic, like linear temporal logic or a description logic? I mean, for example, could it be possib...
(An isogram is a word in which no letters repeat.) I'd like to know if there's a standard name for this problem, and/or any standard algorithms. If not, I'm interested in whether anyone has any ideas about how to solve it efficiently. Input. A list $X$ of $n$-many isograms. Output. An isogram $y$. A list $P$ of $(n-...
Let $G$ be a graph. Toughness is defined as $$ t(G)=\min _S \frac{|S|}{c(G-S)} $$ where $c$ is the number of connected components and the minimum is taken over all vertex cuts $S$ of $G$ (Graph toughness was first introduced by Václav Chvátal (1973)). A graph is $l$-tough if $t(G)\ge l$. Testing whether a graph is q-to...
Imagine there are n children, and they are divided into three separate rooms (Room A, Room B, Room C) without knowing how many children are in each room. As before, their foreheads are marked with either red or blue mud, but now the father also adds a third color, green. Furthermore, some children are wearing glasses t...
Consider this problem: We want to mark some integer numbers such that we mark the minimum number of the numbers and satisfy some constraints. Each constraint wants that at least $k$ numbers in interval $[i,j]$ should be marked such that $i \leq j$ and $k \leq j-i+1$. Is this problem NP-HARD? If yes, please prove it. If...
I have read that pure Aloha's vulnerable time is 2*transmission time. But shouldn't it also include propagation time? What if a frame is propagating in media and gets collided with another frame (transmission of frame is completed)?
I am trying to find a resource which explains how to compute the constrained Delaunay triangulation of a set of points and edge constraints, I found these slides by Jonathan Shewchuck, but without the presenter it's hard to follow. Ideally I am looking for a strategy that only involves edge flipping, without the need f...
I need help with this problem, so if anyone is willing to help me, I would be grateful. How can I return the Hamming sequence that has been encoded to the initial sequence? For example, I have the sequence 111101000010, how to return it to the starting sequence, it is Hamming code (12,8)? I'm not asking for someone to ...
I have a table of fixed positive integer values of anything up to several dozen. There are six columns and several hundred rows. I must choose exactly two values from each column, and zero or one value from each row, for a total of twelve cells selected. Having chosen them, their values are summed for a total score....
Is this a minimal overfitting or like unpresensitive train dataset? However, I read it on the net but still have a problem with the graph! And then I read the following text on the net and again I asked myself is it an unpresensitive validation dataset isn't it? "An unrepresentative validation dataset means that the va...
I need to create a parity-check matrix, H, for a MET-LDPC code. I know that H will still be two-dimensional and have only 0s and 1's, just like "normal" LDPC codes. I am aware of the modified degree distribution functions (because of the multiple edge types). How do I translate the two degree distribution functions to ...
Manders and Adleman showed that it is NP-complete to decide given integers $a, b, c \geq 0$ in binary encoding whether $ax^2 + by = c$ has a solution over the non-negative integers. What is known about the complexity of deciding whether $a\binom{x}{2} +by = c$ has a solution? Here, $\binom{x}{2} = \frac12 x(x-1)$ is th...
I was going through the Wikipedia page on Quines and did not understand this paragraph - A quine is a fixed point of an execution environment, when the execution environment is viewed as a function transforming programs into their outputs. Quines are possible in any Turing-complete programming language, as a direct co...
My laptop started doing this recently It does this sometimes when I wake it from sleep /standby. It just restarts. And sometimes when I turn it on (from having it properly shut down the day before). In both cases the device restarts (since the uptime resets) and a kernel power error gets logged in the event viewer unde...
Consider a raster image representing a elevation map $$ z = f(x, y) $$ An "extended lake" $L$ is the largest domain such that the elevation of every point $\partial L$ is greater than the elevation of any point within $L$. The outflow $P$ is the point on $\partial L$ with the lowest elevation. I came up with the follow...
Problem: There are L lists of positive integers, say L_0, L_1, L_2 ... L_|L|-1. The lists have equal length. There is a target number T. Find what is the combination of elements, one element from each list, whose average is the closest to T. Example: L_0 = [10, 20, 15] L_1 = [9000, 400, 550] L_2 = [1, 2, 3] L_3 = [700,...
I read that in dynamic linking we store the references to the the methods of the library , but a library is essentially a collection of files , and every file will have some code in it , so the reference is stored of which file?
I have multiple (possibly concave) simple polygons, and need to compute the union and difference of them, some polygons have to be added, some subtracted from the final shape. I have found algorithms that can compute the intersection andthe difference of 2 polygons, but because they can produce multiple polygons simply...
SELECT(A,p,r,i) is an algorithm that partitions $A[p:r]$ around the $i$ th order statistic ie. in the output, we have $l\in A[p:p+i-2]<A[p+i-1]< h\in A[p+i:r]$. Where $A[p+i-1]$ is the $i\in \{1,...,r-p+1\}$ order statistic (basically the $i$ th smallest element). returns the $i$ th order statistic worst case run ...
Heap's Algorithm enumerates the permutations of a set of N objects. It's described as: Permute the elements in positions 1 to n−1 by applying this algorithm to those elements. Apply the following steps n−1 times. Increment counter i=1 after each iteration. Swap element in position n with one of the other elements in ...
if we change the halts to do_not_halt() function, it works, so how can this be a proof? def g(): if halts(g): loop_forever() if we change the halts to do_not_halt() function, it works, so how can this be a proof?
Suppose I write an algorithm to perform a computation but I get the intuition that my algorithm is a bit too long, however, it is not immediately obvious to me what a shorter algorithm might be. Is there a way for me to prove the (non-)existence of a shorter algorithm that performs that task - without necessarily havin...
I am looking for an algorithm that allows me to roughly balance items that are grouped into groups with random sizes between n elements in a consistent manner. Consider the following example: There are n persons. There are x hosts. There are y customers. A random amount z of hosts belong to each customer where z is >= ...
I made this problem up in my head, and I'm looking for a solution. I realized that it's a very interesting problem, and I'm way too dumb to solve it, so I'm asking for help. The problem Given a 'desired canvas', which is a grid of colors (let's say an 8 by 8, because it's easy to work with). And given a list of unique ...
So I was reading the Hoare's partition part of the Quicksort wiki and it says: "With respect to this original description, implementations often make minor but important variations. Notably, the scheme as presented below includes elements equal to the pivot among the candidates for an inversion (so "greater than or equ...
I need a list of at least 10 weakly NP-HARD problems. I already know the Knapsack problem, partition problem and subset sum problem. Please introduce other weakly NP-hard problems to me.
I want to efficiently generate partial permutations. That is, I want to generate the set of ordered arrangements of K distinct elements selected from a set from N items. For example, with the set ABCDE where N=5, if K=2, then the partial permutation set is AB, AC, AD, AE, BA, BC, BD, BE, CA, CB, CD, CE, DA, DB, DC, DE,...
I have computed a constrained triangulation of a set of points. The constraint happens to be a closed polygon. The objective is to detect all edges which are inside the polygon, that is, an edge where both endpoints are points in the polygon and for which all interior points are inside the area of the polygon. A hacky ...
I just saw this Youtube link about a voice controller module that can recognize some sentences and perform an action. So what's the math behind this? Is it Support Vector Machine, Deep Neural Networks, MFCC, PCA, LDA? Or non of them?
I am trying to find resources that explain an easy to implement (not necessarily optimal but reasonable runtime) algorithm for inserting Steiner points in a triangulation. There seems to be little literature on the topic. My understanding is that different people pick different criteria to optimize, some pick triangle...
Looking through old exams I found a problem stated as the following: Define a 0L-system as a 3-tuple $S = (\Sigma, w, h)$ where $\Sigma$ is an alphabet, $h:\Sigma^* \to \Sigma^*$ is a homomorphism and $w \in \Sigma^*$ is a starting word. Furthermore define $L(S) = \{w,h(w),h(h(w)),...\}$ and define $L$ as a 0L-languag...
Let: be given by Compute Boolean formulas for the following: This is part of my coursework; I have the answers but can't understand them. I want to develop some intuition on how I can solve these or a general framework on how I can approach them. Some guidance on resources is also appreciated. And sorry I couldn't f...
While Time Complexity is the measure of how an algorithm scales with respect to input size, Space Complexity on the other hand measures how much the memory scales as input changes. I see programmers pre-dominantly using these 2 metrics but are there any other generic measures/metrics for comparing the efficiency...
I have modified Busy Beaver Turing Machine scenario. Is this new scenario equivalent to the standard one? Consider a double sided tape twisted it into a mobius strip having P slots in total. Initially all zeros on the slots. Consider two adjacent slots. We define a Mobius Busy Beaver number which is the sum total of ri...
i tried calculating time complexity for this code: the answer i got is n since the the space complexity is logn and i calculated the sum of geometric sequence with q=4 and n=logn. but apparently its sqrt(n) can someone explain why?
Task. Find such natural numbers a1,. . . , am , that none of them would be included in the list of excluded numbers, a1 + · · · + am = N and max{a1 , . . . , am} would be as small as possible. Numbers cannot be reused. Initial data. The first line contains two natural numbers N and K - desired sum and length of exclude...
I've been looking for an algorithm which divides an undirected graph into 2 subgraphs. However, unlike most existing work on graph partitioning out there (like METIS), I don't intend to obtain subgraphs that contain the same approximate number of vertices. Instead, I would like these 2 subgraphs to have similar count o...
I have this tiny program for finding largest prime divisor (taken from Code Review Stackexchange and written by user Altinak: https://codereview.stackexchange.com/a/74792): Here is my try to write it in pseudocode: GLOBAL VARIABLE highest; // This function takes parameters n and f with 1 <= n and 2 <= f. // It return...
In the following video on computer organization: https://youtu.be/DoR505t8-7I?t=114 the instructor displays the following: and says that the hex string 0xFFFFFF00 is equivalent to -256. After doing a calculation to see this represented in two's complement, this makes sense to me. For my question below it'll help to ...
I tested my XSAT solver using the 4 pigeons in 3 holes problem converted to XSAT. The pigeon hole instance I give below had 108 variables and 88 clauses after being converted to monotone XSAT. My solver quickly proved the instance was unsatisfiable. While converting the proof back to SAT I realized some of the reductio...
We had this problem on our Algorithms final. It threw me off because if $\log$ is $\log_2$ then graphing the function shows this is not true, but if $\log$ is $\log_{10}$ then it looks like it is. How can this idea be formalised?
Since I know that the reduction Clique $\leq_{p}$ Vertex-Cover and Vertex-Cover $\leq_{p}$ Set-Cover are possible, I know how to show this using transitivity property of reductions. However is there a direct reduction from Clique to Set-Cover problem possible ? I have not found any reductions on this in the internet. ...
I wondered if, for a fixed integer $k ≥ 3$, how can I construct a circuit for each $n \in \mathbb{N}$, that takes as input an n-bit integer $x$ and outputs whether 3 divides $k$? Considering an n-bit integer as input: e.g. $\ldots10101110$, where $a_0$ is the rightmost bit and $a_N$ the leftmost bit, $\bmod 3$ has a cy...
A monad is an endofunctor $T:C\rightarrow C$ with natural transformations $\eta:id_C\rightarrow T$ and $\mu:T^2\rightarrow T$. Being natural transformations mean that $$T(f)\circ \eta_A = \eta_B\circ id_C(f)$$ should hold and $$T(f)\circ\mu_A = \mu_B\circ T^2(f)$$ also. These are the algebraic expressions that the defi...
As a cryptographic primitive, universal hashing should have somewhat a criterion on its security. How is its (computational) security defined? Or, in other words, what "breaks" a universal hashing?
The language $L_1 = \{ a^nb^nc^n \}$ is often given as an example of a context-sensitive language. I am wondering if the language $L_2 = \{ a^nb^na^n \}$ belongs also to the same category?
I found this question in one of our past exams, and I'm not to sure about the correct answer. I have a language L1 (which i don't know anything about) and another language L2, which is regular, the question is: given that L1L2, L2L1 are regular can i also say for sure that L1 is regular? At first my answer was no, sinc...
It's given that the bandwidth-delay product defines the number of bits that can fill the link; while the sender can send (1+(2 * Bandwidth * Delay)) units before getting acknowledged for the first unit. Can anyone help me to realize the practical implication the phenomenon of filling the link will imply? What can be th...
I’m interested in substitution systems: maps which use a set of rules to transform elements of a sequence into a new sequence. For simplicity we will consider here only binary 1-D arrays. Unlike the Wolfram language definition, I suppose that LHS of rule may be any length. So a set of rules like [[0] → [1, 0], [1, 1] →...
I have the task to write a program that puts students in classes and that in the best possible way. We have given the name, the foreign language a student chooses(french or latin), a profile (Music,bilingual or normal) and 2 friends and enemys for every student in a table. A friend is someone a student should be in a c...
As I understand that a video file is a binary file, the frames are not really present in a contiguous manner in a video file, so reading the video file by doing a seek and reading it frame by frame wouldn't work until you have loaded the entire file into memory and then go through it frame by frame. But if you see any...
Statement of problem We have two sets of vertices, $V$ and $U$, each of which has a vector of attributes $A$. The set of edges $E$ is defined such that there is an edge $vu\in{E}$ between vertices $v$ with attributes $[a_1,a_2,...]$ and $u$ with attributes $[a'_1,a'_2,...]$ IFF a function $f([a_1,a_2,...],[a'_1,a'_2,.....
It's common in machine learning papers to see things like $p(x,z|\theta)$ or $p(x|z)$. Where $x$ is usually the data vector, $z$ the latent vector and $\theta$ the model parameter, like network weights. However is there a way to make sense of these notations from measure theory's perspective? Perhaps $(x,z,\theta)$ is ...
If I understand correctly, the first incompleteness theorem says that any "effectively axiomatized" formal system which is consistent must contain theorems which are independent of the axioms. In other words, there are models of the system where the theorem is provably true and others where it's provably false. This s...
We are given an array of length $N$ and $Q$ queries (offline) where each query is a value $K$, for each query we need to count number of pairs in array with XOR $K$. If $N$ and $Q$ can both be upto $10^5$, is it possible to answer these queries better than traversing entire array for each query? An analogous version to...
I'm reading a paper that involves an algorithm for RSGD. It's clearly a form of stochastic gradient descent, but I can't find what the R stands for. The authors provide their own implementation of it, and I would like to find its original formulation to compare.
How can I prove that BPP is close to Symmetric difference? I tried to find proof online but couldn't. Can anyone please provide a quick explanation (if it's trivial and I just can't see it) or a link to proof?
I am a math undergrad and we have algorithms as one of our courses. We came across TSP and algos to solve them. I thought of an algorithm and apparently its already known as the Nearest Neighbour algorithm. Could anyone tell why it might lead to longer tours with instances (short numerical examples maybe) ? Thanks in a...
For context, yesterday I posted Does the first incompleteness theorem imply that any Turing complete programming language must have undefined behavior?. Part of what prompted me to ask that question in the first place is that, awhile ago, someone on the learnprogramming subreddit told me something about the reason C++...
Recent research work has shown that transductive learning/inference outperforms standard methods that were used before, where people embed features in a high dimensional space and then use the distance metric in that space to classify objects. This has been found in few-shot learning, other metric learning works, etc. ...
I want to relate Turing completeness to the Halting Problem. As far as I know we say something is turing complete (eg: a programming language) when it can compute any function and can do any task. But since Halting Problem can't be solved by any programming language so every programming language should be Turing Incomp...
According to the book " Operating Systems Concepts " , 9th edition, page 637, we have the following statement : Rather than associating the columns of the access matrix with the objects as access lists, we can associate each row with its domain. A capability list for a domain is a list of objects together with the ope...
I believe its true but struggle to prove. I know NP=union over positive c's of RP(2^-(n^c)) and from here to prove that RP(1/2^n) contained in NP is immediate. the other side is the problem. I've tried the following: Given L in NP and a polynomial verifier V for L with polynomial P, to use a random Turing machine M. M,...
I have a confusion related the Lemma 22.1 in Cormen Leiserson Rivest Stein's Introduction to Algorithm book, Here it is written that delta(s,v) <= delta(s,u) +1 ,where s,u,v are the vertices of a graph G My question is why <= is used ? Won't that be = only ? I am learning Algorithms and Data Structures.