6 · Cs · 30 questions
Computer Science
Algorithms, complexity, automata, number representation and digital logic.
algorithms 7boolean algebra 5digital logic 3formal languages 3automata 2computational geometry 2logic 2floating point 2texstudio 1ubuntu 1matrices 1texmaker 1graphics 1singular value decomposition 1discrete mathematics 1proofs 1modular arithmetic 1pseudocode 1numerical methods 1approximation 1windows 1
Calculators
Questions
- What Is the Time Complexity of a Modulo Operation?Modulo is usually constant time for fixed-width integers, but its cost grows with the bit lengths of arbitrary-precision operands.
- How to Fix TeXstudio Not Starting After an Ubuntu 16.04 UpgradeIf TeXstudio will not start after upgrading to Ubuntu 16.04, use its terminal error to check the package, Qt plugins, and missing libraries.
- How to Simplify X'YZ + XY'Z + XYZ'The expression is already minimal in sum-of-products form: it is true exactly when two of X, Y, and Z are true.
- How Does Strassen’s Recursive Matrix Multiplication Work?Strassen’s algorithm multiplies matrices recursively using seven block products instead of eight, reducing the arithmetic complexity to about n^2.807.
- How to Resize the Editor and Other Panels in TexmakerResize Texmaker's editor, PDF viewer, and side panels by dragging their shared divider; change the editor font separately to adjust text size.
- What Are Right- and Left-Linear Grammars?Learn how right- and left-linear grammars differ, see a worked example, and understand why each generates regular languages.
- How to Prove That a Formal Grammar Is CorrectProve grammar correctness by showing soundness and completeness: the grammar generates every intended string and no unintended strings.
- What Does Propositional Logic Entailment Mean?Propositional entailment means every valuation satisfying the premises also satisfies the conclusion; use truth tables or test Γ and not φ for consistency.
- Why Every P Problem Reduces to Any Nontrivial NP-Complete ProblemUnder polynomial-time many-one reductions, every problem in P reduces to every nontrivial target, including every NP-complete problem.
- How to Determine a Language from a Recursive DefinitionA set over {a,b} cannot be identified without its base cases and recursive rules; learn what details determine the language and how to derive examples.
- Why Doesn't My knitr Example Produce Graphics?Troubleshoot missing knitr graphics by checking chunk options, plotting commands, explicit printing, and whether you rendered the output document.
- How to Interpret SVD in Text Mining and Topic AnalysisSVD represents a term-document matrix using latent directions, allowing you to interpret reduced dimensions as broad textual themes.
- Fast 2D Line–Triangle Intersection TestTest whether an infinite 2D line intersects a triangle using three cross products, without calculating an intersection point or dividing.
- Which Discrete Mathematics Books Are Best for Computer Science Self-Study?For computer science self-study, compare Rosen, Epp, and MIT's free Mathematics for Computer Science, then choose one book and work its exercises.
- How to Compute the Modular Inverse in Elliptic-Curve AdditionFor elliptic-curve addition over a prime field, invert the coordinate difference modulo p with the extended Euclidean algorithm—not ordinary division.
- How to Build a Logic Circuit in Conway’s Game of LifeConway’s Game of Life can compute with moving patterns such as gliders; design a Boolean circuit first, then implement and test its signal interactions.
- Can an NFA Reach Two Final States at the Same Time?An NFA can have multiple accepting states reachable after the same input. Acceptance requires at least one successful path, not a unique final state.
- What Is the Boolean Expression for a 3-Input XOR Gate?A 3-input XOR outputs 1 for odd-parity inputs. Its expression is A XOR B XOR C, or A'B'C + A'BC' + AB'C' + ABC.
- How Do Brackets Work in Boolean Algebra’s Distributive Laws?Learn how parentheses group Boolean expressions, when to distribute AND or OR, and how to simplify bracketed expressions without changing their value.
- What Does a 3-Input XOR Gate Do?A 3-input XOR outputs 1 when an odd number of inputs are high. See its truth table, Boolean expression, and two-gate implementation.
- How to Write Pseudocode in Markdown and Export It to PDFUse a fenced code block for plain pseudocode, or embed a LaTeX algorithm environment in Pandoc Markdown for a numbered, structured PDF algorithm.
- How to Apply Alpha-Max-Beta-Min to Three NumbersThe two-input alpha-max-beta-min formula does not directly extend to three values; sort their magnitudes and include the middle value.
- How to Convert a Number to BinaryUse repeated division by 2 for the integer part and repeated multiplication by 2 for the fraction, then normalize and round for IEEE 754.
- Can Any NFA Be Converted to a DFA?Yes. Every finite NFA has an equivalent DFA; the subset construction tracks sets of possible NFA states, with up to 2^n DFA states.
- Why Is There a Conflict Between UTF-8 and ANSI Encoding?UTF-8 and “ANSI” are not competing text formats: encoding mismatches happen when software decodes bytes using the wrong code page. Learn how to diagnose and fix them.
- How to Create an Algorithm for Solving a Rubik’s CubeA Rubik’s Cube solver needs a cubie-state model, legal move tables, and a search strategy such as IDA* with pattern databases.
- How to Find the Mantissa in a Floating-Point Binary NumberTo find a floating-point mantissa, split the IEEE 754 fields, restore the implicit leading bit for normal values, and account for subnormals.
- How Does the Closest-Pair-of-Points Algorithm Work?The divide-and-conquer closest-pair algorithm finds the nearest two points in 2D in O(n log n) time by checking a narrow strip after each split.
- How to Get a Simplified Sum of Products from a Truth TableWrite the canonical SOP from the rows where the output is 1, then simplify with Boolean algebra or a Karnaugh map. Fully worked 3-variable example.
- Insertion Sort Average Case – Comparisons, Shifts and Θ(n²)Derivation of insertion sort's average case on a random permutation, about n²/4 comparisons and shifts, with the exact formula (n² + 3n)/4 − Hₙ.