instruction stringlengths 35 29.1k |
|---|
By an algorithm $A(p, t)$ attempting to decide whether the program $p$ halts or not by running the program for $t$ seconds (the timeout) and trying to prove that it doesn't halt at the same time, can it decide more and more programs as the time gets bigger, so that any program would result in the algorithm in showing u... |
I didn't find an exact description for this, but I know that any integer type is a simple bit pattern, it seems to me that the simple bit pattern should have a more exact description
as I understand simple bit pattern are synonym for primitives
|
In section 3.7.1, of the book titled: Compiler design in C, by Allen I. Holub (made available freely online, by the author here, & the page #19 of errata, here), have on page #176, the mention of grammar, for a right-recursive list:
stmt_list -> stmt stmt_list | stmt
stmt -> A | B| C
while on the previous page, the le... |
I'm looking at this diagram from Ben Eater's "8 bit computer" tutorial
What's the need to use separate 8 wires for only data input, and another 8 wires only for data output?
Why not use only 8 wires for both input and output to the bus?
|
There's a sentence in the current version of the Wikipedia page for Shor's algorithm which states: we can use efficient classical algorithms to check if $N$ is a prime power. No reference is provided to support it.
Is this true? I've tried to look around for such an algorithm but didn't find much.
There is this website... |
I have a list of lists T.
I stress test my database software by randomly adding and removing sublists and elements of sublists to/from T and from/to my database. (After this I compare T with the database, because they must be identical, because they underwent the same sequence of insertions/deletions.)
I want the rando... |
I am preparing for an exam in computability and still learning about the idea of reductions. I found an interesting problem to start with and am curious if my approach is correct:
Let H0 be the halting problem starting on an empty tape, and let A be a decision problem defined as A ∶= {x ∈ N ∣ x < 10}.
Show or disprove:... |
As far as I know, the halting problem means we can't create a program that checks whether another program is stuck or halt based on given input. This means, the program expects two inputs and one boolean output.
For example in a Python language, there's program called is_halt.py expecting one input integer. Let's say t... |
An undirected graph $G=(V,E)$ is "evenly connected" if for every $v\in V$ there's a (not neceserally simple!) path to all the other vertices, with even number of edges.
Let $G=(V,E)$ be an undirected graph where $3\leq |V|, 2\leq |E|$.
We want the minimal number of edges we need to add to $G$ in order to make the graph... |
There's a very similarly sounding question with an answer already, but my setup is very, very different.
You are given $k$ half spaces in dimension $d$, defined by a point and a direction. You want to find all vertices in the polytope if it is bounded, otherwise, you want to close it (i.e. make it bounded), then find a... |
I'm making a web application that can generate unique unsigned Int32 post IDs for posts. Normally I would just make it auto-increment from 0.
But I don't want the user to "guess" what's the next ID will be from their own post ID. So I would like the sequence to be random. Let's say the very first post has the ID of 968... |
I am currently reading the Crafting Interpreter book and I have a question about the Resolving and Binding chapter
The author gave this example to illustrate the problem with the implementation at that point in the book.
var a = "global";
{
fun showA() {
print a;
}
showA();
var a = "block";
showA();
}
T... |
I have been studying the polynomial hierarchy recently, and I came across an intriguing claim that I would like to explore further:
Assuming co-$NP\subseteq NP\text{/}P$, the claim states that it implies $\Sigma_3^P=\Pi_3^P$, which, in turn, leads to the conclusion that $PH=\Pi_3^P=\Sigma_3^P$.
I find this claim fascin... |
I had been reading about File systems recently and came across the File Allocation Table in FAT systems. As per my understanding the File Allocation Table contains entries of the various files stored in the partition. This includes things starting cluster, ending cluster, file name etc (I still didn't understand exactl... |
Consider the following variation on the Interval Scheduling Problem
You have a processor that can operate 24 hours a day, every day. People
submit requests to run daily jobs on the processor. Each such job comes with a start
time and an end time; if the job is accepted to run on the processor, it must run
continuously,... |
regular ANS collects all the data into one big integer and provides optimal compression. In cases where all the symbol probabilities are powers of two, it is just as good as huffman coding (because huffman coding is also optimal in this case).
Streaming ANS lets us avoid the need to use a BigInteger or other expensive ... |
I want to implement a delaunay triangulator by using incremental building, which is purported to be $O(n \log(n))$ I am a little puzzled about 2 things.
Ever resource I read on the matter says:
Make 3 points that are large enough to contain all other points.
For each point, find the face that contains it, split that f... |
I'm looking for the most efficient way of solving an Levenshtein edit distance problem.
We are given as input:
A set of strings S of size n <= 8, with average length m <= 50
A target string t of length l <= 50
Our task is to 'align' t with S i.e:
Find the subset s* of S, where concat(s*) has the minimum Levenshtei... |
I am a research scholar in the field of algorithms and complexity theory. The problem that I am currently working is the $[1,j]$-domination problem. Given a graph $G = (V, E)$, with $n = |V|$, the problem asks to compute a minimum dominating set $D$, such that all the vertices outside the solution set $D$ have at most ... |
Currently I'm exploring LALR(1) lookahead generation algorithms to implement. I've implemented Aho and Ullman one from their textbook, but recently stumbled upon "A new analysis of LALR formalisms" paper by Park, Choe, Chang.
There they propose an efficient algorithm (commonly referred to as PCC) and provide proofs, pe... |
Assume we have a set of $s$ vertices, say $\{w_1,\ldots,w_s\}$. Assume every vertex $w_i$ has at most $q$ neighbours coloured either red or blue, for some positive integer $q\ge 1$. I would like to check how many neighbours of each colour $w_i$ for each $i\in \{1,\ldots,s\}$ has. What is the complexity of doing it?
Sin... |
I've been playing Bananagrams recently, and have begun to wonder about the math behind it from a computational perspective. I've tried to formalize the problem as a decision problem below.
Loosely formal definition:
Given a finite set (alphabet) $A$ of letters, a finite set (dictionary) $D \subset$(Set of all finite ... |
One classic fair division allocation problem is to allocate indivisible goods among agents with respect to envy freeness (no agent envies another agent).
In my settings, all the goods are divisible (we can split the goods), but we restrict the number of shared goods to one. So only one good can be split, but the split ... |
I've been doings some research into distributed solutions for a large system of linear equations (reading papers such as Wang et al.'s "Solving a system of linear equations: From centralized to distributed algorithms"). Before implementing a solution myself I wanted to see if there are already any free or paid implemen... |
LeetCode problem 1386. Cinema Seat Allocation requires finding the number of 4-person seating groups available (subject to certain constraints) after individual seat reservations have been made. The problem is tagged by LeetCode as Greedy.
The constraints are that there are only 3 permissible 4-person groupings per row... |
Could someone clarify what strings are accepted by the described DFA?
Draw a DFA for the set of all strings with two consecutive 0’s followed by two consecutive 1’s over Ʃ= {0,1}
|
Assume I generate a random binary tree with a bounded height with $n$ nodes.
For a given key we measure the length of its path (the maximum can be $n-1$). So my Question is what is the distribution of the path length?
The tree is constructed by recursively partitioning the given n points until all points are isolated o... |
What I need is similar to garbage collection but a bit different, consider the following code:
int* large_arr = new int [1000000];
...
int b = large_arr[0];
int c = large_arr[1] * large_arr[2];
//after here large_arr is never used
int d = b + c;
...
So whether it's possible for compilers to detect after the comment li... |
Consider sorting on $n$ distinct elements, where all $n!$ permutations are possible. I think a decision tree for comparison sort can can be uniquely characterized as $T(a,n!)$ where $a$ is the comparison sort algorithm and $n!$ is the number of leaves. I believe there's a bijection between number of leaves and the numb... |
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?
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.