instruction stringlengths 35 29.1k |
|---|
I'm about to work with concept drift problem in data streams.
I need to start with real data sets from UCI machine learning repository and add to them concept drift (in attributes domain).
Do you know tools that can help me with this?
Maybe someone knows it is possible to use MOA[1] framework for this?
What is best wa... |
I am not too intelligent,but i got this in my mind.Lets say i download a file from abc.com
and the speed is limited for an IP(say 60kbps).Can i initiate parallel downloads from multiple ip addresses which could be virtual IP's OR two diff.devices and break my download into parts,download each part at 60kbps and then jo... |
In CLRS book, in the road cutting example there is a recursion formula
$$
1+\sum_{j=0}^{n-1}T(j)
$$
and it can be proved that the sum is
$$
2^n
$$
by simple induction. In 3-rd edition it is a formula 15.3 on a page 364.
As I can understand from the recursion-tree aproach, the recursion tree which can be... |
I have a problem whose lower bound of problem complexity is proven to be $O(n+m)$ (n < m) and I also come up with an algorithm whose time complexity is $ O(n+m)$, space complexity is $ O(n)$. (All on deterministic turning machine)
If there exists an algorithm that uses O(1) space to solve the same probelm, what will be... |
DISCLAIMER: I understand that I might not be posting in the right part of StackExchange, or this question might have been asked before (I haven't found it). If this offends anybody, I apologize.
I'm 15 and a sophomore in High School. I have an interest in Computer Science in general. The thing is, I've learned a few la... |
I don't know if it is the right site to ask this. But we're studying about ambiguities of grammar. Including left most derivation and right most derivation. We are given the problem:
E -> E * E | E + E | N
N -> 0N | 1N |
Output: 0110 + 110 * 01111
My question is, is there a shortest way to attain that output? Because... |
I need to implement an algoritm, but I can't understand the theory behind it.
How can I prove that if v is an articulation vertex in a graph G , that it will not be an articulation vertex in G' complimentary graph ?
I know that an articulation vertex , is one which when removed disconects the G . And that the complemen... |
My attempt to solve this:
If $\mathcal{A}$ is an arbitrary infinite recursive set then the members of $\mathcal{A}$ can be ordered in ascending order. We can do bijection between $\mathcal{N}$ and $\mathcal{A}$.
Halting problem is $\mathcal{K}\subseteq\mathcal{N}$ and therefore it's also $\mathcal{K}\subseteq\mathcal{A... |
I have written a program to calculate the number of stable partition in a graph.
( That is: find which partition of the nodes does not have edges between nodes of the same block. )
The professor, asked me a way to evaluate the performance of my algorithm (not the program), but my algorithm is simply a brute force of a... |
I came up with the following. Am I doing something wrong?
Suppose $P=NP$. Let $A$ be an NP hard problem. Let $A'$ be the polynomial reduction of $A$. By the assumtions, the Halting problem holts for $A$. Let $T'$ be the running time of $A'$. Clearly, $T' \in O(P(n))$, with $n$ as input size for $A'$ and $P(n)$ represen... |
According to this algorithm: http://en.wikipedia.org/wiki/Shunting-yard_algorithm
when a left parenthesis is found, it is inserted into the stack, and when a right parenthesis is found, we pop all operands up to the left parenthesis. Neither parenthesis is included in the output.
But what if I want expressions such as ... |
My initial guess is that you would have to queue the lower priority one, but what happens when for example 5 or many more requests happen at the same time? Are all these requests put in a queue or are they lost forever?
|
Is there a language $L$ such that both $L$ and $L$'s complement are non turing recognizable languages, but there is a reduction between them?
I couldn't find one...
|
According to Wikipedia, Regular Language is Recognized by Some DFAs, or expressed by Regular Expression .. and all finite Language are regular but, not all regular is finite ..
that's mean it may be infinite language is regular ?
my example is L = {a^n b^n+1, n >0 } is it regular ?
it generate infinite set of strings ... |
If I find an NP Hard problem that is equivalent to my problem with an additional constraint or bound, can I still prove that my problem is NP Hard?
Generally, this is probably not the case. For example, the NP Hard TSP is just a further constrained version of the shortest path problem.
Specifically, I have the problem:... |
Since a binary tree with $N$ nodes has $N+1$ NULL pointers (across leaves), half the space allocated in a binary search tree for pointer information is wasted. Suppose that if a node has a NULL left child, we make its left child point to its in-order predecessor, and if a node has a NULL right child, we make its right... |
I'm reading multi-level cache and came across a question through which i got confused. I've read that
Between processor and Cache Word/ Byte is transfered
Between Cache and Main memory Block(Block of words) is transfered.
If there is a miss in lower level cache and hit in higher level
cache, first Block of words i... |
The most obvious (and commonly given) answer to this question is John McCarthy, but I have traced the first usage of this term to a 1955 paper, which McCarthy co-authored with Marvin Minsky, Nathaniel Rochester, and Claude Shannon. Although McCarthy was the lead author and probably the main organizer of the 1956 Dartmo... |
I'm reading through the paper Transactors: A Programming Model for Maintaining
Globally Consistent Distributed State in Unreliable
Environments by John Field and Carlos Varela.
I have basic knowledge about the lambda calculus (typed lambda calculus to be more precise) thanks to a class I took at my university.
However,... |
I want an algorithm similar to Dijkstra or Bellman-Ford for finding the shortest path between two nodes in a directed graph, but with an additional constraint.
The additional constraint is that there are $N$ sets of special edges with weight $0$ such that a path is not considered valid if it traverses one edge in a se... |
If we have a quantum state consisting of (let's say) 3 entangled qubits and we read the value of one of them, what happens to the probabilities of the remaining possible states?
For example, if we have three entangled qubits and have an amplitude for every state from $|000\rangle$ to $|111\rangle$ and we measure the se... |
I have a set of labelled points and a set of distance constraints between pairs of points, consisting of a lower and upper distance bound. There is definitely an arrangement of the points in 3D space that fulfils all distance constraints.
I wish to generate arrangements of the points where all constraints are fulfilled... |
I was listening back to a lecture I had, hinting on what we should revise for our upcoming exam. Since then I've covered all the parts, but having difficult in decrypting the following
You might want to look at the interaction between scheduling algorithms and interprocess communication.
I understand both interproce... |
I'm working on a compiler. The textbooks I have say to output a 3-address intermediate code. This can be translated into the target language of choice.
I don't have a problem with the bulk of the source being translated to 3-addr code. But for the data-rich symbol table, this is awkward.
Is the exclusive use of 3-addr ... |
Consider the following langugage:
$\qquad L = \{ \langle M \rangle \mid M \text{ TM}, w \in L(M) \implies ww \in L(M)\}$.
I've been asked to decide whether this language is in R/RE/CO-RE. I've proved that the language doesn't belong to R and RE using Rice theorem, but I can't find a formal proof for CO-RE. Any suggesti... |
Hi need help to proof:
For each A,B problems , if A ≤p B , and B ∈ NP then A ∈ NP
Thanks.
|
(sorry beforehand I know putting scanned diagrams may seem not-so-professional but this problem is sticking for long and its interesting too)
The language corresponding to given regex seems to accepts all strings of 1's with length in multiple of 2 or 3 (i.e.4,6,8,9,10,12,...)
I prepared following NFA first:
Figure 1
... |
The usual candidates for context free languages whose complement is also context free, but they are not regular are the Deterministic Context Free Languages ($DCFL$).
For example, $L=\{a^nb^n\mid n\in\mathbb N\}$ is such language.
Is there a language, $L\in CFL\setminus DCFL$ such that $\bar L\in
CFL$?
Since $DCFL$... |
I've been searching on literature on approximation algorithms in the context of network-flow problems (optimization) to finish my bachelor degree.
However, I have been looking in several well-known algorithm books but, I haven't yet found something. Most books don't go beyond Ford-Fulkerson and/or Edmond-Karp in respec... |
Let L is a regular language then is
L' = {x$_2$x$_1$| x$_1$x$_2$ ∈ L}
regular?
Thus x$_1$x$_2$ is essentially concatenation of two strings, but can reverse concatenation of same two strings yield regular language?
|
I am trying to speed up one of my application, one of the places where I can speed up is in my test if a string contains an array of strings.
example: I have the matches "dog", "cat" "apple" and the string "The dog chases the cat".
In this example would I like an algorithm that returns "dog" and "cat".
I do not care, h... |
A friend of mine actually asked me a very interesting computer science related question, and I have been stuck on it for a long time.
The problem is: you have to travel $1000$ km. The only gas station is at the starting point. Your maximum fuel tank capacity is just enough for $50$ km traveling, you are allowed to "bur... |
Sometimes I see NVIDIA simulations with an additional information abbreviated "fps". I've figured out that fps stands for frames per second, but isn't it enough to support 25 fps? Why do I need 60fps ? Most of the movies use 25 fps and not 60. So does anybody know a reason for that ?
|
There are 120 students at University College taking the introductory
Java programming class. The students have access to the following
computers:
80 students have access to a PC running Microsoft's Windows operating system.
40 students have access to a computer running the Apple operating system.
10 students have acces... |
I have a max PriorityQueue designed using a heap.
A function removemax() that removes and returns the element with the largest priority in $\Theta(\log n)$ and a function insert in $\Theta(\log n)$ for the worst cases (both of them work with the heap by reorganizing it whenever necessary in order to retain the heap pr... |
I'm currently trying trouble to set up the recursive expression for the Karatsuba multiplication of two integers with $n$ and $m$ bits (both having a different number of bits). Usually, the recursion for two $n$ bit integers for Karatsuba multiplication would be:
$T_{n} = \begin{cases} 3T_{n/2} + cn &\mbox{if } n > 1 \... |
I am reading Operating System Concepts by Silberchatz, Galvin, Gagne and they write that a directory can be implemented using a linear list. [pg 470, 8th ed]
However, I visualize directories as a rather hierarchical data structure which can be implemented using a B-tree.
Also, when they say that the nodes contain a poi... |
I'm trying to figure out the complexity of the following algorithm.
for(int i=1; i <= N; i++)
for(int j=1; j <= i; j++)
for(int k=1; k <= i*sqrt(j); k++)
I'm trying to figure it out using a method similar to rizwanhudda's solution in this similar question. I'm having some trouble though because th... |
In poset maximal number is defined as:
An element 'a' belongs to 'A 'is called a maximal number if there is no element 'c' in 'A' such that a is less than c.
but it again says that there can be more than one maximal number. How can it be possible?
|
From following languages which one is regular and why others are not?And what is the regular expression for regular one.
$L_1= \{wxwy | x,y,w \in (a+b)^+\}$
$L_2 = \{xwyw | x,y,w \in (a+b)^+\}$
$L_3 = \{wxyw | x,y,w \in (a+b)^+\}$
Also where can I find these type of problems?
|
The paper I'm looking at: Fast approximate string matching with finite automata (2009)
Explanation of the algorithm (from my understanding anyway):
A word is inputted into the automaton and from each state, a number of possible actions can be taken depending on the current symbol/character being looked at at position $... |
Given two increasing functions $f$ and $g$ with values in the natural numbers, is it always the case that either $f\in O(g)$ or $g\in O(f)$.
If the statement is true, then can anyone provide a counterexample for when any of the two conditions in bold are relaxed.
If the statement is false, can someone provide a counter... |
I am studying about Particle Swarm Optimization (PSO) and I was wondering what the user-defined constants in the update equations are for.
First update equations:
$v(t) = w*v(t) + c_1*rand*(x_{best} - x) + c_2*rand*(g_{best} - x)$
$w$ is known as the weight/inertial constant. Usually values here are in the interval $... |
This question is about the time impact of the length (i.e. number of variables) of the constraints in an Integer Linear Programming formulation.
Most people try to reach the minimum number of constraints/variables, but I couldn't find anything that considers the size of the constraints.
In more concrete terms, I have s... |
The LOOK algorithm (wiki) is the same as the SCAN algorithm in that it also honors requests on both sweep direction of the disk head, however, this algorithm "Looks" ahead to see if there are any requests pending in the direction of head movement. If no requests are pending in the direction of head movement, then the d... |
is it possible to minimize pushdown automata?
If no, why?
Is it because for minimization the equivalence classes need to have a finite index and we cannot guarantee that for CFG?
|
Looking for insight into decisions around garbage collected language design. Perhaps a language expert could enlighten me? I come from a C++ background, so this area is baffling to me.
It seems nearly all modern garbage collected languages with OOPy object support like Ruby, Javascript/ES6/ES7, Actionscript, Lua, etc. ... |
In the picture below, I'm trying to figure out what exactly this NFA is accepting.
What's confusing me is the $\epsilon$ jump at $q_0$.
If a $0$ is entered, does the system move to both $q_0$ and $q_1$ (the accept state)?
If a $1$ is entered, does the system move to both $q_1$ and $q_2$?
Does the system only move... |
I am doing a homework assignment and I've been stuck on this question for a long time now. The question says to prove this equation is a tautology without using a truth table. I assume we have to use equivalences to do this but I can't figure out how to do this.
The equation is:
[⌐p AND (p OR q)] → q
Please help me!!
... |
Dynamic perfect hash tables and cuckoo hash tables are two different data structures that support worst-case O(1) lookups and expected O(1)-time insertions and deletions. Both require O(n) auxiliary space and access to families of hash functions for their operations.
I think that both of these data structures are beaut... |
The crux of the difference between analog and digital computing is the number of bits of precision available, right? Now, I know that in the Turing machine, numbers can be stored with any degree of precision since the storage medium is an infinite tape.
But in the real world, physical quantities such as energy or posit... |
I'm preparing for the exams and this question came up -
Consider a machine with $64MB$ physical memory and a $32$-bit virtual address space. If the page size is $4KB$, what is the approximate size of the page table?
(A) 16MB
(B) 8MB
(C) 2MB
(D) 24MB
The way I've solved it -
Physical Address Space = $64MB = 2^... |
Input: A set $U= \{w_1, w_2, \ldots, w_n\}$, subsets $S_1, S_2, \ldots, S_m$ of $U$ and integer $k$.
Question: Is there a subset with $k$ elements of $U$ which intersects of every $S_i$?
Which reduction should i use to prove that this is np-complete ?
Hint: Reduction from vertex cover.
|
I'm trying to understand the difference between LTL and CTL. In particular, i'm trying to understand when a model (a transition system eg. Kripke structure) satisfy a formula.
This is my point of view:
a model satisfy an LTL formula if an only if all its path starting
from its initial state satisfy the formula
a mode... |
Consider the gate used in Simon's Algorithm. It operates on a control register and target register, changing state like: $|\textbf{x}\rangle|\textbf{y}\rangle->|\textbf{x}\rangle|\textbf{y}\oplus f(x)\rangle$.
As I am working on an universal way to simulate operations on qubits, I've been using a matrix representation ... |
I understand the normal definitions of the P/poly class, but I'm curious how the name came about.
The syntax of the name looks like a quotient group, but I can't think of any way to define P/poly that would use a quotient. Is 'A/B' defined to be something like "the class of problems that would be solvable as efficientl... |
I've been reading on distributed systems for processing on large graphs. The most prominent examples include Pregel (developed by Google) and Apache Giraph. Most of these systems argue their existence that they are for "big data" processing, i.e., they can handle graphs that are too big to fit into a single machine.
W... |
I have $P$ vectors of size $N$ with elements in $\{0,1\}$. Each vector $v$ has a value $\alpha_v$.
I would like to Fill a square matrix $M$ of size $N\times N$ in the following way:
$$\forall i,j \in \{1,2,...,N\}~ M_{i,j} = \sum_{\text{vectors}~v : v_i v_j =1} \alpha_v$$
Is it possible to fill the matrix $M$ in time... |
I have 2 different but similar problems, one belongs to NP and one to L and I don't understand why.
First problem: Input: an undirected graph G with n^2 vertices. Question: Is there exist in G a matching of size n AND an independent set of size n?
Second problem: Input: an undirected graph G with n^2 vertices. Question... |
In the context of clock synchronization among nodes of a network, what is clock offset and what is clock skew?
Are these terms synonymous or is there a difference between them?
|
Question: ($B$ and $C$ are languages)
$B$ is finite,$C$ isn't regular:
Prove/Disprove: $C\cup B$ isn't regular.
Thoughts:
My intuition says this is true, but I need an idea to prove it. Since I don't know if $C$ as a CFG or RE language I don't know what kind of machine I can build for it.
|
Could someone show me ( or give me a valuable hint) how to reduce k-Clique problem to SAT-3CNF problem ? I am able to prove reduction from SAT-3CNF to k-Clique, but in the opposite direction it's hard.
|
In a class on Turing machines, the lecturer said that the language for a machine with 100 states is both recognizable and decidable.
How can we infer this just from the number of states in the machine?
|
I am a mathematician, and I am completely lay in the technical aspects of computer networks and computer architecture. I would like to know if there is any computer network or architecture, protocol, or whatever, which combines unidirectional links with bi-directional ones. If so, what are the practical advantages of t... |
This is the question-
Let $A[1,....,n]$ ba an array storing a bit $(1\,\,or\,\,0)$ at each location, and $f(m)$ is a function whose time complexity is $\theta(m)$. Consider the following program -
counter = 0;
for( i = 1; i <= n; i++)
{
if(A[i] == 1)
counter++;
else
{
f(counter);
... |
I read on the internet that it's possible to reduce clique to vertex cover. Almost everyone use this theorem:
if a graph $G$ has a clique of size $k$ then the complement of $G$ has a vertex cover of size $n-k$, where $n$ is the number of vertices.
Consider the graph on five vertices and the following edges: a clique... |
I want to compute $g^{mn}$ mod $n^2$ where $n=pq$ and I know that $g$ has order $kn$ mod $n^2$ where $m<k$. Is there any clever way of doing it utilizing the order? I have tried other methods of computing $g^{mn}$ directly.
My question stems from an implementation of the Paillier cryptosystem that I'm working on. Right... |
On my homework the question asks:
A program executes serially in 200 seconds. If it is parallelized, 7
seconds of overhead are required for synchronization, locking, and
communication. Compute the execution time, ideal speedup (if there
were no overhead required), actual speedup, and the percentage of the
idea... |
I have the power consumption values of a household for 2 year. To preserve privacy I am down sampling this data before sending it to the utility company. My goal is to get back the original data from the down sampled data. I am thinking I would need some kind of learning based predicting algorithm. My professor suggest... |
I know a regular language is the one which can be expressed as a regular expression or we can create a DFA corresponding to it. Unless a language has a pattern in which one part has to match with other like in $$a^nb^n|n\geq 0 (CFG)$$ It'll be regular. Like AP Series of symbols can be easily expressed as Regular expres... |
Given $ \Sigma= \{a,b\} $, show that $ L:= \{a^nwb^n: m,n \in \mathbb N, m\geqslant n, w\in\Sigma^m\} $ is not regular.
I'm trying to proof this with the Pumping Lemma, but I'm kind of confused because of the middle part $w$.
I would pick the symbols $\ a^na^mb^mb^n $ as a starting point and show that this does breach ... |
In Section 2.3.3 "Polytopes and LP" of the book "Combinatorial Optimization: Algorithms and Complexity" by Christos H. Papadimitriou, Theorem 2.4 establishes the relation between bfs's (basic feasible solutions) of LP and vertices in polytope (for developing the simplex algorithm). However, I have difficulty in underst... |
I'm wondering, what is the best known algorithm, in terms of Big-$O$ notation, to solve Integer Linear Programming?
I know that the problem is $NP$-complete, so I'm not expecting anything polynomial. And I know there are lots of heuristics and such that are used in practical applications like CPLEX, but I'm more intere... |
If the best case for Insertion sort & bubble sort is $O(n)$ then how is lower bound for any comparison sort is $\Omega(n\log n)$? I mean, $O(n)$ is obviously smaller than $\Omega(nlogn)$. What am I missing here?
|
I am doing homework to practice for my midterm exam and cannot answer this question. I need to decide whether or not this statement is true of false and either give a proof or counter example.
For this particular question, I am leaning more towards saying it is false as the question does not really follow the definiti... |
Although I work as a programmer in my daily life and use all the trendy languages (Python, Java, C, etc) I still have no clear view of what functional programming is. From what I've read, one property of functionally languages is that data structures are immutable. For me this alone raises a lot of questions. But first... |
I am trying to prove that merge sort is indeed $O(n \log n)$.
I was able to extract a pattern using constants, however now I am stuck. This is as far as I can get:
$T(n) = 2T(n/2) + cn$
$T(n/2) = 2T(n/4) + c(n/2)$
Now plug in 1. into 2.
$T(n) = 2(2T(n/4) + c(n/2)) + cn$
$T(n) = 4T(n/4) + 2cn$
Now the pattern I was ... |
It is common to define $P$-completeness with respect to logspace many-one reductions. I am looking for a complexity class $C$ such that if $C=P$ then all problems in $P$ are $P$-complete under many-one $C$-reductions.
What is the weakest many-one reduction (computable in class $C$) for which the class of P-complete p... |
I'm trying to understand a proof from the paper: Balcázar, José L.; Gavaldà, Ricard; Hermo, Montserrat: Compressiblity of infinite binary sequences, Published in: Complexity, Logic, and Recursion Theory, A. Sorbi, ed., Marcel Dekker 1997, ISBN 0-8247-0026-0, 75-91.
Theorem 19 For every recursive time bound f , there i... |
The $n$th Fibonacci number can be computed in linear time using the following recurrence:
def fib(n):
i, j = 1, 1
for k in {1...n-1}:
i, j = j, i+j
return i
The $n$th Fibonacci number can also be computed as $\left[\varphi^n / \sqrt{5}\right]$. However, this has problems with rounding issues for e... |
Let's say I'm writing a GA to find an optimal path to travel from point $A$ to point $B$. Genotypes are a list of directions (north, south, east, west) to follow.
So a genotype "NENWEE" will move north once, east once, then north again, west once, and finally east twice.
The directions are encoded as follows:
N : 00
E... |
Is there a difference between the end state of a Turing machine and the halt state? Especially, for example the Busy Beaver 3. It is said that it is with 3 states but there is also a halt. Is the end state $q_2$ or the $halt$?
|
Let $\mathrm{LOG}_{\mathrm{CF}}$ be the class of all languages recognized by a Pushdown-automaton that uses $\leq \log n$ cells of its stack for each input of length $n$.
Obviously, this class is a proper subset of the class of context-free languages. Which languages are in this class, and what (closure) properties doe... |
Assume you have a fixed ($d=O(1)$ for that matter) degree matrix polynomial
$$P(X)=A_0+A_1\cdot X+A_2\cdot X^2+\ldots+A_dX^d$$
Where $A_0,A_1,\ldots A_d\in\mathbb N^{n\times n}$ are given as input. Also given is some constant $\epsilon$.
Can we find a matrix $X_0\in \mathbb R^{n\times n}$ such that $||P(X)||<\epsilon$... |
I have a question regarding the ECGA algorithm. This is what I'm currently studying. If ECGA builds a model of the parent pool using the 'minimum description length' (MDL) measure, why cannot we simply choose the model which has the most likely fit of the parents?
Thanks.
|
I am currently studying about formal languages and automata.
I am trying to solve a problem but there is a notation whose meaning I'm not sure of.
I have a question to find out the relationship between two languages $L_1$ and $L_2$:
$L_1:$
$S \to aSa|bS|e$
$L_2 \to L((ab+ba)^*)$
My question is, does it mean that $L(ab+... |
A weighted digraph (with loops) is bistochastic, iff
the weights are non-negative,
for all non-sink nodes, the sum of the edge weights of the out-edges is $1$, and
for all non-source nodes, the sum of the edge weights of the in-edges is $1$.
The Birkhoff-von Neumann theorem for a bistochastic matrix states that a bis... |
I have the following pseudo-code:
mystery(n):
if n <= 50 :
for i = 1 ... n :
for j = 1 ... n :
print i*j
else :
mystery(n-1)
For the following nested for loop:
for i = 1 ... n :
for j = 1 ... n :
For every i in n, j iterates through n as many as i times. So, why is it that the comp... |
Are there any known subquadratic algorithms for calculating the floor of the square root of an n bit integer?
The naive algorithm would be something like
def sqrt(x):
r = 0
i = x.bit_length() // 2
while i >= 0:
inc = (r << (i+1)) + (1 << (i*2))
if inc <= x:
x -= inc
r... |
I have seen a lot of solvers that are capable of, for example, getting an equation such as x ^ 2 + x = 12 and finding x = [3, -4]. I know some of them are implemented by hardcoding special cases. For example, when finding an equation on the quadratic form, they use a hardcoded bhaskara formula.
What I'm looking for is ... |
Is it possible to proof for a Language L and its L-complemented to be both not recursively enumerable?
Can be useful to consider the (Ld) diagonalization Language?
thank you.
|
Is it possible to re-weight a generally-weighted graph to a distinctly-weighted graph to apply Borůvka's algorithm (wiki) for minimum spanning tree to it?
I can't seem to think of a way to make a distinction between the same weights, it feels unnatural.
|
In the Computability, Complexity and Languages book written by Davis in page 5 he defines a predicate as:
By a predicate or a Boolean-valued function on a set $S$ we mean a total function $P$ on $S$ such that for each $a \in S$, either $P(a) = True$ or $P(a)=False$.
So every predicate is a total function. in Page 30 ... |
I have the following pseudo-code for printing all nodes of a BST :
traverse(x):
if x == nil:
return
else:
print x
traverse(x.left)
traverse(x.right)
I want to find its complexity. I have an idea, but I'm not sure if I am implementing it correctly.
$T(n) = 2T(n-1) + cn$
Where $T(... |
Why is $f(n) = \Theta(g(n))$ where $f(n) = n(n+1)/2$ and $g(n) = \sum_{i=1}^n (n/i)^2$?
Also, why is $f(n) = \Theta(g(n))$ where $f(n) = n^{\log_49}$ and $g(n) = 3^{\log_2 n}$?
I know what notations mean - I just want to prove them.
|
This may be an elementary question, but I'm new to circuit complexity. Does 2-SAT in CNF form belong to the complexity class AC$^0$?
It seems simple enough to construct an AC$^0$ circuit of depth 2 of polynomial size for 2-SAT. $~$Given $n$ variables (which means $2n$ literals), there can be at most $\frac{(2n)(2n-1)}... |
I've recently learned about distributed computing and the synchronous model where, assuming a complete network and no crashes, in each round the following happens:
every node can send a message to all other nodes,
all of these messages are received by all nodes by the end of the current round, and
at the start of th... |
I'm trying to figure out who coined the term "machine learning". An ancillary question is from where is Arthur Samuel cited as defining the field of "machine learning" in 1959 as:
the field of study that gives computers the ability to learn without
being explicitly programmed
?
You can find many, many references to... |
I don't understand the notion of relativization. I expose with an example. Consider a class $A$ that contains $P$, e.g. $NP$. Why $P^A$ is not necessarily equal to $A$? I can naively think that if one can decide any problem in $A$, one can also decide any problem that uses polynomially many steps in a Turing machine pl... |
In load balancing problem we have $m$ machines and $n$ jobs, each taking processing time $t_j$. Total processing time on the machine $i$ is $T_i =\sum_{j\in A(i)}{t_j}$, where $A(i)$ is the set of jobs assigned to machine $i$. Goal is to provide an assignment of jobs, such that $\max T_i$ is minimized.
It is known that... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.