instruction stringlengths 35 11.4k |
|---|
I am not sure what problem may reduce to $3$-Spanning-Tree where $3$-Spanning-Tree is defined as a decision problem which given an undirected graph $G$ determines if there is a spanning tree of $G$ in which every vertex has degree no larger than $3$.
I have already done this for $2$-Spanning-Tree using a reduction from... |
There is a theorem that states that if A is polynomially reducible to B and B is in P, then A will be in P.
Now, would that hold for NP problems?
Simply, since coming out with verifiers all the time might be a longer/trickier task if there is a actually an easier way to to prove something is in NP.
|
There is paper which expresses lambda terms in the terms of logic programming http://www.cse.unt.edu/~tarau/teaching/PL/docs/dbx.pdf Is there conversion in the other direction - expressing definite clauses / Horn rules / logic programming sentences using the lambda terms and type calculus?
This question has the followi... |
I am trying to understand how computers work under the hood, and I came across following sentence.
"Computer technology is based on electronic circuits able to process vectors of 0's and 1's. For that reason all data are encoded by strings of 0's and 1's."
So does the vector mean normal string/number 0 and 1?
Thank yo... |
I was studying the chapter 24 of the CLRS and got to the following question:
24.1-5 $\star$ Let $G=(V,E)$ be a weighted, directed graph with weight function $w : E \rightarrow \mathbb{R}$. Give an $O(VE)$-time
algorithm to find, for each vertex $v \in V$, the value $\delta^{*}(v) = \min_{u \in V}\{\delta(u,v)\}$.
F... |
I have a question about predication and branch prediction.
I've emailed my professor regarding this and he replied me that predication has a less instructions than branch prediction.
So I tried making an example of my on but I'm not sure if this is right..
I've assumed for predication it has 'if' and 'else' each having... |
Let Program P be :"Generate, in lexicographic order, all sequences with k ones and n bit length;
Of these sequences, print the ith sequence."
Apparently the length of this program is $\log(n) + \log(\binom{n}{k}) + c$ where $c$ is a constant. Where $i$ can be represented in $\log(n)$ bits and
k in $\log(\binom{n}{k})$... |
how to use substitute algorithm to prove T(n) =4T(n/2) + n^2 compact lower bound.
this is a algorithm of my class home work,but i dont know how to solve it.
|
(x >= 0 && y >= 0)
q = 0;
r = x;
while ( r >=y ) {
r = r - y;
q = q + 1;
}
(x = q*y +r) && (r >= 0) && (r < y)
For this what if y = 0 ?
If y = 0, then r stays at r inside the while loop, which makes r >= y true always. So it doesn't seem to terminate.
So I think, for pre-condition, doesn't it have to be (y > 0)... |
I am just starting to study Java and was wondering why the following code
if(x>2) x*=2;
if(x>4)x=0;
System.out.println(x);
returns 0 for any value of x greater than 2. For example, when x=3, why would 6 not be returned?
|
I have the function:
$$ f(n) =
\begin {cases}
4 & , n = 1 \\
f(\frac{n}{3}) + n^2 -3 & , n \ge2
\end {cases}
$$
The given solutions shows the unwinding of the function as follows:
Assuming $ n \ge 2$
$$f(n) = f\bigg(\frac{n}{3}\bigg) + n^2 - 3$$
$$ = \bigg[f\bigg(\frac{n}{3}\bigg) + \bigg(\frac{n}{3}\bigg)^2 -3\bigg]... |
Wondering if there is a way to convert a binary tree into a grid such as this:
a
/ \
b c
/ \ / \
d e f g
or
d--b--e
|
a
|... |
I am simplifying a big formula to find the big notation of a certain algorithm. The expression is:
$$\log_2(1-l)/\log_2(1-2^{nH(m/n)-n})$$
where $0.98<l< 1$, $0<m<n/2$, $n>0$ and $H$ is the binary entropy function.
In practice, I known that the algorithm is exponential, but I do not known how simplify that to get the ... |
I need to find average number of recursive calls in quick-sort with array of length 2. I established and solved the following recursion:
$$T_N = \frac{1}{N}\sum_{k=1}^N\left(T_{k-1}+N_{N-k}\right) = \frac{N+1}{N}T_{N-1} = \frac{N+1}{3}.$$
Where $T_0 = T_1 = 0, T_2 = 1$. But:
\begin{align*}
T_3 &= 1/3(1 + 1) &= 2/3\\
T_... |
Sipser in his book provided the following proof for undecidability of REGULAR$_{TM}$:
S = “On input $<M,w>$, where $M$ is a TM and w is a string:
Construct the following TM $M_2$.
$M_2$= “On input $x$:
If $x$ has the form $0^n1^n$, accept .
If $x $ does not have this form, run $M$ on input $w$ and
accept if $M$ a... |
i have been solving the Time-Dependent Traveling Salesman Problem using
an Ant Colony Optimization.
Upon reading the ACO papers, there are several reminders which state
that ACO performs best with daemon actions - improvement heuristics.
In the classical TSP, the most common improvement heuristic used is the k-opt exc... |
I have the impression that for every NP-complete problem, for infinitely many input sizes $n$, the number of yes-instances over all possible inputs of size $n$, is (at least) exponential in $n$.
Is this true? Can it be proven (probably only under the assumption that $P\neq NP$)? Or can we, maybe artificially, find a pr... |
Theoretically, Hoare-Logic let's one prove the correctness of an algorithm, given pre- and post-condition.
However, as far as I've seen it so far, one idealizes his data-types to a mathematical set like $\mathbb{N}$ or $\mathbb{R}$.
So, even though the logic might be sound in Hoare-calculus, the discrepancies between ... |
The PCP theorem characterizes NP as the class of problems checkable probabilistically using log(n) bits and a constant number of random bits and yields $NP=PCP(O(log(n)),O(1))$ .
Is there a pair $(f,g)$ of functions such that $P=PCP(O(f(n)),O(g(n))$ where $g(n) \ne 0$? Or is there any research in that direction or an ... |
Let's say we have given weighted tree of size $n$ and list of important nodes in the tree $k$.
We want to choose subset of edges of the tree such that:
For each two important nodes at least one edge of the path between them will be choosen
The sum of the subset of edges will be minimized
Note that we only need to fin... |
How to generate a numeric or string id(not very large text) for a sequence of elements where ordering doesn't matter.
Example:
[41,1001,32] should generate the same ID as [32,1001,41]
[41,1001,32, 5] should be different.
Elements could be hundreds where each individual ID can be a 4/5-digit number.
I thought about... |
Specifically, many say that to speed up an HTTP routing code going from regex to a Trie is the solution. Sometimes also a compressed Trie or Radix Tree.
The problem though is that after reading everything I think I could read from Wikipedia to blog articles and even Stack Exchange answers I couldn't wrap my head on ho... |
I found that there are algorithms like VFlib and LAD filtering for subgraph isomorphism with one edge type. For multiple node types,one idea could be color all node types with the same type and use colored sub-graph isomorphism which is available for VFlib. I was wondering is there any algo specifically for multiple ed... |
Specifically when it comes to R-Type instructions, the format is
operand, sR1, sR2, dR
where sR1, sR2 are source registers and dR is the destination register.
What I don't understand is why the operation
ADD, R1, R2, R3
results in the sum of R2 and R3 being stored in R1. If R1 and R2 are the 'source registers' then... |
Given an array $A$, find the number of pairs $(i, j)$, such that $ i > j$ and $A[i] \ge A[j]$.
This is a modified version of the famous problem of Counting Inversions, only in this version it allows the elements to be equal as well. I have an algorithm for the classical counting inversions problem implemented, so i´d... |
I have a system which uses segmented paging. Every address is divided as follows:
(s,p,d) = 2,2,11. Main memory has a capacity of 32KB. There are 4 segments which have 4 virtual pages each. I have to find the number of physical and virtual pages. For the virtual pages i suppose that the answer is 16 because every segm... |
We know that $EXPTIME ⊆ NEXPTIME ⊆ EXPSPACE$, where $EXPSPACE = DSPACE(2^{poly(n)})$.
Question: Is known any consequences of $EXPTIME \neq EXPSPACE$?
(nothing in complexity zoo or wikipedia)
|
Does $P=NP$ implies $3SAT$ reduces to $2SAT$?
If so then from $2SAT$ is $NL$-complete can we conclude $NP=NL$?
|
We are currently developing an ilp/milp model to fit the best routes with given resources (people) in a given timeframe and given visits and costs to travel from one visit to another (asymetrical).
We went with a very simple aproach (make a cube person x visit x Time and add constraints from here on). Our solution work... |
I am trying to understand basic concepts such as MIPS rate, frequency, CPI etc.
But I am having some trouble understanding the details.
For example suppose a processor designer builds a processor with frequncy 200 kHz and furthermore let's suppose that the processor has MIPS of 0.2. In what ways can that design be acco... |
The stack seems to be an optimization of memory use for a specific application. Whereas the heap is a general model that works in all cases. Wondering if there are any other types of models of computer memory allocation that are optimized for different use cases.
Following from this:
https://softwareengineering.stackex... |
I am a little confused on how to approach this problem. I am unsure how to construct both parts of the grammar using a context-free grammar.
This is as far as I got, but this will end up producing a's inside of the group of b's and a's. I'm not sure how to add the second group of a's to the right of the b's.
$S \right... |
Tendermint Consensus is resilient for up to 1/3 of Byzantine participants.
Question: What actually happens after when the network hits the threshold of byzantine actors? Forking happens? Does transaction fails for honest nodes?
Similarly, for all the BFT/PBFT consensus algorithm, what happens after when the network hi... |
I'm asking because it seems that P problems refer to decision problems rather than actually propose a solution.
|
Below is a paragraph from a book.
In an ordinary superscalar processor, we would use branch prediction to guess which of the given instructions is to be executed, and go down that path. If the processor guesses wrong, the pipeline must be flushed.
Predication execute all of instructions and once the values of the pred... |
I've been studying the low-level hardware implementations of floating point numbers and doing an exercise to design a custom floating point implementation.
I know that being able to represent negative zero is important for some purposes, but ran across a curious question.
Complex numbers are generally represented by tw... |
In a Operating System, who decides which parts of a program (or task) has to be stored in the virtual memory and which in the RAM ?
|
This is an attempt to understand better recursion.
The following recursive function returns the integer obtained by reversing the digits of an input integer. I'm trying to prove its correctness:
public static int reverse(int n)
{
return reverse(n, 0);
}
public static int reverse(int number, int reverted)
{
if (... |
I've been back and forth about this one. I have the following theoretical homework problem, which describes the SET-INTERSECTION problem. In my homework, it's presented as being NP-complete.
Does this problem have a more common name in general Computer Science nomenclature? I'm trying to wrap my head around the defini... |
I have a fully-connected graph $G=(V,E)$ with edge weights $w(v)\in\mathbb{R};v\in V$ and I need to find a spanning tree $T=(V_t\subseteq V,E_t\subseteq E)$ where the set of edge weights in the tree have as close as possible to equal separation. We quantify the notion of equal separation by minimizing the variance of d... |
Given the following:
"You are organizing a party and you want it to be as much fun as possible.
You have $n$ friends to choose from, but the maximum number of people that you can invite into your flat — its capacity — is $C$. The fun at a party stems from pairwise interactions between guests, and you have the an $n \ti... |
Given a directed acyclic graph with $n$ nodes labeled from $1$ to $n$, what is an efficient way to produce the unique topological ordering with lower labeled nodes prioritized over higher labeled?
In other words: in the ordering the node labeled $1$ appears as early as possible, and if there are many such orders, amon... |
Are there scientific papers that compare distributed systems and big data processing systems?
Big data processing systems can be batch processing systems or streaming big data processing systems.
A batch big data system is a distributed system that:
loads data into the system from relational databases, log files or ot... |
I'm trying to learn buddy allocation and whilst I think I understand the basics of it, there is one problem exercise with which I'm struggling with.
So I have an 8K block and I'm using buddy allocation trying to always allocate to the leftmost free memory area.. and I need to allocate a 5K memory block.
Do I split the... |
Problem:
Given a matrix, find the length of the longest increasing path. We can move up, down, left, or right.
Example:
$$
\begin{pmatrix}
1&2&3&4\\2&2&3&4\\3&2&3&4\\4&5&6&7
\end{pmatrix}
$$
Output: 7
Longest path is 1, 2, 3, 4, 5, 6, 7
Question:
I am not sure if this post is relevant to this site. I having some troubl... |
I'm struggling to understand why this function is computable.
This is the requirement:
Consider the following program P, written in a pseudo-C language:
P:
{
int x, y, z;
read (x, y, z);
while (x != y)
{
x = x - y;
z = z + y;
}
write z;
}
Let $f(x, y, z)$ be the func... |
I have some questions about energy emitted when one bit of information is processed.
Landauer's principle states the minimum possible amount of energy required to erase one bit of information is k T ln2
Considering this,
How this formula is found? In terms of energy and memory unit, what is the processing cost per bit... |
I'm wondering if algorithms described in:
https://ieeexplore.ieee.org/abstract/document/7782946/
http://drops.dagstuhl.de/opus/volltexte/2014/4845/
easy to implement. They seem to mention the word "simple" but I'm not sure if this is all just theoretical play of "who's going to find the best $O$", or if this can be imp... |
Given two large sets (say 1 million items each), what is the fastest way to compare the values with each other.
This is a typical join problem, for which there are two standard solutions:
nested loop join
hash join
The nested loop is naive because it compares every value to every other value. This makes it slower tha... |
I'd like to know how clock synchronization is done on computers, I've read this wikipedia article however it didn't give me exactly what I was looking for, I'll outline the problem I'd like answered:
My computer has the current time stored inside it which is maintained by a clock however this clock is subject to clock ... |
What would be the solution of the following recurrence?
$$T(n) = 2T(n-2) + n\log n.$$
I've managed to get:
$$T(n) = 2^{n/2}T(0)+\sum_{i=0}^{n/2} 2^i (n-2i) \log(n-2i). $$
The sum cannot be easily bounded for estimating the recurrence, because part of it increases while the other part decreases as the index grows.
|
I am trying to understand the space and time Hierarchy theorems according to
Sanjeev Arora, Boaz Barak: Computational Complexity: A Modern Approach
but the more general case.
What I don't understand is why the language decided by our custom machine is in the larger complexity class. For example, with the case of ti... |
Most of the resources on the web I have encountered say that "sorted arrays and other sorted data structures are implemented with binary search trees (BSTs)".
Even though B-trees are a generalization of BSTs, I have not seen much of anything say they are used to create ordered data structures. Wondering if programming ... |
I would like to understand the basics of how traffic light scheduling works. Looking through research papers the topics typically revolve around actual highway systems in urban areas, but also includes managing information routing in wireless networks, and a few other areas. They also seem to be modeled similar to how ... |
Is there a faster algorithm to merge two sorted linked lists where one is guaranteed to be much larger than the other?
By merging two sorted lists I mean taking two sorted lists $A$ and $B$ and producing a new list that contains all the elements of $A$ and $B$ and is sorted itself.
The typical solution, which Wikipedia... |
Assuming I have a schema depicted in the image , showing relationships(specialization) between Staffs, Academic Staffs and Non Academic Staffs. Is it possible to have a query that retrieves the department and level if the staff is an academic staff or state and unit if it is a non academic staff based on type attribute... |
Is it possible to use the Bentley-Ottmann algorithm with a mixture of allowed segment types, say, line segments and arcs?
The same question could be asked for Balaban's algorithm but it's gonna be for an other time.
http://www.dtic.mil/dtic/tr/fulltext/u2/a058768.pdf
|
I have one question for which I don't know any good solution (and my solution doesn't satisfy constraints). Namely, on one of the interviews i got problem like this:
Determine the minimum possible height of the binary tree, if you could
remove numNodes leaf nodes from the tree (where after removal of all leaf child... |
I'm trying to come up with a data structure that could access, insert, and delete any element in constant time. I know that's pretty difficult, but I'm just doing it to invoke thought and understanding about computer science. However, I'm starting to question whether it is even possible.
My theory is: For access to be... |
The k bit subset sum problem is:
Input:
$(S, k, b)$ where $S$ is multi set of positive integers encoded in binary (base 2), $k$ is also positive integer encoded in binary (base 2) and $b$ is bit (binary digit) so that always $b\in\{0,1\}$.
Output:
True if exists subset sum of $S$ whose $k$ bit (binary digit) equals to ... |
I am trying to demonstrate the following idea without success.
There are infinitely many $n \in \mathbb{N}$ such that: There is a
non-deterministic Buchi automata of size $n$ such that a deterministic Rabin Automata
accepting the same language has at least $n!$ states.
Any help would be appreciated
|
So I was practicing optimal alignment algorithm and I was stuck with this question of finding optimal alignment for a string of length m with a string length n ? Also is it possible to run it in theta(n) times. Can anyone help me with this?
|
I was interested in learning more about program induction and program synthesis. I was especially interested in learning about how to form program from data for example. My background is in traditional ML+Neural Nets so I have no idea were to start...I am familiar with Program Sythesis by Sketching but beyond that don'... |
I am with the following question, because I do not know if what the following paragraph indicates:
Does this refer to this image?
Maybe to this other?
If not, tell me what you are referring to please. Thanks in advance
|
I have a research paper, Elastic image matching is NP-complete by Daniel Keysers and Walter Unger, that illustrates the reduction from 3-SAT to an image matching problem in order to prove that this problem is NP-Complete. It says that from 3-SAT formula we construct an equivalent image matching problem using a cost fu... |
Let's suppose that I have a big digraph D and a small tree T (small w.r.t D), both directed, D can be connected or not, but T is connected.
Here an example:
Let's say that D is as follow:
And T is the following tree:
So I would like to identify the nodes and edges in D that can potentially match with T. In other word... |
In Arora's paper, he wrote,
Papadimitriou and Yannakakis also noted that the classical style of reduction (Cook-Levin-Karp [41, 99, 85]) relies on representing a computational history by a combinatorial problem. A computational history is a very non-robust object, since even changing a bit in it can affect its correct... |
I have this language:
$$ L = \{ a^i b^j c^k : i + 1000\ < j + 100 < k \}, $$
and what I believe is that we can't prove with the Pumping Lemma that it is not context-free, because we would always be able to choose $x$ as $b$, $v$ as $b$ and $y$ as $c$. For example, suppose we have the string $a^pb^{p+1000}c^{p+10000}... |
I'm working to filter a table of pairwise names (1.1 M rows) based on string distance algorithms. Most are names, though some are businesses.
Edit-based algorithms seem to be best, however in attempting to set a cutoff value for match vs. non-match, there is an issue with the length of the string. In a 16 character st... |
I have been looking for an algorithm to calculate $e^x$ to arbitrary precision (millions of digits). The best way I know is to use Taylor polynomials. However, the Taylor polynomial algorithm seems to have no way to enhance the precision of already existing estimates of $e^x$.
For example:
I already have an exact app... |
I've been working on a problem and in order to prove the bigger picture, I need to understand how a binary OR function can be computed by a constant fan-in MOD3 gate. I would seem that the output would need to depend on every input bit as just looking at some of them would leave out the possibility that those that were... |
I have the following Question:
A speed-dating event consists of n women and n men. An event has many rounds: In a round, each woman meets one man for 5 minutes, and decides whether to go out on a real date with the man.
In the first round, 50% of the women agreed to a date, and in the second round, 40% of the women ag... |
Classification algorithms, such as k-Nearest Neighbors, are well known in machine learning area, but I faced this new expression Monotone classification and I wonder what does it stand for.
I guess that it has something to do with some peculiar characteristic of the dataset, e.g. if all the objects have growing attribu... |
There are $n$ people and $n$ items. For each person, there is a set of items he likes. Our goal is to give to each person a single item that he likes, i.e, find a perfect matching in the preference graph (encoding the "like" relation).
In some cases, this may be done using a picking sequence: order the people in a queu... |
At the moment I'm just reading through this article on the word problem for groups (https://projecteuclid.org/euclid.bams/1183548590), and I'm wondering about a certain snippet.
On page 40 the article describes a word that can encode the state of a turing machine, namely $S_{k_{u}}...S_{k_{1}}q_{i}S_{j_{1}}...S_{j_{v}}... |
It can't be solved with master method. The result seems to be T(n) = Θ (nlg lgn), but I have a problem to prove it. Could you help please?
|
Given $n$ cities, I'm looking to build a transportation system that allows travelling between every two cities.
For every two cities $i$ and $j$, a road can be paved in the cost of $c_{ij}$. Also, it is possible to establish an airport in city $i$ in the cost of $a_i$ (all costs are positive).
One can travel betwe... |
I want to express the following in relational algebra:
Given a table of
PEOPLE: ID, SocietyName
Where the combination of ID and SocietyName form a key such that we could have the same ID in the table more than once but paired with a different society name.
I would like to be able to output all pairs of people, ID1 and... |
I was introduced in concurrency programming this morning.
I haven't understood why "non deterministm" is a fundamental aspect of cuncurrenty programming.
What i think is that, since there is a scheduler (so an algorithm) i deterministicly know the order of the tasks
|
I'm studying the concurrency in programming and the atomic instructions.
What i have not understood is the concept of "fairness" applied to this matter.
Can you give me an hint ?
|
Problem:
Given $S$ — a sorted array where some of the elements were randomly changed, assuming that you're provided with an $S_1$ — an array of indexes of changed elements. Design an algorithm that will sort the array in $O(n)$ time.
Additionally, we know that $\text{length of }S_1\le\log_2(\text{length of }S)$.
Exampl... |
It is well-known that the language over $T$ with at least 2 symbols is nondeterministic. for simplicity, the language $\{ww^R: w\in\{a,b\}\}$ (even-length palindroms of $a$, $b$) is context-free, but cannot be accepted by any deterministic PDA. The idea of proof is desribed, e.g., by Hopcroft, Ulman, Motwan in 'Introdu... |
Suppose the following:
We use Dijkstra’s algorithm to find the shortest route to our destination.
The start node (current vehicle position) keeps changing, i.e. moving towards the destination along the calculated shortest path. For this reason we use the inverted form, where the cost of a node represents the cost to r... |
Karp reducibility between NP-complete problems $A$ and $B$ is defined as a polynomial-time computable function $f$ such that $a \in A$ if and only if $f(a) \in B$.
I am interested in polynomial-time invertability of Karp reductions between natural NP-complete problems.
Is it true that every Karp reduction $f$ is also ... |
In the big O section of Cracking the Coding Interview 6th edition, I read the following.
"Best, worse, and expected case describe the big O for expected inputs and scenarios."
"Big O, big omega, big theta describe the upper, lower and tighter bounds for the run-time."
I understand what best, worse, and the expected ca... |
The problem below is adapted from CLRS Problem 5-2 "Searching an unsorted array":
Consider a deterministic linear search algorithm which searches an array $A$ for $x$ in order, say $A[1], A[2], \ldots, A[n]$, until either it finds $A[i] = x$ or it reaches the end of the array. Assume that all possible permutations of ... |
Preamble
Suppose we have some symbols x, y, ... and wildcards (ξ), (ζ), ... which have any meaning. Wildcards are said to ‘match’ any symbol: wildcard (ξ) matches symbol x under the mapping {(ξ): x}. Now suppose we can construct directed trees from these symbols and wildcards. The notion of matching should extend to th... |
The diagram on the Wikipedia page of FSA shows the hierarchy of the computational devices, in that diagram it is denoted that the finite state machines are superior to the combinatorial circuits.
Combinatorial circuits are the model of propositional logic i.e. both are equivalent, where we do a discussion about the tru... |
I am interested to understand why smooth locally decodable codes were defined historically as they were (I believe it may be because they make for easier analysis in obtaining lower bounds on locally decodable codes but would like to understand exactly how). What is their advantage over locally decodable codes that do ... |
The standard resolution algorithm returns false if no new clauses are added.
I know that if $KB \land \neg a \implies []$, it returns true by proof by contradiction, but how can I understand the false case intuitively?
|
Let T be a full binary weighted tree. For a node v in T, the cost of going right is a i.e w(v, v.right) = a while w(v, v.left) = b
How do I find optimal paths to all leaves from the root. I don't think classical graph traversals are helpful in this context as I don't need to visit all nodes.
|
I heard about the following problem in a competitive programming camp:
Given an undirected weighted graph $G$ with one vertex initially.
Suppose you are given two types of queries:
Add a new vertex to $G$ with some undirected weighted edges between this vertex and subset of vertices added previously to $G$ in time com... |
I need to find a data structure that supports the following operations:
init(A): gets an array of size $n$ of different numbers and builds the data structure - should be $O(n)$.
max(i,j): gets two indexes $i<j$ and returns the maximum value between these two cells, that is, $A[i],A[i+1],\dots,A[j]$ - should be $O(\log... |
I need to construct a graph with the following properties:
$w(u, v)$ = $-w(v, u)$, for every edge $(u, v) \in E$
Weight of all $u \leadsto v$ paths is equal, for every $u, v \in V$ (this is zero weight cycle property from the title).
Weight of $s \leadsto t$ paths is maximal, for some input vertices $s$ and $t$
Yes, ... |
In the Peterson Algorithm for mutual exclusion an implicit assumption is that the operations with the shared global variables happen atomically.
To me, this is not a superficial assumption , cause it's another mutual exclusion issue .
In which way we make the operations with the shared global variables happen atomicall... |
Is there an algorithm for mutual exclusion with shared flag variables, as the Peterson's one, that doesn't prevent the starvation ?
|
so for a homework assignment i need to prove the following:
We have arbitrary languages L1⊆∑1*, L2⊆∑2*, L3⊆∑3*, L4⊆∑4*
Prove that the followging is either true or false:
If L1 ∪ L2 ⊆ L3 ∩ L4, then L1◦L2 ⊆ L3◦L4 (◦ = concatenation)
Now i know this is true, but i don't know how to approach this problem...
Any tips on poi... |
I am attempting to understand exactly how the terminology for k-approximation algorithms work, from when k is known and determining what k is.
If we assume that a vertex cover in a graph G is of size 7 and that there is a 3-approximation algorithm for finding the minimum vertex cover. Does that mean the algorithm could... |
I am attempting to figure out how to use approximation factors to determine the answers an algorithm can return for graph problems.
For example, if a graph G actually has a maximum clique with 13 vertices, and we use a 1.5-approximation algorithm to approximate the maximum clique - what is the minimum size clique that ... |
I am trying to prove the algorithm for Question 5 in this practice exam.
I am trying to prove this algorithm with the following three claims:
Suppose we have a graph G, a minimum spanning tree T, and a set of edges A that is a subset of T. Suppose that we also have a cut C = (S, V - S) that respects A, and edge e = (... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.