crc standard mathematical tables and formulas, 33rd edition standard mathematical... · 2020. 8....

873

Upload: others

Post on 25-Jan-2021

11 views

Category:

Documents


0 download

TRANSCRIPT

  • “K29784_FM” — 2017/12/6 — 17:41 — page 2 — #2

    CRC STANDARD MATHEMATICAL TABLES AND FORMULAS33RD EDITION

  • “K29784_FM” — 2017/12/6 — 17:41 — page 4 — #4

    Advances in Applied Mathematics

    Series Editor: Daniel Zwillinger

    Published Titles

    Advanced Engineering Mathematics with MATLAB, Fourth Edition Dean G. Duffy

    CRC Standard Curves and Surfaces with Mathematica®, Third Edition David H. von Seggern

    CRC Standard Mathematical Tables and Formulas, 33rd Edition Dan Zwillinger

    Dynamical Systems for Biological Modeling: An Introduction Fred Brauer and Christopher Kribs

    Fast Solvers for Mesh-Based Computations Maciej Paszyński

    Green’s Functions with Applications, Second Edition Dean G. Duffy

    Handbook of Peridynamic Modeling Floriin Bobaru, John T. Foster,

    Philippe H. Geubelle, and Stewart A. Silling

    Introduction to Financial Mathematics Kevin J. Hastings

    Linear and Complex Analysis for Applications John P. D’Angelo

    Linear and Integer Optimization: Theory and Practice, Third Edition Gerard Sierksma and Yori Zwols

    Markov Processes James R. Kirkwood

    Pocket Book of Integrals and Mathematical Formulas, 5th Edition Ronald J. Tallarida

    Stochastic Partial Differential Equations, Second Edition Pao-Liu Chow

    Quadratic Programming with Computer Programs Michael J. Best

  • “K29784_FM” — 2017/12/6 — 17:41 — page 6 — #6

    Advances in Applied Mathematics

    Edited by

    Dan Zwillinger

    CRC STANDARD MATHEMATICAL TABLES AND FORMULAS33RD EDITION

  • “K29784_FM” — 2017/12/6 — 17:41 — page 8 — #8

    CRC PressTaylor & Francis Group6000 Broken Sound Parkway NW, Suite 300Boca Raton, FL 33487-2742

    © 2018 by Taylor & Francis Group, LLCCRC Press is an imprint of Taylor & Francis Group, an Informa business

    No claim to original U.S. Government works

    Printed on acid-free paperVersion Date: 20171206

    International Standard Book Number-13: 978-1-4987-7780-3 (Hardback)

    This book contains information obtained from authentic and highly regarded sources. Reasonable efforts have been made to publish reliable data and information, but the author and publisher cannot assume responsibility for the validity of all materials or the consequences of their use. The authors and publishers have attempted to trace the copyright holders of all material reproduced in this publication and apologize to copyright holders if permission to publish in this form has not been obtained. If any copyright material has not been acknowledged please write and let us know so we may rectify in any future reprint.

    Except as permitted under U.S. Copyright Law, no part of this book may be reprinted, reproduced, transmitted, or utilized in any form by any electronic, mechanical, or other means, now known or hereafter invented, including photocopying, microfilming, and recording, or in any information storage or retrieval system, without written permission from the publishers.

    For permission to photocopy or use material electronically from this work, please access www.copyright.com (http://www.copyright.com/) or contact the Copyright Clearance Center, Inc. (CCC), 222 Rosewood Drive, Danvers, MA 01923, 978-750-8400. CCC is a not-for-profit organization that provides licenses and registration for a variety of users. For organizations that have been granted a photocopy license by the CCC, a separate system of payment has been arranged.

    Trademark Notice: Product or corporate names may be trademarks or registered trademarks, and are used only for identification and explanation without intent to infringe.

    Visit the Taylor & Francis Web site athttp://www.taylorandfrancis.com

    and the CRC Press Web site athttp://www.crcpress.com

    MATLAB• is a trademark of The MathWorks, Inc. and is used with permission. The MathWorks does not warrant the accuracy of the text or exercises in this book. This book’s use or discussion of MATLAB• software or related products does not constitute endorsement or sponsorship by The MathWorks of a particular pedagogical approach or particular use of the MATLAB• software.

    www.copyright.comhttp://www.copyright.com/http://www.taylorandfrancis.comhttp://www.crcpress.com

  • “smtf33” — 2017/12/6 — 19:00 — page v — #1

    Table of Contents

    Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi

    Chapter 1Numbers and Elementary Mathematics . . . . . . . . . . . . . . . . . . . 1

    1.1 Proofs without words . . . . . . . . . . . . . . . . . . . . . . . . 31.2 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.3 Special numbers . . . . . . . . . . . . . . . . . . . . . . . . . . 131.4 Interval analysis . . . . . . . . . . . . . . . . . . . . . . . . . . 241.5 Fractal Arithmetic . . . . . . . . . . . . . . . . . . . . . . . . . 251.6 Max-Plus Algebra . . . . . . . . . . . . . . . . . . . . . . . . . 261.7 Coupled-analogues of Functions . . . . . . . . . . . . . . . . . . 271.8 Number theory . . . . . . . . . . . . . . . . . . . . . . . . . . . 281.9 Series and products . . . . . . . . . . . . . . . . . . . . . . . . . 47

    Chapter 2Algebra . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

    2.1 Elementary algebra . . . . . . . . . . . . . . . . . . . . . . . . . 692.2 Polynomials . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732.3 Vector algebra . . . . . . . . . . . . . . . . . . . . . . . . . . . 782.4 Linear and matrix algebra . . . . . . . . . . . . . . . . . . . . . 832.5 Abstract algebra . . . . . . . . . . . . . . . . . . . . . . . . . . 106

    Chapter 3Discrete Mathematics . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133

    3.1 Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1353.2 Combinatorics . . . . . . . . . . . . . . . . . . . . . . . . . . . 1403.3 Graphs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1513.4 Combinatorial design theory . . . . . . . . . . . . . . . . . . . . 1723.5 Difference equations . . . . . . . . . . . . . . . . . . . . . . . . 184

    Chapter 4Geometry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191

    4.1 Euclidean geometry . . . . . . . . . . . . . . . . . . . . . . . . 1934.2 Grades and Degrees . . . . . . . . . . . . . . . . . . . . . . . . 1934.3 Coordinate systems in the plane . . . . . . . . . . . . . . . . . . 1944.4 Plane symmetries or isometries . . . . . . . . . . . . . . . . . . 2004.5 Other transformations of the plane . . . . . . . . . . . . . . . . . 2074.6 Lines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2094.7 Polygons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211

  • “smtf33” — 2017/12/6 — 19:00 — page vi — #2

    vi Table of Contents

    4.8 Surfaces of revolution: the torus . . . . . . . . . . . . . . . . . . 2194.9 Quadrics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2194.10 Spherical geometry and trigonometry . . . . . . . . . . . . . . . 2244.11 Conics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2294.12 Special plane curves . . . . . . . . . . . . . . . . . . . . . . . . 2404.13 Coordinate systems in space . . . . . . . . . . . . . . . . . . . . 2494.14 Space symmetries or isometries . . . . . . . . . . . . . . . . . . 2524.15 Other transformations of space . . . . . . . . . . . . . . . . . . . 2554.16 Direction angles and direction cosines . . . . . . . . . . . . . . . 2574.17 Planes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2574.18 Lines in space . . . . . . . . . . . . . . . . . . . . . . . . . . . 2594.19 Polyhedra . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2614.20 Cylinders . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2654.21 Cones . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2654.22 Differential geometry . . . . . . . . . . . . . . . . . . . . . . . . 267

    Chapter 5Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275

    5.1 Differential calculus . . . . . . . . . . . . . . . . . . . . . . . . 2775.2 Differential forms . . . . . . . . . . . . . . . . . . . . . . . . . 2885.3 Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2915.4 Table of indefinite integrals . . . . . . . . . . . . . . . . . . . . 3055.5 Table of definite integrals . . . . . . . . . . . . . . . . . . . . . 3435.6 Ordinary differential equations . . . . . . . . . . . . . . . . . . . 3505.7 Partial differential equations . . . . . . . . . . . . . . . . . . . . 3625.8 Integral equations . . . . . . . . . . . . . . . . . . . . . . . . . . 3755.9 Tensor analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . 3785.10 Orthogonal coordinate systems . . . . . . . . . . . . . . . . . . . 3885.11 Real analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3935.12 Generalized functions . . . . . . . . . . . . . . . . . . . . . . . 4035.13 Complex analysis . . . . . . . . . . . . . . . . . . . . . . . . . . 4055.14 Significant Mathematical Equations . . . . . . . . . . . . . . . . 417

    Chapter 6Special Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419

    6.1 Ceiling and floor functions . . . . . . . . . . . . . . . . . . . . . 4216.2 Exponentiation . . . . . . . . . . . . . . . . . . . . . . . . . . . 4216.3 Exponential function . . . . . . . . . . . . . . . . . . . . . . . . 4226.4 Logarithmic functions . . . . . . . . . . . . . . . . . . . . . . . 4226.5 Trigonometric functions . . . . . . . . . . . . . . . . . . . . . . 4246.6 Circular functions and planar triangles . . . . . . . . . . . . . . . 4336.7 Tables of trigonometric functions . . . . . . . . . . . . . . . . . 4376.8 Angle conversion . . . . . . . . . . . . . . . . . . . . . . . . . . 4406.9 Inverse circular functions . . . . . . . . . . . . . . . . . . . . . . 441

  • “smtf33” — 2017/12/6 — 19:00 — page vii — #3

    Table of Contents vii

    6.10 Hyperbolic functions . . . . . . . . . . . . . . . . . . . . . . . . 4436.11 Inverse hyperbolic functions . . . . . . . . . . . . . . . . . . . . 4476.12 Gudermannian function . . . . . . . . . . . . . . . . . . . . . . 4496.13 Orthogonal polynomials . . . . . . . . . . . . . . . . . . . . . . 4516.14 Clebsch–Gordan coefficients . . . . . . . . . . . . . . . . . . . . 4586.15 Bessel functions . . . . . . . . . . . . . . . . . . . . . . . . . . 4606.16 Beta function . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4696.17 Elliptic integrals . . . . . . . . . . . . . . . . . . . . . . . . . . 4706.18 Jacobian elliptic functions . . . . . . . . . . . . . . . . . . . . . 4736.19 Error functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 4756.20 Fresnel integrals . . . . . . . . . . . . . . . . . . . . . . . . . . 4766.21 Gamma function . . . . . . . . . . . . . . . . . . . . . . . . . . 4786.22 Hypergeometric functions . . . . . . . . . . . . . . . . . . . . . 4816.23 Lambert Function . . . . . . . . . . . . . . . . . . . . . . . . . . 4836.24 Legendre functions . . . . . . . . . . . . . . . . . . . . . . . . . 4846.25 Polylogarithms . . . . . . . . . . . . . . . . . . . . . . . . . . . 4886.26 Prolate Spheroidal Wave Functions . . . . . . . . . . . . . . . . 4896.27 Sine, cosine, and exponential integrals . . . . . . . . . . . . . . . 4906.28 Weierstrass Elliptic Function . . . . . . . . . . . . . . . . . . . . 4926.29 Integral transforms: List . . . . . . . . . . . . . . . . . . . . . . 4936.30 Integral transforms: Preliminaries . . . . . . . . . . . . . . . . . 4946.31 Fourier integral transform . . . . . . . . . . . . . . . . . . . . . 4946.32 Discrete Fourier transform (DFT) . . . . . . . . . . . . . . . . . 5006.33 Fast Fourier transform (FFT) . . . . . . . . . . . . . . . . . . . . 5026.34 Multidimensional Fourier transforms . . . . . . . . . . . . . . . 5026.35 Hankel transform . . . . . . . . . . . . . . . . . . . . . . . . . . 5036.36 Hartley transform . . . . . . . . . . . . . . . . . . . . . . . . . . 5046.37 Hilbert transform . . . . . . . . . . . . . . . . . . . . . . . . . . 5056.38 Laplace transform . . . . . . . . . . . . . . . . . . . . . . . . . 5086.39 Mellin transform . . . . . . . . . . . . . . . . . . . . . . . . . . 5126.40 Z-Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5126.41 Tables of transforms . . . . . . . . . . . . . . . . . . . . . . . . 517

    Chapter 7Probability and Statistics . . . . . . . . . . . . . . . . . . . . . . . . . . 533

    7.1 Probability theory . . . . . . . . . . . . . . . . . . . . . . . . . 5357.2 Classical probability problems . . . . . . . . . . . . . . . . . . . 5457.3 Probability distributions . . . . . . . . . . . . . . . . . . . . . . 5537.4 Queuing theory . . . . . . . . . . . . . . . . . . . . . . . . . . . 5627.5 Markov chains . . . . . . . . . . . . . . . . . . . . . . . . . . . 5657.6 Random number generation . . . . . . . . . . . . . . . . . . . . 5687.7 Random matrices . . . . . . . . . . . . . . . . . . . . . . . . . . 5747.8 Control charts and reliability . . . . . . . . . . . . . . . . . . . . 5757.9 Statistics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580

  • “smtf33” — 2017/12/6 — 19:00 — page viii — #4

    viii Table of Contents

    7.10 Confidence intervals . . . . . . . . . . . . . . . . . . . . . . . . 5887.11 Tests of hypotheses . . . . . . . . . . . . . . . . . . . . . . . . . 5957.12 Linear regression . . . . . . . . . . . . . . . . . . . . . . . . . . 6097.13 Analysis of variance (ANOVA) . . . . . . . . . . . . . . . . . . 6137.14 Sample size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6207.15 Contingency tables . . . . . . . . . . . . . . . . . . . . . . . . . 6237.16 Acceptance sampling . . . . . . . . . . . . . . . . . . . . . . . . 6267.17 Probability tables . . . . . . . . . . . . . . . . . . . . . . . . . . 628

    Chapter 8Scientific Computing . . . . . . . . . . . . . . . . . . . . . . . . . . . . 645

    8.1 Basic numerical analysis . . . . . . . . . . . . . . . . . . . . . . 6468.2 Numerical linear algebra . . . . . . . . . . . . . . . . . . . . . . 6598.3 Numerical integration and differentiation . . . . . . . . . . . . . 6688.4 Programming techniques . . . . . . . . . . . . . . . . . . . . . . 688

    Chapter 9Mathematical Formulas from the Sciences . . . . . . . . . . . . . . . . . 689

    9.1 Acoustics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6919.2 Astrophysics . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6929.3 Atmospheric physics . . . . . . . . . . . . . . . . . . . . . . . . 6949.4 Atomic Physics . . . . . . . . . . . . . . . . . . . . . . . . . . . 6959.5 Basic mechanics . . . . . . . . . . . . . . . . . . . . . . . . . . 6969.6 Beam dynamics . . . . . . . . . . . . . . . . . . . . . . . . . . . 6989.7 Biological Models . . . . . . . . . . . . . . . . . . . . . . . . . 6999.8 Chemistry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7009.9 Classical mechanics . . . . . . . . . . . . . . . . . . . . . . . . 7019.10 Coordinate systems – Astronomical . . . . . . . . . . . . . . . . 7029.11 Coordinate systems – Terrestrial . . . . . . . . . . . . . . . . . . 7039.12 Earthquake engineering . . . . . . . . . . . . . . . . . . . . . . 7049.13 Economics (Macro) . . . . . . . . . . . . . . . . . . . . . . . . 7059.14 Electromagnetic Transmission . . . . . . . . . . . . . . . . . . . 7079.15 Electrostatics and magnetism . . . . . . . . . . . . . . . . . . . 7089.16 Electromagnetic Field Equations . . . . . . . . . . . . . . . . . . 7099.17 Electronic circuits . . . . . . . . . . . . . . . . . . . . . . . . . 7109.18 Epidemiology . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7119.19 Fluid mechanics . . . . . . . . . . . . . . . . . . . . . . . . . . 7129.20 Human body . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7139.21 Modeling physical systems . . . . . . . . . . . . . . . . . . . . . 7149.22 Optics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7159.23 Population genetics . . . . . . . . . . . . . . . . . . . . . . . . . 7169.24 Quantum mechanics . . . . . . . . . . . . . . . . . . . . . . . . 7179.25 Quaternions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7199.26 Radar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 720

  • “smtf33” — 2017/12/6 — 19:00 — page ix — #5

    Table of Contents ix

    9.27 Relativistic mechanics . . . . . . . . . . . . . . . . . . . . . . . 7219.28 Solid mechanics . . . . . . . . . . . . . . . . . . . . . . . . . . 7229.29 Statistical mechanics . . . . . . . . . . . . . . . . . . . . . . . . 7239.30 Thermodynamics . . . . . . . . . . . . . . . . . . . . . . . . . . 724

    Chapter 10Miscellaneous . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 725

    10.1 Calendar computations . . . . . . . . . . . . . . . . . . . . . . . 72710.2 Cellular automata . . . . . . . . . . . . . . . . . . . . . . . . . . 72810.3 Communication theory . . . . . . . . . . . . . . . . . . . . . . . 72910.4 Control theory . . . . . . . . . . . . . . . . . . . . . . . . . . . 73410.5 Computer languages . . . . . . . . . . . . . . . . . . . . . . . . 73610.6 Compressive Sensing . . . . . . . . . . . . . . . . . . . . . . . . 73710.7 Constrained Least Squares . . . . . . . . . . . . . . . . . . . . . 73810.8 Cryptography . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73910.9 Discrete dynamical systems and chaos . . . . . . . . . . . . . . . 74010.10 Elliptic curves . . . . . . . . . . . . . . . . . . . . . . . . . . . 74310.11 Financial formulas . . . . . . . . . . . . . . . . . . . . . . . . . 74610.12 Game theory . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75410.13 Knot theory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75710.14 Lattices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75910.15 Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76110.16 Moments of inertia . . . . . . . . . . . . . . . . . . . . . . . . . 76610.17 Music . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76710.18 Operations research . . . . . . . . . . . . . . . . . . . . . . . . 76910.19 Proof Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . 78110.20 Recreational mathematics . . . . . . . . . . . . . . . . . . . . . 78210.21 Risk analysis and decision rules . . . . . . . . . . . . . . . . . . 78310.22 Signal processing . . . . . . . . . . . . . . . . . . . . . . . . . . 78510.23 Units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79410.24 Voting power . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80110.25 Greek alphabet . . . . . . . . . . . . . . . . . . . . . . . . . . . 80310.26 Braille code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80310.27 Morse code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80310.28 Bar Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 804

    List of References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 805

    List of Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 809

    List of Notations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 811

    Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 819

  • “smtf33” — 2017/12/6 — 19:00 — page x — #6

    http://taylorandfrancis.com

  • “smtf33” — 2017/12/6 — 19:00 — page xi — #7

    Preface

    It has long been the established policy of CRC Press to publish, in handbook form,the most up-to-date, authoritative, logically arranged, and readily usable referencematerial available.

    Just as pocket calculators have replaced tables of square roots and trig functions;the internet has made printed tabulation of many tables and formulas unnecessary.As the content and capabilities of the internet continue to grow, the content of thisbook also evolves. For this edition of Standard Mathematical Tables and Formulaethe content was reconsidered and reviewed. The criteria for inclusion in this editionincludes:

    • information that is immediately useful as a reference (e.g., interpretation ofpowers of 10);

    • information that is useful and not commonly known (e.g., proof methods);• information that is more complete or concise than that which can be easily

    found on the internet (e.g., table of conformal mappings);

    • information difficult to find on the internet due to the challenges of entering anappropriate query (e.g., integral tables).

    Applying these criteria, practitioners from mathematics, engineering, and the sci-ences have made changes in several sections and have added new material.

    • The “Mathematical Formulas from the Sciences” chapter now includes topicsfrom biology, chemistry, and radar.

    • Material has been augmented in many areas, including: acceptance sampling,card games, lattices, and set operations.

    • New material has been added on the following topics: continuous wavelet trans-form, contour integration, coupled analogues, financial options, fractal arith-metic, generating functions, linear temporal logic, matrix pseudospectra, maxplus algebra, proof methods, and two dimensional integrals.

    • Descriptions of new functions have been added: Lambert, prolate spheroidal,and Weierstrass.

    Of course, the same successful format which has characterized earlier editions of theHandbook has been retained. Material is presented in a multi-sectional format, witheach section containing a valuable collection of fundamental reference material—tabular and expository.

    xi

  • “smtf33” — 2017/12/6 — 19:00 — page xii — #8

    xii Preface

    In line with the established policy of CRC Press, the Handbook will be updatedin as current and timely manner as is possible. Suggestions for the inclusion of newmaterial in subsequent editions and comments regarding the present edition are wel-comed. The home page for this book, which will include errata, will be maintainedat http://www.mathtable.com/smtf.

    This new edition of the Handbook will continue to support the needs of practi-tioners of mathematics in the mathematical and scientific fields, as it has for almost90 years. Even as the internet becomes more powerful, it is this editor’s opinion thatthe new edition will continue to be a valued reference.

    MATLAB R© is a registered trademark of The MathWorks, Inc.For product information please contact:The MathWorks, Inc.3 Apple Hill DriveNatick, MA, 01760-2098 USATel: 508-647-7000Fax: 508-647-7001E-mail: [email protected]: www.mathworks.com

    Every book takes time and care. This book would not have been possible without theloving support of my wife, Janet Taylor, and my son, Kent Zwillinger.

    May 2017Daniel Zwillinger

    [email protected]

    http://www.mathtable.com/smtfwww.mathworks.commailto:[email protected]:[email protected]

  • “smtf33” — 2017/12/6 — 19:00 — page xiii — #9

    Editor-in-ChiefDaniel Zwillinger

    Rensselaer Polytechnic Institute

    Troy, New York

    Contributors

    George E. Andrews

    Evan Pugh University Professor in

    Mathematics

    The Pennsylvania State University

    University Park, Pennsylvania

    Lawrence Glasser

    Professor of Physics Emeritus

    Clarkson University

    Potsdam, New York

    Michael Mascagni

    Professor of Computer Science

    Professor of Mathematics

    Professor of Scientific Computing

    Florida State University

    Tallahassee, Florida

    Ray McLenaghan

    Adjunct Professor in Department of

    Applied Mathematics

    University of Waterloo

    Waterloo, Ontario, Canada

    Roger B. Nelsen

    Professor Emeritus of Mathematics

    Lewis & Clark College

    Portland, Oregon

    Dr. Joseph J. Rushanan

    MITRE Corporation

    Bedford, Massachusetts

    Dr. Les Servi

    MITRE Corporation

    Bedford, Massachusetts

    Dr. Michael T. Strauss

    President HME

    Newburyport, Massachusetts

    Dr. Nico M. Temme

    Centrum Wiskunde & Informatica

    Amsterdam, The Netherlands

    Ahmed I. Zayed

    Professor in Department of

    Mathematical Sciences

    DePaul University

    Chicago, Illinois

    xiii

  • “smtf33” — 2017/12/6 — 19:00 — page 1 — #11

    Chapter 1Numbers andElementaryMathematics

    1.1 PROOFS WITHOUT WORDS . . . . . . . . . . . . . . . . . . . . 3

    1.2 CONSTANTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.2.1 Divisibility tests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51.2.2 Decimal multiples and prefixes . . . . . . . . . . . . . . . . . . . . . . . 61.2.3 Binary prefixes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.2.4 Interpretations of powers of 10 . . . . . . . . . . . . . . . . . . . . . . . 71.2.5 Numerals in different languages . . . . . . . . . . . . . . . . . . . . . . . 81.2.6 Roman numerals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81.2.7 Types of numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

    1.2.8 Representation of numbers . . . . . . . . . . . . . . . . . . . . . . . . . 101.2.9 Representation of complex numbers – DeMoivre’s theorem . . . . . . . . . . 101.2.10 Arrow notation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111.2.11 Ones and Twos Complement . . . . . . . . . . . . . . . . . . . . . . . . . 111.2.12 Symmetric base three representation . . . . . . . . . . . . . . . . . . . . . 111.2.13 Hexadecimal addition and subtraction table . . . . . . . . . . . . . . . . . 121.2.14 Hexadecimal multiplication table . . . . . . . . . . . . . . . . . . . . . . 12

    1.3 SPECIAL NUMBERS . . . . . . . . . . . . . . . . . . . . . . . . 131.3.1 Powers of 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 131.3.2 Powers of 10 in hexadecimal . . . . . . . . . . . . . . . . . . . . . . . . . 131.3.3 Special constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141.3.4 Factorials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161.3.5 Bernoulli polynomials and numbers . . . . . . . . . . . . . . . . . . . . . 171.3.6 Euler polynomials and numbers . . . . . . . . . . . . . . . . . . . . . . . 181.3.7 Fibonacci numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181.3.8 Sums of powers of integers . . . . . . . . . . . . . . . . . . . . . . . . . 191.3.9 Negative integer powers . . . . . . . . . . . . . . . . . . . . . . . . . . . 201.3.10 Integer sequences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211.3.11 p-adic Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231.3.12 de Bruijn sequences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

    1.4 INTERVAL ANALYSIS . . . . . . . . . . . . . . . . . . . . . . . . 24

    1.5 FRACTAL ARITHMETIC . . . . . . . . . . . . . . . . . . . . . . 25

    1

  • “smtf33” — 2017/12/6 — 19:00 — page 2 — #12

    2 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.6 MAX-PLUS ALGEBRA . . . . . . . . . . . . . . . . . . . . . . . 26

    1.7 COUPLED-ANALOGUES OF FUNCTIONS . . . . . . . . . . . . 271.7.1 Coupled-operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

    1.8 NUMBER THEORY . . . . . . . . . . . . . . . . . . . . . . . . . 281.8.1 Congruences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281.8.2 Chinese remainder theorem . . . . . . . . . . . . . . . . . . . . . . . . . 291.8.3 Continued fractions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301.8.4 Diophantine equations . . . . . . . . . . . . . . . . . . . . . . . . . . . 321.8.5 Greatest common divisor . . . . . . . . . . . . . . . . . . . . . . . . . . 351.8.6 Least common multiple . . . . . . . . . . . . . . . . . . . . . . . . . . . 351.8.7 Möbius function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361.8.8 Prime numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371.8.9 Prime numbers of special forms . . . . . . . . . . . . . . . . . . . . . . . 391.8.10 Prime numbers less than 7,000 . . . . . . . . . . . . . . . . . . . . . . . 421.8.11 Factorization table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 441.8.12 Euler totient function . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46

    1.9 SERIES AND PRODUCTS . . . . . . . . . . . . . . . . . . . . . 471.9.1 Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 471.9.2 General properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 471.9.3 Convergence tests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 491.9.4 Types of series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 501.9.5 Fourier series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 541.9.6 Series expansions of special functions . . . . . . . . . . . . . . . . . . . . 591.9.7 Summation formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631.9.8 Faster convergence: Shanks transformation . . . . . . . . . . . . . . . . . 631.9.9 Summability methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . 641.9.10 Operations with power series . . . . . . . . . . . . . . . . . . . . . . . . 641.9.11 Miscellaneous sums . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 641.9.12 Infinite products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 651.9.13 Infinite products and infinite series . . . . . . . . . . . . . . . . . . . . . . 65

  • “smtf33” — 2017/12/6 — 19:00 — page 3 — #13

    1.1. PROOFS WITHOUT WORDS 3

    1.1 PROOFS WITHOUT WORDS

    —the Chou pei suan ching

    (author unknown, circa B.C. 200?)

    The Pythagorean Theorem

    A Property of the Sequence of Odd Integers (Galileo, 1615)

    1

    3

    1+3

    5+7

    1+3+5

    7+9+11= = . . .=

    1+3+ . . . +(2n–1)

    (2n+1)+(2n+3)+ . . . +(4n–1)

    1

    3=

    1+2+ . . . + n =n(n+1)

    2

    1+2+ . . . +n = n2

    2n

    2+1 1. . = n(n+1)

    2

    —Ian Richards

    1 + 3 + 5 + . . . + (2n–1) = n2

    1+3+ . . . + (2n–1) = 14

    (2n) = n2 2

  • “smtf33” — 2017/12/6 — 19:00 — page 4 — #14

    4 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    Geometric Series

    —Rick Mabry

    2 31

    4

    1

    3+

    1

    4+ + . . . =

    1

    4

    1

    1

    r

    1–r

    2r

    r

    2r

    ...

    1

    Geometric Series

    1 + r + r + ...2

    1

    1

    1 – r=

    —Benjamin G. Klein

    and Irl C. Bivens

    sinxsiny

    cosxsin

    y

    siny

    cosxcosy

    sinxco

    sy

    1

    x

    y

    x

    cosy

    Addition Formulae for the Sine and Cosine

    sin(x + y) = sinxcosy + cosxsiny

    cos(x + y) = cosxcosy – sinxsiny

    d(a,b)

    (a,ma + c)

    x

    y

    y = mx + c

    |ma + c – b|

    1 + m

    2

    1

    m

    d |ma + c – b|

    1=

    1 + m 2

    The Distance Between a Point and a Line

    —R. L. Eisenman

  • “smtf33” — 2017/12/6 — 19:00 — page 5 — #15

    1.2. CONSTANTS 5

    The Arithmetic Mean-Geometric Mean Inequality

    a b

    ab

    a+b2

    —Charles D. Gallant

    a,b > 0a+b

    ab2

    The Mediant Property

    —Richard A. Gibbs

    a

    b

    c

    d

    a + c

    b + d

  • “smtf33” — 2017/12/6 — 19:00 — page 6 — #16

    6 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.2.2 DECIMAL MULTIPLES AND PREFIXES

    The prefix names and symbols below are taken from Conference Générale des Poidset Mesures, 1991. The common names are for the United States.

    Factor Prefix Symbol Common name

    10(10100) googolplex

    10100 googol1024 yotta Y heptillion1021 zetta Z hexillion

    1 000 000 000 000 000 000 = 1018 exa E quintillion1 000 000 000 000 000 = 1015 peta P quadrillion

    1 000 000 000 000 = 1012 tera T trillion1 000 000 000 = 109 giga G billion

    1 000 000 = 106 mega M million1 000 = 103 kilo k thousand100 = 102 hecto H hundred10 = 101 deka da ten0.1 = 10−1 deci d tenth0.01 = 10−2 centi c hundredth

    0.001 = 10−3 milli m thousandth0.000 001 = 10−6 micro µ millionth

    0.000 000 001 = 10−9 nano n billionth0.000 000 000 001 = 10−12 pico p trillionth

    0.000 000 000 000 001 = 10−15 femto f quadrillionth0.000 000 000 000 000 001 = 10−18 atto a quintillionth

    10−21 zepto z hexillionth10−24 yocto y heptillionth

    1.2.3 BINARY PREFIXES

    A byte is 8 bits. A kibibyte is 210 = 1024 bytes. Other prefixes for power of 2 are:

    Factor Prefix Symbol

    210 kibi Ki220 mebi Mi230 gibi Gi240 tebi Ti250 pebi Pi260 exbi Ei

  • “smtf33” — 2017/12/6 — 19:00 — page 7 — #17

    1.2. CONSTANTS 7

    1.2.4 INTERPRETATIONS OF POWERS OF 10

    10−43 Planck time in seconds10−35 Planck length in meters10−30 mass of an electron in kilograms10−27 mass of a proton in kilograms10−15 the radius of the hydrogen nucleus (a proton) in meters10−11 the likelihood of being dealt 13 top honors in bridge10−10 the (Bohr) radius of a hydrogen atom in meters10−9 the number of seconds it takes light to travel one foot10−6 the likelihood of being dealt a royal flush in poker100 the density of water is 1 gram per milliliter101 the number of fingers that people have102 the number of stable elements in the periodic table104 the speed of the Earth around the sun in meters/second105 the number of hairs on a human scalp106 the number of words in the English language107 the number of seconds in a year108 the speed of light in meters per second109 the number of heartbeats in a lifetime for most mammals1010 the number of people on the earth1011 the distance from the Earth to the sun in meters1013 diameter of the solar system in meters1014 number of cells in the human body1015 the surface area of the earth in square meters1016 the number of meters light travels in one year1017 the age of the universe in seconds1018 the volume of water in the earth’s oceans in cubic meters1019 the number of possible positions of Rubik’s cube1021 the volume of the earth in cubic meters1024 the number of grains of sand in the Sahara desert1025 the mass of the earth in kilograms1030 the mass of the sun in kilograms1050 the number of atoms in the earth1052 the mass of the observable universe in kilograms1054 the number of elements in the monster group1078 the volume of the universe in cubic meters

    (Note: these numbers have been rounded to the nearest power of ten.)

  • “smtf33” — 2017/12/6 — 19:00 — page 8 — #18

    8 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.2.5 NUMERALS IN DIFFERENT LANGUAGES

    1.2.6 ROMAN NUMERALSThe major symbols in Roman numerals are I = 1, V = 5, X = 10, L = 50, C = 100,D = 500, and M = 1,000. The rules for constructing Roman numerals are:

    1. A symbol following one of equal or greater value adds its value. (For example,II = 2, XI = 11, and DV = 505.)

    2. A symbol following one of lesser value has the lesser value subtracted fromthe larger value. An I is only allowed to precede a V or an X, an X is onlyallowed to precede an L or a C, and a C is only allowed to precede a D oran M. (For example IV = 4, IX = 9, and XL = 40.)

    3. When a symbol stands between two of greater value, its value is subtractedfrom the second and the result is added to the first. (For example, XIV=10+(5−1) = 14, CIX= 100+(10−1) = 109, DXL= 500+(50−10) = 540.)

    4. When two ways exist for representing a number, the one in which the symbolof larger value occurs earlier in the string is preferred. (For example, 14 isrepresented as XIV, not as VIX.)

    Decimal number 1 2 3 4 5 6 7 8 9Roman numeral I II III IV V VI VII VIII IX

    10 14 50 200 400 500 600 999 1000X XIV L CC CD D DC CMXCIX M

    1995 1999 2000 2001 2017 2018MCMXCV MCMXCIX MM MMI MMXVII MMXVIII

  • “smtf33” — 2017/12/6 — 19:00 — page 9 — #19

    1.2. CONSTANTS 9

    1.2.7 TYPES OF NUMBERS

    1. Natural numbers The set of natural numbers, {0, 1, 2, . . .}, is customarilydenoted by N. Many authors do not consider 0 to be a natural number.

    2. Integers The set of integers, {0,±1,±2, . . .}, is customarily denoted by Z.3. Rational numbers The set of rational numbers, { pq | p, q ∈ Z, q 6= 0}, is

    customarily denoted by Q.

    (a) Two fractions pq andrs are equal if and only if ps = qr.

    (b) Addition of fractions is defined by pq +rs =

    ps+qrqs .

    (c) Multiplication of fractions is defined by pq · rs =prqs .

    4. Real numbers Real numbers are defined to be converging sequences ofrational numbers or as decimals that might or might not repeat. The set of realnumbers is customarily denoted by R.

    Real numbers can be divided into two subsets. One subset, the algebraic num-bers, are real numbers which solve a polynomial equation in one variable withinteger coefficients. For example;

    √2 is an algebraic number because it solves

    the polynomial equation x2 − 2 = 0; and all rational numbers are algebraic.Real numbers that are not algebraic numbers are called transcendental num-bers. Examples of transcendental numbers include π and e.

    5. Definition of infinity The real numbers are extended to R by the inclusionof +∞ and −∞ with the following definitions

    (a) for x in R: −∞ < x 0 then x · ∞ =∞(f) if x > 0 then x·(−∞) = −∞(g) ∞+∞ =∞(h) −∞−∞ = −∞(i) ∞ ·∞ =∞(j) −∞ · (−∞) =∞

    6. Complex numbers The set of complex numbers is customarily denotedby C. They are numbers of the form a + bi, where i2 = −1, and a and b arereal numbers.

    Operation computation resultaddition (a+ bi) + (c+ di) (a+ c) + i(b+ d)multiplication (a+ bi)(c+ di) (ac− bd) + (ad+ bc)ireciprocal

    1

    a+ bi

    (a

    a2 + b2

    )−(

    b

    a2 + b2

    )i

    complex conjugate z = a+ bi z = a− bi

    Properties include: z + w = z + w and zw = z w.

  • “smtf33” — 2017/12/6 — 19:00 — page 10 — #20

    10 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.2.8 REPRESENTATION OF NUMBERS

    Numerals as usually written have radix or base 10, so the numeral anan−1 . . . a1a0represents the number an10n + an−110n−1 + · · · + a2102 + a110 + a0. However,other bases can be used, particularly bases 2, 8, and 16. When a number is written inbase 2, the number is said to be in binary notation. The names of other bases are:

    2 binary3 ternary4 quaternary5 quinary

    6 senary7 septenary8 octal9 nonary

    10 decimal11 undenary12 duodecimal16 hexadecimal

    20 vigesimal60 sexagesimal

    When writing a number in base b, the digits used range from 0 to b − 1. Ifb > 10, then the digit A stands for 10, B for 11, etc. When a base other than 10 isused, it is indicated by a subscript:

    101112 = 1× 24 + 0× 23 + 1× 22 + 1× 2 + 1 = 23,A316 = 10× 16 + 3 = 163,5437 = 5× 72 + 4× 7 + 3 = 276.

    (1.2.1)

    To convert a number from base 10 to base b, divide the number by b, and theremainder will be the last digit. Then divide the quotient by b, using the remainderas the previous digit. Continue this process until a quotient of 0 is obtained.

    EXAMPLE To convert 573 to base 12, divide 573 by 12, yielding a quotient of 47 and aremainder of 9; hence, “9” is the last digit. Divide 47 by 12, yielding a quotient of 3 anda remainder of 11 (which we represent with a “B”). Divide 3 by 12 yielding a quotientof 0 and a remainder of 3. Therefore, 57310 = 3B912.

    Converting from base b to base r can be done by converting to and from base10. However, it is simple to convert from base b to base bn. For example, to con-vert 1101111012 to base 16, group the digits in fours (because 16 is 24), yielding1 1011 11012, and then convert each group of 4 to base 16 directly, yielding 1BD16.

    1.2.9 REPRESENTATION OF COMPLEX NUMBERS –DEMOIVRE’S THEOREM

    A complex number a + bi can be written in the form reiθ , where r2 = a2 + b2 andtan θ = b/a. Because eiθ = cos θ + i sin θ,

    (a+ bi)n = rn(cosnθ + i sinnθ),

    n√1 = cos

    2kπ

    n+ i sin

    2kπ

    n, k = 0, 1, . . . , n− 1.

    n√−1 = cos (2k + 1)π

    n+ i sin

    (2k + 1)π

    n, k = 0, 1, . . . , n− 1.

    (1.2.2)

  • “smtf33” — 2017/12/6 — 19:00 — page 11 — #21

    1.2. CONSTANTS 11

    1.2.10 ARROW NOTATIONArrow notation is used to represent large numbers. Start with m ↑ n = m ·m · · ·m︸ ︷︷ ︸

    n

    ,

    then (evaluation proceeds from the right)

    m ↑↑ n = m ↑ m ↑ · · · ↑ m︸ ︷︷ ︸n

    m ↑↑↑ n = m ↑↑ m ↑↑ · · · ↑↑ m︸ ︷︷ ︸n

    For example,m ↑ n = mn, m ↑↑ 2 = mm, and m ↑↑ 3 = m(mm).

    1.2.11 ONES AND TWOS COMPLEMENT

    One’s and two’s complement are ways to represent numbers in a computer. Forpositive values the binary representation, the ones’ complement representation, andthe twos’ complement representation are the same.

    • Ones’ complement represents integers from −(2N−1 − 1

    )to 2N−1 − 1. For

    negative values, the binary representation of the absolute value is obtained, andthen all of the bits are inverted (i.e., swapping 0’s for 1’s and vice versa).• Twos’ complement represents integers from −2N−1 to 2N−1 − 1. For negative

    vales, the two’s complement representation is the same as the value one addedto the ones’ complement representation.

    Number Ones’ complement Twos’ complement7 0111 01116 0110 01105 0101 01014 0100 01003 0011 00112 0010 00101 0001 00010 0000 0000−0 1111−1 1110 1111−2 1101 1110−3 1100 1101−4 1011 1100−5 1010 1011−6 1001 1010−7 1000 1001−8 1000

    1.2.12 SYMMETRIC BASE THREE REPRESENTATIONIn the symmetric base three representation, powers of 3 are added and subtractedto represent numbers; the symbols {↓, 0, ↑} represent {−1, 0, 1}. For example, onewrites ↑↓↓ for 5 since 5 = 9−3−1. To negate a number in symmetric base three, turnits symbol upside down, e.g., −5 =↓↑↑. Basic arithmetic operations are especiallysimple in this base.

  • “smtf33” — 2017/12/6 — 19:00 — page 12 — #22

    12 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.2.13 HEXADECIMAL ADDITION AND SUBTRACTION TABLE

    A = 10, B = 11, C = 12, D = 13, E = 14, F = 15.Example: 6 + 2 = 8; hence 8− 6 = 2 and 8− 2 = 6.Example: 4 + E = 12; hence 12− 4 = E and 12− E = 4.

    1 2 3 4 5 6 7 8 9 A B C D E F1 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 102 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 113 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 124 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 135 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 146 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 157 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 168 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 179 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18 19B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1AC 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1BD 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1CE 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1DF 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E

    1.2.14 HEXADECIMAL MULTIPLICATION TABLE

    Example: 2× 4 = 8.Example: 2× F = 1E.

    1 2 3 4 5 6 7 8 9 A B C D E F1 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F2 02 04 06 08 0A 0C 0E 10 12 14 16 18 1A 1C 1E3 03 06 09 0C 0F 12 15 18 1B 1E 21 24 27 2A 2D4 04 08 0C 10 14 18 1C 20 24 28 2C 30 34 38 3C5 05 0A 0F 14 19 1E 23 28 2D 32 37 3C 41 46 4B6 06 0C 12 18 1E 24 2A 30 36 3C 42 48 4E 54 5A7 07 0E 15 1C 23 2A 31 38 3F 46 4D 54 5B 62 698 08 10 18 20 28 30 38 40 48 50 58 60 68 70 789 09 12 1B 24 2D 36 3F 48 51 5A 63 6C 75 7E 87A 0A 14 1E 28 32 3C 46 50 5A 64 6E 78 82 8C 96B 0B 16 21 2C 37 42 4D 58 63 6E 79 84 8F 9A A5C 0C 18 24 30 3C 48 54 60 6C 78 84 90 9C A8 B4D 0D 1A 27 34 41 4E 5B 68 75 82 8F 9C A9 B6 C3E 0E 1C 2A 38 46 54 62 70 7E 8C 9A A8 B6 C4 D2F 0F 1E 2D 3C 4B 5A 69 78 87 96 A5 B4 C3 D2 E1

  • “smtf33” — 2017/12/6 — 19:00 — page 13 — #23

    1.3. SPECIAL NUMBERS 13

    1.3 SPECIAL NUMBERS

    1.3.1 POWERS OF 2

    1 2 0.52 4 0.253 8 0.1254 16 0.06255 32 0.031256 64 0.0156257 128 0.00781258 256 0.003906259 512 0.00195312510 1024 0.000976562511 2048 0.0004882812512 4096 0.00024414062513 8192 0.000122070312514 16384 0.0000610351562515 32768 0.00003051757812516 65536 0.000015258789062517 131072 0.0000076293945312518 262144 0.00000381469726562519 524288 0.000001907348632812520 1048576 0.0000009536743164062521 2097152 0.00000047683715820312522 4194304 0.000000238418579101562523 8388608 0.0000001192092895507812524 16777216 0.00000005960464477539062525 33554432 0.0000000298023223876953125

    1.3.2 POWERS OF 10 IN HEXADECIMAL

    n 10n 10−n

    0 116 1161 A16 0.19999999999999999999. . .162 6416 0.028F5C28F5C28F5C28F5. . .163 3E816 0.004189374BC6A7EF9DB2. . .164 271016 0.00068DB8BAC710CB295E. . .165 186A016 0.0000A7C5AC471B478423. . .166 F424016 0.000010C6F7A0B5ED8D36. . .167 98968016 0.000001AD7F29ABCAF485. . .168 5F5E10016 0.0000002AF31DC4611873. . .169 3B9ACA0016 0.000000044B82FA09B5A5. . .16

    10 2540BE40016 0.000000006DF37F675EF6. . .16

  • “smtf33” — 2017/12/6 — 19:00 — page 14 — #24

    14 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.3.3 SPECIAL CONSTANTS

    1.3.3.1 The constant πThe transcendental number π is defined as the ratio of the circumference of a circleto the diameter. It is also the ratio of the area of a circle to the square of the radius(r) and appears in several formulas in geometry and trigonometry

    circumference of a circle = 2πr, volume of a sphere =4

    3πr3,

    area of a circle = πr2, surface area of a sphere = 4πr2.

    One method of computing π is to use the infinite series for the function tan−1 x andone of the identities

    π = 4 tan−1 1 = 6 tan−11√3

    = 2 tan−11

    2+ 2 tan−1

    1

    3+ 8 tan−1

    1

    5− 2 tan−1 1

    239

    = 24 tan−11

    8+ 8 tan−1

    1

    57+ 4 tan−1

    1

    239

    = 48 tan−11

    18+ 32 tan−1

    1

    57− 20 tan−1 1

    239

    (1.3.1)

    There are many identities involving π. For example:

    π =∞∑

    i=0

    1

    16i

    (4

    8i+ 1− 2

    8i+ 4− 1

    8i+ 5− 1

    8i+ 6

    )

    π = limk→∞

    2k

    √√√√√√√2−

    √√√√√√2 +

    √√√√√2 +

    √√√√2 +

    2 +

    √2 + · · ·+

    √2 +√2

    ︸ ︷︷ ︸k square roots

    2

    π=

    ∞∏

    k=1

    k square roots︷ ︸︸ ︷√

    2 +

    √2 + · · ·+

    √2 +√2

    2

    π3

    32=

    ∞∑

    n=0

    (−1)n(2n+ 1)3

    = 1− 127

    +1

    125− 1

    343+ . . .

    To 100 decimal places:π ≈ 3. 14159 26535 89793 23846 26433 83279 50288 41971 69399 37510

    58209 74944 59230 78164 06286 20899 86280 34825 34211 70679

  • “smtf33” — 2017/12/6 — 19:00 — page 15 — #25

    1.3. SPECIAL NUMBERS 15

    In different bases:π ≈ 11.00100100001111110110101010001000100001011010001. . . 2π ≈ 3.11037552421026430215142306305056006701632112201. . . 8π ≈ 3.243F6A8885A308D313198A2E03707344A4093822299F. . . 16

    To 50 decimal places:

    π/8 ≈ 0.39269 90816 98724 15480 78304 22909 93786 05246 46174 92189π/4 ≈ 0.78539 81633 97448 30961 56608 45819 87572 10492 92349 84378π/3 ≈ 1.04719 75511 96597 74615 42144 61093 16762 80657 23133 12504π/2 ≈ 1.57079 63267 94896 61923 13216 91639 75144 20985 84699 68755√π ≈ 1.77245 38509 05516 02729 81674 83341 14518 27975 49456 12239

    In 2016 π was computed to 12.1 trillion decimal digits. The frequency counts of thedigits for π − 3, using 1 trillion decimal places, are:

    digit 0: 99999485134 digit 5: 99999671008digit 1: 99999945664 digit 6: 99999807503digit 2: 100000480057 digit 7: 99999818723digit 3: 99999787805 digit 8: 100000791469digit 4: 100000357857 digit 9: 99999854780

    1.3.3.2 The constant eThe transcendental number e is the base of natural logarithms. It is given by

    e = limn→∞

    (1 +

    1

    n

    )n=

    ∞∑

    n=0

    1

    n!. (1.3.2)

    e ≈ 2.71828 18284 59045 23536 02874 71352 66249 77572 47093 6999595749 66967 62772 40766 30353 54759 45713 82178 52516 64274 . . .

    In different bases:e ≈ 10.10110111111000010101000101100010100010101110110. . . 2e ≈ 2.55760521305053551246527734254200471723636166134. . . 8e ≈ 2.B7E151628AED2A6ABF7158809CF4F3C762E7160F3. . . 16

    The exponential function is ex =∞∑

    n=0

    xn

    n!. Euler’s formula relates e and π: eπi = −1

    1.3.3.3 The constant γEuler’s constant γ is defined by

    γ = limn→∞

    (n∑

    k=1

    1

    k− logn

    ). (1.3.3)

    It is not known whether γ is rational or irrational.

    γ ≈ 0.57721 56649 01532 86060 65120 90082 40243 10421 59335 9399235988 05767 23488 48677 26777 66467 09369 47063 29174 67495 . . .

  • “smtf33” — 2017/12/6 — 19:00 — page 16 — #26

    16 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.3.3.4 The constant φThe golden ratio, φ, is defined as the positive root of the equation φ1 =

    1+φφ or

    φ2 = φ+1; that is φ = 1+√5

    2 . There is the continued faction representationφ =[1]

    and the representation in square roots

    φ =

    1 +

    √1 +

    √1 +√1 + . . .

    φ ≈ 1.61803 39887 49894 84820 45868 34365 63811 77203 09179 80576 . . .

    1.3.4 FACTORIALS

    The factorial of n, denoted n!, is the product of all positive integers less than or equalto n; n! = n ·(n−1) ·(n−2) · · ·2 ·1. By definition, 0! = 1. If n is a negative integer(n = −1,−2, . . . ) then n! = ±∞. The generalization of the factorial function tonon-integer arguments is the gamma function (see page 478); when n is an integer,Γ(n) = (n− 1)!.

    The double factorial of n is denoted by n!! and is defined as n!! = n(n− 2)(n−4) · · · , where the last term in the product is 2 or 1, depending on whether n is evenor odd. The shifted factorial (also called Pochhammer’s symbol) is denoted by (a)nand is defined as

    (a)n = a · (a+ 1) · (a+ 2) · · · (a+ n− 1)︸ ︷︷ ︸n terms

    =(a+ n− 1)!(a− 1)! =

    Γ(a+ n)

    Γ(a)(1.3.4)

    Approximations to n! for large n include Stirling’s formula (the first term of thefollowing)

    n! ≈√2πe

    (ne

    )n+ 12 (1 +

    1

    12n+

    1

    288n2+ . . .

    )(1.3.5)

    and Burnside’s formula

    n! ≈√2π

    (n+ 12e

    )n+ 12(1.3.6)

    n n! log10 n! n!! log10 n!!

    0 1 0.00000 1 0.000001 1 0.00000 1 0.000002 2 0.30103 2 0.301033 6 0.77815 3 0.477124 24 1.38021 8 0.903095 120 2.07918 15 1.176096 720 2.85733 48 1.681247 5040 3.70243 105 2.021198 40320 4.60552 384 2.584339 3.6288× 105 5.55976 945 2.97543

    10 3.6288× 106 6.55976 3840 3.58433

  • “smtf33” — 2017/12/6 — 19:00 — page 17 — #27

    1.3. SPECIAL NUMBERS 17

    n n! log10 n! n!! log10 n!!

    20 2.4329× 1018 18.38612 3.7159× 109 9.5700630 2.6525× 1032 32.42366 4.2850× 1016 16.6319540 8.1592× 1047 47.91165 2.5511× 1024 24.4067250 3.0414× 1064 64.48307 5.2047× 1032 32.7164060 8.3210× 1081 81.92017 2.8481× 1041 41.4545670 1.1979× 10100 100.07841 3.5504× 1050 50.5502880 7.1569× 10118 118.85473 8.9711× 1059 59.9528490 1.4857× 10138 138.17194 4.2088× 1069 69.62416

    100 9.3326× 10157 157.97000 3.4243× 1079 79.53457150 5.7134× 10262 262.75689 9.3726× 10131 131.97186500 1.2201× 101134 1134.0864 5.8490× 10567 567.767091000 4.0239× 102567 2567.6046 3.9940× 101284 1284.6014

    1.3.5 BERNOULLI POLYNOMIALS AND NUMBERS

    The Bernoulli polynomials Bn(x) are defined by the generating function

    text

    et − 1 =∞∑

    n=0

    Bn(x)tn

    n!. (1.3.7)

    These polynomials can be defined recursively by B0(x) = 1, B′n(x) = nBn−1(x),and

    ∫ 10 Bn(x) dx = 0 for n ≥ 1. The identityBk+1(x+1)−Bk+1(x) = (k+1)xk

    means that sums of powers can be computed via Bernoulli polynomials

    1k + 2k + · · ·+ nk = Bk+1(n+ 1)−Bk+1(0)k + 1

    . (1.3.8)

    The Bernoulli numbers are the Bernoulli polynomials evaluated at 0: Bn = Bn(0).

    A generating function for the Bernoulli numbers is∞∑

    n=0

    Bntn

    n!=

    t

    et − 1 . In the

    following table each Bernoulli number is written as a fraction of integers: Bn =Nn/Dn. Note that B2m+1 = 0 for m ≥ 1.

    n Bn(x)0 11 (2x− 1)/22 (6x2 − 6x+ 1)/63 (2x3 − 3x2 + x)/24 (30x4 − 60x3 + 30x2 − 1)/305 (6x5 − 15x4 + 10x3 − x)/6

    n Nn Dn Bn

    0 1 1 1.00000× 1001 −1 2 −5.00000× 10−12 1 6 1.66667× 10−14 −1 30 −3.33333× 10−26 1 42 2.38095× 10−28 −1 30 −3.33333× 10−2

    10 5 66 7.57576× 10−2

  • “smtf33” — 2017/12/6 — 19:00 — page 18 — #28

    18 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.3.6 EULER POLYNOMIALS AND NUMBERS

    The Euler polynomials En(x) are defined by the generating function

    2ext

    et + 1=

    ∞∑

    n=0

    En(x)tn

    n!. (1.3.9)

    Alternating sums of powers can be computed in terms of Euler polynomialsn∑

    i=1

    (−1)n−iik = nk − (n− 1)k + · · · ∓ 2k ± 1k = Ek(n+ 1) + (−1)nEk(0)

    2.

    (1.3.10)The Euler numbers are defined as En = 2nEn(12 ). A generating function is

    ∞∑

    n=0

    Entn

    n!=

    2et

    e2t + 1(1.3.11)

    n En(x)0 11 (2x− 1)/22 x2 − x3 (4x3 − 6x2 + 1)/44 x4 − 2x3 + x5 (2x5 − 5x4 + 5x2 − 1)/2

    n En2 −14 56 −618 1385

    10 −5052112 2702765

    1.3.7 FIBONACCI NUMBERS

    The Fibonacci numbers {Fn} are defined by the recurrence:F1 = 1, F2 = 1, Fn+2 = Fn + Fn+1. (1.3.12)

    An exact formula is available (see page 186):

    Fn =1√5

    [(1 +√5

    2

    )n−(1−√5

    2

    )n](1.3.13)

    Note that Fn is the integer nearest to φn/√5 as n→∞, where φ is the golden ratio.

    n Fn1 12 13 24 35 56 87 138 219 34

    10 55

    n Fn11 8912 14413 23314 37715 61016 98717 159718 258419 418120 6765

    n Fn21 1094622 1771123 2865724 4636825 7502526 12139327 19641828 31781129 51422930 832040

    n Fn31 134626932 217830933 352457834 570288735 922746536 1493035237 2415781738 3908816939 6324598640 102334155

  • “smtf33” — 2017/12/6 — 19:00 — page 19 — #29

    1.3. SPECIAL NUMBERS 19

    1.3.8 SUMS OF POWERS OF INTEGERS

    1. Define the sum of the first n kth-powers

    sk(n) = 1k + 2k + · · ·+ nk =

    n∑

    m=1

    mk. (1.3.14)

    (a) sk(n) = (k + 1)−1 [Bk+1(n+ 1)−Bk+1(0)](where the Bk are Bernoulli polynomials, see Section 1.3.5).

    (b) If sk(n) =∑k+1

    m=1 amnk−m+2, then

    sk+1(n) =

    (k + 1

    k + 2

    )a1n

    k+2 + · · ·+(k + 1

    k

    )a3n

    k

    + · · ·+(k + 1

    2

    )ak+1n

    2 +

    [1− (k + 1)

    k+1∑

    m=1

    amk + 3−m

    ]n.

    (c) Note the specific values

    s1(n) = 1 + 2 + 3 + · · ·+ n =1

    2n(n+ 1)

    s2(n) = 12 + 22 + 32 + · · ·+ n2 = 1

    6n(n+ 1)(2n+ 1)

    s3(n) = 13 + 23 + 33 + · · ·+ n3 = 1

    4n2(n+ 1)2 = [s1(n)]

    2

    s4(n) = 14 + 24 + 34 + · · ·+ n4 = 1

    5(3n2 + 3n− 1)s2(n)

    s5(n) = 15 + 25 + 35 + · · ·+ n5 = 1

    12n2(n+ 1)2(2n2 + 2n− 1)

    2.n∑

    k=1

    (km− 1) = 12mn(n+ 1)− n

    3.n∑

    k=1

    (km− 1)2 = n6

    [m2(n+ 1)(2n+ 1)− 6m(n+ 1) + 6

    ]

    4.n∑

    k=1

    (−1)k+1(km− 1) = (−1)n

    4[2− (2n+ 1)m] + m− 2

    4

    5.n∑

    k=1

    (−1)k+1(km− 1)2 = (−1)n+1

    2

    [n(n+ 1)m2 − (2n+ 1)m+ 1

    ]+ 1−m2

    n

    n∑

    k=1

    k

    n∑

    k=1

    k2n∑

    k=1

    k3n∑

    k=1

    k4n∑

    k=1

    k5

    1 1 1 1 1 12 3 5 9 17 333 6 14 36 98 2764 10 30 100 354 13005 15 55 225 979 4425

  • “smtf33” — 2017/12/6 — 19:00 — page 20 — #30

    20 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.3.9 NEGATIVE INTEGER POWERS

    Riemann’s zeta function is defined to be ζ(n) =∑∞

    k=11kn (it is defined for Re n > 1

    and extended to C). Related functions are

    α(n) =

    ∞∑

    k=1

    (−1)k+1kn

    , β(n) =

    ∞∑

    k=0

    (−1)k(2k + 1)n

    , γ(n) =

    ∞∑

    k=0

    1

    (2k + 1)n.

    Properties include:

    1. α(n) = (1 − 21−n)ζ(n)

    2. ζ(2k) =(2π)2k

    2(2k)!|B2k|

    3. γ(n) = (1− 2−n)ζ(n)

    4. β(2k + 1) =(π/2)2k+1

    2(2k)!|E2k|

    5. The series β(1) = 1− 13 + 15 − · · · = π/4 is known as Gregory’s series.

    6. Catalan’s constant is G = β(2) ≈ 0.915966.

    7. Riemann hypothesis: The non-trivial zeros of the Riemann zeta function (i.e.,the {zi} that satisfy ζ(zi) = 0) lie on the critical line given by Re zi = 12 .(The trivial zeros are z = −2,−4,−6, . . . .)

    n ζ(n) =∞∑

    k=1

    1

    kn

    ∞∑

    k=1

    (−1)k+1kn

    ∞∑

    k=0

    (−1)k(2k + 1)n

    ∞∑

    k=0

    1

    (2k + 1)n

    1 ∞ 0.6931471805 0.7853981633 ∞2 1.6449340668 0.8224670334 0.9159655941 1.23370055013 1.2020569032 0.9015426773 0.9689461463 1.05179979034 1.0823232337 0.9470328294 0.9889445517 1.01467803165 1.0369277551 0.9721197705 0.9961578281 1.00452376286 1.0173430620 0.9855510912 0.9986852222 1.00144707667 1.0083492774 0.9925938199 0.9995545079 1.00047154878 1.0040773562 0.9962330018 0.9998499902 1.00015517909 1.0020083928 0.9980942975 0.9999496842 1.000051345210 1.0009945751 0.9990395075 0.9999831640 1.0000170414

    β(1) = π/4 ζ(2) = π2/6β(3) = π3/32 ζ(4) = π4/90β(5) = 5π5/1536 ζ(6) = π6/945β(7) = 61π7/184320 ζ(8) = π8/9450β(9) = 277π9/8257536 ζ(10) = π10/93555

  • “smtf33” — 2017/12/6 — 19:00 — page 21 — #31

    1.3. SPECIAL NUMBERS 21

    1.3.10 INTEGER SEQUENCES

    These sequences are in numerical order (disregarding leading zeros or ones).

    1. 1, −1, −1, 0, −1, 1, −1, 0, 0, 1, −1, 0, −1, 1, 1, 0, −1, 0, −1, 0, 1, 1, −1, 0, 0, 1, 0,0, −1, −1, −1, 0, 1, 1, 1, 0, −1, 1, 1, 0, −1, −1, −1, 0, 0, 1, −1, 0, 0, 0, 1, 0, −1, 0,1, 0 Möbius function µ(n), n ≥ 1

    2. 1, 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 2, 1, 0, 0, 1, 0, 0, 1, 0, 1,0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 2, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 2, 0, 0, 1,0 Number of ways of writing n as a sum of 2 squares, n ≥ 0

    3. 1, 1, 1, 2, 1, 1, 1, 3, 2, 1, 1, 2, 1, 1, 1, 5, 1, 2, 1, 2, 1, 1, 1, 3, 2, 1, 3, 2, 1, 1, 1, 7, 1, 1,1, 4, 1, 1, 1, 3, 1, 1, 1, 2, 2, 1, 1, 5, 2, 2, 1, 2, 1, 3, 1, 3, 1, 1, 1, 2, 1, 1, 2, 11, 1, 1, 1,2 Number of Abelian groups of order n, n ≥ 1

    4. 1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51,1, 2, 1, 14, 1, 2, 2, 14, 1, 6, 1, 4, 2, 2, 1, 52, 2, 5, 1, 5, 1, 15, 2, 13, 2, 2, 1, 13, 1, 2, 4,267 Number of groups of order n, n ≥ 1

    5. 0, 1, 1, 2, 1, 2, 2, 3, 1, 2, 2, 3, 2, 3, 3, 4, 1, 2, 2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 1, 2,2, 3, 2, 3, 3, 4, 2, 3, 3, 4, 3, 4, 4, 5, 2, 3, 3, 4, 3, 4, 4, 5, 3, 4, 4, 5, 4, 5, 5, 6, 1, 2, 2, 3,2 Number of 1’s in binary expansion of n, n ≥ 0

    6. 1, 2, 1, 2, 3, 6, 9, 18, 30, 56, 99, 186, 335, 630, 1161, 2182, 4080, 7710, 14532, 27594,52377, 99858, 190557, 364722, 698870, 1342176, 2580795, 4971008Number of binary irreducible polynomials of degree n, or n-bead necklaces, n ≥ 0

    7. 1, 2, 2, 3, 2, 4, 2, 4, 3, 4, 2, 6, 2, 4, 4, 5, 2, 6, 2, 6, 4, 4, 2, 8, 3, 4, 4, 6, 2, 8, 2, 6, 4, 4,4, 9, 2, 4, 4, 8, 2, 8, 2, 6, 6, 4, 2, 10, 3, 6, 4, 6, 2, 8, 4, 8, 4, 4, 2, 12, 2, 4, 6, 7, 4, 8, 2,6 d(n), the number of divisors of n, n ≥ 1

    8. 1, 1, 2, 2, 3, 4, 5, 6, 8, 10, 12, 15, 18, 22, 27, 32, 38, 46, 54, 64, 76, 89, 104, 122,142, 165, 192, 222, 256, 296, 340, 390, 448, 512, 585, 668, 760, 864, 982, 1113, 1260,1426 Number of partitions of n into distinct parts, n ≥ 1

    9. 1, 1, 2, 2, 4, 2, 6, 4, 6, 4, 10, 4, 12, 6, 8, 8, 16, 6, 18, 8, 12, 10, 22, 8, 20, 12, 18, 12, 28,8, 30, 16, 20, 16, 24, 12, 36, 18, 24, 16, 40, 12, 42, 20, 24, 22, 46, 16, 42

    Euler totient function φ(n): count numbers ≤ n and prime to n, for n ≥ 110. 1, 2, 3, 4, 5, 7, 8, 9, 11, 13, 16, 17, 19, 23, 25, 27, 29, 31, 32, 37, 41, 43, 47, 49, 53,

    59, 61, 64, 67, 71, 73, 79, 81, 83, 89, 97, 101, 103, 107, 109, 113, 121, 125, 127, 128,131 Powers of prime numbers

    11. 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 60, 61, 67, 71, 73, 79,83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 168,173 Orders of simple groups

    12. 1, 2, 3, 5, 7, 11, 15, 22, 30, 42, 56, 77, 101, 135, 176, 231, 297, 385, 490, 627, 792,1002, 1255, 1575, 1958, 2436, 3010, 3718, 4565, 5604, 6842, 8349, 10143, 12310,14883 Number of partitions of n, n ≥ 1

    13. 2, 3, 5, 7, 13, 17, 19, 31, 61, 89, 107, 127, 521, 607, 1279, 2203, 2281, 3217,4253, 4423, 9689, 9941, 11213, 19937, 21701, 23209, 44497, 86243, 110503, 132049,216091, 756839, 859433 Mersenne primes: n such that 2n − 1 is prime

    14. 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987, 1597, 2584, 4181,6765, 10946, 17711, 28657, 46368, 75025, 121393, 196418, 317811, 514229, 832040,1346269 Fibonacci numbers: F (n) = F (n− 1) + F (n− 2)

  • “smtf33” — 2017/12/6 — 19:00 — page 22 — #32

    22 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    15. 1, 2, 3, 6, 10, 20, 35, 70, 126, 252, 462, 924, 1716, 3432, 6435, 12870, 24310, 48620,92378, 184756, 352716, 705432, 1352078, 2704156, 5200300, 10400600, 20058300

    Central binomial coefficients: C(n, ⌊n/2⌋), n ≥ 116. 1, 1, 1, 2, 3, 6, 11, 23, 47, 106, 235, 551, 1301, 3159, 7741, 19320, 48629, 123867,

    317955, 823065, 2144505, 5623756, 14828074, 39299897, 104636890,279793450 Number of trees with n unlabeled nodes, n ≥ 1

    17. 0, 0, 1, 1, 2, 3, 7, 21, 49, 165, 552, 2176, 9988Number of prime knots with n crossings, n ≥ 1

    18. 0, 1, 2, 4, 5, 8, 9, 10, 13, 16, 17, 18, 20, 25, 26, 29, 32, 34, 36, 37, 40, 41, 45, 49, 50,52, 53, 58, 61, 64, 65, 68, 72, 73, 74, 80, 81, 82, 85, 89, 90, 97, 98, 100, 101, 104,106 Numbers that are sums of 2 squares

    19. 1, 2, 4, 6, 10, 14, 20, 26, 36, 46, 60, 74, 94, 114, 140, 166, 202, 238, 284, 330, 390,450, 524, 598, 692, 786, 900, 1014, 1154, 1294, 1460, 1626, 1828, 2030, 2268, 2506

    Binary partitions (partitions of 2n into powers of 2), n ≥ 020. 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, 32768,

    65536, 131072, 262144, 524288, 1048576, 2097152, 4194304, 8388608, 16777216,33554432, 67108864 Powers of 2

    21. 1, 1, 2, 4, 9, 20, 48, 115, 286, 719, 1842, 4766, 12486, 32973, 87811, 235381,634847, 1721159, 4688676, 12826228, 35221832, 97055181, 268282855, 743724984,2067174645 Number of rooted trees with n unlabeled nodes, n ≥ 1

    22. 1, 1, 2, 4, 9, 22, 59, 167, 490, 1486, 4639, 14805, 48107, 158808, 531469, 1799659,6157068, 21258104, 73996100, 259451116, 951695102, 3251073303

    Number of different scores in n-team round-robin tournament, n ≥ 123. 1, 1, 2, 5, 12, 35, 108, 369, 1285, 4655, 17073, 63600, 238591, 901971,

    3426576, 13079255, 50107909, 192622052, 742624232, 2870671950, 11123060678,43191857688 Polyominoes with n cells, n ≥ 1

    24. 1, 1, 2, 5, 14, 38, 120, 353, 1148, 3527, 11622, 36627, 121622, 389560, 1301140,4215748, 13976335, 46235800, 155741571, 512559185, 1732007938,5732533570 Number of ways to fold a strip of n blank stamps, n ≥ 1

    25. 0, 1, 2, 9, 44, 265, 1854, 14833, 133496, 1334961, 14684570, 176214841,2290792932, 32071101049, 481066515734, 7697064251745, 130850092279664

    Derangements: permutations of n elements with no fixed points

    26. 1, 3, 4, 7, 6, 12, 8, 15, 13, 18, 12, 28, 14, 24, 24, 31, 18, 39, 20, 42, 32, 36, 24, 60,31, 42, 40, 56, 30, 72, 32, 63, 48, 54, 48, 91, 38, 60, 56, 90, 42, 96, 44, 84, 78, 72, 48,124 σ(n), sum of the divisors of n, n ≥ 1

    27. 1, 3, 4, 7, 9, 12, 13, 16, 19, 21, 25, 27, 28, 31, 36, 37, 39, 43, 48, 49, 52, 57, 61, 63,64, 67, 73, 75, 76, 79, 81, 84, 91, 93, 97, 100, 103, 108, 109, 111, 112, 117, 121, 124,127 Numbers of the form x2 + xy + y2

    28. 1, 20, 400, 8902, 197281, 4865609, 119060324, 3195901860, 84998978956,2439530234167 Number of possible chess games at the end of the nth ply.

    29. 1, 362, 130683, 47046243, 16889859363, 6046709375131Number of Go games with n moves.

    For information on these and hundreds of thousands of other sequences, see “TheOn-Line Encyclopedia of Integer Sequences,” at oeis.org.

  • “smtf33” — 2017/12/6 — 19:00 — page 23 — #33

    1.3. SPECIAL NUMBERS 23

    1.3.11 p-ADIC NUMBERS

    Given a prime p, a non-zero rational number x can be written as x =a

    bpn where n

    is an integer and p does not divide a or b. Define the p-adic norm of x as |x|p = p−nand also define |0|p = 0. The p-adic norm has the properties:

    1. |x|p ≥ 0 for all non-negative rational numbers x2. |x|p = 0 if and only if x = 03. For all non-negative rational numbers x and y

    (a) |xy|p = |x|p|y|p(b) |x+ y|p ≤ max (|x|p, |y|p) ≤ |x|p + |y|p

    Note the product formula: |x|∏p∈{2,3,5,7,11,... } |x|p = 1.Let Qp be the topological completion of Q with respect to | · |p. Then Qp is the

    field of p-adic numbers. The elements of Qp can be viewed as infinite series: theseries

    ∑∞n=0 an converges to a point in Qp if and only if limn→∞ |an|p = 0.

    EXAMPLE The number 140297

    = 22 · 3−3 · 5 · 7 · 11−1 has the different p-adic norms:

    •∣∣∣∣140

    297

    ∣∣∣∣2

    = 2−2 =1

    4

    •∣∣∣∣140

    297

    ∣∣∣∣3

    = 33 = 27

    •∣∣∣∣140

    297

    ∣∣∣∣5

    = 5−1 =1

    5

    •∣∣∣∣140

    297

    ∣∣∣∣7

    = 7−1 =1

    7

    •∣∣∣∣140

    297

    ∣∣∣∣11

    = 111 = 11

    1.3.12 DE BRUIJN SEQUENCES

    A sequence of length qn over an alphabet of size q is a de Bruijn sequence if everypossible n-tuple occurs in the sequence (allowing wraparound to the start of the se-quence). There are de Bruijn sequences for any q and n. (In fact, there are q!q

    n−1/q!

    distinct sequences.) The table below contains some small examples.

    q n Length Sequence2 1 2 012 2 4 01102 3 8 011101002 4 16 01010011011110003 2 9 0012202113 3 27 0001002011012021022111212224 2 16 0011310221203323

  • “smtf33” — 2017/12/6 — 19:00 — page 24 — #34

    24 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.4 INTERVAL ANALYSIS

    1. Definitions

    (a) An interval x is a subset of the real line:x = [x, x] = {z ∈ R | x ≤ z ≤ x}.

    (b) A thin interval is a real number: x is thin if x = x

    (c) mid(x) =x+ x

    2

    (d) rad(x) =x− x2

    (e) |x| = mag(x) = maxz∈x|z|

    (f) 〈x〉 = mig(x) = minz∈x|z|

    The MATLAB R© package INTLAB performs interval computations.2. Interval arithmetic rules

    Operation Rule

    x+ y[x+ y, x+ y

    ]

    x− y[x− y, x− y

    ]

    xy[min(xy, xy, xy, xy),max(xy, xy, xy, xy)

    ]

    xy

    [min

    (xy ,

    xy ,

    xy ,

    xy

    ),max

    (xy ,

    xy ,

    xy ,

    xy

    ))]

    if 0 6∈ y

    3. Interval arithmetic properties

    Property + and − ∗ and /

    commutative x+ y = y + x xy = yx

    associative x+ (y + z) = (x+ y) + z x(yz) = (xy)z

    identity elements 0 + x = x+ 0 = x 1 ∗ y = y ∗ 1 = y

    sub-distributivity x(y ± z) ⊆ xy ± xz (equality holds if x is thin)

    sub-cancellation x− y ⊆ (x + z)− (y + z) xy ⊆ xzyz0 ∈ x− x 1 ∈ yy

    4. Examples

    (a) [1, 2] + [−2, 1] = [−1, 3](b) [1, 2]− [1, 2] = [−1, 1]

    (c) [1, 2] ∗ [−2, 1] = [−4, 2](d) [1, 2]/[1, 2] =

    [12 , 2]

    (e) If f(a, b;x) = ax+ b then (when a = [1, 2], b = [5, 7], and x = [2, 3]);

    f([1, 2], [5, 7]; [2, 3]) = [1, 2]·[2, 3]+[5, 7] = [1·2, 2·3]+[5, 7] = [7, 13]

  • “smtf33” — 2017/12/6 — 19:00 — page 25 — #35

    1.5. FRACTAL ARITHMETIC 25

    1.5 FRACTAL ARITHMETIC

    Given a real-valued bijection f with f(0) = 0 and f(1) = 1 define

    x⊕ y = f−1 (f(x) + f(y)) x⊖ y = f−1 (f(x)− f(y))x⊙ y = f−1 (f(x)f(y)) x⊘ y = f−1 (f(x)/f(y))

    (1.5.1)

    For example, if f(x) = xq then x ⊙ y = xy and x ⊕ y = (xq + yq)1/q . Note thatthe following hold:

    • Associativity: (x ⊕ y)⊕ z = x⊕ (y ⊕ z) and (x ⊙ y)⊙ z = x⊙ (y ⊙ z)• Commutativity: x⊕ y = y ⊕ x and x⊙ y = y ⊙ x• Distributivity: (x⊕ y)⊙ z = (x⊙ z)⊕ (y ⊙ z)

    The elements 0 and 1 satisfy 0⊕ x = x and 1⊙ x = x.1. x⊖ x = 0 and x⊘ x = 1.2. In general, x⊕ x 6= 2⊙ x.3. If 0⊖ x exists, it is denoted as ⊖x

    Define derivative and integration operations:

    dfA(x)

    dfx= lim

    h→0(A(x⊕ h)⊖A(x)) ⊘ h

    ∫ b

    a

    Ff (x)⊙ dfx = f−1(∫ f(b)

    f(a)

    F (y) dy

    ) (1.5.2)

    so that

    1.df (A(x) ⊙B(x))

    dfx=df (A(x))

    dfx⊙B(x) ⊕A(x) ⊙ df (B(x))

    dfx

    2.df (A(x) ⊕B(x))

    dfx=df (A(x))

    dfx⊕ df (B(x))

    dfx

    3.df (A[B(x)])

    dfx=df (A[B(x)])

    dfB(x)⊙ df (B(x))

    dfx

    4.∫ b

    a

    dfA(x)

    dfx⊙ dfx = A(b)⊖A(a)

    5.dfdfx

    ∫ b

    a

    A(x′)⊙ dfx′ = A(x)

    6.dfFf (x)

    dfx= f−1 (F ′(f(x)))

    Special functions Given a function F define Ff as Ff (x) = f−1 (F (f(x))).

    1. The expf function satisfies expf (x⊕ y) = expf x⊙ expf y and is the uniquesolution to the differential equation dfA(x)dfx = A(x) with A(0) = 1.

    2. The lnf function satisfies lnf (x⊙ y) = lnf x⊕ lnf y

  • “smtf33” — 2017/12/6 — 19:00 — page 26 — #36

    26 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.6 MAX-PLUS ALGEBRA

    The max-plus algebra is an algebraic structure with real numbers and two opera-tions (called “plus” and “times”); “plus” is the operation of taking a maximum, and“times” is the “standard addition” operation. Mathematically:

    The max-plus semiring Rmax is the set R ∪ {−∞} with two operations called“plus” (⊕) and “times” (⊗) defined as follows:• a⊕ b = max(a, b)• a⊗ b = a+ b

    For a and b in Rmax the following laws apply:

    1. Associativity

    • (a⊕ b)⊕ c = a⊕ (b⊕ c)• (a⊗ b)⊗ c = a⊗ (b⊗ c)

    2. Commutativity

    • a⊕ b = b⊕ a• a⊗ b = b⊗ a

    3. Distributivity: (a⊕ b)⊗ c = a⊗ c⊕ b⊗ c4. Idempotency of ⊕ : a⊕ a = a

    Special elements are the “zero element” ǫ = −∞ and and the “unit element” e = 0.These have the properties:• ǫ⊕ a = a • ǫ⊗ a = ǫ • e⊗ a = a

    Let A and B be matrices and let [C]ij be the ij th element of matrix C. Then

    • [A⊕B]ij = [A]ij ⊕ [B]ij = max([A]ij , [B]ij)when A and B have the same size• [A⊗B]ij =

    ⊕pk=1([A]ik ⊗ [B]kj) = max([A]i1 + [B]1j , . . . , [A]ip + [B]pj)

    when A has p columns and B has p rows.

    Notes

    1. Rmax is not a group since not all elements have an additive inverse. (Only oneelement has an additive inverse, it is −∞.)

    2. The equation a⊕ x = b need not have a unique solution.• If a < b, then x = b• If a = b, then x can be any value with x ≤ b• If a > b, then there is no solution

    3. In Rmax matrix multiplication is associative.4. Defining exponential as an = a⊗ a⊗ · · · ⊗ a︸ ︷︷ ︸

    n times

    = a+ a+ · · ·+ a︸ ︷︷ ︸n times

    = na we

    find ax ⊗ ay = ax+y and (ax)y = axy, as in ordinary arithmetic.5. The Kleene star of the matrix A is the matrix A∗ = I +A+A2 + · · · .6. The completed max-plus semiringRmax is the same asRmax with the additional

    element +∞ and the convention (−∞) + (+∞) = (+∞) + (−∞) = −∞

  • “smtf33” — 2017/12/6 — 19:00 — page 27 — #37

    1.7. COUPLED-ANALOGUES OF FUNCTIONS 27

    EXAMPLELet A =

    [10 −∞5 3

    ]and B =

    [8 27 0

    ]. Then

    • Scalar multiplication of a matrix 5⊗A =[5⊗ 10 5⊗ (−∞)5⊗ 5 5⊗ 3

    ]=

    [15 −∞10 8

    ]

    • Matrix addition A⊕B =[10⊕ 8 −∞⊕ 25⊕ 7 3⊕ 0

    ]=

    [10 27 3

    ]

    • Matrix multiplication

    A⊗B =[10⊗ 8⊕ (−∞)⊗ 7 10⊗ 2⊕ (−∞)⊗ 0

    5⊗ 8⊕ 3⊗ 7 5⊗ 2⊕ 3⊗ 0

    ]

    =

    [18⊕ (−∞) 12⊕ (−∞)13⊕ 10 7⊕ 3

    ]=

    [18 1213 7

    ]

    1.7 COUPLED-ANALOGUES OF FUNCTIONS1. The coupled-logarithm, for x > 0, is lnκ(x) =

    xκ − 1κ

    Note that:

    limκ→0

    lnκ(x) = lnx lnκ (xa) = a lnaκ(x) lnκ (e

    xκ) = x (1.7.1)

    2. The coupled-exponential is exκ =

    {[1 + κx]1/κ when 1 + κx ≥ 00 otherwise

    Note that:

    limκ→0

    exκ = ex (eκ)

    a= eaxκ/a expκ (lnκ(x)) = x

    d

    dxeaxκ = a exp κ1−κ [(1− κ)ax] when κ 6= 1∫

    eaxκ dx =1

    a(1 + κ)exp κ

    1+κ[(1 + κ)ax] + c1 when κ 6= −1

    (1.7.2)

    1.7.1 COUPLED-OPERATIONS1. Coupled-addition is defined by: x⊕κ y = x+ y + κxy. Note that:

    exκeyκ = e

    x⊕κyκ

    lnκ(xy) = lnκ(x)⊕ lnκ(y)x⊕ y ⊕ z = x+ y + z + κ(xy + xz + yz) + κ2xyz

    (1.7.3)

    2. Coupled-subtraction is defined by: x⊖κ y = (x− y)/(1 + κy)3. Coupled-division is defined by: x⊘κ y = (xq − yq + 1)1/κ4. Coupled-multiplication is defined by: x⊗κ y = (xκ + yκ − 1)1/κ. Note that:

    exκ ⊗κ eyκ = ex+yκ lnκ(x ⊗κ y) = lnκ(x) + lnκ(y)

    x1 ⊗κ x1 ⊗κ · · · ⊗κ xn =n∏

    i=1

    κ xi = (xκ1 + x

    κ2 + · · ·+ xκn − n+ 1)1/κ

  • “smtf33” — 2017/12/6 — 19:00 — page 28 — #38

    28 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.8 NUMBER THEORY

    Divisibility The notation “a|b” means that the number a evenly divides the number b.That is, the ratio ba is an integer.

    1.8.1 CONGRUENCES

    1. If the integers a and b leave the same remainder when divided by the numbern,then a and b are congruent modulo n. This is written a ≡ b (mod n).

    2. If the congruencex2 ≡ a (mod p) has a solution, then a is a quadratic residueof p. Otherwise, a is a quadratic non-residue of p.

    (a) Let p be an odd prime. Legendre’s symbol(ap

    )has the value +1 if a is

    a quadratic residue of p, and the value−1 if a is a quadratic non-residueof p. This can be written

    (ap

    )≡ a(p−1)/2 (mod p).

    (b) The Jacobi symbol generalizes the Legendre symbol to non-prime mod-uli. If n =

    ∏ki=1 p

    bii then the Jacobi symbol can be written in terms of

    the Legendre symbol as follows

    ( an

    )=

    k∏

    i=1

    (a

    pi

    )bi. (1.8.1)

    3. An exact covering sequence is a set of non-negative ordered pairs{(ai, bi)}i=1,...,k such that every non-negative integer n satisfies n ≡ ai(mod bi) for exactly one i. An exact covering sequence satisfies

    k∑

    i=1

    xai

    1− xbi =1

    1− x . (1.8.2)

    For example, every positive integer n is either congruent to 1 mod 2, or 0mod 4, or 2 mod 4. Hence, the three pairs {(1, 2), (0, 4), (2, 4)} of residuesand moduli exactly cover the positive integers. Note that

    x

    1− x2 +1

    1− x4 +x2

    1− x4 =1

    1− x . (1.8.3)

    4. Carmichael numbers are composite numbers {n} that satisfy an−1 ≡ 1(mod n) for every a (with 1 < a < n) that is relatively prime to n. There areinfinitely many Carmichael numbers. Every Carmichael number has at leastthree prime factors. If n =

    ∏i pi is a Carmichael number, then (pi−1) divides

    (n− 1) for each i.There are 43 Carmichael numbers less than 106 and 105,212 less than 1015.The Carmichael numbers less than ten thousand are 561, 1105, 1729, 2465,2821, 6601, and 8911.

  • “smtf33” — 2017/12/6 — 19:00 — page 29 — #39

    1.8. NUMBER THEORY 29

    1.8.1.1 Properties of congruences1. If a ≡ b (mod n), then b ≡ a (mod n).2. If a ≡ b (mod n), and b ≡ c (mod n), then a ≡ c (mod n).3. If a ≡ a′ (mod n), and b ≡ b′ (mod n), then a± b ≡ a′ ± b′ (mod n).4. If a ≡ a′ (mod n), then a2 ≡ (a′)2 (mod n), a3 ≡ (a′)3 (mod n), etc.5. If GCD(k,m) = d, then the congruence kx ≡ n (mod m) is solvable if and

    only if d divides n. It then has d solutions.6. If p is a prime, then ap ≡ a (mod p).7. If p is a prime, and p does not divide a, then ap−1 ≡ 1 (mod p).8. If GCD(a,m) = 1, then aφ(m) ≡ 1 (mod m). (See Section 1.8.12 for φ(m).)9. If p is an odd prime and a is not a multiple of p, then Wilson’s theorem states

    (p− 1)! ≡ −(ap

    )a(p−1)/2 (mod p).

    10. If p and q are odd primes, then Gauss’ law of quadratic reciprocity states that(p

    q

    )(q

    p

    )= (−1)(p−1)(q−1)/4. Therefore, if a and b are relatively prime odd

    integers and b ≥ 3, then(ab

    )= (−1)(a−1)(b−1)/4

    (b

    a

    ).

    11. The number −1 is a quadratic residue of primes of the form 4k + 1 and anon-residue of primes of the form 4k + 3. That is

    (−1p

    )= (−1)(p−1)/2 =

    {+1 when p ≡ 1 (mod 4)−1 when p ≡ 3 (mod 4)

    12. The number 2 is a quadratic residue of primes of the form 8k ± 1 and a non-residue of primes of the form 8k ± 3. That is

    (2

    p

    )= (−1)(p2−1)/8 =

    {+1 when p ≡ ±1 (mod 8)−1 when p ≡ ±3 (mod 8)

    1.8.2 CHINESE REMAINDER THEOREM

    Let m1,m2, . . . ,mr be pairwise relatively prime integers. The system ofcongruences

    x ≡ a1 (mod m1)x ≡ a2 (mod m2)

    ...

    x ≡ ar (mod mr)

    (1.8.4)

    has a unique solution modulo M = m1m2 · · ·mr. This unique solution can bewritten as

    x = a1M1y1 + a2M2y2 + · · ·+ arMryr (1.8.5)where Mk =M/mk, and yk is the inverse of Mk (modulomk).

  • “smtf33” — 2017/12/6 — 19:00 — page 30 — #40

    30 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    EXAMPLE For the system of congruences

    x ≡ 1 (mod 3)x ≡ 2 (mod 5)x ≡ 3 (mod 7)

    we haveM = 3·5·7 = 105 withM1 = 35,M2 = 21, andM3 = 15. The equation fory1 is M1y1 = 35y1 ≡ 1 (mod 3) with solution y1 ≡ 2 (mod 3). Likewise, y2 ≡ 1(mod 5) and y3 ≡ 1 (mod 7). This results in x = 1 ·35 ·2+2 ·21 ·1+3 ·15 ·1 ≡ 52(mod 105).

    1.8.3 CONTINUED FRACTIONS

    The symbol [a0, a1, . . . , aN ], with ai > 0, represents the simple continued fraction,

    [a0, a1, . . . , aN ] = a0 +1

    a1 +1

    a2 +1

    a3 +1

    a4 +. . .

    · · ·+ 1aN.

    (1.8.6)

    The nth convergent (with 0 < n < N ) of [a0, a1, . . . , aN ] is defined to be[a0, a1, . . . , an]. If {pn} and {qn} are defined by

    p0 = a0, p1 = a1a0 + 1, pn = anpn−1 + pn−2 (2 ≤ n ≤ N)q0 = 1, q1 = a1, qn = anqn−1 + qn−2 (2 ≤ n ≤ N)

    then [a0, a1, . . . , an] = pn/qn. The continued fraction is convergent if and only ifthe infinite series

    ∑∞i ai is divergent.

    If the positive rational number x can be represented by a simple con-tinued fraction with an odd (even) number of terms, then it is also repre-sentable by one with an even (odd) number of terms. (Specifically, if an =1 then [a0, a1, . . . , an−1, 1] = [a0, a1, . . . , an−1 + 1], and if an ≥ 2, then[a0, a1, . . . , an] = [a0, a1, . . . , an − 1, 1].) Aside from this indeterminacy, the sim-ple continued fraction of x is unique. The error in approximating by a convergent isbounded by ∣∣∣∣x−

    pnqn

    ∣∣∣∣ ≤1

    qnqn+1<

    1

    q2n. (1.8.7)

    The algorithm for finding a continued fraction expansion of a number is to re-move the integer part of the number (this becomes ai), take the reciprocal, and repeat.

  • “smtf33” — 2017/12/6 — 19:00 — page 31 — #41

    1.8. NUMBER THEORY 31

    For example, for the number π:

    β0 = π ≈ 3.14159 a0 = ⌊β0⌋ = 3β1 = 1/(β0 − a0) ≈ 7.062 a1 = ⌊β1⌋ = 7β2 = 1/(β1 − a1) ≈ 15.997 a2 = ⌊β2⌋ = 15β3 = 1/(β2 − a2) ≈ 1.0034 a3 = ⌊β3⌋ = 1β4 = 1/(β3 − a3) ≈ 292.6 a4 = ⌊β4⌋ = 292

    Since π = [3, 7, 15, 1, 292, 1, 1, 1, 2, 1, 3, 1, 14, 2, . . . ] approximations to π may befound from the convergents: 227 ≈ 3.142, 333106 ≈ 3.14150, 355113 ≈ 3.1415929.

    Since e = [2, 1, 2, 1, 1, 4, 1, 1, 6, . . . , 1, 1, 2n, . . . ] approximations to e may befound from the convergents: 83 ≈ 2.6, 114 ≈ 2.75, 197 ≈ 2.714, 8732 ≈ 2.7187, . . ..

    A periodic continued fraction is an infinite continued fraction in which al =al+k for all l ≥ L. The set of partial quotients aL, aL+1, . . . , aL+k−1 is the period.A periodic continued fraction may be written as

    [a0, a1, . . . , aL−1, aL, aL+1, . . . , aL+k−1] . (1.8.8)

    For example,√2 = [1, 2]√3 = [1, 1, 2]√4 = [2]√5 = [2, 4]

    √6 = [2, 2, 4]√7 = [2, 1, 1, 1, 4]√8 = [2, 1, 4]√9 = [3]

    √10 = [3, 6]√11 = [3, 3, 6]√12 = [3, 2, 6]√13 = [3, 1, 1, 1, 1, 6]

    √14 = [3, 1, 2, 1, 6]√15 = [3, 1, 6]√16 = [4]√17 = [4, 8]

    If x = [b, a] then x = 12 (b+√b2 + 4ba ). For example, [1] = [1, 1] = (1+

    √5)/2,

    [2] = [2, 2] = 1 +√2, and [2, 1] = 1 +

    √3.

    Functions can be represented as continued fractions. Using the notation

    b0 +a1

    b1 +a2

    b2 +a3

    b3 +a4

    b4 + . . .

    ≡ b0 +a1b1+

    a2b2+

    a3b3+

    a4b4+

    . . . (1.8.9)

    we have (allowable values of z may be restricted in the following)

    (a) ln(1 + z) = z1+z2+

    z3+

    4z4+

    4z5+

    9z6+ . . .

    (b) ez = 11−z1+

    z2−

    z3+

    z2−

    z5+

    z2− · · · = 1 + z1− z2+ z3− z2+ z5− z2+ z7− . . .

    (c) tan z = z1−z2

    3−z2

    5−z2

    7− . . .

    (d) tanh z = z1+z2

    3+z2

    5+z2

    7+ . . .

  • “smtf33” — 2017/12/6 — 19:00 — page 32 — #42

    32 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.8.4 DIOPHANTINE EQUATIONS

    A diophantine equation is one whose solutions are integers.1. Fermat’s last theorem states that there are no integer solutions to xn+yn = zn,

    when n > 2. This was proved by Andrew Wiles in 1995.2. The similar, but slightly different, equation xn + yn = zn+1 has parametric

    solutions given by x = a (am + bm)u, y = b (am + bm)u, z = (am + bm)v

    where gcd(m,n) = 1 and nv −mu = 1.3. The Hurwitz equation, x21 + x

    22 + · · · + x2n = ax1x2 · · ·xn, has no integer

    solutions for a > n.4. Bachet’s equation, y2 = x3 + k, has no solutions when k is: −144, −105,−78,−69,−42,−34,−33,−31,−24,−14, −5, 7, 11, 23, 34, 45, 58, 70.

    5. Ramanujan’s “square equation,” 2n = 7+ x2, has solutions for n = 3, 4, 5, 7,and 15 corresponding to x = 1, 3, 5, 11, and 181.

    6. For given k and m consider ak1 + ak2 + · · · + akm = bk1 + bk2 + · · · + bkn with

    a1 ≥ a2 ≥ · · · ≥ am, b1 ≥ b2 ≥ · · · ≥ bn, a1 > 1, and m ≤ n. For example:52 = 42 + 32

    123 + 13 = 103 + 93

    1584 + 594 = 1344 + 1334

    4224814 = 4145604 + 2175194 + 958004

    1445 = 1335 + 1105 + 845 + 275

    Given k andm the least value of n for which a solution is known is as follows:

    m = 1 2 3 4 5 6k = 2 2

    3 3 24 3 25 4 36 7 5 37 7 6 5 48 8 7 5 49 10 8 8 6 5

    10 12 12 11 9 7 67. Cannonball problem: If n2 cannonballs can be stacked to form a square pyra-

    mid of height k, what are n and k? The Diophantine equation is∑k

    i=1 i2 =

    16k(k+1)(2k+1) = n

    2 with solutions (k, n) = (1, 1) and (k, n) = (24, 70).8. The Euler equation 2n = 7x2 + y2 has a unique solution, with x and y odd,

    for n ≥ 3:x =

    2n/2+1√7|sinαn| y = 2n/2+1 |cosαn|

    where αn =([n− 2] tan−1

    √7).

    The solutions are (n, x, y) = {(3, 1, 1), (4, 1, 3), (5, 1, 5), (6, 3, 1), . . .}

  • “smtf33” — 2017/12/6 — 19:00 — page 33 — #43

    1.8. NUMBER THEORY 33

    9. Apart from the trivial solutions (with x = y = 0 or x = u), the generalsolution to the equation x3 + y3 = u3 + v3 is given parametrically by

    x = λ[1− (a− 3b)(a2 + 3b2)

    ]y = λ

    [(a+ 3b)(a2 + 3b2)− 1

    ]

    u = λ[(a+ 3b)− (a2 + 3b2)2

    ]v = λ

    [(a2 + 3b2)2 − (a− 3b)

    ]

    where {λ, a, b} are any rational numbers except that λ 6= 0.10. A parametric solution to x4 + y4 = u4 + v4 is given by

    x = a7 + a5b2 − 2a3b4 + 3a2b5 + ab6

    y = a6b − 3a5b2 − 2a4b3 + a2b5 + b7

    u = a7 + a5b2 − 2a3b4 − 3a2b5 + ab6

    v = a6b + 3a5b2 − 2a4b3 + a2b5 + b7

    11. Parametric solutions to the equation (A2+B2)(C2+D2) = E2+F 2 are givenby the Fibonacci identity (a2+b2)(c2+d2) = (ac±bd)2+(bc∓ad)2 = e2+f2.A similar identity is the Euler four-square identity (a21 + a

    22 + a

    23 +

    a24)(b21 + b

    22 + b

    23 + b

    24) = (a1b1 − a2b2 − a3b3 − a4b4)2 + (a1b2 + a2b1 +

    a3b4−a4b3)2+(a1b3−a2b4+a3b1+a4b2)2+(a1b4+a2b3−a3b2−a4b1)2.12. The only integer solutions to the equation xy = yx are (2, 4) and x = y. Non-

    integral solutions are given by{x =

    (1 + 1u

    )u, y =

    (1 + 1u

    )u+1}. Setting

    u = 2, 3, . . . yields the rational solutions(94 ,

    278

    ),(6427 ,

    25681

    ), . . .

    1.8.4.1 Pythagorean triplesIf the positive integersA, B, andC satisfyA2+B2 = C2, then the triplet (A,B,C)is a Pythagorean triple. A right triangle can be constructed with sides of length Aand B and a hypotenuse of C. There are infinitely many Pythagorean triples.

    A general solution to A2 +B2 = C2, with GCD(A,B) = 1 and A even, is

    A = 2xy, B = x2 − y2, C = x2 + y2, (1.8.10)where x and y are relatively prime integers of opposite parity (i.e., one is even andthe other is odd) with x > y > 0. The table below left shows some Pythagoreantriples with the associated (x, y) values.

    x y A = 2xy B = x2 − y2 C = x2 + y2

    2 1 4 3 54 1 8 15 176 1 12 35 378 1 16 63 65

    10 1 20 99 1013 2 12 5 135 2 20 21 29

    n p q A B C

    6 1 18 7 24 256 2 9 8 15 176 3 6 9 12 15

    A different general solution is obtained by factoring even squares as n2 = 2pq. HereA = n+p,B = n+q, andC = n+p+q. The table above right shows the (p, q) and(A,B,C) values obtained from the factorizations 36 = 2 ·1 ·18 = 2 ·2 ·9 = 2 ·3 ·6.

  • “smtf33” — 2017/12/6 — 19:00 — page 34 — #44

    34 CHAPTER 1. NUMBERS AND ELEMENTARY MATHEMATICS

    1.8.4.2 Pell’s equationPell’s equation is x2 − dy2 = 1. The solutions, integral values of (x, y), arise fromcontinued fraction convergents of

    √d. If (x, y) is the least positive solution to Pell’s

    equation (with d square-free), then every positive solution (xk, yk) is given by

    xk + yk√d = (x+ y

    √d)k (1.8.11)

    The following tables contain the least positive solutions to Pell’s equation with dsquare-free and d < 100.

    d x y

    2 3 23 2 15 9 46 5 27 8 3

    10 19 611 10 313 649 18014 15 415 4 117 33 819 170 3921 55 1222 197 4223 24 526 51 1029 9,801 1,82030 11 231 1,520 27333 23 4

    d x y

    35 6 137 73 1238 37 639 25 441 2,049 32042 13 243 3,482 53146 24,335 3,58847 48 751 50 753 66,249 9,10055 89 1257 151 2058 19,603 2,57459 530 6961 1,