instruction
stringlengths
35
29.1k
We have two equations $g = O(f)$ and $h = O(f)$ , then can we derive that $g = O(h)$. I came up with following proof but i dont know it's correct or not. $$g = O(f)$$ $$g \le c_1*f $$ $$h \le c_2*f $$ Now we have to prove, $$g = O(h)$$ $$g \le c_3*h$$ $$g \le c_3*c_2*f $$ $$ c1 \le c3*c2 $$ We can find $c_3$ such that...
I would like to know how to alter/add NOTs when applying Duality principle. Suppose I have P = XY(X+Y) + NOT(Y), how to find its dual? My book says that while applying Duality Principle to a relation: Change all 0s to 1s Change all ORs to ANDs Change all ANDs to ORs But it doesn't say anything about NOTs.
I know that unsafe state does not always mean deadlock. That is a situation that banker's algorithm does not detect deadlock accurately. I am just wondering if there is any example of a safe state that deadlocks?
I'm reading a paper, and there is this paragraph about LLVM: ''it heavily relies on the static single assignment form (SSA) which cannot be readily used to design an abstract interpreter. The $\phi$-nodes need to be eliminated and other inadequate constructs need to be simplified using various LLVM transformatio...
[Using Idris syntax and terminology, but the question is not about Idris] If a monad interface (or type class) has a constraint requiring applicative functor, a monad instance can be written by implementing either bind: (>>=) : Monad m => m a -> (a -> m b) -> m b, or join : Monad m => m (m a) -> m a, or both. However, ...
Pseudocode: if n < 2 return false while n != 1 if n % 2 != 0 return false n = n/2 return true The loop will terminate when n is odd. If n = 1, true is returned and that means that n0 was a power of 2. Otherwise it's false. I'm new at this and struggle with the proving the power of 2 part for before...
I'm interested in implementing equality checking mod 10 in an arithmetic circuit. Is this possible? Preliminary evidence points towards "no", but I thought it best to ask before completely writing it off. First, note that if $\mathbb{Z}_{10}$ were a field, this would be trivial due to Lagrange interpolation (allowing ...
In the book here: http://neuralnetworksanddeeplearning.com/chap3.html If you scroll down to Exercise 2 in the Softmax Section, it says Show that $\partial a^L_{j}/\partial z^L_{k}$ is positive if $j=k$ and negative if $j \neq k$. As a consequence, increasing $z^L_j$ is guaranteed to increase the corresponding output a...
Given two sequences of points(i.e. ordered points), connect the points in seq_A with the points in seq_B according to some rules. A point could be connected to 0, 1, or many points in the other sequence. But there should not be any line crossing. And each line could be assigned with a weight(controlled by relation betw...
I am trying to find the name of an algorithm for a game I am making. I am pretty sure it exists, but I have no idea what name it has. Say I have a matrix like: $$ \begin{array}{|r|r|r|} \hline \hphantom{-}1 & -1 & 0 \\\hline 0 & 0 & 1 \\\hline 0 & 1 & -2 \\\hline \end{array} $$ I know that the sum of e...
I am going through Richard Sutton book about Reinforcement Learning and I just encountered the tile coding method. I understood pretty well the principles, however, at the very end of the section, tile hashing is mentionned. Hashing produces tiles consisting of noncontiguous, disjoint regions ran- domly spread throu...
How to prove $\Theta(g(n))\cup o(g(n))\ne O(g(n))$ ? Is there a simple example for understanding? Seems there's a gap between $O(g(n))- \Theta(g(n))$ and $o(g(n))$ just from the definition. But I cannot understand What kind of function lays there?
Is it there any computer or cellular automaton or model of the brain where they could compute logically impossible things and incomputable things? For example, if we wanted to compute/simulate/think about a universe where 1+1=3 (which would gives as result a universe where literally everything could happen, possible or...
I've been trying to get into Agda and I noticed that it doesn't have recursion, which implies that it isn't Turing-Complete. From what I could understand, if Agda had recursion, it would make itself an inconsistency from a type theory perspective. Something stuck to my mind: Is it possible to exist a language that it i...
I have a question that I am stuck on reasoning about knowledge. For the following statement, I need to show whether it is valid, satisfiable or unsatisfiable: $\bf{K}$(Happy $\lor$Sad) $\implies$ $\neg \bf{K}($Happy) I have done the following: Let e w be an interpretation where e is the set of possible worlds and w is ...
Background I have several F# codebases with reasonably high level of complexity of code. In order to convince myself that the code is solid I do whatever I can to write as much of it as possible type-driven and pure (up to what I am able to determine is pure without much help from the compiler) and unit test it like cr...
Imagine I have a binary heap, traversed in a breadth first manner like so: 0 1 | 2 3 | 4 | 5 | 6 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 To the left of root (0) is 1, to the right is 2, to the left of 1 is 3 to it's right is 4 etc. So node 13 corresp...
I've noticed that Big-Oh notation actually has some properties such as summation, product but i couldn't find an introductory explanation for their use or how they can help to solve asymptotic problems. 1) Is it possible to explain these properties in plain English? 2) Can these properties be applied to Big-Omega and ...
I came across this problem in Tim Roughgarden's course on Coursera: In this problem you are given as input a graph $T=(V,E)$ that is a tree (that is, $T$ is undirected, connected, and acyclic). A perfect matching of $T$ is a subset $F \subseteq E$ of edges such that every vertex $v \in V$ is the endpoint of exac...
There exist 5 rules for any pseudocode , one of these rules is : "Keep statements language independent" I don't understand what is this rule is saying. So can someone explain it and then give an example of pseudocode written to be language independent ? Moreover, the source for this rule is "Invitation to Computer Sci...
What is the highest time complexity lower bound that has been proven on any (non-contrived) NP complete problem?
I am somewhat aware of the correspondence between (tuple and domain) relational calculus, relational algebra, and SQL. To the best of my understanding, one should be able to automatically convert a formula in relational calculus to an SQL query whose run on a database produces rows that make the original formula satisf...
Lets assume I'm talking about Jpeg and Mp4 and a general video player(not sure if different ones load it differently, if they do please tell) So do video players (process) usually load the entire Jpeg or Mp4 including metadata into its own memory space right? like lets say we have a 1920x1080 picture with 10 bytes of ...
The problem of "Scheduling to Minimize Lateness" is as follows (Section 4.2 of the book "Algorithm Design" by Jon Kleinberg and Eva Tardos): Input: A finite set $J = {J_1, J_2, \ldots, J_n}$ of $n$ jobs, their processing time $t_1, t_2, \ldots, t_n$ and deadlines $d_1, d_2, \ldots, d_n$. We assume that all jobs were a...
The question is simple and given as, alphabet $A$ is $\{a, b\}$, and language $L$ over $A$: $L = \{w: w \in \{a, b\}^*, n(a) - n(b) = 1 \mod 3\}$. Here $n(a)$ = number of $a$ and $n(b)$ is number of $b$. My answer is that it's not a regular language because the modular expression can be simplified as. $n(a) =n(b) +3k+1...
Problem statement: Input: a digraph $G(V, A)$ and a natural number $k$ Output: YES if it is possible to color all vertices of $V(G)$ by $k$ colors such that no directed cycle is monochromatic, NO otherwise Is this an $NP$-complete problem?
The question is as follows $$(a^* (ba)^* )^* (b+\epsilon) = (a+b)^* (b+\epsilon)\,.$$ But I am unable to solve this regex expression. My answer is as follows: \begin{alignat*}{2} (a^* + (ba)^* )^* ( b+\epsilon)\qquad &\text{(using property} (a^* b^*)^* = (a^*+b^*)^* = (a+b)^*\text{)}\\ =(a+ ba)^* ( b+\epsilon)\qquad...
Are there any known famous and usable algorithms that seem to solve some famous problem but which haven't been proven to be correct?
I'm reading Computer Science: An Interdisciplinary Approach. It mentioned an NFA (nondeterministic finite automaton) with a null transition, as shown above, recognizes all binary strings that do not contain bba as a substring. I didn't quite understand why it says so. If the null transition happens before reading the ...
I am focusing here on positive even SAT problems, that is a CNF for which all literals are positive, and in which an even number n of variables occur. This is obviously trivial : just set all variables to true and all clauses are satisfied. The same if we look for an assignment that would have all but one variables be...
I was told that this language is regular but as I can show below, pumping lemma is not working for it. What am I doing wrong? Is this language really regular? Why?
Consider the alphabet $\mathcal{A}=\{a_0,a_1,a_2,a_3\}$ with the the following corresponding probabilities: $\, p_{A,1}=\{0.5,0.3,0.15,0.05\}$ $\, p_{A,2}=\{0.5,0.25,0.125,0.125\}$ The entropy for the first case is $H(A,1)= 1.65$, and for the second is $H(A,2)=1.75$. The Huffman code for both can be $\{0, 10, 110, 11...
My first post here so please correct me if my terms are off or needs clarification. Suppose I have several sets of lists of spans. I define a span as a pair of indexes: begin and end index in a string. You can also think of a span as a consecutive sequence of 1's in a bitarray. e.g. 00111 is a span of (2,5). I will hav...
I have a ciphertext $c$ encrypted with RSA algorithm that needs to decrypt. I have the public key $(n,e)$. Is it possible to decrypt with this amount of information?
I asked my Advanced Algorithms professor recently if we could solve the coin change problem (least number of coins necessary to make change for S cents using denominations d1, d2, ... dk). I thought this might be possible using something like the least common multiple of the denominations to find a subset of answer tha...
the question is as follows, further the notation used are standard as used in theory of computation $$L = \big\{ w : w \in \{a,b\}^*,\ |n(a) - n(b)| = 2k\}\,.$$ Beware 'K' is not a fixed integer its a set of natural number , so 2k means all natural nunbers divisible by 2 and so on for 3k , 4k... .I think the above lan...
I am given a connected graph. I have to construct a spanning tree from the graph, that has minimum diameter. However, I looked for the solution, and the solution goes like this. If the diameter of the tree is even, then it must have a center node. Then we try to find the center node by finding all pair shortest path fi...
Problem I am trying to solve is this: There are n nodes, and for every pair of node $X$ and $Y$, the relation "$X \space knows \space Y$" is either $T$ or $F$. It is possible that "$X \space knows \space Y$" but "$Y \space doesn't \space know \space X$". We are trying to find if a special node exists: that is known ...
I am thoroughly confused by a problem that was brought up in class: Given the following pseudocode for a function RANDOM which generates a random number based off of recursion: function RANDOM(n) 1. if n = 1 then 1.1 return 1 1.2 else 2.1 assign x = 0 with probability 1/2, or 2.2 assign x = 1 with probabi...
There are tones of solutions for Knights tour or shortest path for Knights movement from source cell to destination cell. most of the solutions are using BFS which seems the best algorithm. Here is my implementation using HashMap: public class Knight_HashMap { static HashMap<String, Position> chessboard = new...
Our problem is to decide whether a digraph has a guarding set of size at most $k$. Definitions are following. A digraph $G(V,A)$ has $V(G)$ as its vertex set and $A(G)$ as its arc set. A guarding set $S\subseteq V(G)$ is a set of vertices such that: For each vertex $v\in V(G)$, some of its incoming neighbor $u$ (i.e. ...
So is it even possible for a user process to even try to access a physical memory location that does not belong to it and therefore getting an error by operating system? because for example with a 32 bit cpu the user process has an illusion of having a 32 bit memory all for it self (correct me if I'm wrong) and each pa...
Problems: A table with $n$ rows and $m$ columns is filled with number from $1$ to $100$ (duplication allowed). The player starts at $(1, 1)$. He can only move right or down. The goal is to reach $(n, m)$. Let $S$ be the product of numbers the player has met along the way to $(n, m)$. Find maximum number of trailing zer...
Why some sets are countable and some are not countable? Say regular set are countable but how (0+1)* will be countable? It is an infinite string, then how it could be a countable set? How the set of all non-decreasing functions from N to N are countable? How the set of all finite partitions of N are uncountable?
How to convert access control matrix to Bell-LaPadula. Can teach me step by step What best way to control converting Bell-LaPadula Model lattice using Access Control Matrix Matrix GIVEN $\quad\quad\quad\quad$O1 O2 O3 O4 S1 w r w rw S2 rw r S3 ...
So, I need to find the T(n) and then Big-O (tight upper bound) for the following piece of code: int sum = 0; for(int i = 1; i < n; i *= 2) { for(int j = n; j > 0; j /= 2) { for(int k = j; k < n; k += 2) { sum += i + j * k; } } } Now from what I calculated for the loops, first loop r...
A four-part question dealing with formal languages and regular expressions: How many basic regular expressions (using only the rules 0/ϵ, 1/∅, *, +, and •) are there to match a given string? How many using just *, +, and •? How many using just + and •? How many using just •?
I have an array of items $A = \{A_i\}, i \in I $ with integer weights $W_i, i \in I$. I need to build a function $f: I \rightarrow A $, that produces evenly distributed patterns of array elements predictable manner. For example: an array of 3 elements: $A_1 = 1, A_2 = 2, A_3 = 3$ and weights: $W_1 = 1, W_2 = 2, W_3 = ...
Me and my colleague are exploring new ideas to solve SAT efficiently (i.e. in polynomial time) and it's the case that there is a candidate algorithm. Unfortunately, neither of us can write scripts well (to test more examples to prove its correctness) or more accurately ... have the sufficient mathematical maturity to w...
Let $U=\{1,2,\ldots,n\}$ and $S \subseteq \mathscr{P}(U)$. Let $T$ be a subset of $S$, randomly constructed selecting independently each element of $S$ with probability $p$. Is there a polynomial time algorithm that computes: $$\mathbb{Pr}\left[ U =\bigcup_{X \in T} X \right]$$ Or is there any equivalent famous problem...
...where $s$ is a substitution that replaces each symbol of each string in $L$ with a regular expression. For example, if $L=a^*b$ and $s(a) =ab, s(b) = b^*$, we have $s(L) = (ab)^*b^*$. My thoughts so far are that replacing characters in a regular expression with regular expressions still gives us a regular expressio...
How should I approach this one a(n) = $\frac{n^3}{log^{3}(n)}$. As We can tell that $n^3$ grow much faster than $log^{3}(3)$. All of sudden, not sure what to do, found this [post][1], which is also in the fraction form, Do we calculate out $\frac{n^3}{log^{3}(n)}$ or just pick $n^3$. Eventually, the accurate number is...
Is there any kind of function which is used in python to calculate the time complexity of another function?
The interval partitioning problem is described as follows: Given a set {1, 2, …, n} of n requests, where ith request starts at time s(i) and finishes at time f(i), find the minimum number of resources needed to schedule all requests so that no two requests are assigned to the same resource at the same time. I...
I found it a little bit difficult and confusing to define the complement language in specific cases. For example, take the next language: $$L = \left\{\langle M, w\rangle \;\middle|\; \begin{array}{l}M \text{ is a Non-Deterministic TM,}\\ \text{and it has an accepting run on }w\text{ of length }\leq |w|\end{array}\rig...
Why is it impossible to reverse a hash code? There could be some way to crack this coding?
ASDL stands for Abstract Syntax Description Language (ASDL), whereby ADT stands for Algebraic data type. By looking at Python.asdl it appears to me to be the same thingy, just with different names, which I highly assume is wrong. Can anyone explain what the difference is?
Given an undirected graph $G(V,E)$, a vector system is a set $S$ of ordered pair (intuitively called vector) $(u,v)$ (we shall call $u$ the initial point, and $v$ the terminal point) that satisfies the following criteria: For each vector $(u,v)\in S$, we have that $uv \in E(G)$. So, each vector must be an orientation ...
I'm sure there are standard test cases of hard, combinatorial, NP problems, ... (like knapsack, bin packing, partitioning, ...) that practitioners or algorithm developers use when they compare a new algorithm against existing ones (as I often see in papers), but where can I find them ? (a single repository is more pref...
If some language $L$ is in P, and some other language $K$ is contained in $L$, does that mean that $K$ is also in P? Thanks :)
A circuit is simply a DAG, with some input wires, some output wires, and some operations on the vertices. Consider an arithmetic circuit where the only operations are addition ($+$) and multiplication ($\times$) over some ring, say, the integers modulo $N$. Now, if I understand correctly, any circuit can be thought of...
I just started reading about formal language theory and what i have learnt so far that: Alphabet is a finite set of symbols. String/Word: is always finite. Because a language is set of strings of symbols and per definition alphabet and strings both are finite then how can a language be infinite? I searched a lot but di...
I was wondering what is the correct time complexity expressed in terms of big O on this type of loop: for(i=1;i<=n;i++) for(int j=1;j*i<=n;j++) // O(1) code here The inner loops will make $n + \frac{n}{2} + \frac{n}{3} + \dots + \frac{n}{n}$. I know that this type of formula is $O(n \log n)$, so is this th...
We have a function $T(n)$ defined by $T(1) =1$ and $T(n)=3T(\lfloor n/2\rfloor)+n$ for $n > 1$. We need to show that $T(2^n)=\Theta (3^n)$. How should I approach this question? Any suggestion?
I would like to check the answer of this exercise: A circular doubled linked list with N elements has pointers that cost k bytes each of space in memory. How many bytes do the pointers of this list cost in total? Researching about circular linked lists, i can assume that each node has 2 pointers. So am i right to say t...
Is it true that inserting an element to an AVL tree requires $O(1)$ rotations? How many rotations, does deletion from AVL require? I've searched for these two questions with no luck so far.
I am completely new to AI and doing self-learning to acquire this knowledge. I went through the different available search algorithm like BFS, DFS and A* but something that I can't understand is a heuristic function that needs to be embedded in these algorithms. I am fine with algorithms but I don't know how we find a ...
Comparison-based sorting algorithms have a minimum worst-case complexity of $O(n \log n)$, while it is easy to check that an array is sorted in $O(n)$ time. Are there other problems with proven minimum complexity $O(n^k)$ for some $k > 1$ that can be checked in $O(n)$ time? How high can $k$ get?
Here I have a problem in understanding the optimal testing strategy. In a scenario, You have been given two laptop batteries and a testing device. The testing device will make the battery connected to it (one battery can be connected at a time) deliver x mA, where x is an integer. The testing device is constructed in s...
Description: Suppose that we are given a fixed non-bipartite graph $H$. A graph $G$ is loopless surjectively homomorphic to $H$ if there exists a loopless surjective homomorphism $\varphi:V(G)\to V(H)$ such that: For every $u,v\in V(G)$, $(\varphi(u)=\varphi(v))\lor(uv\in E(G)\implies\varphi(u)\varphi(v)\in E(H))$. ...
So far I know how to normalize when you are given, say: 1111010010 Mantissa, and 000100 exponent and are told that it's a positive number: 1.111010010 and the exponent value is 4 move point 3 to the right: 1111.010010 subtract exponent by 3 = 1; 000001 replace extra binary digits behind sign bit with trailing 0s 1.0100...
The above image, describing Strassen's matrix multiplication algorithm, is from the book Introduction to Algorithms by Cormen, Leiserson, Rivest, and Stein. The algorithm multiplies two square matrices of order $n$, where $n$ is a power of $2$, i.e., $n=2,4,8,16,32,\dots$ and so on. Can this algorithm be modified so ...
I'm trying to do the following demonstration: (C and S are CNF) C is a logical consequence of S iff. S u {-C} UNSAT And I did the following: C is a logical consequence of S iff. S u {-C} UNSAT iff. for all interpretation I that SAT S -> I SAT C iff. for all I, eval_I(S) = 1 -> eval_I(C) = 1 iff. for all I, -eval_I(S) =...
I have the following code: constant B:Type constant A:Type constant P:B → A → Prop definition F:Type := B → A axiom a1: ∀b:B, ∃a:A, P b a theorem thrm1: ∀b:B, ∀a:A, (P b a) → ∃f:F, (f b = a) ∧ ∀bb:B, P bb (f bb) := λ b:B, λ a:A, assume h: P b a, sorry It should be almost trivial to prove this, yet I'm not...
This is an interview question. I need to implement a data structure that supports the following operations: Insertion of an integer in $O(1)$ Deletion of an integer (for example, if we call delete(7), then 7 is deleted from the data structure, if the integer 7 exists in it) in $O(1)$. Return maximum integer in the dat...
As title, (note: this questions is asking weather or not all vertices are contained IN a cycle not asking if the G contains a cycle. My attempt is that: So this graph would be an counter example that disprove that every vertex is contained in a cycle. Would like to know if this is a valid counter-example since V1 is n...
Problem Statement: Let $n\geq 2$ be a natural number. We are interested in sequences $(x_1,x_2,...,x_n)$ of natural numbers such that $$x_1+x_2+...+x_n = x_1x_2...x_n\text{ and }x_1\leq x_2\leq...\leq x_n.$$ Let $A(n)$ denote the set of all such sequences. Moreover, we denote by $a(n)$ the cardinality of the set $A(n...
In Breadth-first search and depth-first search, in this source code https://gist.github.com/gennad/791932 public void bfs() { // BFS uses Queue data structure Queue queue = new LinkedList(); queue.add(this.rootNode); printNode(this.rootNode); rootNode.visited = true; ...
I am looking to create a series of closed volumes that represent the empty voids made by rooms in a house. In order to do this, all I have is the raw geometry of all the elements that encapsulate these spaces (walls, floors and ceilings), in the form of closed meshes. Some additional requirements... The elements that ...
What happens if a CPU instruction (e.g. on ARM architecture) tries to access a physical address that is out of range. This easily could happen if the CPU is on non-virtual (non-paging) mode. This could also happen if the CPU is in paging mode and the page table maps the virtual address to a physical address that is out...
I had previously asked a question on space complexity of radix sort here. I have also read this question. However, I still get confused about it which means that the concept is not clear. I have the following implementation which is meant only for positive integers: #include <iostream> #include <vector> #include <array...
What alorithm/heuristic can be applied to get a shortest path to all the blue coordinates below without going through red coordinates? starting and ending in bottom left(0,0). I have list of all the blue and red coordinates.
In case I have sorted edges already, What is the best time complexity of Kruskal Algorithm?
I have a question about this. Because if the input binary strings have size of O(n), it takes exponential time to list all possibilities of it. If an language is in NEXP, then we can list all input possible input strings and then use exponential time to check each one, which is still in exponential time in total. It se...
Why the next idea doesn't work: If L_2 in R and L_1 in P and the languages are not trivial, then there is a polynomial-time reduction from L_1 to L_2 I know that if such reduction exists, than L_1 is also in R --> But L_1 is in P and P is in R, so everything looks OK :) Will be glad for your help here.
Maybe time complexity isn't the right term. Performance? There must be some way of describing the efficiency of a program over time. For instance, I recently had a part of a program that took a continual stream of discrete strings (~256 chars) and checked if each one was in some sort of set or container. Initially ...
In The Art of Computer Programming D. Knuth, in section 5.3.3 Minimum Comparison Selection defines : $V_t(n)$ as the minimum number of comparisons needed to find the $t^{th}$ largest element of $n$ numbers $W_t(n)$ as the minimum number of comparisons needed to find and sort the $t$ largest elements of $n$ numbers Th...
Say we have a modern (Skylake, say) Intel CPU running at a fixed 5GHz clock rate. Since Intel CPUs run micro-operations internally and reaches > 1 instructions per cycle, it needs to be able to run more than one micro-operation per cycle. But from how registers work we know that new data can only be stored and computat...
in Polyhedral Study of the Cardinality Constrained Knapsack Problem the authors prove that the Cardinality Constrained Knapsack Problem is NP-Hard by reducing PARTITION to it. Besides, it's easy to see that the KP problem is a special case of the QKP. How should one proceed to prove the NP-Hardness of the Cardinality C...
So I am stuck: I have this algorithm from which I need to find a loop invariant but I just can't get my head around it : main_f = x follow_up = x while (follow_up < y): follow_up = follow_up + 1 main_f = main_f + follow_up return main_f So basically I have a list of values of this function(main_f): Initialisati...
I am reading the "Introduction to Algorithms" by Thomas Cormen et al. Particularly the theorem which says that given an open-address hash table with load factor $\alpha = n/m < 1$, the expected number of probes in an unsuccessful search is at most $1/(1-\alpha)$, assuming uniform hashing. In the proof they are assuming...
I am reading the "Introduction to Algorithms" by Thomas Cormen et al. Particularly the theorem which says that given an open-address hash table with load factor α=n/m<1, the expected number of probes in an unsuccessful search is at most 1/(1−α), assuming uniform hashing. In the proof they are saying - $p_i$ = It is th...
One can define the semantics of one definite word using the references to real world entities, relationships with the other words and other concepts and represent all this knowledge about this one word using logical symbolic expressions. And then one can encode all this set of symbolic expressions into vector of real n...
If we define the Myhill-Nerode relation on a CFL how can i prove that there is at least one infinite equivalence class?
So aren’t MCV and LCV the exact opposite?MCV tries to choose the variable with the most constraints on remaining variables but LCV is opposite: it tries to rule out as least values for other variables as possible
I was reading about denotational semantics Broadly speaking, denotational semantics is concerned with finding mathematical objects called domains that represent what programs do. For example, programs (or program phrases) might be represented by partial functions. I was wondering, how does one map programs to partia...
I am trying to solve the following problem about maxflow mincut it seems like my conclusion is incorrect and I am wonder where. There is no graph just following question. An edge e can be (x) always full, (y) sometimes full, (z) never full; it can be (x') always crossing, (y') sometimes crossing, (z') never crossing. ...
I'm a beginner in Turing machine computation and want to design two TMs; one that converts decimal number to binary, and other one that converts binary to decimal. Could anyone help me design these Turing machines? How can I start? Thanks.
I need to solve an optimization problem, maximizing fitness in a set of around 1 million solutions. Calculating the fitness of any solution is very time consuming, taking around 5 minutes. Therefore, I am only able to calculate the fitness of 100 solutions per run. Each solution is represented by vector in ten dimensio...
For which case are both $f(n) \ne O(g(n))$ and $g(n) \ne O(f(n))$ true? I have following answer to this which I could not understand: Sometimes true: For $f(n) = 1$ and $g(n) = |n \sin n|$ it is true, while for any $f(n) = O(g(n))$, e.g. $f(n) = g(n) = 1$, it is not true. Please someone help in understanding: For wh...