sqil, sqil, imitation learning
Combine IL and RL.
1,106 technical terms and definitions
Combine IL and RL.
Soft Q Imitation Learning simplifies imitation learning by labeling expert demonstrations with reward one and agent experience with reward zero.
Generate database queries from natural language.
Generate SQL from natural language. Text-to-SQL models.
Text-to-SQL converts natural language to SQL queries. Requires schema understanding. Fine-tune or few-shot for accuracy.
I can help you design schemas, write SQL queries, optimize indexes, and explain Postgres/TimescaleDB features in simple terms.
Reading comprehension benchmark.
Stanford Question Answering Dataset tests reading comprehension.
Query-efficient black-box attack.
Squeeze-and-Excite adds channel attention. Recalibrate features. Small overhead, accuracy gain.
Channel-wise attention mechanism.
Squeeze-and-excitation blocks recalibrate channel-wise features through global pooling and gating.
Session-based Recommendation with Graph Neural Networks uses gated graph neural networks to model item transitions within sessions.
Tiny features on mask to improve main pattern.
Yield of memory arrays sensitive to variation.
Session-based recommendation with graph neural networks includes multiple architectural variants for capturing transitions.
Stochastic Recurrent Neural Network uses stochastic hidden states for modeling uncertainty in sequences.
Server-Sent Events stream data from server. One-way. Good for LLM token streaming.
Structural similarity measure.
Simultaneous Switching Output noise occurs when multiple drivers switch creating transient currents that couple into power and signal nets.
Statistical Static Timing Analysis propagates delay distributions through timing graphs.
Multi-class structured SVMs handle problems with structured inputs and multiple output classes using joint feature representations.
Consistency over time.
Measurement stability is consistency of bias over time.
Consistency of measurements over time.
Open-source latent diffusion model.
Stable Diffusion generates images through latent space diffusion with text conditioning.
Stable Diffusion generates images from text. Latent diffusion for efficiency. Open source, highly customizable.
StableLM is Stability AI language model. Various sizes.
Stack AI is enterprise no-code AI platform.
Answer programming questions.
Planar defects in crystal.
Train meta-model on predictions from base models.
Stacking trains meta-model on predictions. Learns to combine.
Chemical treatment to enhance defects.
Retrieved docs may be outdated.
Short-Term Attention Memory Priority model uses attention to capture both general interests and current intent for session recommendation.
Determine position toward target (favor oppose neutral).
Pre-designed logic gates for digital design.
Patents required for standards.
Standard operating procedures define approved methods for activities.
High-quality reference from standards body.
Standard work documents best-known methods ensuring consistency and continuous improvement baseline.
Standardize establishes consistent procedures maintaining workplace organization.
Use z-scores for different processes.
Time waiting for operator or material.
Standing waves form on transmission lines from constructive interference between incident and reflected signals.
Gap between package and board.
# Computer Science Journey Roadmap for a Bright Future Computer Scientist ## Computer Science ## Timeline | Phase | Focus | |-------|-------| | **Spark** | Curiosity, patterns, play-based logic | | **Foundation** | Basic math, computational thinking, typing | | **Building** | Pre-algebra, visual programming, problem-solving | | **Acceleration** | Algebra through Pre-Calculus, real programming | | **Mastery** | Calculus, AP courses, projects, competitions | | **Launch** | Stanford application, ready for CS 106A | ## Phase 1: The Spark Years ### What's Happening Build the mental architecture. ### Daily Activities **Pattern Recognition (Foundation of ALL Computing)** - Sorting toys by color, size, shape - "What comes next?" games with blocks - Finding patterns in nature (leaves, flowers, clouds) - Simple puzzles (start with 4 pieces, work up) **Sequencing (The Heart of Algorithms)** - Following recipe steps with a parent - Getting dressed in order (underwear before pants!) - Telling stories with "first, then, finally" - Building block towers step-by-step **Counting & Numbers** - Count everything: stairs, apples, fingers - Number recognition games - Simple board games with dice - Comparing quantities (more/less/same) ### Recommended Resources | Resource | Type | Why It's Great | |----------|------|----------------| | **Cubetto** | Physical robot | Screen-free coding concepts | | **Code-a-Pillar** | Toy | Sequencing through play | | **Robot Turtles** | Board game | First programming game | | **Pattern blocks** | Manipulatives | Spatial reasoning | | **Osmo** | iPad + physical | Tangram and numbers | ### Role - No screens for learning yet (play outside!) - Ask "why?" and "what if?" questions - Let frustration happen — it builds persistence - Celebrate attempts, not just successes - Read books about scientists and inventors ## Foundation Years ### Math Progression **Build Knowledge** - Addition and subtraction to 20 - Place value (ones, tens) - Basic shapes and their properties - Simple word problems - Introduction to measurement **Continue** - Addition/subtraction to 100 - Introduction to multiplication (groups) - Basic fractions (½, ¼) - Time telling - Mental math strategies **More** - Multiplication tables (master them!) - Division concepts - Fractions on number line - Basic geometry - Introduction to area and perimeter ### Computational Thinking Introduction **Decomposition**: Breaking problems into smaller parts - "How do we clean this room?" → List of small tasks - Building LEGO sets step by step - Planning a birthday party **Pattern Recognition**: Finding similarities - Number patterns - Word patterns (rhyming) - Patterns in music **Abstraction**: Focusing on important information - Giving directions (what details matter?) - Drawing maps - Simplifying complex games **Algorithms**: Step-by-step instructions - Writing "recipes" for daily tasks - Creating treasure hunt clues - Teaching someone a game ### Weekly Schedule Example | Day | Activity | Time | |-----|----------|------| | Mon | Math practice | 30 min | | Tue | Scratch project | 45 min | | Wed | Reading + logic puzzles | 30 min | | Thu | Math practice | 30 min | | Fri | Code.org course | 45 min | | Sat | STEM exploration | 1 hour | | Sun | Games (chess, board games) | 1 hour | ### Critical Skills to Develop - **Typing**: Start with proper finger placement - **Reading comprehension**: Essential for word problems - **Persistence**: Stick with hard problems - **Curiosity**: Ask questions about how things work ## Building Years ### Math Acceleration This is where you start pulling ahead. **Foundation** - Multi-digit multiplication - Long division - Fraction operations - Decimal introduction - Factors and multiples **Continue** - Fraction mastery (all operations) - Decimal operations - Percentage basics - Coordinate graphing introduction - Order of operations (PEMDAS) **More** - Pre-Algebra concepts - Negative numbers - Ratios and proportions - Basic equations - Statistical thinking (mean, median, mode) ### Programming Progression **Programming Foundation** - Complete games with scoring - Multiple sprites and levels - Variables and lists - User input handling - Cloning and procedures **Transition Languages** | Language | Platform | Purpose | |----------|----------|---------| | **Python** | Codecademy, Replit | Real text-based coding | | **JavaScript** | Khan Academy | Web interactivity | | **Swift Playgrounds** | iPad | Mobile development | ### First Python Programs to Write ```python Your first programs: 1. Hello World (print statement) 2. Calculator (user input, math operations) 3. Number guessing game (loops, conditionals) 4. Mad Libs (string manipulation) 5. Simple quiz game (functions) ``` ### Problem-Solving Development **Math Competitions to Explore** - AMC 8 preparation - MathCounts practice - Math Olympiad for Elementary Schools (MOEMS) **Logic and Reasoning** - KenKen puzzles - Logic grid puzzles - Chess (join a club!) - Strategy games ### Key Concepts to Understand | Concept | What It Means | Stanford Connection | |---------|---------------|---------------------| | Variables | Boxes that hold values | Used in CS 106A | | Loops | Repeating actions | Core programming skill | | Conditionals | If-then decisions | Fundamental logic | | Functions | Reusable code blocks | CS 107 foundation | | Data types | Numbers vs. text | Essential for CS 106B | ## Acceleration Years ### This Is Where Magic Happens Students who excel at Stanford CS typically have a strong foundation. ### Math Trajectory **Algebra I** - Linear equations and inequalities - Systems of equations - Graphing linear functions - Polynomials introduction - Factoring basics **Geometry + Algebra II** - Proofs and logical reasoning (!!!) - Geometric properties - Quadratic equations - Exponential functions - Complex numbers introduction **Pre-Calculus** - Trigonometry - Advanced functions - Sequences and series - Limits introduction - Polar coordinates ### Why Proofs Matter for Stanford CS CS 103 (Mathematical Foundations of Computing) is heavily proof-based. Starting geometry proofs at 13 gives you a 5-year head start on this critical skill. **Proof Types to Master:** 1. Direct proofs 2. Proof by contradiction 3. Proof by induction 4. Proof by cases ### Programming Deepening **Python Proficiency** ```python Projects to build: - Text-based adventure game - Simple web scraper - Data analysis with CSV files - Basic GUI applications - API interactions ``` **Data Structures Introduction** ```python Concepts to learn: - Lists and arrays - Dictionaries/hash maps - Stacks and queues - Basic recursion - File I/O operations ``` **Object-Oriented Programming** ```python Master these concepts: - Classes and objects - Inheritance - Encapsulation - Polymorphism - Design patterns basics ``` ### Stanford-Aligned Projects | Project | Skills Developed | Stanford Course Prep | |---------|------------------|----------------------| | Build a calculator app | OOP, GUI | CS 106A | | Create a game with classes | Data structures | CS 106B | | Simple database program | File handling, SQL basics | CS 145 | | Probability simulator | Statistics, Python | CS 109 | ### Extracurricular Development **Academic Competitions** - USA Computing Olympiad (USACO) — start Bronze division - AMC 10/12 mathematics - Science Olympiad - Hackathons (beginner level) **Personal Projects** - GitHub portfolio (start building!) - Open source contributions (documentation is fine) - Tutoring younger students - Blog about learning journey ### Resources for This Phase | Resource | Use Case | Cost | |----------|----------|------| | **Art of Problem Solving** | Advanced math | $20-30/book | | **USACO Training** | Competition prep | Free | | **MIT OpenCourseWare** | Preview college courses | Free | | **Brilliant.org** | Interactive learning | Subscription | | **LeetCode** | Programming practice | Free/Premium | ## Mastery Years ### The Stanford Preparation Phase This is when everything comes together. You're now directly preparing for the courses in your original list. ### Math Course Sequence **AP Calculus AB or Calculus (MATH 19 equivalent)** - Limits and continuity - Derivatives and their applications - Basic integration - Fundamental Theorem of Calculus **AP Calculus BC (MATH 20 equivalent)** - Advanced integration techniques - Series and sequences - Parametric and polar functions - Introduction to differential equations **Multivariable Calculus or Linear Algebra** This is strategic. You have two paths: | Path | What to Take | Benefit | |------|--------------|---------| | **Path A** | Multivariable Calculus (MATH 21 equiv) | Traditional, safe, Stanford accepts | | **Path B** | Linear Algebra | Directly prepares for MATH 51 | **My Recommendation**: If available, take Linear Algebra. Here's why: - MATH 51 is one of the hardest first-year courses - Linear algebra appears in CS 109, CS 229 (ML), and graphics - Most high schoolers do calculus but skip linear algebra ### Computer Science Courses **AP Computer Science A** - Java fundamentals - Object-oriented programming - Data structures basics - Algorithms introduction - Prepares for CS 106B **Beyond AP** | Option | Description | Stanford Benefit | |--------|-------------|------------------| | **AP CS Principles** | Broader CS exposure | Application looks well-rounded | | **Post-AP Algorithms** | Self-study algorithms | Ready for CS 161 | | **College courses** | Dual enrollment | Proves readiness | | **Research projects** | Independent work | Application standout | ### Statistics Preparation Stanford's CS requires probability (CS 109 or STATS 116). Prepare by: **AP Statistics** - Descriptive statistics - Probability fundamentals - Inferential statistics - Regression analysis **Probability deepening** - Combinatorics - Conditional probability - Bayes' theorem - Probability distributions ### Building Your Stanford Application **Freshman Year of HS** - Join coding club/competition team - Start USACO seriously - Begin math competition prep - Explore CS areas (AI, systems, theory) **Sophomore Year** - Lead club projects - Advance in USACO (aim for Silver/Gold) - Summer coding camp or internship - Start personal project portfolio **Junior Year** - Major leadership role - Research opportunity (reach out to professors!) - Significant independent project - Strong AP scores - AMC/AIME performance **Senior Year** - Application submission - Continue projects - Mentor younger students - Maintain excellence ### Sample Junior Year Schedule | Course | Why | |--------|-----| | AP Calculus BC | Core math requirement | | AP Physics C (Mechanics) | Mathematical physics | | AP Computer Science A | Programming foundation | | AP English | Communication skills | | Honors History | Breadth | | Linear Algebra (if available) | MATH 51 prep | ### Competition Goals | Competition | Target Level | |-------------|--------------| | USACO | Gold or Platinum division | | AMC 12 | 120+ score | | AIME | Qualification | | Science Olympiad | State level | | Hackathons | Multiple wins | ## Mapping to Stanford Requirements Now let's explicitly connect your preparation to every course you listed. ### CS Core Requirements | Stanford Course | Preparation | Key Prerequisite Skills | |-----------------|---------------------------|-------------------------| | **CS 106A** | Python | Variables, loops, functions, OOP | | **CS 106B** | data structures, Java | Recursion, pointers, memory | | **CS 107** | Self-study | C programming, assembly basics | | **CS 103** | Geometry proofs, discrete math | Logic, proofs, set theory | | **CS 109** | AP Statistics + probability self-study | Counting, probability theory | | **CS 161** | USACO training, algorithm courses | Big-O, sorting, graphs | ### Math Requirements | Stanford Course | Your Preparation | |-----------------|------------------| | **MATH 19/20/21** | AP Calculus AB/BC | | **MATH 51** | Linear algebra exposure | | **MATH 52** | Multivariable calc | | **MATH 53** | Differential equations intro | ### Statistics Path | Stanford Course | Your Preparation | |-----------------|------------------| | **STATS 116/117** | AP Statistics + probability | | **CS 109** | Coding + probability combined | ## Complete Resource Library ### By Age Group **Entry Level** - Hello Ruby by Linda Liukas - My First Coding Book (DK) - Cubetto robot - Pattern blocks and tangrams **Fundamental** - Coding Games in Scratch (DK) - ScratchJr and Scratch - Code.org (free) - Math Olympiad Contest Problems **Advanced** - Python for Kids by Jason Briggs - Khan Academy (math + computing) - Beast Academy (math) - AMC 8 prep books **Continue** - Introduction to Algorithms (CLRS) — start exposure - Art of Problem Solving series - Codecademy Pro - Brilliant.org - USACO training pages **More** - How to Prove It by Daniel Velleman - Discrete Mathematics and Its Applications by Rosen - MIT OpenCourseWare - Stanford's own free courses - Concrete Mathematics by Graham, Knuth, Patashnik ### Online Platforms | Platform | Best For | |----------|----------| | **Khan Academy** | Math, basics | | **Brilliant** | Interactive learning | | **Art of Problem Solving** | Advanced math | | **USACO** | Competition prep | | **Codecademy** | Programming courses | | **LeetCode** | Algorithm practice | | **Coursera** | College courses | | **edX** | College courses | ## Your Personalized Path Based on Interest You mentioned three recommended paths. Let me give you early indicators and preparation for each. ### Path 1: Theoretical CS / Math Research **Early Signs** - Fascinated by "why" not just "how" - Enjoys puzzles for hours - Loves abstract patterns - Asks deep questions about infinity, logic **Special Preparation** - Extra emphasis on proof-writing - Philosophy and logic exploration - Mathematical olympiad focus - Graduate-level textbooks early **Key Courses to Target:** - MATH 61DM series - CS 154 (Automata and Complexity) - CS 265 (Randomized Algorithms) ### Path 2: Applied Computational Math **Early Signs** - Loves building things - Interested in physics and engineering - Enjoys optimization ("fastest way to...") - Data and measurements are fascinating **Special Preparation** - Strong physics background - Numerical methods introduction - Engineering projects (robotics, etc.) - Scientific computing focus **Key Courses to Target:** - CME 100/102/104 series - CS 205L (Continuous Methods) - Optimization courses ### AI/ML with Mathematical Foundations **Early Signs** - Fascinated by robots and "thinking machines" - Pattern recognition comes naturally - Interested in how brains work - Loves prediction games **Special Preparation** - Extra statistics and probability - Neural network intuition early (age 13+) - Psychology and cognitive science exposure - Data science projects **Key Courses to Target:** - CS 229 (Machine Learning) - CS 231N (Deep Learning) - STATS 315A/B (Statistical Learning) ## Progress Tracking Milestones ### Math Milestones | Milestone | Check | |-----------|-------| | Count to 100, basic addition | Addition/subtraction fluency | Multiplication tables mastered | Fraction/decimal operations | Pre-algebra completion | Algebra I completion | Geometry + Algebra II | Pre-Calculus completion | AP Calculus BC (5 score) | Linear Algebra or higher ### Programming Milestones | Milestone | Check | |-----------|-------| | First Scratch project | Complete game in Scratch | First Python program | Python project portfolio (3+) | Data structures understanding | OOP mastery | Algorithm analysis (Big-O) | USACO Silver | USACO Gold + substantial projects ### CS Theory Milestones | Milestone | Check | |-----------|-------| | First mathematical proof written | Proof techniques familiarity | Discrete math basics | Logic and set theory | Ready for CS 103 level material ## Mindset Principles for the Journey ### 1. Embrace Productive Struggle The feeling of being stuck is where learning happens. Stanford CS students struggle regularly — it's part of the experience. ### 2. Build, Don't Just Learn Every concept should connect to a project. Don't just learn recursion — build a fractal generator. ### 3. Teach to Learn The best way to solidify knowledge is to teach it. Start tutoring when you're ahead. ### 4. Depth Over Breadth (Eventually) Early years: explore everything Teen years: go deep in areas of passion ### 5. Maintain Joy If computer science stops being fun, something is wrong. Recalibrate. ## Study Role ### Your Role is Everything - You are the primary "teacher" through play - Model curiosity and problem-solving - Provide materials but don't over-direct - Limit screens; maximize physical exploration ### Facilitator Role - Find programs, camps, and resources - Monitor progress without pressure - Connect with other parents of curious kids - Balance enrichment with childhood joy ### Coach Role - Help set goals and track progress - Facilitate competition registration - Encourage independence - Provide emotional support during struggles ### Advisor Role - Help with college planning - Support research opportunities - Guide but don't control extracurriculars - Trust the preparation you've built ### Key Cautions - **Burnout is real**: This is a marathon, not a sprint - **Comparison is poison**: Every child's path is unique - **Mental health first**: No school is worth your child's wellbeing - **Stanford is not the only path**: This preparation serves any great CS program
# Stanford University: Computer Science & Mathematics Programs ## Overview Stanford University offers multiple pathways for students interested in the intersection of **computer science** and **mathematics**. These programs span: - Undergraduate degrees with interdisciplinary focus - Specialized graduate programs (MS/PhD) - Research opportunities in theoretical computer science - Applied computational mathematics ## Undergraduate Programs ### 1. Computer Science B.S. #### Math Requirements The CS major requires **26 units** of mathematics: - **Core CS Math Classes:** - `CS 103` - Mathematical Foundations of Computing - `CS 109` - Introduction to Probability for Computer Scientists - **Calculus Requirement:** - `MATH 19/20/21` sequence, or - AP Credit (up to 10 units with placement into `MATH 51/CME 100`) - **Linear Algebra:** - `MATH 51` - Linear Algebra, Multivariable Calculus, and Modern Applications - **Additional Math Electives:** 2 courses from approved list #### CS 103: Mathematical Foundations Topics covered include: - Proof techniques and formal logic - Mathematical induction - Sets, functions, and relations - Formal languages theory - Deterministic Finite Automata (DFA) - Non-deterministic Finite Automata (NFA) - Regular Expressions: $L(R) = \{w \mid w \text{ matches } R\}$ - Context-Free Grammars (CFG) - Turing Machines - NP-Completeness: $P \stackrel{?}{=} NP$ #### CS 109: Probability for Computer Scientists Key mathematical concepts: - **Combinatorics:** - Permutations: $P(n,k) = \frac{n!}{(n-k)!}$ - Combinations: $C(n,k) = \binom{n}{k} = \frac{n!}{k!(n-k)!}$ - **Probability Axioms:** - $P(\Omega) = 1$ - $P(A) \geq 0$ for all events $A$ - $P(A \cup B) = P(A) + P(B)$ if $A \cap B = \emptyset$ - **Conditional Probability:** $$P(A|B) = \frac{P(A \cap B)}{P(B)}$$ - **Bayes' Theorem:** $$P(A|B) = \frac{P(B|A) \cdot P(A)}{P(B)}$$ - **Law of Large Numbers:** $$\bar{X}_n \xrightarrow{p} \mu \text{ as } n \to \infty$$ - **Central Limit Theorem:** $$\frac{\bar{X}_n - \mu}{\sigma/\sqrt{n}} \xrightarrow{d} N(0,1)$$ ### 2. Data Science B.S. **Note:** Replaced the Mathematical and Computational Science (MCS) program as of August 30, 2022. #### Program Structure - **Math Core (15 units):** - `MATH 51` - Linear Algebra, Multivariable Calculus (5 units) - *Substitution:* `MATH 61CM` or `MATH 61DM` - `MATH 52` - Integral Calculus of Several Variables (5 units) - *Substitution:* `MATH 62CM` or `MATH 63DM` - `MATH 53` - Differential Equations with Linear Algebra (5 units) - *Substitution:* `MATH 63CM` or `MATH 131P` - **Statistics Core:** - `STATS 117` - Introduction to Probability Theory (3 units) - `STATS 118` - Probability Theory for Statistical Inference (3 units) - *Alternative:* `CS 109` / `MS&E 120` / `EE 178` - **Computer Science Core:** - `CS 106A` - Programming Methodology (5 units) - `CS 106B` - Programming Abstractions (5 units) - `CS 107` - Computer Organization and Systems (5 units) - **Gateway Courses:** - `DATASCI 112` - Principles of Data Science - `DATASCI 154` - Data-Driven Decision Making #### Subplans Available 1. **Mathematics and Computation** - Technical foundations 2. **Biology and Medicine** - Biomedical data applications 3. **Computational Neuroscience** - Neural data analysis 4. **Quantitative Finance** - Financial modeling #### Key Mathematical Concepts in Data Science - **Linear Regression:** $$\hat{\beta} = (X^TX)^{-1}X^Ty$$ - **Gradient Descent:** $$\theta_{t+1} = \theta_t - \alpha \nabla_\theta J(\theta_t)$$ - **Maximum Likelihood Estimation:** $$\hat{\theta}_{MLE} = \arg\max_\theta \prod_{i=1}^{n} f(x_i | \theta)$$ - **Cross-Entropy Loss:** $$H(p,q) = -\sum_{x} p(x) \log q(x)$$ ### 3. Mathematics B.S. with CS Theory/Discrete Mathematics Subplan #### Purpose Designed for students seeking deep background in: - Computer science theory - Discrete mathematics - Preparation for graduate studies in either field #### Requirements (64 total units) - **Math Department Courses:** 49 units minimum - Courses numbered 101 and above - At most 15 units from `MATH 50/60CM/60DM` series - **Additional Electives:** 15 units - Courses with significant mathematical content - Up to 6 units may be CR/NC - **Recommended Sequence:** - `MATH 61DM` - Modern Mathematics: Discrete Methods I (5 units) - `MATH 62DM` - Modern Mathematics: Discrete Methods II (5 units) - `MATH 63DM` - Modern Mathematics: Discrete Methods III (5 units) #### Required CS Courses | Course | Title | Units | |--------|-------|-------| | `CS 103` | Mathematical Foundations of Computing | 5 | | `CS 161` | Design and Analysis of Algorithms | 5 | #### Additional Required Math - `MATH 116` or `MATH 143` or `MATH 144` or `MATH 147` (4 units) - Logic course from approved list - Combinatorics/Discrete Math courses #### Key Theorems and Concepts - **Master Theorem** (Algorithm Analysis): For recurrence $T(n) = aT(n/b) + f(n)$: $$ T(n) = \begin{cases} \Theta(n^{\log_b a}) & \text{if } f(n) = O(n^{\log_b a - \epsilon}) \\ \Theta(n^{\log_b a} \log n) & \text{if } f(n) = \Theta(n^{\log_b a}) \\ \Theta(f(n)) & \text{if } f(n) = \Omega(n^{\log_b a + \epsilon}) \end{cases} $$ - **Graph Theory - Euler's Formula:** $$V - E + F = 2$$ where $V$ = vertices, $E$ = edges, $F$ = faces - **Pigeonhole Principle:** If $n$ items are placed into $m$ containers with $n > m$, at least one container has $> 1$ item. - **Stirling's Approximation:** $$n! \approx \sqrt{2\pi n}\left(\frac{n}{e}\right)^n$$ ### 4. Symbolic Systems B.S. #### Program Overview Interdisciplinary program integrating: - Computer Science - Linguistics - Mathematics - Philosophy - Psychology - Statistics #### Core Requirements - **Foundation Courses:** - `SYMSYS 1` - Minds and Machines (gateway course) - Single-variable calculus sequence - `MATH 51` or `CME 100` (Linear Algebra) - **Breadth Requirements** (four methodological areas): 1. **Philosophy:** Critical reasoning, argumentation 2. **Linguistics:** Language structure and processing 3. **Psychology:** Cognitive processes 4. **Computer Science:** Computational methods - **Probability Requirement:** - `STATS 116` - Theory of Probability, or - `CS 109` - Probability for Computer Scientists - **Cross-Area Requirement:** - Course connecting multiple disciplines #### Concentrations Available - Artificial Intelligence - Cognitive Science - Human-Computer Interaction - Natural Language Processing - Decision Making and Rationality #### Notable Alumni - **Reid Hoffman** - LinkedIn founder (B.S. 1990) - **Marissa Mayer** - Former Yahoo CEO (B.S. 1997) - **Mike Krieger** - Instagram co-founder (B.S. 2008) - **Scott Forstall** - iPhone software development leader ## Graduate Programs ### 1. ICME (Institute for Computational & Mathematical Engineering) #### Program Overview - **Founded:** 2004 (building on SCCM program from 1989) - **Degrees Offered:** M.S. and Ph.D. - **School:** Stanford School of Engineering - **Faculty:** 50+ affiliated faculty from 20+ departments #### M.S. Program Tracks 1. **General Track** - Mathematical modeling in physical/engineering sciences - Core computational and mathematical engineering courses - Programming coursework - Breadth and depth electives 2. **Data Science Track** - Mathematical, statistical, computational foundations - Machine learning and data analysis - Programming in Python, R, C++ 3. **Imaging Science Track** - Mathematical models for imaging/inverse problems - Medical, biological, physics applications - High-performance computing 4. **Mathematical and Computational Finance Track** - Stochastic calculus - Financial modeling - Risk analysis 5. **Computational Geosciences Track** - Earth science numerical methods - High-performance computing for geosciences #### Ph.D. Program Core coursework includes: - Matrix computations - Optimization theory - Stochastic processes - Discrete mathematics - Partial differential equations #### Key Mathematical Areas - **Matrix Computations:** - SVD: $A = U\Sigma V^T$ - Eigendecomposition: $Av = \lambda v$ - Condition number: $\kappa(A) = \|A\| \cdot \|A^{-1}\|$ - **Optimization:** - Convex optimization: $\min_{x} f(x)$ subject to $g_i(x) \leq 0$ - KKT conditions: $$\nabla f(x^*) + \sum_{i=1}^{m} \lambda_i \nabla g_i(x^*) = 0$$ $$\lambda_i g_i(x^*) = 0, \quad \lambda_i \geq 0$$ - **Stochastic Differential Equations:** $$dX_t = \mu(X_t, t)dt + \sigma(X_t, t)dW_t$$ - **Numerical PDEs:** - Finite difference: $\frac{\partial u}{\partial t} \approx \frac{u^{n+1}_i - u^n_i}{\Delta t}$ - Finite element methods - Spectral methods ### 2. Theoretical Computer Science (CS Theory Group) #### Research Areas - **Complexity Theory** - Time complexity classes: $P, NP, PSPACE, EXP$ - Space complexity: $L, NL, PSPACE$ - Circuit complexity - **Cryptography** - Public-key cryptography - Zero-knowledge proofs - Post-quantum cryptography - **Algorithm Theory** - Approximation algorithms - Randomized algorithms - Online algorithms - **Quantum Computing** - Quantum algorithms - Quantum complexity: $BQP, QMA$ - Quantum error correction - **Algorithmic Game Theory** - Mechanism design - Price of anarchy - Nash equilibrium computation - **Geometric Algorithms** - Computational geometry - High-dimensional geometry #### Key Complexity Classes $$P \subseteq NP \subseteq PSPACE \subseteq EXP$$ - **P:** Polynomial time solvable $$P = \bigcup_{k \geq 1} DTIME(n^k)$$ - **NP:** Nondeterministic polynomial time $$NP = \{L : \exists \text{ poly-time verifier } V, \text{ poly } p, \forall x \in L, \exists w, |w| \leq p(|x|), V(x,w) = 1\}$$ - **BPP:** Bounded-error probabilistic polynomial time $$BPP = \{L : \exists \text{ probabilistic poly-time } M, P[M(x) = L(x)] \geq 2/3\}$$ ## Key Courses ### Foundational Mathematics Courses | Course | Title | Units | Key Topics | |--------|-------|-------|------------| | `MATH 19` | Calculus | 3 | Limits, derivatives, integrals | | `MATH 20` | Calculus | 3 | Integration techniques, series | | `MATH 21` | Calculus | 3 | Differential equations, multivariable intro | | `MATH 51` | Linear Algebra & Multivariable Calculus | 5 | Matrices, vector spaces, gradients | | `MATH 52` | Integral Calculus of Several Variables | 5 | Multiple integrals, vector calculus | | `MATH 53` | Differential Equations | 5 | ODEs, Fourier methods | ### Discrete Mathematics Sequence | Course | Title | Units | Key Topics | |--------|-------|-------|------------| | `MATH 61DM` | Discrete Methods I | 5 | Proofs, combinatorics | | `MATH 62DM` | Discrete Methods II | 5 | Graph theory, number theory | | `MATH 63DM` | Discrete Methods III | 5 | Advanced topics | ### Computer Science Theory Courses | Course | Title | Units | Key Topics | |--------|-------|-------|------------| | `CS 103` | Mathematical Foundations | 5 | Logic, automata, computability | | `CS 109` | Probability | 5 | Probability theory, statistics | | `CS 154` | Introduction to Automata and Complexity | 3-4 | Formal languages, complexity | | `CS 161` | Algorithm Design and Analysis | 5 | Algorithm design, analysis | | `CS 265` | Randomized Algorithms | 3 | Probabilistic analysis | | `CS 261` | Optimization and Algorithmic Paradigms | 3 | Advanced optimization | ### Statistics Courses | Course | Title | Units | Key Topics | |--------|-------|-------|------------| | `STATS 116` | Theory of Probability | 4 | Probability theory | | `STATS 117` | Introduction to Probability | 3 | Basic probability | | `STATS 118` | Probability for Statistical Inference | 3 | Statistical foundations | | `STATS 191` | Applied Statistics | 3-4 | Regression, ANOVA | | `STATS 200` | Statistical Inference | 3 | Estimation, hypothesis testing | ## Mathematical Foundations ### Linear Algebra Essentials #### Vector Spaces A vector space $V$ over field $\mathbb{F}$ satisfies: - **Closure under addition:** $\forall u, v \in V: u + v \in V$ - **Closure under scalar multiplication:** $\forall \alpha \in \mathbb{F}, v \in V: \alpha v \in V$ - **Associativity:** $(u + v) + w = u + (v + w)$ - **Commutativity:** $u + v = v + u$ - **Additive identity:** $\exists 0 \in V: v + 0 = v$ - **Additive inverse:** $\forall v \in V, \exists (-v): v + (-v) = 0$ - **Distributivity:** $\alpha(u + v) = \alpha u + \alpha v$ #### Matrix Decompositions - **Singular Value Decomposition (SVD):** $$A = U \Sigma V^T$$ where $U \in \mathbb{R}^{m \times m}$, $\Sigma \in \mathbb{R}^{m \times n}$, $V \in \mathbb{R}^{n \times n}$ - **Eigenvalue Decomposition:** $$A = Q \Lambda Q^{-1}$$ where $\Lambda = \text{diag}(\lambda_1, \ldots, \lambda_n)$ - **QR Decomposition:** $$A = QR$$ where $Q$ is orthogonal, $R$ is upper triangular - **LU Decomposition:** $$A = LU$$ where $L$ is lower triangular, $U$ is upper triangular - **Cholesky Decomposition** (for positive definite $A$): $$A = LL^T$$ ### Probability Theory #### Discrete Distributions - **Bernoulli:** $P(X = 1) = p, P(X = 0) = 1-p$ $$E[X] = p, \quad Var(X) = p(1-p)$$ - **Binomial:** $P(X = k) = \binom{n}{k} p^k (1-p)^{n-k}$ $$E[X] = np, \quad Var(X) = np(1-p)$$ - **Poisson:** $P(X = k) = \frac{\lambda^k e^{-\lambda}}{k!}$ $$E[X] = \lambda, \quad Var(X) = \lambda$$ - **Geometric:** $P(X = k) = (1-p)^{k-1}p$ $$E[X] = \frac{1}{p}, \quad Var(X) = \frac{1-p}{p^2}$$ #### Continuous Distributions - **Uniform:** $f(x) = \frac{1}{b-a}$ for $x \in [a,b]$ $$E[X] = \frac{a+b}{2}, \quad Var(X) = \frac{(b-a)^2}{12}$$ - **Normal/Gaussian:** $$f(x) = \frac{1}{\sigma\sqrt{2\pi}} e^{-\frac{(x-\mu)^2}{2\sigma^2}}$$ $$E[X] = \mu, \quad Var(X) = \sigma^2$$ - **Exponential:** $f(x) = \lambda e^{-\lambda x}$ for $x \geq 0$ $$E[X] = \frac{1}{\lambda}, \quad Var(X) = \frac{1}{\lambda^2}$$ ### Algorithm Complexity #### Big-O Notation - **Big-O (upper bound):** $$f(n) = O(g(n)) \iff \exists c > 0, n_0: \forall n \geq n_0, f(n) \leq c \cdot g(n)$$ - **Big-Omega (lower bound):** $$f(n) = \Omega(g(n)) \iff \exists c > 0, n_0: \forall n \geq n_0, f(n) \geq c \cdot g(n)$$ - **Big-Theta (tight bound):** $$f(n) = \Theta(g(n)) \iff f(n) = O(g(n)) \text{ and } f(n) = \Omega(g(n))$$ #### Common Time Complexities | Complexity | Name | Example | |------------|------|---------| | $O(1)$ | Constant | Array access | | $O(\log n)$ | Logarithmic | Binary search | | $O(n)$ | Linear | Linear search | | $O(n \log n)$ | Linearithmic | Merge sort | | $O(n^2)$ | Quadratic | Bubble sort | | $O(n^3)$ | Cubic | Matrix multiplication (naive) | | $O(2^n)$ | Exponential | Subset enumeration | | $O(n!)$ | Factorial | Permutation enumeration | #### Recurrence Relations - **Divide and Conquer:** $$T(n) = aT(n/b) + f(n)$$ - **Examples:** - Merge Sort: $T(n) = 2T(n/2) + O(n) = O(n \log n)$ - Binary Search: $T(n) = T(n/2) + O(1) = O(\log n)$ - Strassen's Algorithm: $T(n) = 7T(n/2) + O(n^2) = O(n^{\log_2 7}) \approx O(n^{2.81})$ ## Research Areas ### Theoretical Computer Science at Stanford #### 1. Complexity Theory - **Open Problems:** - $P \stackrel{?}{=} NP$ (Millennium Prize Problem) - $P \stackrel{?}{=} BPP$ - $NP \stackrel{?}{=} coNP$ - **Key Results:** - Cook-Levin Theorem: SAT is NP-complete - Time Hierarchy Theorem - Space Hierarchy Theorem #### 2. Cryptography - **RSA Encryption:** - Public key: $(n, e)$ where $n = pq$ - Private key: $d$ where $ed \equiv 1 \pmod{\phi(n)}$ - Encryption: $c = m^e \mod n$ - Decryption: $m = c^d \mod n$ - **Discrete Log Problem:** Given $g, h$ in group $G$, find $x$ such that $g^x = h$ #### 3. Machine Learning Theory - **PAC Learning:** $$P[\text{error}(h) \leq \epsilon] \geq 1 - \delta$$ Sample complexity: $m \geq \frac{1}{\epsilon}\left(\ln|H| + \ln\frac{1}{\delta}\right)$ - **VC Dimension:** Maximum $n$ such that hypothesis class $H$ can shatter some set of $n$ points - **Bias-Variance Tradeoff:** $$E[(y - \hat{f}(x))^2] = \text{Bias}^2(\hat{f}) + \text{Var}(\hat{f}) + \sigma^2$$ #### 4. Quantum Computing - **Qubit State:** $$|\psi\rangle = \alpha|0\rangle + \beta|1\rangle, \quad |\alpha|^2 + |\beta|^2 = 1$$ - **Quantum Gates:** - Hadamard: $H = \frac{1}{\sqrt{2}}\begin{pmatrix} 1 & 1 \\ 1 & -1 \end{pmatrix}$ - Pauli-X: $X = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}$ - CNOT: Controlled-NOT gate - **Shor's Algorithm:** Factors $n$ in $O((\log n)^3)$ quantum time - **Grover's Algorithm:** Searches unsorted database of $N$ items in $O(\sqrt{N})$ queries ## Program Comparison ### Decision Matrix | Factor | CS B.S. | Data Science B.S. | Math + CS Subplan | Symbolic Systems | ICME (Graduate) | |--------|---------|-------------------|-------------------|------------------|-----------------| | **Math Depth** | Medium | Medium-High | Very High | Medium | Very High | | **CS Depth** | Very High | Medium | Medium | Medium | Medium | | **Theory Focus** | Configurable | Low | Very High | Medium | High | | **Applied Focus** | High | Very High | Low | High | Very High | | **Interdisciplinary** | Low | Medium | Low | Very High | High | | **Industry Prep** | Very High | Very High | Medium | High | High | | **Research Prep** | High | Medium | Very High | High | Very High | | **Flexibility** | High | Medium | Low | Very High | Medium | ### Recommended Paths #### For Theoretical CS/Math Research: 1. **Undergraduate:** - Mathematics B.S. with CS Theory Subplan, OR - CS B.S. with Theory Track 2. **Graduate:** - Ph.D. in Computer Science (Theory), OR - Ph.D. in Mathematics 3. **Key Courses:** - `MATH 61DM` series - `CS 154`, `CS 161` - `CS 265` (Randomized Algorithms) - Graduate complexity theory seminars #### For Applied Computational Math: 1. **Undergraduate:** - Data Science B.S. (Math & Computation subplan), OR - CS B.S. with systems focus 2. **Graduate:** - ICME M.S./Ph.D. 3. **Key Courses:** - `MATH 51/52/53` - `CME 100/102/104` - `CS 205L` (Continuous Methods) - Optimization courses #### For AI/ML with Mathematical Foundations: 1. **Undergraduate:** - CS B.S. with AI Track, OR - Symbolic Systems B.S. 2. **Graduate:** - CS M.S./Ph.D. (AI specialization), OR - Statistics M.S./Ph.D. 3. **Key Courses:** - `CS 229` (Machine Learning) - `CS 231N` (Deep Learning) - `STATS 315A/B` (Statistical Learning) - `CS 228` (Probabilistic Graphical Models) ## Mathematical Notation Reference ### Set Theory | Symbol | Meaning | |--------|---------| | $\in$ | Element of | | $\subseteq$ | Subset of | | $\cup$ | Union | | $\cap$ | Intersection | | $\setminus$ | Set difference | | $\emptyset$ | Empty set | | $\mathbb{N}$ | Natural numbers | | $\mathbb{Z}$ | Integers | | $\mathbb{Q}$ | Rational numbers | | $\mathbb{R}$ | Real numbers | | $\mathbb{C}$ | Complex numbers | ### Logic | Symbol | Meaning | |--------|---------| | $\land$ | Logical AND | | $\lor$ | Logical OR | | $\neg$ | Logical NOT | | $\Rightarrow$ | Implies | | $\Leftrightarrow$ | If and only if | | $\forall$ | For all | | $\exists$ | There exists | ### Calculus | Symbol | Meaning | |--------|---------| | $\frac{d}{dx}$ | Derivative | | $\frac{\partial}{\partial x}$ | Partial derivative | | $\nabla$ | Gradient | | $\nabla \cdot$ | Divergence | | $\nabla \times$ | Curl | | $\int$ | Integral | | $\oint$ | Contour integral | | $\sum$ | Summation | | $\prod$ | Product | | $\lim$ | Limit | ### Linear Algebra | Symbol | Meaning | |--------|---------| | $A^T$ | Transpose | | $A^{-1}$ | Inverse | | $A^*$ | Conjugate transpose | | $\|v\|$ | Norm | | $\langle u, v \rangle$ | Inner product | | $\det(A)$ | Determinant | | $\text{tr}(A)$ | Trace | | $\text{rank}(A)$ | Rank | | $\text{ker}(A)$ | Kernel/null space | | $\text{im}(A)$ | Image/column space | ## Resources ### Official Stanford Links - **Computer Science Department:** https://cs.stanford.edu - **Mathematics Department:** https://mathematics.stanford.edu - **Data Science Program:** https://datasciencemajor.stanford.edu - **ICME:** https://icme.stanford.edu - **Symbolic Systems:** https://symsys.stanford.edu - **Stanford Bulletin:** https://bulletin.stanford.edu ### Course Exploration - **ExploreCourses:** https://explorecourses.stanford.edu