Best of MathSeptember 2025

  1. 1
    Article
    Avatar of palindromeThe Palindrome·38w

    The Competitive Programmer's Introduction to Graph Theory

    A comprehensive introduction to graph theory fundamentals covering nodes, edges, paths, and cycles. Explains key concepts like connectivity, directed and weighted graphs, trees, node degrees, and graph coloring including bipartite graphs. Includes practical examples with visual illustrations and practice problems to reinforce learning.

  2. 2
    Article
    Avatar of palindromeThe Palindrome·37w

    Correlation vs. cosine similarity

    Explores the key differences between Pearson correlation and cosine similarity, two statistical measures for quantifying relationships between variables. While both are based on dot products, correlation performs double normalization (mean-centering and variance scaling) while cosine similarity only normalizes by magnitude. Through mathematical explanations and Python simulations, the post demonstrates that these measures can yield dramatically different results depending on data scaling and offsets. Correlation is recommended when measurement units are arbitrary or different, while cosine similarity is preferred when variables share meaningful units, particularly in machine learning applications with vector embeddings.

  3. 3
    Article
    Avatar of hnHacker News·37w

    The maths you need to start understanding LLMs

    Explains the fundamental mathematical concepts needed to understand how Large Language Models work, focusing on vectors, matrices, high-dimensional spaces, embeddings, and projections. Covers vocab spaces where logits represent token probabilities, embedding spaces where similar concepts cluster together, and how matrix multiplication enables projections between different dimensional spaces. Demonstrates that neural network layers are essentially matrix multiplications that project between spaces, making LLM inference accessible with high-school level mathematics.

  4. 4
    Article
    Avatar of css_tricksCSS-Tricks·36w

    The “Most Hated” CSS Feature: cos() and sin()

    CSS trigonometric functions cos() and sin() enable powerful layout and animation techniques despite being labeled the "most hated" CSS feature in State of CSS 2025. The functions map to unit circle coordinates, allowing developers to create circular layouts, wavy patterns, and damped oscillatory animations. Practical examples include circular menus, DNA-strand-like chains, and physics-based bouncing effects that decay over time.