mscroggs.co.uk
mscroggs.co.uk

subscribe

Blog

A non-converging LaTeX document

 2019-09-15 
Today, I wrote this LaTeΧ document. It only uses default LaTeΧ functionality, and uses no packages.
If you compile it (twice so that cross references are not ??s), you will get a four page document (pages numbered i to iv), that repeatedly says: "This document ends on page v."
This document ends on page iv and says: "This document ends on page v."
If you then recompile it, you will get a five page document (pages numbered i to v), that repeatedly says: "This document ends on page iv."
This document ends on page v and says: "This document ends on page iv."
Repeatedly compiling it will alternately give these two results, and so the process of compiling this LaTeX document does not converge.
Tags: latex
                        
(Click on one of these icons to react to this blog post)

You might also enjoy...

Comments

Comments in green were written by me. Comments in blue were not written by me.
 Add a Comment 


I will only use your email address to reply to your comment (if a reply is needed).

Allowed HTML tags: <br> <a> <small> <b> <i> <s> <sup> <sub> <u> <spoiler> <ul> <ol> <li> <logo>
To prove you are not a spam bot, please type "g" then "r" then "a" then "p" then "h" in the box below (case sensitive):

Archive

Show me a random blog post
 2026 

May 2026

World Cup stickers 2026

Apr 2026

A new puzzle every day
Mixing Wordle with other games

Feb 2026

Christmas (2025) is over
 2025 

Dec 2025

Christmas card 2025

Nov 2025

Christmas (2025) is coming!

Sep 2025

The partridge puzzle

Aug 2025

TMiP 2025 puzzle hunt

Jun 2025

A nonogram alphabet

Mar 2025

How to write a crossnumber

Jan 2025

Christmas (2024) is over
Friendly squares
 2024 

Dec 2024

A regular expression Christmas puzzle
Christmas card 2024

Nov 2024

Christmas (2024) is coming!

Feb 2024

Zines, pt. 2

Jan 2024

Christmas (2023) is over
 2023 
▼ show ▼
 2022 
▼ show ▼
 2021 
▼ show ▼
 2020 
▼ show ▼
 2019 
▼ show ▼
 2018 
▼ show ▼
 2017 
▼ show ▼
 2016 
▼ show ▼
 2015 
▼ show ▼
 2014 
▼ show ▼
 2013 
▼ show ▼
 2012 
▼ show ▼

Tags

estimation arrangement puzzles chess gather town the aperiodical coventry radio 4 exponential growth quadrilaterals ternary squares computational complexity crossnumbers people maths pythagoras world cup friendly squares golden ratio triangles light noughts and crosses signorini conditions convergence approximation folding paper bodmas news dragon curves crossnumber numerical analysis finite group a gamut of games big internet math-off raspberry pi standard deviation arithmetic tmip determinants error bars wordle live stream machine learning wool data visualisation bempp christmas correlation pascal's triangle matrix multiplication kings databet logs mathslogicbot mathsteroids crosswords matrix of cofactors london gaussian elimination harriss spiral draughts captain scarlet php binary graphs phd matrices pi numbers weak imposition games runge's phenomenon bluesky probability propositional calculus matrix of minors errors pac-man chebyshev royal baby datasaurus dozen sound stirling numbers football video games inverse matrices oeis alphabets statistics fractals cambridge bots asteroids talking maths in public tennis accuracy tetris warwick inline code matt parker logic finite element method rugby speed gerry anderson pokémon wordle sport trigonometry misleading statistics pizza cutting rhombicuboctahedron wave scattering crochet sorting cross stitch python geogebra puzzles map projections national lottery dinosaurs platonic solids data ucl game show probability reuleaux polygons fence posts rust london underground flexagons programming latex youtube reddit recursion fonts realhats dataset go royal institution polynomials boundary element methods nonograms partridge puzzle braiding pokémon electromagnetic field christmas card guest posts hats final fantasy dates kenilworth interpolation hannah fry manchester science festival hexapawn advent calendar logo graph theory regular expressions bubble bobble pi approximation day javascript palindromes zines chalkdust magazine 24 hour maths newcastle manchester plastic ratio menace game of life weather station anscombe's quartet coins nine men's morris curvature folding tube maps countdown simultaneous equations books mean geometry golden spiral martin gardner mathsjam turtles preconditioning european cup sobolev spaces edinburgh thirteen frobel stickers craft hyperbolic surfaces

Archive

Show me a random blog post
▼ show ▼
© Matthew Scroggs 2012–2026