TransWikia.com

I get "missing number, treated as zero" error with no reason I can see

TeX - LaTeX Asked by Eytan Zweig on November 29, 2020

The following test code

documentclass[11pt,a4paper]{article}

begin{document}
section{Introduction}

[DWP (1981), Heim & Kratzer (1990)]  [[`vi is mortal']]g= 1 iff [[`mortal']] g([[vi]]g)  [[`mortal'] ]g([[vi]]g) iff $lambda$x.mortal(x)(g(vi))

end{document}

generates this error message:

! Missing number, treated as zero.
<to be read again> 
[
l.6 ... Heim & Kratzer (1990)]  [[`vi is mortal']
                                                  ]g= 1 iff [[`mortal']] g([...

? 

I have no idea why. Anyone have any ideas?

One Answer

The problem is caused by the input pattern [...], which matches the usage of [<dimen>]. By historical reasons, in syntax [<dimen>], spaces are allowed (aka ignored) before [.

You can use relax as a workaround.

documentclass[11pt,a4paper]{article}

begin{document}
section{Introduction}

[DWP (1981), Heim & Kratzer (1990)] relax
[[`vi is mortal']]g= 1 iff [[`mortal']] g([[vi]]g) relax
[[`mortal'] ]g([[vi]]g) iff $lambda$x.mortal(x)(g(vi))

end{document}

PS: you might need some verbatim environments or algorithm packages to typeset the pseudocode.

Correct answer by muzimuzhi Z on November 29, 2020

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP