Book 7, the last book on the Ray’s Arithmetic shelf, is now playable: Ray’s New Higher Algebra (Joseph Ray, Grade 11). It runs in the same app as Books 1-6 at https://abcbooks.fyi/math/ , with the same “Reed” voice. Each lesson reads the book’s articles aloud, asks a short quiz, then gives the book’s own problems on the algebra pad from Book 6, which learned many new kinds of answers for this book. This post covers what is new for Book 7 and how to rebuild it. The app, the server and the voice recorder are explained in the Book One post, the Study and Quiz steps in the Book 5 post, and the algebra pad in the Book 6 post. Every block has a Copy button.
What is in Book 7
The book numbers its articles 1 to 444, and its table of contents lists articles, not pages. Each section of the contents became a lesson (long ones split in two): 88 lessons, 685 articles to study, 219 quiz questions and 1,663 problems with 2,286 answers.
- Lessons 1-21, Fundamental rules, theorems, factoring, fractions (book pages 11-77).
- Lessons 22-34, Simple equations and their supplement: about 100 word problems, two and three unknown quantities, negative solutions, the couriers problem, impossible problems.
- Lessons 35-45, Powers, roots, radicals, inequalities: square and cube roots of numbers and expressions, radicals, imaginary quantities, fractional exponents, radical equations, inequalities.
- Lessons 46-54, Quadratic equations: pure and affected, completing the square, the problem of the lights, trinomial equations, binomial surds, simultaneous quadratics.
- Lessons 55-63, Ratio, proportion, progressions, permutations, binomial theorem.
- Lessons 64-70, Series: indeterminate coefficients, partial fractions, the binomial theorem for any exponent, differences, piling cannon balls, interpolation, recurring and reversed series.
- Lessons 71-76, Continued fractions, logarithms, exponential equations, interest and annuities.
- Lessons 77-88, Theory of equations: roots and coefficients, Descartes’ rule, transforming equations, synthetic division, equal roots, Sturm’s theorem, rational roots, Horner’s and Newton’s methods, Cardan’s rule, recurring and binomial equations.
New on the algebra pad
The pad keeps Book 6’s rules (same value at random numbers, and written as simply as the book’s answer). Book 7 adds:
- Exponents that are fractions or letters: a^(2/3), a^m, x^(m+n). Type xⁿ, then the exponent in brackets. They show as raised numbers and letters.
- Cube and fourth roots: ∛ and ∜ keys appear when the answer needs them. Higher roots are typed as powers, 27^(1/6), the form the book itself teaches.
- The square root of minus 1: the book writes √−1, not i, so the pad does too (2√−3, a+b√−1). The checker works in complex numbers, so √−a·√−b = −√ab, the book’s way.
- Plus or minus: a ± key; 3±√5 stands for both roots.
- Roots in any order: a cubic’s three roots, or a quartic’s four, can be typed in any order.
- Solution sets: “x = 3, y = 2; or x = 2, y = 3”: any set can come first, and each set stays together.
- Inequalities and equations as answers: x > 5, or a transformed equation like x³ − 6x² + 11x − 6 = 0 (any equivalent form counts). The > < = keys appear when needed.
- Lists: the terms of a series or the parts of a continued fraction are typed one at a time.
- A × key and a . key appear on the questions whose answer needs them (like 6×72^(1/6), or a logarithm such as −0.154902).
How the book was typed up
Two free scans were used:
- raysarithmetic.wordpress.com, “Ray’s New Higher Algebra (11)”, 406 pages, 14.1 MB. Clean, book page = PDF page, but its printed answers are blanked out, like the Book 6 scan.
- archive.org cu31924031285806 (a Cornell copy), 420 pages, 9.4 MB. Book page = PDF page + 6. Its answers are printed, and it has a text layer: the words are readable, the formulas are not.
So the words came from the Cornell text layer, every formula was read off the page pictures, and every answer was checked against the Cornell scan’s printed one. The build script checks each answer against its question too, with the Book 6 checks plus new ones: {list: ...}, log, ln, n!, C(n,r) and P(n,r) in number checks, and a check for cube and higher roots.
Things found on the way:
- The two scans are not the same printing everywhere. On page 289 they differ; the Cornell one was followed. The book also has a misprint there: the greatest term of (2+5/3)⁶ is 20000/27, not 20000/81.
- Extraneous roots. Some printed answers only fit the squared equation. Only roots that really solve the question are asked for.
- One half a. The checker reads
1/2aas 1/(2a), like the pad does, so one half a is written(1/2)a. - Logarithms. Decimal answers were computed and compared with the book’s 6-place tables; where the book’s rounding gives a slightly different figure, both are accepted.
- Testing the pad. A script (
playthrough.js) types every one of the 2,286 answers key by key on the on-screen buttons, about 48 minutes. It found 5 answers needing a key the pad didn’t show (× and .), now fixed. - The offline cache serves the old app. After changing
app.jsoralg.js, bumprays-shell-v20insw.js.
The voice
The same recorder as Books 1-6: 5,075 lines, 4,413 of them new at each speed. New spoken forms: “A to the two-thirds power”, “the cube root of”, “plus or minus”, “the square root of minus 1”, “is greater than”.
Files
Set up the Book One post first, and download both PDFs (above) into C:\RaysArithmetic\source\pdf\ as rays-higher-algebra-11.pdf and rays-higher-algebra-11-cornell.pdf. Book 7 adds or replaces the files below. Each block writes one file into /root/rays-rebuild/ when pasted into a Proxmox host shell (Proxmox web UI, pve, Shell). Then copy that folder to the PC and put:
algebra2.txtinC:\RaysArithmetic\source\make-book.ps1,make-audio.ps1,alg.cs,selftest-alg.ps1,playthrough.jsinC:\RaysArithmetic\tools\alg.js,app.js,index.html,sw.jsinC:\RaysArithmetic\public\(they replace the earlier versions and run all seven books)
Proxmox host shell:
mkdir -p /root/rays-rebuild
algebra2.txt: the whole of Book 7: articles, quizzes and problems with their checks.
cat > /root/rays-rebuild/algebra2.txt <<'EOF'
@book: algebra2 | Ray's New Higher Algebra | Higher Algebra - Book Seven | #3b4a8f
# Ray's New Higher Algebra (Joseph Ray, 1866), typed from source/pdf/rays-higher-algebra-11.pdf (book page N = PDF
# page N; answers blanked) with the answers read off source/pdf/rays-higher-algebra-11-cornell.pdf (book page N = PDF
# page N + 6; answers printed). The OCR (rays-higher-algebra-11-cornell.ocr.txt) gives the prose; every formula was
# read off the page images. Plan and answer types still to come: algebra2-plan.md.
# Format = Book Six's (source/algebra1.txt): art:, mc:, tf:, q:, sol:, backtick math, {$ expr @ same} build-checked
# answers, {N @= expr} numbers, chk:. Book 7 adds a^(2/3), a^m, a^(m+n), ∛x, ∜x, √-1, 3±√5 (one answer for two roots),
# {list: 1, 3, 5/2} (typed one item at a time), and "x = {A} or {B} or {C}" roots in any order.
== 1 | Fundamental Rules | Definitions and notation
art: 1 | Mathematics | Mathematics is the science of the exact relations of Quantity as to Magnitude or Form.
art: 2 | Quantity | Quantity, as the subject of mathematical investigations, is any thing capable of being measured, or about which the question How much? may be asked. It may be 1. Geometric, involving Form; 2. Number.
art: 3 | Number | Number is quantity considered as composed of equal parts of the same kind, each called the unit; and the magnitude of the quantity is indicated by its ratio to the unit.
art: 4 | | Numbers are represented by conventional symbols. When the symbols used are general, as distinguished from the arithmetical symbols, viz., the Arabic numerals, the process of investigation is called Algebraic.
art: 5 | Algebra | Algebra is the method of investigating the relations of numbers by means of general symbols. Remark: the word "quantity", whenever used in algebra, is synonymous with "number".
art: 6 | | The algebraic symbols are of two kinds: 1. Symbols of numbers; 2. Symbols of relation. Numbers are usually represented by letters; as, `a`, `b`, `x`, `y`; sometimes, of course, when known, by the Arabic numerals.
art: 7 | Signs | The symbols of relation, usually called Signs, are the representatives of certain phrases, and are used to express operations with precision and brevity. The principal algebraic signs are =, +, −, ×, ÷, >, √.
art: 8 | The Sign of Equality | The sign =, is read equal to. It denotes that the quantities between which it is placed are equal. Thus, `x=b`, denotes that the quantity represented by `x` equals `b`.
art: 9 | The Sign of Addition | The sign +, is read plus. It denotes that the quantity to which it is prefixed is to be added. Thus, `a+b` denotes that `b` is to be added to `a`.
art: 10 | The Sign of Subtraction | The sign −, is read minus. It denotes that the quantity to which it is prefixed is to be subtracted. Thus, `a-b` denotes that `b` is to be subtracted from `a`.
art: 11 | | The signs + and − are called the signs. The former is called the positive, the latter the negative sign; they are said to be contrary, or opposite.
art: 12 | | Every quantity is supposed to have either the positive or negative sign. When a quantity has no sign prefixed to it, + is understood. Thus, `a=+a`. Quantities having the positive sign are called positive; those having the negative sign, negative.
art: 13 | | Quantities having the same sign are said to have like signs; those having different signs, unlike signs. Thus, `+a` and `+b`, or `-a` and `-b`, have like signs; while `+c` and `-d` have unlike signs.
art: 14 | The Sign of Multiplication | The sign ×, is read into, or multiplied by. It denotes that the quantities between which it is placed are to be multiplied together. The product of two or more letters is also expressed by a dot or period, or by writing the letters in close succession. The last method is generally to be preferred. Thus, the continued product of the numbers designated by `a`, `b`, and `c`, is denoted by `a*b*c`, or a.b.c, or `abc`.
art: 15 | Factors | Factors are quantities that are to be multiplied together. Thus, in the product `ab`, there are two factors, `a` and `b`; in the product `3*5*7`, there are three factors, 3, 5, and 7.
art: 16 | The Sign of Division | The sign ÷, is read divided by. It denotes that the quantity preceding it is to be divided by that following it. Division is also expressed by placing the dividend as the numerator, and the divisor as the denominator of a fraction. Thus, `a÷b`, or `a/b`, signifies that `a` is to be divided by `b`.
art: 17 | The Sign of Inequality | The sign > denotes that one of the two quantities between which it is placed is greater than the other. The opening of the sign is toward the greater quantity. Thus, `a>b` denotes that `a` is greater than `b`; it is read `a` greater than `b`. Also, `c<d` denotes that `c` is less than `d`, and is read, `c` less than `d`.
art: 18 | A Coefficient | A Coefficient is a number or letter prefixed to a quantity, to show how many times it is taken. Thus, if `a` is to be taken 4 times, instead of writing `a+a+a+a`, write `4a`; also, `az+az+az=3az`. The coefficient is called numeral or literal, according as it is a number or a letter. Thus, in the quantities `5x` and `mx`, 5 is a numeral and `m` a literal coefficient. In `3az`, 3 may be considered as the coefficient of `az`, or `3a` as the coefficient of `z`. When no numeral coefficient is expressed, 1 is understood. Thus, `a` is the same as `1a`, and `ax` the same as `1ax`.
art: 19 | A Power | A Power of a quantity is the product arising from multiplying the quantity by itself one or more times. When the quantity is taken twice as a factor, the product is called the second power; when three times, the third power; and so on. Thus, `2*2=4`, is the second power of 2; `2*2*2=8`, is the third power of 2; `a*a=aa`, is the second power of `a`. The second power is often termed the square, and the third power, the cube.
art: 19 | An Exponent | An Exponent is a small figure or letter placed on the right, and a little above a quantity, to express its power. Thus, `aa=a^2`, `aaa=a^3`, etc. `a^m` indicates that `a` is taken as a factor as many times as there are units in `m`. When no exponent is expressed, 1 is understood. Thus, `a` is the same as `a^1`, each signifying the first power of `a`.
art: 20 | A Root | A Root of a quantity is a factor, which, multiplied by itself a certain number of times, will produce the given quantity. The root is called the square or second root, the cube or third root, the fourth root, etc., according to the number of times it must be taken as a factor to produce the given quantity. Thus, 2 is the second or square root of 4, since `2*2=4`; `a` is the fourth root of `a^4`, since `a*a*a*a=a^4`.
art: 21 | The Radical Sign | The Radical Sign, √, when prefixed to a quantity, denotes that its root is to be extracted. An Index is a figure or letter placed over a radical sign to denote what root is to be taken. Thus, the square root of 9 is 3; the cube root of 8 is 2; the fourth root of `a` is written with the index 4. When the radical sign has no index over it, 2 is understood; thus, `√a` means the square root of `a`.
art: 22 | An Algebraic Quantity | An Algebraic Quantity, or an Algebraic Expression, is any quantity written in algebraic language, that is, by means of symbols. Thus, `5a` is the algebraic expression of 5 times the number `a`; `3b+4c`, for 3 times the number `b` increased by 4 times the number `c`; `3a^2-7ab`, for 3 times the square of `a`, diminished by 7 times the product of the number `a` by the number `b`.
art: 23 | A Monomial | A Monomial is a quantity not united to any other by the sign of addition or subtraction; as, `4a`, `a^2bc`, `4xy`, etc. A monomial is often called a simple quantity, or term.
art: 24 | A Polynomial | A Polynomial, or Compound Quantity, is an algebraic expression composed of two or more terms; as, `a+b`, `c-x+y`, etc.
art: 25 | A Binomial | A Binomial is a quantity having two terms; as, `a+b`, `x^2+y`, etc. A Residual Quantity is a binomial, the second term of which is negative; as, `a-b`.
art: 26 | A Trinomial | A Trinomial is a quantity consisting of three terms; as, `a+b-c`.
art: 27 | The Numerical Value | The Numerical Value of an algebraic expression is the number obtained by giving a particular value to each letter, and then performing the operations indicated. Thus, in the algebraic expression `4a-3c`, if `a=5` and `c=6`, the numerical value is `4*5-3*6=20-18=2`.
art: 28 | | The value of a polynomial is not affected by changing the order of the terms, provided each term retains its sign. Thus, `2ab+c-b^2` is evidently the same as `-b^2+c+2ab`.
art: 29 | Degree | The Degree of any term is equal to the number of literal factors which it contains. Thus, `5a` is of the first degree; it contains one literal factor. `ax` is of the second degree; it contains two literal factors. `3a^3b^2c=3aaabbc` is of the sixth degree.
art: 30 | Homogeneous | A polynomial is said to be homogeneous when each of its terms is of the same degree. Thus, `a-b+3c` is homogeneous, each term being of the first degree; `x^3-2xy^2` is homogeneous, each term being of the third degree; `x^2-2xy^2` is not homogeneous.
art: 31 | Arrangement | An algebraic quantity is said to be arranged according to the dimensions of any letter it contains, when the exponents of that letter occur in the order of their magnitudes, either increasing or decreasing. Thus, `ax-a^2x^2+a^3x^3` is arranged according to the ascending powers of `a`; and `bx^3-b^2x^2+b^3x` is arranged according to the descending powers of `x`.
art: 32 | A Parenthesis | A Parenthesis, ( ), is used to show that all the terms of a polynomial which it incloses are to be considered together, as a single term. Thus, `10-(a-b)` means that `a-b` is to be subtracted from 10; `5(a+b-c)` means that `a+b-c` is to be multiplied by 5; `5a+(b-c)` means that `b-c` is to be added to `5a`. When the parenthesis is used, the sign of multiplication is generally omitted. Thus, `(a-b)*(a+b)` is written `(a-b)(a+b)`. A Vinculum, a line drawn over the terms, is sometimes used instead of a parenthesis. Sometimes the vinculum is placed vertically; it is then called a bar.
art: 33 | Similar Quantities | Similar, or Like Quantities, are such as contain the same letter or letters with the same exponents. Thus, `3ab` and `-2ab`, `5a^2b` and `-3a^2b` are similar. Unlike Quantities are such as contain different letters or different powers of the same letter. Thus, `5a` and `3b`, `3ab^2` and `3a^2b`, are unlike or dissimilar. Remark: an exception must be made in those cases where letters are taken to represent coefficients. Thus, `ax^2` and `bx^2` are like quantities, when `a` and `b` are taken as coefficients of `x^2`.
art: 34 | The Reciprocal | The Reciprocal of a quantity is unity divided by that quantity. Thus, the reciprocal of `a` is `1/a`; of 3, is `1/3`; of `2/3`, is `1÷(2/3)=3/2`. Hence, the reciprocal of a fraction is the fraction inverted.
art: 35 | Accents | The same letter, accented, is often used to denote quantities which occupy similar positions in different equations or investigations. Thus, a, a′, a″, a‴, read, a, a prime, a second, a third, and so on.
mc: Algebra is the method of investigating the relations of numbers by means of... | *general symbols | the Arabic numerals only | figures and lines
mc: In algebra, the word "quantity" means the same as... | *number | magnitude | unit
mc: The symbols of relation are usually called... | *signs | letters | coefficients
mc: When a quantity has no sign before it, the sign understood is... | *+ | − | ×
mc: `+c` and `-d` have... | *unlike signs | like signs | no signs
mc: Which way of writing the product of `a`, `b` and `c` is generally preferred? | *`abc` | `a*b*c` | a.b.c
mc: In `mx`, the letter `m` is called a... | *literal coefficient | numeral coefficient | exponent
mc: When no coefficient is written, the coefficient understood is... | *1 | 0 | 2
mc: In `a^m`, the `m` is called the... | *exponent | coefficient | index
mc: The figure placed over a radical sign to show what root is taken is called the... | *index | exponent | coefficient
mc: When the radical sign has no index over it, the root understood is the... | *square root | cube root | first root
mc: A binomial whose second term is negative, as `a-b`, is called a... | *residual quantity | trinomial | monomial
mc: What is the degree of the term `3a^3b^2c`? | *sixth | third | fifth
mc: Which polynomial is homogeneous? | *`x^3-2xy^2` | `x^2-2xy^2` | `a^2+b`
mc: `bx^3-b^2x^2+b^3x` is arranged according to the... | *descending powers of `x` | ascending powers of `x` | descending powers of `b`
mc: The reciprocal of `2/3` is... | *`3/2` | `-2/3` | `2/3`
mc: How is a′ read? | *a prime | a second | a accent
tf: `3ab^2` and `3a^2b` are similar quantities. {F}
tf: Changing the order of the terms of a polynomial, each keeping its sign, does not change its value. {T}
tf: The reciprocal of a fraction is the fraction inverted. {T}
q: In `4a-3c`, if `a=5` and `c=6`, what is the numerical value? {2 @= 4*5-3*6}
q: What is the reciprocal of `a`? {$ 1/a}
q: How many factors are there in the product `3*5*7`? {3}
== 2 | Fundamental Rules | Exercises on the definitions
art: 36 | Other signs | The following signs are also used, for the sake of brevity: ∞, a quantity indefinitely great, or infinity; ∴ signifies therefore, or consequently; ∵ signifies since, or because; ∼ is used to represent the difference between two quantities, as `c∼d`, when it is not known which is the greater.
art: 36 | Exercises | First, copy each example on the slate or blackboard, and then read it, that is, express it in common language. Second, find the numerical value in each, supposing `a=2`, `b=3`, `c=4`, `x=5`, `y=6`.
mc: The sign ∴ signifies... | *therefore | because | infinity
mc: The sign ∵ signifies... | *since, or because | therefore | difference
mc: The sign ∞ stands for... | *a quantity indefinitely great | nothing | the difference of two quantities
q: When `a=2`, `b=3`, `c=4`, `x=5`, `y=6`: find `7b+x-y`. {20 @= 7*3+5-6}
q: Find `a^2by-3x^2`. {$ -3 @ 2^2*3*6-3*5^2}
q: Find `c+a*c-a`. {10 @= 4+2*4-2}
q: Find `(c+a)(c-a)`. {12 @= (4+2)*(4-2)}
q: Find `(a^2+b+c-y)/2`. {2 1/2 @= (2^2+3+4-6)/2}
q: Find `(cx-ay)/(x-b)`. {4 @= (4*5-2*6)/(5-3)}
q: Find `bc/y+ay/c`. {5 @= 3*4/6+2*6/4}
q: Find `ab(c-a)/(y-c) - √(aby)`. {0 @= 2*3*(4-2)/(6-4)-√(2*3*6)}
q: Find the difference between `abx` and `a+b+x`, when `a=4`, `b=1/2`, `x=3`. {1 1/2 @= (4+1/2+3)-4*(1/2)*3}
q: And when `a=5`, `b=7`, `x=12`? {396 @= 5*7*12-(5+7+12)}
q: Required the values of `a^2+2ab+b^2`, and `a^2-2ab+b^2`, when `a=7` and `b=4`. {121 @= 7^2+2*7*4+4^2} and {9 @= 7^2-2*7*4+4^2}
q: What is the value of `n(n-1)(n-2)(n-3)`, when `n=4`, and when `n=10`? {24 @= 4*3*2*1} and {5040 @= 10*9*8*7}
q: Find the difference between `6abc-2ab`, and `6abc÷2ab`, when `a`, `b`, `c` are 3, 5, and 6 respectively. {492 @= (6*3*5*6-2*3*5)-(6*3*5*6)/(2*3*5)}
q: Find the value of `(a^2-b^2)/(a^3+b^3)`, when `a=5` and `b=3`. {2/19 @= (5^2-3^2)/(5^3+3^3)}
art: 36 | Verify | Verify the following, by giving to each letter any value whatever: 14. `a(m+n)(m-n)=am^2-an^2`. 15. `(x^3-y^3)/(x-y)=x^2+xy+y^2`.
tf: `a(m+n)(m-n)=am^2-an^2`, whatever values the letters have. {T}
tf: `(x^3-y^3)/(x-y)=x^2+xy+y^2`, whatever values the letters have (except `x=y`). {T}
art: 36 | To be expressed in algebraic symbols | Write each of the following in algebraic symbols.
q: Five times `a`, plus the second power of `b`. {$ 5a+b^2}
q: `x`, plus `y` divided by `3z`. {$ x+y/(3z)}
q: `x` plus `y`, divided by `3z`. {$ (x+y)/(3z)}
q: 3 into `x` minus `n` times `y`, divided by `m` minus `n`. {$ (3x-ny)/(m-n)}
q: `a` third power minus `x` third power, divided by `a` second power minus `x` second power. {$ (a^3-x^3)/(a^2-x^2)}
q: The square root of `m` minus the square root of `n`. {$ √m-√n}
q: The square root of `m` minus `n`. {$ √(m-n)}
== 3 | Fundamental Rules | Addition
art: 37 | Addition | Addition, in Algebra, is the process of finding the simplest expression for the sum of two or more algebraic quantities. There are three cases of algebraic addition: 1st. When the quantities are similar, and have like signs. 2d. When the quantities are similar, but the signs unlike. 3d. When the quantities are dissimilar, or part similar and part dissimilar.
art: 38 | First Case | Let it be required to find the sum of `3x^2y`, `5x^2y`, and `7x^2y`. Here, `x^2y` is taken, in the first term, 3 times; in the second, 5 times; and in the third, 7 times; hence, in all, it is taken 15 times. Since adding the quantities can not change their character, and since each term is positive, their sum is `+15x^2y`. In the same way the sum of `-3x^2y`, `-5x^2y`, and `-7x^2y` is `-15x^2y`.
art: 38 | Rule | Add the coefficients, and prefix the sum, with the common sign, to the literal part.
art: 39 | Second Case | Let it be required to find the sum of `+9a`, `-5a`, `+4a`, and `-2a`. Here, `+9a+4a` is `+13a`; and `-5a-2a` is `-7a`. Now since the sum of two equal quantities, of which one is positive and the other negative, is evidently 0, `-7a` will cancel `+7a` in the quantity `+13a`, and leave `+6a` for the aggregate, or result of the four quantities. In like manner, the sum of `-9a`, `+5a`, `-4a`, and `+2a` is `-6a`.
art: 39 | Rule | To add similar quantities having different signs: 1. Add the positive and negative coefficients separately. 2. Subtract the less sum from the greater, and give to the difference the sign of the greater. 3. Prefix this difference to the literal part.
art: 40 | Third Case | Let it be required to find the sum of `5a^2-3b+c`, `+b-a^2`, and `5b+3a^2`. In writing the quantities, we place, for convenience, those which are similar under each other. The sum in the first column is `+7a^2`, and in the second, `+3b`; there being no term similar to `c`, it is annexed, with its proper sign: `7a^2+3b+c`.
art: 41 | General Rule for Addition | 1. Write the quantities to be added, placing those that are similar under each other. 2. Add the similar quantities by the rules already given. 3. Annex the other quantities with their proper signs. Remark: in algebraic Addition, Subtraction, and Multiplication, it is best to begin the operation at the left hand.
mc: The sum of `3x^2y`, `5x^2y`, and `7x^2y` is... | *`15x^2y` | `15x^6y^3` | `105x^2y`
mc: The sum of two equal quantities, one positive and the other negative, is... | *0 | twice either | the positive one
mc: When adding similar quantities with different signs, the difference takes the sign of the... | *greater sum | less sum | first term
mc: A term with no similar term among the others is... | *annexed with its proper sign | dropped | added to the first column
mc: In algebraic addition it is best to begin the operation at the... | *left hand | right hand | middle
q: Find the sum of `+9a`, `-5a`, `+4a`, and `-2a`. {$ 6a @ 9a-5a+4a-2a}
q: Find the sum of `-9a`, `+5a`, `-4a`, and `+2a`. {$ -6a @ -9a+5a-4a+2a}
q: Find the sum of `5a^2-3b+c`, `+b-a^2`, and `5b+3a^2`. {$ 7a^2+3b+c @ (5a^2-3b+c)+(b-a^2)+(5b+3a^2)}
q: Find the sum of `4ax+3by`, `5ax+8by`, `8ax+6by`, and `20ax+by`. {$ 37ax+18by @ (4ax+3by)+(5ax+8by)+(8ax+6by)+(20ax+by)}
q: Of `10cz-2ax^2`, `15cz-3ax^2`, `24cz-9ax^2`, and `3cz-8ax^2`. {$ 52cz-22ax^2 @ (10cz-2ax^2)+(15cz-3ax^2)+(24cz-9ax^2)+(3cz-8ax^2)}
q: Of `3x^2y^2-10y^4`, `-x^2y^2+5y^4`, `8x^2y^2-6y^4`, and `4x^2y^2+2y^4`. {$ 14x^2y^2-9y^4 @ (3x^2y^2-10y^4)+(-x^2y^2+5y^4)+(8x^2y^2-6y^4)+(4x^2y^2+2y^4)}
q: Of `a+b+c+d`, `a+b+c-d`, `a+b-c+d`, `a-b+c+d`, and `-a+b+c+d`. {$ 3a+3b+3c+3d @ (a+b+c+d)+(a+b+c-d)+(a+b-c+d)+(a-b+c+d)+(-a+b+c+d)}
q: Of `3(x^2-y^2)`, `8(x^2-y^2)`, and `-5(x^2-y^2)`. {$ 6(x^2-y^2) @ 3(x^2-y^2)+8(x^2-y^2)-5(x^2-y^2)}
q: Of `10a^2b-12a^3bc-15b^2c^4+10`, `-4a^2b+8a^3bc-10b^2c^4-4`, `-3a^2b-3a^3bc+20b^2c^4-3`, and `2a^2b+12a^3bc+5b^2c^4+2`. {$ 5a^2b+5a^3bc+5 @ (10a^2b-12a^3bc-15b^2c^4+10)+(-4a^2b+8a^3bc-10b^2c^4-4)+(-3a^2b-3a^3bc+20b^2c^4-3)+(2a^2b+12a^3bc+5b^2c^4+2)}
q: Of `a^m-b^n+3x^p`, `2a^m-3b^n-x^p`, and `a^m+4b^n-x^q`. {$ 4a^m+2x^p-x^q @ (a^m-b^n+3x^p)+(2a^m-3b^n-x^p)+(a^m+4b^n-x^q)}
== 4 | Fundamental Rules | Subtraction; the bracket
art: 42 | Subtraction | Subtraction, in Algebra, is the process of finding the difference between two algebraic quantities. The quantity to be subtracted is called the subtrahend; that from which the subtraction is to be made, the minuend; the quantity left, the difference or remainder. The explanation may be divided into two cases: 1st. Where all the terms are positive. 2d. Where the terms are either partly or wholly negative.
art: 43 | First Case | Let it be required to subtract `4a` from `7a`. It is evident that 7 times any quantity, less 4 times that quantity, is equal to 3 times the quantity; therefore, `7a` less `4a` is equal to `3a`. If it be required to subtract `b` from `a`, we can only indicate the operation, by placing the sign minus before the quantity to be subtracted: `a-b`.
art: 44 | Second Case | Let it be required to subtract `b-c` from `a`. If we subtract `b` from `a`, the result, `a-b`, is obviously too little, for the quantity `b` ought to be diminished by `c` before it is taken from `a`. We have, in fact, subtracted a quantity too great by `c`, and to obtain a true result, the difference, `a-b`, must be increased by `c`; this gives, for the true remainder, `a-b+c`. To illustrate by figures, let `a=9`, `b=5`, and `c=3`: from 9 take `5-3`; the remainder is `9-5+3=7`. The same result would have been obtained by changing the signs of the quantity to be subtracted, and then adding it.
art: 45 | Rule for Subtraction | 1. Write the quantities, placing similar terms under each other. 2. Conceive the signs of all the terms of the subtrahend to be changed, from + to −, or from − to +, and then proceed by the rule for algebraic addition. Remark: 1. Beginners should solve a few examples by actually changing the signs of the subtrahend. 2. Proof: add the remainder and the subtrahend, as in arithmetic.
art: 45 | Examples | (1) From `8a^2b-3cx-z^2` take `3a^2b+4cx-3z^2`: the same, with the signs of the subtrahend changed, is `8a^2b-3cx-z^2` and `-3a^2b-4cx+3z^2`; remainder `5a^2b-7cx+2z^2`. (2) From `5a^3-3mz+5y^4` take `-2a^3+3mz+6y^4`: remainder `7a^3-6mz-y^4`. (3) From `ax^2-3cy^2-z^2` take `bx^2-3cy^2+y^3`: remainder `(a-b)x^2-y^3-z^2`.
mc: The quantity to be subtracted is called the... | *subtrahend | minuend | remainder
mc: From `a` take `b-c`. Taking `b` alone subtracts too much by... | *`c` | `b` | `a`
mc: To prove a subtraction, add the remainder and the... | *subtrahend | minuend | dividend
q: From `7a` take `4a`. {$ 3a @ 7a-4a}
q: From `8a^2b-3cx-z^2` take `3a^2b+4cx-3z^2`. {$ 5a^2b-7cx+2z^2 @ (8a^2b-3cx-z^2)-(3a^2b+4cx-3z^2)}
q: From `5a^3-3mz+5y^4` take `-2a^3+3mz+6y^4`. {$ 7a^3-6mz-y^4 @ (5a^3-3mz+5y^4)-(-2a^3+3mz+6y^4)}
q: From `4a-2b+3c` take `3a+4b-c`. {$ a-6b+4c @ (4a-2b+3c)-(3a+4b-c)}
q: From `9x^2-4y+9` take `7x^2+5y-14`. {$ 2x^2-9y+23 @ (9x^2-4y+9)-(7x^2+5y-14)}
q: From `23xy^2-7y+11x^2` take `11xy^2-5y-9x^2`. {$ 12xy^2-2y+20x^2 @ (23xy^2-7y+11x^2)-(11xy^2-5y-9x^2)}
q: From `12x+18` take `12x-18+y`. {$ 36-y @ (12x+18)-(12x-18+y)}
q: From `x^2-y^3` take `-4-y^3+4x^2`. {$ 4-3x^2 @ (x^2-y^3)-(-4-y^3+4x^2)}
q: From `4ax^3+bx+c` take `3x^3-2x+5`. Collect the powers of `x`. {$ (4a-3)x^3+(2+b)x+c-5 @ (4ax^3+bx+c)-(3x^3-2x+5)}
q: From `-17x^3+9ax^2-7a^2x+15a^3` take `-19x^3+9ax^2-9a^2x+17a^3`. {$ 2x^3+2a^2x-2a^3 @ (-17x^3+9ax^2-7a^2x+15a^3)-(-19x^3+9ax^2-9a^2x+17a^3)}
q: From `x^3+3x^2+3x+1` take `x^3-3x^2+3x-1`. {$ 6x^2+2 @ (x^3+3x^2+3x+1)-(x^3-3x^2+3x-1)}
q: From `9a^mx^2-13+20ab^3x-4b^mcx^2` take `3b^mcx^2+9a^mx^2-6+3ab^3x`. {$ 17ab^3x-7b^mcx^2-7 @ (9a^mx^2-13+20ab^3x-4b^mcx^2)-(3b^mcx^2+9a^mx^2-6+3ab^3x)}
q: From `4a^m+2x^p-x^q` take `a^m-b^n+3x^p` and `2a^m-3b^n-x^p`. {$ a^m+4b^n-x^q @ (4a^m+2x^p-x^q)-(a^m-b^n+3x^p)-(2a^m-3b^n-x^p)}
art: 46 | The Bracket, or Vinculum | As the bracket, or vinculum, is frequently employed in relation to Addition and Subtraction, the rules which govern its use should be well understood. 1st. Where the sign plus precedes a parenthesis, or vinculum, it may be omitted without affecting the expression; and, conversely, any number of terms may be inclosed within a parenthesis preceded by the sign plus, without affecting the value of the expression. Thus, `a+(b-c)=a+b-c`; `6+(5-3)=6+5-3`.
art: 46 | | 2d. Where the sign minus precedes a vinculum, it may be omitted if the signs of all the terms within it be changed; for the minus indicates subtraction, which is effected by changing the signs of all the terms of the quantity to be subtracted. Thus, `a-(b-c)=a-b+c`; `a-(x-y+z)=a-x+y-z`. Sometimes several brackets are employed in the same expression, all of which may be removed, beginning with the innermost.
art: 46 | | 3d. Any quantity may be inclosed in a parenthesis preceded by the sign minus, provided the signs of all the inclosed terms be changed. Thus, `a-b+c=a-(b-c)=c-(b-a)`. This principle often enables us to express the same quantity under several different forms. Thus, `a-b+c+d=a-(b-c-d)=a-[b-(c+d)]`.
mc: When the sign minus precedes a parenthesis, the parenthesis may be removed if... | *the signs of all the terms within it are changed | the first term's sign is changed | nothing is changed
mc: `a-(x-y+z)` is equal to... | *`a-x+y-z` | `a-x-y+z` | `a+x-y+z`
mc: `a-b+c` may also be written... | *`a-(b-c)` | `a-(b+c)` | `-(a-b+c)`
art: 46 | Simplify | Simplify, as much as possible, the following expressions.
q: Simplify `(1-2x+3x^2)+(3+2x-x^2)`. {$ 4+2x^2 @ (1-2x+3x^2)+(3+2x-x^2)}
q: Simplify `(a-b-c)+(b+c-d)+(d-e+f)+(e-f-g)`. {$ a-g @ (a-b-c)+(b+c-d)+(d-e+f)+(e-f-g)}
q: Simplify `3(x^2+y^2)-[(x^2+2xy+y^2)-(2xy-x^2-y^2)]`. {$ x^2+y^2 @ 3(x^2+y^2)-((x^2+2xy+y^2)-(2xy-x^2-y^2))}
q: Simplify `a-(x-a)-[x-(a-x)]`. {$ 3a-3x @ a-(x-a)-(x-(a-x))}
q: Simplify `1-(1-[1-(1-x)])`. {$ x @ 1-(1-(1-(1-x)))}
== 5 | Fundamental Rules | Observations on addition and subtraction
art: 47 | | All quantities are to be regarded as positive, unless, for some special reason, they are otherwise designated. Negative quantities are always, in some particular respect, the opposite of positive quantities. Thus, if a merchant's gains are positive, his losses are negative; if latitude north of the equator is +, that south is −; if distance to the right of a certain line is +, that to the left is −; if time after a certain hour is +, time before that hour is −; if motion in one direction be +, motion in an opposite direction is −; and so on.
art: 48 | | This relation of the signs gives rise to some important particulars. 1st. The addition, to any quantity, of a negative number, produces a less result than adding zero. Thus, 10 and 3 make 13; 10 and 0 make 10; 10 and −1 make 9; 10 and −3 make 7. Adding a negative number produces the same result as subtracting an equal positive number.
art: 48 | | 2d. The subtraction of a negative quantity produces a greater result than subtracting zero. Thus, 10 less 3 is 7; 10 less 0 is 10; 10 less −1 is 11; 10 less −3 is 13. Here, subtracting a negative number produces the same result as adding an equal positive number.
art: 49 | | When two negative quantities are considered algebraically, that is called the least which contains the greatest number of units; thus, −3 is said to be less than −2. But that which contains the greatest number of units is said to be numerically the greatest; thus, −3 is numerically greater than −2.
art: 50 | | The sum of two positive quantities is always greater than either of them. Thus, `+5+3=+8`. The sum of two negative quantities, algebraically considered, is less than either of them. Thus, `-5-3=-8`. The sum of a positive and negative quantity is always less than the positive quantity. Thus, `+5-3=+2`.
art: 51 | | The difference of two positive quantities, as in arithmetic, is always less than the greater quantity. Thus, `2a` from `5a` leaves `3a`. The difference of two negative quantities is always greater, algebraically considered, than the minuend. Thus, `-2a` from `-5a` leaves `-3a`. The difference between a positive and a negative quantity, found by subtracting the latter from the former, is always greater than either of them. Thus, `2a-(-a)=3a`.
mc: If a merchant's gains are positive, his losses are... | *negative | positive | zero
mc: Adding a negative number gives the same result as... | *subtracting an equal positive number | adding an equal positive number | adding zero
mc: Subtracting a negative number gives the same result as... | *adding an equal positive number | subtracting an equal positive number | subtracting zero
mc: Algebraically, which is less? | *−3 | −2 | they are equal
mc: Numerically, which is greater? | *−3 | −2 | they are equal
tf: The sum of two negative quantities is less than either of them. {T}
tf: The sum of a positive and a negative quantity is always greater than the positive quantity. {F}
q: What is 10 and −3? {7 @= 10-3}
q: What is 10 less −3? {13 @= 10+3}
q: Subtract `-2a` from `-5a`. {$ -3a @ -5a-(-2a)}
q: Subtract `-a` from `2a`. {$ 3a @ 2a-(-a)}
q: The latitude of A is 10° N. (+); the latitude of B is 5° S. (−); what is their difference of latitude? (degrees) {15 @= 10-(-5)}
q: At 7 A. M., a thermometer stood at −9°; at 2 P. M., at +15°; what was the change of temperature? (degrees) {24 @= 15-(-9)}
== 6 | Fundamental Rules | Multiplication
art: 52 | Multiplication | Multiplication, in Algebra, is the process of taking one algebraic quantity as many times as there are units in another. The quantity to be multiplied is called the multiplicand; the quantity by which we multiply, the multiplier; and the result, the product. The multiplicand and multiplier are called factors.
art: 53 | Preliminary Principle | The product of two factors is the same, whichever be made the multiplier. To prove this, suppose we have a sash containing `a` vertical and `b` horizontal rows of panes. Since there are `a` vertical rows and `b` panes in each row, the whole number of panes will be represented by `b` taken `a` times, that is, by `ab`; or by `a` taken `b` times, that is, by `ba`. Hence, `ab` is equal to `ba`. In a similar manner, the product of three, or of any number of factors, is the same, in whatever order they are taken. Thus, `a*b*c=abc`, `cab`, `bac`, or `cba`; and `2*3*4=4*2*3=3*2*4=4*3*2`, the product in each case being 24.
art: 53 | | It also follows from this principle, that when either of the factors of a product is multiplied, the product itself is multiplied. Thus, `2*3`, multiplied by 5, may be written `5*2*3`, or `5*3*2`; that is, `10*3`, or `15*2`, either of which is equal to 30. Remark: the distinction between the multiplication of numbers and of factors should be carefully noticed. Thus, `3*2` multiplied by 2 equals `6*2`, or `3*4`; not `6*4`.
art: 54 | | In multiplication there are four things to be considered in relation to each term, viz., the coefficient; the literal part; the exponent; and the sign.
art: 55 | Of the Coefficient and Literal Part | Let it be required to find the product of `2ac` by `3b`. To indicate the multiplication, we may write the product thus, `2ac*3b`. But, by Art. 53, this is the same as `2*3*abc`, and `2*3=6`; therefore, the product is `6abc`. Rule of the Coefficients: multiply together the coefficients of the factors for the coefficient of the product. Rule for the Literal Part: annex to the coefficient all the letters of the factors in alphabetical order. Thus, `3ac*5b=15abc`; `2am*cn=2acmn`; `5a*4ax=20aax`; `7cy*3yz=21cyyz`.
art: 56 | Of the Exponent | Let it be required to find the product of `2a^2` by `3a^3`. Since `2a^2=2aa`, and `3a^3=3aaa`, the product will be `2aa*3aaa`, or `6aaaaa`, which, for the sake of brevity, is written `6a^5`. Rule of the Exponents: add the exponents of any letter in the factors for its exponent in the product.
art: 57 | General Rule for Multiplying one Positive Monomial by Another | 1. Multiply the coefficients for the coefficient of the product. 2. Annex all the letters found in both factors. 3. When the same letter occurs in both, add its exponents.
q: Multiply `2ac` by `3b`. {$ 6abc @ 2ac*3b}
q: Multiply `3ac` by `5b`. {$ 15abc @ 3ac*5b}
q: Multiply `5a` by `4ax`. {$ 20a^2x @ 5a*4ax}
q: Multiply `7cy` by `3yz`. {$ 21cy^2z @ 7cy*3yz}
q: Multiply `2a^2` by `3a^3`. {$ 6a^5 @ 2a^2*3a^3}
q: Multiply `x^2y` by `xy`. {$ x^3y^2 @ x^2y*xy}
q: Multiply `c^(n+1)` by `c^(n-1)`. {$ c^(2n) @ c^(n+1)*c^(n-1)}
q: Multiply `x^(m+p)` by `x^(n-p)`. {$ x^(m+n) @ x^(m+p)*x^(n-p)}
q: Multiply `bc` by `z`. {$ bcz @ bc*z}
q: Multiply `3ax` by `by`. {$ 3abxy @ 3ax*by}
q: Multiply `4am` by `3bn`. {$ 12abmn @ 4am*3bn}
q: Multiply `5a^2x` by `7ax^3y`. {$ 35a^3x^4y @ 5a^2x*7ax^3y}
q: Multiply `3a^mx^n` by `9a^nx^m`. {$ 27a^(m+n)x^(m+n) @ 3a^mx^n*9a^nx^m}
art: 58 | Rule for Multiplying a Polynomial by a Monomial | Required to find the product of `a+b` by `m`. Here, the sum of the units in `a` and `b` is to be taken `m` times. The units in `a` taken `m` times `=ma`, and the units in `b` taken `m` times `=mb`; hence, `a+b` taken `m` times `=ma+mb`. Rule: multiply each term of the multiplicand by the multiplier.
q: Multiply `x+y` by `n`. {$ nx+ny @ (x+y)*n}
q: Multiply `ax^2+cz` by `3ac`. {$ 3a^2cx^2+3ac^2z @ (ax^2+cz)*3ac}
q: Multiply `2a^2+3b^2` by `5ab`. {$ 10a^3b+15ab^3 @ (2a^2+3b^2)*5ab}
q: Multiply `mx+ny+vz` by `m^2n`. {$ m^3nx+m^2n^2y+m^2nvz @ (mx+ny+vz)*m^2n}
art: 59 | Rule for Multiplying one Polynomial by Another | Required to find the product of `a+b` by `m+n`. Here, `a+b` is to be taken as many times as there are units in `m+n`, which is evidently as many times as there are units in `m`, plus as many times as there are units in `n`. Thus, `ma+mb` = multiplicand taken `m` times; `na+nb` = multiplicand taken `n` times; `ma+mb+na+nb` = multiplicand taken `(m+n)` times. Rule: multiply each term of the multiplicand by each term of the multiplier, and add the products.
q: Multiply `x+y` by `a+c`. {$ ax+ay+cx+cy @ (x+y)(a+c)}
q: Multiply `2x+3z` by `3x+2z`. {$ 6x^2+13xz+6z^2 @ (2x+3z)(3x+2z)}
q: Multiply `2a+c` by `a+2c`. {$ 2a^2+5ac+2c^2 @ (2a+c)(a+2c)}
q: Multiply `x^2+xy+y^2` by `x+y`. {$ x^3+2x^2y+2xy^2+y^3 @ (x^2+xy+y^2)(x+y)}
q: Multiply `a^2+2ab+b^2` by `a+b`. {$ a^3+3a^2b+3ab^2+b^3 @ (a^2+2ab+b^2)(a+b)}
art: 60 | Of the Signs | 1st. Required the product of `+b` by `a`. The quantity `b`, taken once, is `+b`; taken twice, is `+2b`; taken 3 times, `+3b`; and hence, taken `a` times, it is `+ab`. Hence, plus multiplied by plus gives plus. 2d. Required the product of `-b` by `a`. The quantity `-b`, taken once, is `-b`; taken twice, `-2b`; and hence, taken `a` times, is `-ab`. Hence, minus multiplied by plus gives minus.
art: 60 | | 3d. Required to multiply `b` by `-a`. Since `b*(+a)` implies that `b` is to be added `a` times to 0, `b*(-a)` must indicate (Art. 47) that `b` is to be subtracted `a` times from 0. Subtracted once, it is `-b`; twice, `-2b`; and so on. Hence, subtracted `a` times, it is `-ab`: plus multiplied by minus gives minus. 4th. Required to multiply `-b` by `-a`. Reasoning as above, `-b` subtracted `a` times from 0, gives `+ab`: minus multiplied by minus gives plus.
art: 60 | Note | The following proof of the 3d and 4th cases is generally regarded as more satisfactory. Let it be required to find the product of `c-d` by `a-b`. Here `c-d` is to be taken as many times as there are units in `a-b`. This will be done by taking `c-d` as many times as there are units in `a`, and then subtracting from this product `c-d` taken as many times as there are units in `b`. Thus, `ac-ad` = `c-d` taken `a` times; `bc-bd` = `c-d` taken `b` times; by subtraction, `ac-ad-bc+bd` = `c-d` taken `a-b` times. The final result, in the terms `-bc` and `+bd`, is what it would have been if we had added the partial products, assuming that `+c` multiplied by `-b` gives `-bc`, and that `-d` multiplied by `-b` gives `+bd`.
art: 60 | General Rule for the Signs | The product of like signs gives plus, and of unlike signs, minus.
art: 61 | General Rule for the Multiplication of Algebraic Quantities | 1. Multiply every term of the multiplicand by each term of the multiplier, observing the rules for the coefficients, the exponents, and the signs. 2. Add the several partial products together.
mc: The product of `-b` by `-a` is... | *`+ab` | `-ab` | `-a-b`
mc: Plus multiplied by minus gives... | *minus | plus | zero
mc: `2*3` multiplied by 5 may be written... | *`10*3` | `10*15` | `2*3+5`
tf: The product of several factors is the same, in whatever order they are taken. {T}
tf: Like signs give minus in a product. {F}
q: Multiply `7-4` by 5, first term by term. {15 @= 7*5-4*5}
q: Multiply `8+3` by `6-4`, term by term. {22 @= 8*6-8*4+3*6-3*4}
q: Multiply `4a^2-3ac+2` by `5ax`. {$ 20a^3x-15a^2cx+10ax @ (4a^2-3ac+2)*5ax}
q: Multiply `5a-2ab+10` by `-9ab`. {$ -45a^2b+18a^2b^2-90ab @ (5a-2ab+10)*(-9ab)}
q: Multiply `2x+3z` by `2x-3z`. {$ 4x^2-9z^2 @ (2x+3z)(2x-3z)}
q: Multiply `4a^2-6a+9` by `2a+3`. {$ 8a^3+27 @ (4a^2-6a+9)(2a+3)}
q: Multiply `a-b+c-d` by `a+b-c-d`. {$ a^2-b^2-c^2+d^2-2ad+2bc @ (a-b+c-d)(a+b-c-d)}
q: Multiply `x^3+y^2+z^2` by `x^2+y^2`. {$ x^5+x^2y^2+x^2z^2+x^3y^2+y^4+y^2z^2 @ (x^3+y^2+z^2)(x^2+y^2)}
q: Multiply `a^3+3a^2b+3ab^2+b^3` by `a^3-3a^2b+3ab^2-b^3`. {$ a^6-3a^4b^2+3a^2b^4-b^6 @ (a^3+3a^2b+3ab^2+b^3)(a^3-3a^2b+3ab^2-b^3)}
q: Multiply `12x^3-8x^2y+15xy^2-10y^3` by `3x+2y`. {$ 36x^4+29x^2y^2-20y^4 @ (12x^3-8x^2y+15xy^2-10y^3)(3x+2y)}
q: Multiply `a^2+ax+x^2` by `a^2-ax+x^2`. {$ a^4+a^2x^2+x^4 @ (a^2+ax+x^2)(a^2-ax+x^2)}
q: Multiply `a^2+2ab+2b^2` by `a^2-2ab+2b^2`. {$ a^4+4b^4 @ (a^2+2ab+2b^2)(a^2-2ab+2b^2)}
q: Multiply `1+x+x^2+x^3+x^4` by `1-x`. {$ 1-x^5 @ (1+x+x^2+x^3+x^4)(1-x)}
q: Multiply `27x^3+9x^2y+3xy^2+y^3` by `3x-y`. {$ 81x^4-y^4 @ (27x^3+9x^2y+3xy^2+y^3)(3x-y)}
q: Multiply `a^3+2a^2b+2ab^2+b^3` by `a^3-2a^2b+2ab^2-b^3`. {$ a^6-b^6 @ (a^3+2a^2b+2ab^2+b^3)(a^3-2a^2b+2ab^2-b^3)}
q: Multiply `x^4-x^3+x^2-x+1` by `x^2+x-1`. {$ x^6-x^4+x^3-x^2+2x-1 @ (x^4-x^3+x^2-x+1)(x^2+x-1)}
q: Multiply `1+x+x^4+x^5` by `1-x+x^2-x^3`. {$ 1-x^8 @ (1+x+x^4+x^5)(1-x+x^2-x^3)}
q: Multiply together `x-3`, `x+4`, `x-5`, and `x+6`. {$ x^4+2x^3-41x^2-42x+360 @ (x-3)(x+4)(x-5)(x+6)}
q: Multiply together `a+b`, `a-b`, `a^2+ab+b^2`, and `a^2-ab+b^2`. {$ a^6-b^6 @ (a+b)(a-b)(a^2+ab+b^2)(a^2-ab+b^2)}
== 7 | Fundamental Rules | Detached coefficients; remarks on multiplication
art: 62 | Multiplication by Detached Coefficients | In the multiplication of polynomials, the coefficients of the product depend on the coefficients of the factors, and not upon the literal parts of the terms. Hence, by detaching the coefficients of the factors from the literal parts, and multiplying them together, we shall obtain the coefficients of the product. If to these coefficients the proper letters are then annexed, the whole product will be obtained. This method is applicable where the powers of the same letter increase or decrease regularly.
art: 62 | Example 1 | Multiply `a^2-2ab+b^2` by `a+b`. Coefficients `1-2+1` by `1+1`: the partial products are `1-2+1` and `+1-2+1`, giving `1-1-1+1`. After finding the coefficients, it is obvious that `a^3` will be the first term, and `b^3` the last; hence, the entire product is `a^3-a^2b-ab^2+b^3`.
art: 62 | Example 2 | Multiply `a^3-3a^2b+b^3` by `a^2-b^2`. Supposing the powers of `a` to decrease regularly, there is a term wanting in each factor. These must be supplied by 0: `1-3+0+1` by `1+0-1`. The coefficients of the product are `1-3-1+4-0-1`, and the entire product is `a^5-3a^4b-a^3b^2+4a^2b^3-b^5`.
q: Multiply `a^2-2ab+b^2` by `a+b`. {$ a^3-a^2b-ab^2+b^3 @ (a^2-2ab+b^2)(a+b)}
q: Multiply `a^3-3a^2b+b^3` by `a^2-b^2`. {$ a^5-3a^4b-a^3b^2+4a^2b^3-b^5 @ (a^3-3a^2b+b^3)(a^2-b^2)}
q: Multiply `m^3+m^2n+mn^2+n^3` by `m-n`. {$ m^4-n^4 @ (m^3+m^2n+mn^2+n^3)(m-n)}
q: Multiply `1+2z+3z^2+4z^3+5z^4` by `1-z`. {$ 1+z+z^2+z^3+z^4-5z^5 @ (1+2z+3z^2+4z^3+5z^4)(1-z)}
mc: When a power of the letter is wanting in a factor, in detached coefficients its place is filled by... | *0 | 1 | −1
mc: The method of detached coefficients works when the powers of the same letter... | *increase or decrease regularly | are all equal | are all even
art: 63 | Remarks on Algebraic Multiplication | The degree of the product of any two monomials is equal to the sum of the degrees of the multiplicand and multiplier. Thus, `2a^2b`, which is of the 3d degree, multiplied by `3ab^3` of the 4th degree, gives `6a^3b^4`, which is of the 7th degree. This is also true of two polynomials.
art: 64 | | In the multiplication of two polynomials, when the partial products do not contain similar terms, if there be `m` terms in the multiplicand, and `n` terms in the multiplier, the number of terms in the product will be `m*n`. Thus, in Example 6, Art. 61, there are 3 terms in the multiplicand, 2 in the multiplier, and `3*2=6` in the product.
art: 65 | | If the partial products contain similar terms, the number of terms in the reduced product will evidently be less than `m*n`.
art: 66 | | When the multiplication of two polynomials, indicated by a parenthesis, as `(m+n)(p+q)`, is actually performed, the expression is said to be expanded, or developed.
mc: `2a^2b` (3d degree) times `3ab^3` (4th degree) gives a product of the... | *7th degree | 12th degree | 4th degree
mc: A multiplicand of 3 terms times a multiplier of 2 terms, with no similar terms, gives a product of... | *6 terms | 5 terms | 3 terms
mc: Performing the multiplication `(m+n)(p+q)` is called... | *expanding, or developing, it | factoring it | reducing it
tf: If the partial products contain similar terms, the reduced product has fewer than `m*n` terms. {T}
q: Expand `(m+n)(p+q)`. {$ mp+mq+np+nq @ (m+n)(p+q)}
== 8 | Fundamental Rules | Division of monomials; polynomials by monomials
art: 67 | Division | Division, in Algebra, is the process of finding how many times one algebraic quantity is contained in another. Or, having the product of two factors, and one of them given, Division teaches the method of finding the other. The quantity by which we divide is called the divisor; the quantity to be divided, the dividend; the result of the operation, the quotient.
art: 68 | | In division, as in multiplication, there are four things to be considered, viz., the sign; the coefficient; the exponent, and the literal part.
art: 69 | Rule of the Signs | Since `+a*+b=+ab`, `-a*+b=-ab`, `+a*-b=-ab`, and `-a*-b=+ab`, it follows that `+ab÷+b=+a`, `-ab÷+b=-a`, `-ab÷-b=+a`, and `+ab÷-b=-a`. Like signs in the divisor and dividend give plus in the quotient; unlike signs give minus.
art: 70 | | Required to find how often `2a^2` is contained in `6a^5b`. Since division is the reverse of multiplication, the quotient multiplied by the divisor must produce the dividend. 1st. The coefficient of the quotient must be such a number, that when multiplied by 2 the product shall be 6; therefore we divide 6 by 2. Rule of the Coefficients: divide the coefficient of the dividend by the coefficient of the divisor. 2d. The exponent of `a` in the quotient must be such a number, that when 2 is added to it, the sum shall be 5; that is, it must be 3, or `5-2`. Rule of the Exponents: subtract the exponent of any letter in the divisor from the exponent of the same letter in the dividend for its exponent in the quotient. 3d. The letter `b`, which is a factor of the dividend but not of the divisor, must be in the quotient. Rule of the Literal Part: write, in the quotient, every letter found in the dividend, and not in the divisor. The quotient is `3a^3b`.
art: 71 | General Rule for Dividing one Monomial by Another | 1. Prefix the proper sign, on the principle that like signs give plus, and unlike signs give minus. 2. Divide the coefficient of the dividend by that of the divisor. 3. Subtract the exponent of the divisor from that of the dividend, when the same letter or letters occur in both. 4. Annex any letter found in the dividend but not in the divisor.
q: How often is `2a^2` contained in `6a^5b`? {$ 3a^3b @ 6a^5b/(2a^2)}
q: Divide `4a^5` by `2a^2`, and by `-2a^2`. {$ 2a^3 @ 4a^5/(2a^2)} and {$ -2a^3 @ 4a^5/(-2a^2)}
q: Divide `30a^4b^2` by `5a^2b`. {$ 6a^2b @ 30a^4b^2/(5a^2b)}
q: Divide `-28x^3y^7z^4` by `-7xy^2z`. {$ 4x^2y^5z^3 @ -28x^3y^7z^4/(-7xy^2z)}
q: Divide `-35a^2b^3c` by `5ab^2`. {$ -7abc @ -35a^2b^3c/(5ab^2)}
q: Divide `32xyz` by `-8xy`. {$ -4z @ 32xyz/(-8xy)}
q: Divide `42c^3m^2n` by `-3cmn`. {$ -14c^2m @ 42c^3m^2n/(-3cmn)}
q: Divide `x^(m+n)` by `x^n`. {$ x^m @ x^(m+n)/x^n}
q: Divide `x^(m-n)` by `x^n`. {$ x^(m-2n) @ x^(m-n)/x^n}
q: Divide `v^(m+n)` by `v^(m+p)`. {$ v^(n-p) @ v^(m+n)/v^(m+p)}
art: 71 | Note | In the following examples, the quantities included within the parenthesis are to be considered together, as a single quantity.
q: Divide `(a+b)^3` by `(a+b)^2`. {$ a+b @ (a+b)^3/(a+b)^2}
q: Divide `(m-n)^5` by `(m-n)^2`. {$ (m-n)^3 @ (m-n)^5/(m-n)^2}
q: Divide `8(a-b)^3x^2y` by `2(a-b)xy`. {$ 4(a-b)^2x @ 8(a-b)^3x^2y/(2(a-b)xy)}
q: Divide `(a+bx^2)^(p+1)` by `(a+bx^2)^(p-1)`. {$ (a+bx^2)^2 @ (a+bx^2)^(p+1)/(a+bx^2)^(p-1)}
art: 72 | | It is evident that one monomial can not be divided by another in the following cases: 1st. When the coefficient of the dividend is not exactly divisible by the coefficient of the divisor. 2d. When the same literal factor has a greater exponent in the divisor than in the dividend. 3d. When the divisor contains one or more literal factors not found in the dividend. In each of these cases the division is to be indicated by a fraction. See Art. 119.
art: 73 | | It has been shown, Art. 53, that any product is multiplied by multiplying either of its factors; hence, conversely, any dividend will be divided by dividing either of its factors. Thus, `6*9÷3=2*9`; or, `6*3=18`.
mc: Which division can not be done exactly, and must be written as a fraction? | *`a^2b` by `ab^3` | `6a^3` by `2a` | `a^2b` by `ab`
mc: Like signs in the divisor and dividend give, in the quotient... | *plus | minus | zero
tf: Any dividend is divided by dividing either of its factors. {T}
art: 74 | Division of Polynomials by Monomials | In multiplying a polynomial by a monomial, we multiply each term of the multiplicand by the multiplier. Hence, conversely, the Rule: divide each term of the dividend by the divisor, according to the rule for the division of monomials. Note: place the divisor on the left, as in arithmetic.
q: Divide `a^2+ab` by `a`. {$ a+b @ (a^2+ab)/a}
q: Divide `3xy+2x^2y` by `-xy`. {$ -3-2x @ (3xy+2x^2y)/(-xy)}
q: Divide `10a^2z-15z^2-25z` by `5z`. {$ 2a^2-3z-5 @ (10a^2z-15z^2-25z)/(5z)}
q: Divide `3ab+12abx-9a^2b` by `-3ab`. {$ -1-4x+3a @ (3ab+12abx-9a^2b)/(-3ab)}
q: Divide `5x^3y^3-40a^2x^2y^2+25a^4xy` by `-5xy`. {$ -x^2y^2+8a^2xy-5a^4 @ (5x^3y^3-40a^2x^2y^2+25a^4xy)/(-5xy)}
q: Divide `4abc-24ab^2-32abd` by `-4ab`. {$ -c+6b+8d @ (4abc-24ab^2-32abd)/(-4ab)}
q: Divide `a^mb^3+a^(m+1)b^2+a^(n-2)b` by `ab`. {$ a^(m-1)b^2+a^mb+a^(n-3) @ (a^mb^3+a^(m+1)b^2+a^(n-2)b)/(ab)}
q: Divide `3a(x+y)+c^2(x+y)^2` by `x+y`. {$ 3a+c^2(x+y) @ (3a(x+y)+c^2(x+y)^2)/(x+y)}
q: Divide `(b+c)(b-c)^2-(b-c)(b+c)^2` by `(b+c)(b-c)`. {$ -2c @ ((b+c)(b-c)^2-(b-c)(b+c)^2)/((b+c)(b-c))}
q: Divide `b^2c(m+n)-bc^2(m+n)` by `bc(m+n)`. {$ b-c @ (b^2c(m+n)-bc^2(m+n))/(bc(m+n))}
== 9 | Fundamental Rules | Division of polynomials
art: 75 | Division of one Polynomial by Another | To deduce a rule, we first form a product, and then reverse the operation. Multiplying `a^3-5a^2b` by `a^2+2ab-b^2` gives `a^5-3a^4b-11a^3b^2+5a^2b^3`. Now divide this product by `a^3-5a^2b`. Arranging the dividend and divisor according to the decreasing powers of the letter `a`, the division of `a^5`, the first term of the dividend, by `a^3`, the first term of the divisor, will give `a^2`, the first term of the quotient.
art: 75 | | If we subtract from the dividend `a^5-5a^4b`, which is the product of the divisor by `a^2`, the remainder `+2a^4b-11a^3b^2+5a^2b^3` will be the product of the divisor by the other terms of the quotient. Its first term `+2a^4b`, divided by `a^3`, gives `+2ab`, the 2d term of the quotient. Multiplying the divisor by `+2ab`, and subtracting, we have a 2d remainder, `-a^3b^2+5a^2b^3`, whose first term divided by `a^3` gives `-b^2`, the 3d term of the quotient. The remainder zero shows that the quotient `a^2+2ab-b^2` is exact. It is immaterial whether the divisor be placed on the right or left of the dividend; by placing it on the right, it is more easily multiplied by the respective terms of the quotient.
art: 76 | Rule for the Division of one Polynomial by Another | 1. Arrange the dividend and divisor with reference to a certain letter. 2. Divide the first term of the dividend by the first term of the divisor, for the first term of the quotient. Multiply the divisor by this term, and subtract the product from the dividend. 3. Divide the first term of the remainder by the first term of the divisor, for the second term of the quotient. Multiply the divisor by this term, and subtract the product from the last remainder. 4. Proceed in the same manner, and if the final remainder is 0, the division is said to be exact.
mc: Before dividing one polynomial by another, first... | *arrange both with reference to a certain letter | multiply them together | change all the signs
mc: If the final remainder is 0, the division is said to be... | *exact | impossible | indeterminate
q: Divide `a^5-3a^4b-11a^3b^2+5a^2b^3` by `a^3-5a^2b`. {$ a^2+2ab-b^2 @ (a^5-3a^4b-11a^3b^2+5a^2b^3)/(a^3-5a^2b)}
q: Divide `15x^2+16xy-15y^2` by `5x-3y`. {$ 3x+5y @ (15x^2+16xy-15y^2)/(5x-3y)}
q: Divide `m^2-n^2` by `m+n`. {$ m-n @ (m^2-n^2)/(m+n)}
q: Divide `x^3+y^3` by `x+y`. {$ x^2-xy+y^2 @ (x^3+y^3)/(x+y)}
q: Divide `7x^2y+5xy^2+2x^3+y^3` by `3xy+x^2+y^2`. {$ 2x+y @ (7x^2y+5xy^2+2x^3+y^3)/(3xy+x^2+y^2)}
art: 76 | Example 5 | Divide `x^2+x^3-7x^4+5x^5` by `x-x^2`. Arranged by the ascending powers of `x`, the quotient is `x+2x^2-5x^3`; arranged by the descending powers, it is `-5x^3+2x^2+x`. The two quotients are the same, but differently arranged.
q: Divide `x^2+x^3-7x^4+5x^5` by `x-x^2`. {$ x+2x^2-5x^3 @ (x^2+x^3-7x^4+5x^5)/(x-x^2)}
q: Divide `6x^2+5xy-4y^2` by `3x+4y`. {$ 2x-y @ (6x^2+5xy-4y^2)/(3x+4y)}
q: Divide `x^3-40x-63` by `x-7`. {$ x^2+7x+9 @ (x^3-40x-63)/(x-7)}
q: Divide `3h^5+16h^4k-33h^3k^2+14h^2k^3` by `h^2+7hk`. {$ 3h^3-5h^2k+2hk^2 @ (3h^5+16h^4k-33h^3k^2+14h^2k^3)/(h^2+7hk)}
q: Divide `a^5-243` by `a-3`. {$ a^4+3a^3+9a^2+27a+81 @ (a^5-243)/(a-3)}
q: Divide `x^6-2a^3x^3+a^6` by `x^2-2ax+a^2`. {$ x^4+2ax^3+3a^2x^2+2a^3x+a^4 @ (x^6-2a^3x^3+a^6)/(x^2-2ax+a^2)}
q: Divide `1-6x^5+5x^6` by `1-2x+x^2`. {$ 1+2x+3x^2+4x^3+5x^4 @ (1-6x^5+5x^6)/(1-2x+x^2)}
q: Divide `p^2+pq+2pr-2q^2+7qr-3r^2` by `p-q+3r`. {$ p+2q-r @ (p^2+pq+2pr-2q^2+7qr-3r^2)/(p-q+3r)}
q: Divide `4x^5+4x-x^3` by `3x+2x^2+2`. {$ 2x^3-3x^2+2x @ (4x^5+4x-x^3)/(3x+2x^2+2)}
q: Divide `x^6-a^6` by `x^3+2ax^2+2a^2x+a^3`. {$ x^3-2ax^2+2a^2x-a^3 @ (x^6-a^6)/(x^3+2ax^2+2a^2x+a^3)}
q: Divide `m^2+2mp-n^2-2nq+p^2-q^2` by `m-n+p-q`. {$ m+n+p+q @ (m^2+2mp-n^2-2nq+p^2-q^2)/(m-n+p-q)}
q: Divide `a^3+b^3+c^3-3abc` by `a+b+c`. {$ a^2+b^2+c^2-ab-ac-bc @ (a^3+b^3+c^3-3abc)/(a+b+c)}
q: Divide `x^(m+n)+x^ny^n+x^my^m+y^(m+n)` by `x^n+y^m`. {$ x^m+y^n @ (x^(m+n)+x^ny^n+x^my^m+y^(m+n))/(x^n+y^m)}
q: Divide `ax^3-(a^2+b)x^2+b^2` by `ax-b`. {$ x^2-ax-b @ (ax^3-(a^2+b)x^2+b^2)/(ax-b)}
q: Divide `a^(2m)-3a^mc^n+2c^(2n)` by `a^m-c^n`. {$ a^m-2c^n @ (a^(2m)-3a^mc^n+2c^(2n))/(a^m-c^n)}
q: Divide `x^4+x^-4-x^2-x^-2` by `x-x^-1`. {$ x^3-x^-3 @ (x^4+x^-4-x^2-x^-2)/(x-x^-1)}
q: Divide `a^8+a^6b^2+a^4b^4+a^2b^6+b^8` by `a^4+a^3b+a^2b^2+ab^3+b^4`. {$ a^4-a^3b+a^2b^2-ab^3+b^4 @ (a^8+a^6b^2+a^4b^4+a^2b^6+b^8)/(a^4+a^3b+a^2b^2+ab^3+b^4)}
q: Divide `a^2+(a-1)x^2+(a-1)x^3+(a-1)x^4-x^5` by `a-x`. {$ a+x+x^2+x^3+x^4 @ (a^2+(a-1)x^2+(a-1)x^3+(a-1)x^4-x^5)/(a-x)}
q: Divide `1-9x^8-8x^9` by `1+2x+x^2`. {$ 1-2x+3x^2-4x^3+5x^4-6x^5+7x^6-8x^7 @ (1-9x^8-8x^9)/(1+2x+x^2)}
q: Divide `1+2x` by `1-3x` to 5 terms in the quotient. {$ 1+5x+15x^2+45x^3+135x^4}
art: 77 | Division by Detached Coefficients | Division may sometimes be conveniently performed by detaching the coefficients, as explained in Art. 62. Thus, to divide `x^2+2xy+y^2` by `x+y`: `1+2+1` divided by `1+1` gives coefficients 1 and 1. Also, `x^2÷x=x`, and `y^2÷y=y`; therefore, the quotient is `1x+1y`, or `x+y`.
art: 77 | | Divide `12a^4-26a^3b-8a^2b^2+10ab^3-8b^4` by `3a^2-2ab+b^2`. Dividing `12-26-8+10-8` by `3-2+1`, the coefficients of the quotient are `4-6-8`. Also, `a^4÷a^2=a^2`, and `b^4÷b^2=b^2`; therefore, the quotient is `4a^2-6ab-8b^2`.
q: Divide `x^2+2xy+y^2` by `x+y`. {$ x+y @ (x^2+2xy+y^2)/(x+y)}
q: Divide `12a^4-26a^3b-8a^2b^2+10ab^3-8b^4` by `3a^2-2ab+b^2`. {$ 4a^2-6ab-8b^2 @ (12a^4-26a^3b-8a^2b^2+10ab^3-8b^4)/(3a^2-2ab+b^2)}
q: Divide `a^3+x^3` by `a+x`, by detached coefficients. {$ a^2-ax+x^2 @ (a^3+x^3)/(a+x)}
q: Divide `m^5-5m^4n+10m^3n^2-10m^2n^3+5mn^4-n^5` by `m^2-2mn+n^2`. {$ m^3-3m^2n+3mn^2-n^3 @ (m^5-5m^4n+10m^3n^2-10m^2n^3+5mn^4-n^5)/(m^2-2mn+n^2)}
q: Divide `a^6-3a^4b^2+3a^2b^4-b^6` by `a^3-3a^2b+3ab^2-b^3`. {$ a^3+3a^2b+3ab^2+b^3 @ (a^6-3a^4b^2+3a^2b^4-b^6)/(a^3-3a^2b+3ab^2-b^3)}
== 10 | Algebraic Theorems | Square of a sum and of a difference; sum times difference
art: 78 | Algebraic Theorems | One of the chief objects of Algebra is to establish certain general truths. The following theorems, derived from multiplication and division, serve to show some of its most simple applications.
art: 78 | Theorem I | The square of the sum of two quantities is equal to the square of the first, plus twice the product of the first by the second, plus the square of the second. Let `a` represent one of the quantities and `b` the other. Then `a+b` = their sum; and `(a+b)(a+b)`, or `(a+b)^2`, = the square of their sum. By multiplying, we obtain `a^2+2ab+b^2`, which proves the theorem.
q: By Theorem I, `(2+5)^2 = 4+20+25` = ? {49 @= 4+20+25}
q: Square `2m+3n`. {$ 4m^2+12mn+9n^2 @ (2m+3n)^2}
q: Square `ax+by`. {$ a^2x^2+2abxy+b^2y^2 @ (ax+by)^2}
q: Square `ax^2+3xz^3`. {$ a^2x^4+6ax^3z^3+9x^2z^6 @ (ax^2+3xz^3)^2}
art: 79 | Theorem II | The square of the difference of two quantities is equal to the square of the first, minus twice the product of the first by the second, plus the square of the second. Then `a-b` = their difference; and `(a-b)^2` = the square of their difference. By multiplying, we obtain `a^2-2ab+b^2`, which proves the theorem.
q: By Theorem II, `(5-3)^2 = 25-30+9` = ? {4 @= 25-30+9}
q: Square `2x-y`. {$ 4x^2-4xy+y^2 @ (2x-y)^2}
q: Square `3x-5z`. {$ 9x^2-30xz+25z^2 @ (3x-5z)^2}
q: Square `az-3cx`. {$ a^2z^2-6acxz+9c^2x^2 @ (az-3cx)^2}
art: 80 | Theorem III | The product of the sum and difference of two quantities, is equal to the difference of their squares. `a+b` = their sum, and `a-b` = their difference. Multiplying, we obtain `a^2-b^2`, which proves the theorem.
q: By Theorem III, `(7+4)(7-4) = 49-16` = ? {33 @= 49-16}
q: Multiply `2x+y` by `2x-y`. {$ 4x^2-y^2 @ (2x+y)(2x-y)}
q: Multiply `3a^2+4b^2` by `3a^2-4b^2`. {$ 9a^4-16b^4 @ (3a^2+4b^2)(3a^2-4b^2)}
q: Multiply `3ax+5by` by `3ax-5by`. {$ 9a^2x^2-25b^2y^2 @ (3ax+5by)(3ax-5by)}
mc: The square of the sum of two quantities is the square of the first, plus... | *twice the product of the two, plus the square of the second | the square of the second | the product of the two, plus the square of the second
mc: `(a-b)^2` is equal to... | *`a^2-2ab+b^2` | `a^2-b^2` | `a^2+2ab-b^2`
mc: `(a+b)(a-b)` is equal to... | *`a^2-b^2` | `a^2+b^2` | `a^2-2ab+b^2`
== 11 | Algebraic Theorems | Transfer of factors; zero exponent; divisibility of a^m-b^m
art: 81 | Theorem IV | Any factor may be transferred from one term of a fraction to another, if, at the same time, the sign of its exponent be changed. Take the fraction `ax^5/(bx^3)`. Since we may divide both terms by the same quantity without changing the value of the fraction, divide first by `x^3`, and then by `x^5` (Art. 70). Thus, `ax^5/(bx^3)=ax^2/b`, and `ax^5/(bx^3)=a/(bx^(3-5))=a/(bx^-2)`; therefore `ax^2/b=a/(bx^-2)`. In a similar manner, `a/(bx^2)=ax^-2/b`. Also, `1/x^2=x^-2/1=x^-2`, and `x^m=1/x^-m`, from which it follows that the reciprocal of a quantity is equal to the same quantity with the sign of its exponent changed.
art: 81 | Examples | 1. `a^2b/(cd^2)=b/(a^-2cd^2)=bd^-2/(a^-2c)`. 2. `a^m=1/a^-m`. 3. `a/b^m=ab^-m=b^-m/a^-1`. 4. `a^(m-n)=1/a^(n-m)`.
mc: The reciprocal of `x^2` may be written... | *`x^-2` | `-x^2` | `x^(1/2)`
mc: `a/(bx^2)` is equal to... | *`ax^-2/b` | `ax^2/b` | `-ax^2/b`
mc: `a^(m-n)` is equal to... | *`1/a^(n-m)` | `1/a^(m-n)` | `a^(n-m)`
q: Write `1/x^3` with no denominator. {$ x^-3 @ 1/x^3}
q: Write `a^2b/(cd^2)` with no denominator. {$ a^2bc^-1d^-2 @ a^2b/(cd^2)}
art: 82 | Theorem V | Any quantity, whose exponent is 0, is equal to unity. If we divide `a^2` by `a^2`, and apply the rule for the exponents (Art. 70), we find `a^2/a^2=a^(2-2)=a^0`; but, since any quantity is contained in itself once, `a^2/a^2=1`; therefore, `a^0=1`. Similarly, `x^m/x^m=x^(m-m)=x^0`. But `x^m/x^m=1`; therefore, `x^0=1`. By this notation, we may preserve the trace of a letter which has disappeared in division. Thus, `a^2b/(ab)=a^(2-1)b^(1-1)=a^1b^0=a`.
mc: `x^0` is equal to... | *1 | 0 | `x`
q: Divide `a^2b` by `ab`. {$ a @ a^2b/(ab)}
art: 83 | Theorem VI | The difference of the same power of two quantities is always divisible by the difference of the quantities. If we divide `a^2-b^2`, `a^3-b^3`, etc., successively by `a-b`, the quotients will be found, by trial, to follow a simple law, both as to the exponents and the signs: `(a^2-b^2)÷(a-b)=a+b`; `(a^3-b^3)÷(a-b)=a^2+ab+b^2`; `(a^4-b^4)÷(a-b)=a^3+a^2b+ab^2+b^3`; and so on.
art: 83 | Proof | Let us divide `a^m-b^m` by `a-b`. The first term of the quotient is `a^(m-1)`, and the first remainder, `a^(m-1)b-b^m`, which equals `b(a^(m-1)-b^(m-1))`. The remainder consists of two factors, `b` and `a^(m-1)-b^(m-1)`. Now, if the second of these factors is divisible by `a-b`, then will the quantity `a^m-b^m` be divisible by `a-b`. That is, if the difference of the same powers of two quantities is divisible by the difference of the quantities themselves, then will the difference of the next higher powers be divisible by it. But `a^2-b^2` is divisible by `a-b`; hence `a^3-b^3` is also divisible by `a-b`; and so on; which proves the theorem generally.
q: Divide `a^4-b^4` by `a-b`. {$ a^3+a^2b+ab^2+b^3 @ (a^4-b^4)/(a-b)}
q: Divide `a^5-b^5` by `a-b`. {$ a^4+a^3b+a^2b^2+ab^3+b^4 @ (a^5-b^5)/(a-b)}
art: 84 | Lemma | The even powers of a negative quantity are positive, and the odd powers negative. Thus, `-a`, the 1st power of `-a`, is negative; `-a*-a=a^2`, the 2d power, is positive; `-a*-a*-a=-a^3`, the 3d power, is negative; `-a*-a*-a*-a=a^4`, the 4th power, is positive; and so on.
mc: The 5th power of `-a` is... | *`-a^5` | `a^5` | `-5a`
mc: The 6th power of `-a` is... | *`a^6` | `-a^6` | `6a`
art: 85 | Theorem VII | The difference of the even powers of the same degree of two quantities, is always divisible by the sum of the quantities. If we take the quantities `a-b` and `a^m-b^m`, and put `-c` instead of `b`, `a-b` will become `a+c`; and when `m` is even, `b^m` will become `c^m`, and `a^m-b^m` will become `a^m-c^m`: but `a^m-b^m` is always divisible by `a-b`; therefore `a^m-c^m` is always divisible by `a+c` when `m` is even.
q: Divide `a^2-b^2` by `a+b`. {$ a-b @ (a^2-b^2)/(a+b)}
q: Divide `a^4-b^4` by `a+b`. {$ a^3-a^2b+ab^2-b^3 @ (a^4-b^4)/(a+b)}
q: Divide `a^6-b^6` by `a+b`. {$ a^5-a^4b+a^3b^2-a^2b^3+ab^4-b^5 @ (a^6-b^6)/(a+b)}
art: 86 | Theorem VIII | The sum of the odd powers of the same degree of two quantities, is always divisible by the sum of the quantities. Put `-c` instead of `b` as before; when `m` is odd, `b^m` will become `-c^m` (Art. 84), and `a^m-b^m` will become `a^m+c^m`: but `a^m-b^m` is always divisible by `a-b`; therefore `a^m+c^m` is always divisible by `a+c` when `m` is odd.
art: 86 | | By a method of proof similar to that employed in Theorem VI, it may be shown that the sum of two quantities of the same degree can never be divided by the difference of the quantities. Thus, `a+b`, `a^2+b^2`, `a^3+b^3`, `a^4+b^4`, etc., are not divisible by `a-b`. When, in either of the last three theorems, `a` or `b` becomes unity, the form of the quotient will be obvious.
q: Divide `a^3+b^3` by `a+b`. {$ a^2-ab+b^2 @ (a^3+b^3)/(a+b)}
q: Divide `a^5+b^5` by `a+b`. {$ a^4-a^3b+a^2b^2-ab^3+b^4 @ (a^5+b^5)/(a+b)}
q: Divide `a^7+b^7` by `a+b`. {$ a^6-a^5b+a^4b^2-a^3b^3+a^2b^4-ab^5+b^6 @ (a^7+b^7)/(a+b)}
q: Divide `a^5-1` by `a-1`. {$ a^4+a^3+a^2+a+1 @ (a^5-1)/(a-1)}
q: Divide `1+a^5` by `1+a`. {$ 1-a+a^2-a^3+a^4 @ (1+a^5)/(1+a)}
mc: `a^m-b^m` is always divisible by... | *`a-b` | `a+b` | `a^2+b^2`
mc: `a^m-b^m` is divisible by `a+b` when `m` is... | *even | odd | any number
mc: `a^m+b^m` is divisible by `a+b` when `m` is... | *odd | even | any number
tf: `a^4+b^4` is divisible by `a-b`. {F}
== 12 | Algebraic Theorems | Factoring
art: 87 | Factoring | The following summary of the principles of arithmetic should be remembered. Proposition I: a factor of any number is a factor of any multiple of that number. Proposition II: a factor of two numbers is a factor of their sum. From these are inferred the following, and the converse of each: 1. Every number ending in 0, 2, 4, 6, or 8, is divisible by 2. 2. Every number is divisible by 4, when the number denoted by its two right hand digits is divisible by 4. 3. Every number ending in 0 or 5, is divisible by 5. 4. Every number ending with 0, 00, etc., is divisible by 10, 100, etc.
art: 88 | A Divisor or Factor | A Divisor or Factor of a quantity, is a quantity that will exactly divide it without a remainder. Thus, `a` is a factor or divisor of `ab`, and `a+x` is a divisor or factor of `a^2-x^2`.
art: 89 | A Prime Quantity | A Prime Quantity is one which is exactly divisible, only by itself and unity. Thus, `x`, `y`, and `x+z`, are prime quantities; while `xy`, and `ax+az`, are not prime.
art: 90 | | Two quantities are said to be prime to each other, or relatively prime, when no quantity except unity will exactly divide them both. Thus, `ab` and `cd` are prime to each other.
art: 91 | A Composite Quantity | A Composite Quantity is one which is the product of two or more factors, neither of which is unity. Thus, `a^2-x^2` is a composite quantity, the factors being `a+x` and `a-x`.
mc: Is 7316 divisible by 4? | *yes, since 16 is | no, since 7 is not | no, since it ends in 6
mc: Which is a prime quantity? | *`x+z` | `xy` | `ax+az`
mc: `ab` and `cd` are... | *prime to each other | both prime | composite to each other
art: 92 | Monomials | To separate a monomial into its prime factors: Rule. Resolve the coefficient into its prime factors; then, these with the literal factors of the monomial, will be the prime factors of the given quantity. Thus, `18ab^2=2*3*3*a*b*b`; `28x^2yz^3=2*2*7*x*x*y*z*z*z`; `210ax^3yz^2=2*3*5*7*a*x*x*x*y*z*z`.
q: How many prime factors 3 are there in `18ab^2`? {2}
art: 93 | A monomial factor | To separate a polynomial into its factors, when one of them is a monomial: Rule. Divide the given quantity by the greatest monomial that will exactly divide each of its terms. The divisor will be one factor, and the quotient the other.
q: Separate into factors `a+ax`. {$ a(1+x) @ a+ax}
q: Separate into factors `xz+yz`. {$ z(x+y) @ xz+yz}
q: Separate into factors `x^2y+xy^2`. {$ xy(x+y) @ x^2y+xy^2}
q: Separate into factors `6ab^2+9a^2bc`. {$ 3ab(2b+3ac) @ 6ab^2+9a^2bc}
q: Separate into factors `a^2bx^3y-ab^2xy^2+abcxyz^2`. {$ abxy(ax^2-by+cz^2) @ a^2bx^3y-ab^2xy^2+abcxyz^2}
art: 94 | Binomials and trinomials | To separate any binomial or trinomial which is the product of two or more polynomials, into its prime factors: 1st. Any trinomial can be separated into two binomial factors, when the extremes are squares and positive, and the middle term is twice the product of the square roots of the extreme terms. The factors will be the sum or difference of the square roots of the extreme terms, according as the sign of the middle term is plus or minus. Thus, `a^2+2ab+b^2=(a+b)(a+b)`; `a^2-2ab+b^2=(a-b)(a-b)`. 2d. Any binomial which is the difference of two squares, can be separated into factors, one of which is the sum and the other the difference of their roots. Thus, `a^2-b^2=(a+b)(a-b)`.
art: 94 | | 3d. Any binomial which is the difference of the same powers of two quantities, can be separated into at least two factors, one of which is the difference of the two quantities. Thus, `x^3-y^3=(x-y)(x^2+xy+y^2)`. 4th. Any binomial which is the difference of the even powers of two quantities, higher than the second degree, can be separated into at least three factors. Thus, `a^4-b^4=(a^2+b^2)(a+b)(a-b)`. 5th. Any binomial which is the sum of the odd powers of two quantities, can be separated into at least two factors, one of which is the sum of the quantities. Thus, `a^3+b^3=(a+b)(a^2-ab+b^2)`.
art: 94 | | 6th. Some binomials composed of the sum of like even powers may be factored, as may be verified by multiplication: `a^2+b^2=(a+√(2ab)+b)(a-√(2ab)+b)`; `a^4+b^4=(a^2+√2ab+b^2)(a^2-√2ab+b^2)`; `a^6+b^6=(a^2+b^2)(a^4-a^2b^2+b^4)`; `a^10+b^10=(a^2+b^2)(a^8-a^6b^2+a^4b^4-a^2b^6+b^8)`; `a^12+b^12=(a^4+b^4)(a^8-a^4b^4+b^8)`.
tf: `a^4+b^4=(a^2+√2ab+b^2)(a^2-√2ab+b^2)`. {T}
art: 94 | Exercises | Separate the following into their simplest factors.
q: `c^2+2cd+d^2` {$ (c+d)^2 @ c^2+2cd+d^2}
q: `a^2x^4+2ax^2y+y^2` {$ (ax^2+y)^2 @ a^2x^4+2ax^2y+y^2}
q: `25x^2y^4+20xy^2z+4z^2` {$ (5xy^2+2z)^2 @ 25x^2y^4+20xy^2z+4z^2}
q: `9x^4-6x^2z^2+z^4` {$ (3x^2-z^2)^2 @ 9x^4-6x^2z^2+z^4}
q: `4m^2x^2-4mn^2x+n^4` {$ (2mx-n^2)^2 @ 4m^2x^2-4mn^2x+n^4}
q: `x^2-z^2` {$ (x+z)(x-z) @ x^2-z^2}
q: `9a^2x^4-25` {$ (3ax^2+5)(3ax^2-5) @ 9a^2x^4-25}
q: `16-a^2b^4z^6` {$ (4+ab^2z^3)(4-ab^2z^3) @ 16-a^2b^4z^6}
q: `a^4-x^4` {$ (a^2+x^2)(a+x)(a-x) @ a^4-x^4}
q: `z^3+1` {$ (z+1)(z^2-z+1) @ z^3+1}
q: `y^3-1` {$ (y-1)(y^2+y+1) @ y^3-1}
q: `a^3x^3-b^3y^3` {$ (ax-by)(a^2x^2+abxy+b^2y^2) @ a^3x^3-b^3y^3}
q: `x^5+y^5` {$ (x+y)(x^4-x^3y+x^2y^2-xy^3+y^4) @ x^5+y^5}
q: `x^6-y^6` {$ (x+y)(x-y)(x^2+xy+y^2)(x^2-xy+y^2) @ x^6-y^6}
art: 94 | Quadratic trinomials | A Quadratic Trinomial is of the form `x^2+ax+b`, in which the sign of the second term may be either plus or minus. Such a quantity may be resolved into factors by inspection. Observe carefully the product resulting from the multiplication of two factors of the form `x+a` and `x+b`. Thus, `x^2-5x+6=(x-2)(x-3)`, since the first term of each factor must be `x`, and the other terms, −2 and −3, must be such that their sum will be −5, and their product +6.
q: Decompose into binomial factors `x^2+3x+2`. {$ (x+1)(x+2) @ x^2+3x+2}
q: `x^2-8x+15` {$ (x-3)(x-5) @ x^2-8x+15}
q: `x^2-x-2` {$ (x+1)(x-2) @ x^2-x-2}
q: `x^2+x-12` {$ (x-3)(x+4) @ x^2+x-12}
q: `x^2-x-12` {$ (x+3)(x-4) @ x^2-x-12}
q: `x^2+2x-35` {$ (x-5)(x+7) @ x^2+2x-35}
art: 95 | Monomial factor first | Examples to be resolved into factors, by first separating the monomial factor, and then applying Arts. 93 and 94. Thus, `ax^3y-axy^3=axy(x^2-y^2)=axy(x+y)(x-y)`.
q: `ax^3y-axy^3` {$ axy(x+y)(x-y) @ ax^3y-axy^3}
q: `3ax^2+6axy+3ay^2` {$ 3a(x+y)(x+y) @ 3ax^2+6axy+3ay^2}
q: `2cx^2-12cx+18c` {$ 2c(x-3)(x-3) @ 2cx^2-12cx+18c}
q: `3m^3n-3mn^3` {$ 3mn(m+n)(m-n) @ 3m^3n-3mn^3}
q: `2x^5y-2xy^5` {$ 2xy(x^2+y^2)(x+y)(x-y) @ 2x^5y-2xy^5}
q: `2x^2+6x-8` {$ 2(x+4)(x-1) @ 2x^2+6x-8}
q: `2x^3+4x^2-70x` {$ 2x(x+7)(x-5) @ 2x^3+4x^2-70x}
art: 95 | Canceling | Solve the following, by first indicating the operations to be performed, and then canceling common factors. Thus, multiply `4x-12` by `1-x^2`, and divide the product by `2+2x`: `(4x-12)(1-x^2)/(2+2x)=4(x-3)(1+x)(1-x)/(2(1+x))=2(x-3)(1-x)=2(4x-3-x^2)=8x-6-2x^2`.
q: Multiply `4x-12` by `1-x^2`, and divide the product by `2+2x`. {$ 8x-6-2x^2 @ (4x-12)(1-x^2)/(2+2x)}
q: Multiply `x^2+2xy+y^2` by `x-y`, and divide the product by `x^2-y^2`. {$ x+y @ (x^2+2xy+y^2)(x-y)/(x^2-y^2)}
q: Multiply together `1-c`, `1-c^2`, and `1+c^2`, and divide the product by `1-2c+c^2`. {$ 1+c+c^2+c^3 @ (1-c)(1-c^2)(1+c^2)/(1-2c+c^2)}
q: Multiply `x^3-x^2-30x` by `x^2+11x+30`, and divide the product by the product of `x^2-36` and `x^2+10x+25`. {$ x @ (x^3-x^2-30x)(x^2+11x+30)/((x^2-36)(x^2+10x+25))}
== 13 | Algebraic Theorems | Greatest common divisor
art: 96 | A Common Divisor | A Common Divisor, or Common Measure, is any quantity that will exactly divide two or more quantities. Thus, `ab` is a common divisor of `ab^2` and `abx`. Two quantities often have more than one common divisor. Thus, `a^2cx` and `abdx` have three common divisors, `a`, `x`, and `ax`.
art: 97 | The Greatest Common Divisor | The Greatest Common Divisor, or Greatest Common Measure, of two quantities, is the greatest quantity that will exactly divide each of them. Thus, the greatest common divisor of `6a^2bx^2` and `9a^3cxz` is `3a^2x`.
art: 98 | | Quantities that have a common divisor are said to be commensurable; and those that have no common divisor, incommensurable. G.C.D. stands for greatest common divisor.
art: 99 | G.C.D. of monomials | Let it be required to find the G.C.D. of `14a^3cx` and `21a^2bx`. By separating each quantity into its prime factors, we have `14a^3cx=7*2*aaacx`, and `21a^2bx=7*3*aabx`. The only factors common to both are 7, `aa` or `a^2`, and `x`; hence, both can be divided by either of these factors, or by their product, `7a^2x`, and by no other quantity; therefore `7a^2x` is their G.C.D. Rule: 1. Resolve the quantities into their prime factors. 2. Multiply together those factors that are common to all the terms, for the greatest common divisor.
q: Find the G.C.D. of `14a^3cx` and `21a^2bx`. {$ 7a^2x @gcd: 14a^3cx; 21a^2bx}
q: Find the G.C.D. of `6a^2xy`, `9a^3x^3`, and `15a^4x^4y^3`. {$ 3a^2x @gcd: 6a^2xy; 9a^3x^3; 15a^4x^4y^3}
q: Find the G.C.D. of `15abc^2` and `21b^2cd`. {$ 3bc @gcd: 15abc^2; 21b^2cd}
q: Of `4a^3b`, `10a^3c`, and `14a^2bc`. {$ 2a^2 @gcd: 4a^3b; 10a^3c; 14a^2bc}
q: Of `4ax^4y^3`, `20x^4y^2z`, and `12x^3y^3z^2`. {$ 4x^3y^2 @gcd: 4ax^4y^3; 20x^4y^2z; 12x^3y^3z^2}
q: Of `12a^2x^2z^2`, `18ax^3z^2`, `30a^2x^3z`, and `6ax^2z^2`. {$ 6ax^2z @gcd: 12a^2x^2z^2; 18ax^3z^2; 30a^2x^3z; 6ax^2z^2}
art: 100 | Propositions | Previous to investigating the rule for finding the G.C.D. of two polynomials: Proposition I. A divisor of any quantity is also a divisor of any multiple of that quantity. Thus, if A will divide B, it will divide 2B, 3B, etc. Proposition II. A divisor of two quantities is also a divisor of their sum or their difference. Thus, if A will divide B and C, it will divide B+C, or B−C.
art: 101 | G.C.D. of polynomials | Let it be required to find the G.C.D. of two polynomials, A and B, of which A is the greater. If we divide A by B, and there is no remainder, B is evidently the G.C.D., since it can have no divisor greater than itself. Divide A by B, and call the quotient Q; then if there is a remainder R, it is evidently equal to A−BQ. If, now, there is any common divisor of A and B, it will also divide BQ and A−BQ, or R; so the common divisor must divide A, B, and R, and can not be greater than R. Now, if R will exactly divide B, it will also exactly divide BQ and BQ+R, that is, A; and it will be the greatest common divisor, since no divisor of A, B, and R can be greater than R.
art: 101 | | Suppose, however, that when we undertake to divide R into B, we find that the quotient is Q′, with a remainder R′. Reasoning as before, if R′ exactly divides R, it will exactly divide both A and B, and will be their greatest common divisor. By continuing to divide the last divisor by the last remainder, when any division becomes exact, the last divisor will be the greatest common measure of A and B. The same method of proof may be applied to numbers; for example, let A=120, and B=35.
q: By this method, find the greatest common measure of 120 and 35. {5 @= 35-2*15}
art: 102 | | When a remainder becomes unity, or does not contain the letter of arrangement, it is evident that there is no common divisor of the two quantities.
art: 103 | | If either quantity contains a factor not found in the other, that factor may be canceled without affecting the common divisor. Thus, `a` is the G.C.D. of `ax` and `ay`, and will be, if we cancel `x` in `ax`, or `y` in `ay`.
art: 104 | | We may multiply either quantity by a factor not found in the other, without changing the G.C.D. Thus, in the two quantities, `ax` and `ay`, if we multiply `ax` by `m`, or `ay` by `n`, the G.C.D. will still be `a`.
art: 105 | | But if we multiply either quantity by a factor found in the other, we change the G.C.D. Thus, in `ax` and `ay`, if we multiply `ay` by `x`, or `ax` by `y`, the G.C.D. becomes `ax` or `ay`.
art: 106 | | From Art. 101, it is evident that the three preceding articles apply also to the successive remainders.
art: 107 | | Any common factor of two quantities must also be a factor of their G.C.D. Where such common factor is easily seen, we may set it aside, and find the G.C.D. of what remains. Thus, take `55x` and `15x`. Setting aside `x`, we find the greatest common measure of 55 and 15 to be 5. Annexing `x`, we have `5x`.
mc: In `ax` and `ay`, multiplying `ay` by `x` makes the G.C.D.... | *`ax` | `a` | `x`
mc: In `ax` and `ay`, multiplying `ax` by `m` makes the G.C.D.... | *still `a` | `am` | `m`
mc: When a remainder becomes unity, the two quantities have... | *no common divisor | a common divisor of one term | the remainder as G.C.D.
art: 107 | Example 1 | Find the G.C.D. of `x^3-z^3` and `x^4-x^2z^2`. Here the second quantity contains `x^2` as a factor, but it is not a factor of the first; we may, therefore, cancel it (Art. 103), and the second quantity becomes `x^2-z^2`. Then divide the first by it. After dividing, we find the remainder `xz^2-z^3`, or `(x-z)z^2`; `z^2` is a factor of the remainder, but not of `x^2-z^2`, the next dividend. We therefore cancel it, and the second divisor becomes `x-z`. Dividing by this, we find there is no remainder; therefore, `x-z` is the G.C.D.
art: 107 | Example 2 | Find the G.C.D. of `x^5+x^2z^3` and `x^5-x^3z^2`. The factor `x^2` is common to both quantities; it is a factor of the G.C.D. (Art. 107), and may be taken out and reserved. The quantities become `x^3+z^3` and `x^3-xz^2`. The second still contains a factor `x`, which the first does not; canceling it, it becomes `x^2-z^2`. Proceeding as in the first example, we find that `x+z` divides without a remainder; therefore `x^2(x+z)` is the required G.C.D.
art: 107 | Example 3 | Find the G.C.D. of `10a^2x^2-4a^2x-6a^2` and `5bx^2-11bx+6b`. By separating the monomial factors, `10a^2x^2-4a^2x-6a^2=2a^2(5x^2-2x-3)`, and `5bx^2-11bx+6b=b(5x^2-11x+6)`. The factors `2a^2` and `b` have no common measure, and hence are not factors of the common divisor; we suppress them (Art. 103), and find the G.C.D. of the remaining quantities to be `x-1`.
art: 107 | Example 4 | Find the G.C.D. of `4a^2-5ay+y^2`, and `3a^3-3a^2y+ay^2-y^3`. In this example it is necessary, in two instances, to multiply the dividend by 4, that the coefficient of the first term may be divisible by the first term of the divisor (Art. 104). We find `19y^2` is a factor of the first remainder, but not of the first divisor, and hence can not be a factor of the G.C.D.; it must, therefore, be suppressed. Dividing `4a^2-5ay+y^2` by `a-y` leaves no remainder; hence `a-y` is the G.C.D.
q: Find the G.C.D. of `x^3-z^3` and `x^4-x^2z^2`. {$ x-z @gcd: x^3-z^3; x^4-x^2z^2}
q: Find the G.C.D. of `x^5+x^2z^3` and `x^5-x^3z^2`. {$ x^2(x+z) @gcd: x^5+x^2z^3; x^5-x^3z^2}
art: 108 | Rule | To find the greatest common divisor of two polynomials: 1. Divide the greater polynomial by the less, and if there is no remainder, the less quantity will be the divisor sought. 2. If there be a remainder, divide the first divisor by it, and continue to divide the last divisor by the last remainder, until a divisor is obtained which leaves no remainder; this will be the G.C.D. of the two given polynomials.
art: 108 | Notes | 1. When the highest power of the leading letter is the same in both, it is immaterial which of the quantities is made the dividend. 2. If both quantities contain a common factor, let it be set aside, as forming a factor of the common divisor, and proceed to find the G.C.D. of the remaining factors. 3. If either quantity contains a factor not found in the other, it may be canceled before commencing the operation. 4. Whenever it is necessary, the dividend may be multiplied by any quantity which will render the first term exactly divisible by the first term of the divisor. 5. If, in any case, the remainder is unity, or does not contain the leading letter, there is no common divisor. 6. To find the G.C.D. of three or more quantities, first find the G.C.D. of two of them; then of that divisor and one of the other quantities, and so on. 7. Since the G.C.D. of any two quantities contains all the factors common to both, it may often be found most easily by separating the polynomials into factors.
q: Find the G.C.D. of `5x^2-2x-3` and `5x^2-11x+6`. {$ x-1 @gcd: 5x^2-2x-3; 5x^2-11x+6}
q: Of `9x^2-4` and `9x^2-15x-14`. {$ 3x+2 @gcd: 9x^2-4; 9x^2-15x-14}
q: Of `a^2-ab-12b^2` and `a^2+5ab+6b^2`. {$ a+3b @gcd: a^2-ab-12b^2; a^2+5ab+6b^2}
q: Of `a^4-x^4` and `a^3+a^2x-ax^2-x^3`. {$ a^2-x^2 @gcd: a^4-x^4; a^3+a^2x-ax^2-x^3}
q: Of `x^3-5x^2+13x-9` and `x^3-2x^2+4x-3`. {$ x-1 @gcd: x^3-5x^2+13x-9; x^3-2x^2+4x-3}
q: Of `21x^3-26x^2+8x` and `6x^2-x-2`. {$ 3x-2 @gcd: 21x^3-26x^2+8x; 6x^2-x-2}
q: Of `x^4+2x^2+9` and `7x^3-11x^2+15x+9`. {$ x^2-2x+3 @gcd: x^4+2x^2+9; 7x^3-11x^2+15x+9}
q: Of `x^2+5x+4`, `x^2+2x-8`, and `x^2+7x+12`. {$ x+4 @gcd: x^2+5x+4; x^2+2x-8; x^2+7x+12}
q: Of `2b^3-10ab^2+8a^2b` and `9a^4-3ab^3+3a^2b^2-9a^3b`. {$ a-b @gcd: 2b^3-10ab^2+8a^2b; 9a^4-3ab^3+3a^2b^2-9a^3b}
q: Of `x^4+a^2x^2+a^4` and `x^4+ax^3-a^3x-a^4`. {$ x^2+ax+a^2 @gcd: x^4+a^2x^2+a^4; x^4+ax^3-a^3x-a^4}
q: Of `x^4-px^3+(q-1)x^2+px-q` and `x^4-qx^3+(p-1)x^2+qx-p`. {$ x^2-1 @gcd: x^4-px^3+(q-1)x^2+px-q; x^4-qx^3+(p-1)x^2+qx-p}
== 14 | Algebraic Theorems | Least common multiple
art: 109 | A Multiple | A Multiple of a quantity is any quantity that contains it exactly. Thus, 6 is a multiple of 2 or of 3; and `ab` is a multiple of `a` or of `b`; also, `a(b-c)` is a multiple of `a` or `(b-c)`.
art: 110 | A Common Multiple | A Common Multiple of two or more quantities, is a quantity that contains either of them exactly. Thus, 12 is a common multiple of 2 and 3; and `20xy`, of `2x` and `5y`.
art: 111 | The Least Common Multiple | The Least Common Multiple of two or more quantities, is the least quantity that will contain them exactly. Thus, 6 is the least common multiple of 2 and 3; `10xy`, of `2x` and `5y`. L.C.M. stands for least common multiple.
art: 112 | To find the L.C.M. | It is evident that the L.C.M. of two or more quantities contains all the prime factors of each of the quantities once, and does not contain any prime factor besides. Thus, the L.C.M. of `ab` and `bc` must contain the factors `a`, `b`, `c`, and no other factor. Let us find the L.C.M. of `mx`, `nx`, and `m^2nz`. We see that `m` is a prime factor common to two of them. It must, therefore, be a factor of the L.C.M.; and as it can occur but once in the L.C.M., we cancel `m` in each of the quantities in which it is found, which is done by dividing by it. For the same reason we divide by `n` and by `x`. We thus find that the L.C.M. must contain the factors `m`, `n`, and `x`; also, `mz`. Hence, `m*n*x*mz=m^2nxz`.
art: 112 | Rule | 1. Arrange the quantities in a horizontal line, divide by any prime factor that will exactly divide two or more of them, and set the quotients and the undivided quantities in a line beneath. 2. Continue dividing as before, until no prime factor, except unity, will exactly divide two or more of the quantities. 3. Multiply the divisors and the quantities in the last line together, and the product will be the L.C.M. required. Or, separate the quantities into their prime factors; then, to form a product, 1st, take each factor once; 2d, if any factor occurs more than once, take it the greatest number of times it occurs in either of the quantities.
art: 113 | | Since the G.C.D. of two quantities contains all the factors common to both, if we divide the product of two quantities by their G.C.D., the quotient will be their L.C.M.
mc: The L.C.M. of `ab` and `bc` contains the factors... | *`a`, `b`, `c`, and no other | `a`, `b`, `b`, `c` | `b` only
mc: The product of two quantities divided by their G.C.D. is their... | *L.C.M. | G.C.D. | quotient
q: Find the L.C.M. of `mx`, `nx`, and `m^2nz`. {$ m^2nxz @lcm: mx; nx; m^2nz}
q: Find the L.C.M. of `6a^2`, `9ax^3`, and `24x^5`. {$ 72a^2x^5 @lcm: 6a^2; 9ax^3; 24x^5}
q: Of `32x^2y^2`, `40ax^5y`, and `5a^2x(x-y)`. {$ 160a^2x^5y^2(x-y) @lcm: 32x^2y^2; 40ax^5y; 5a^2x(x-y)}
q: Of `3x+6y` and `2x^2-8y^2`. {$ 6x^2-24y^2 @lcm: 3x+6y; 2x^2-8y^2}
q: Of `a^3+x^3` and `a^2-x^2`. {$ a^4-a^3x+ax^3-x^4 @lcm: a^3+x^3; a^2-x^2}
q: Of `x-1`, `x^2-1`, `x-2`, and `x^2-4`. {$ x^4-5x^2+4 @lcm: x-1; x^2-1; x-2; x^2-4}
q: Of `x^2-1`, `x^2+1`, `(x-1)^2`, `(x+1)^2`, `x^3-1`, and `x^3+1`. {$ x^10-x^6-x^4+1 @lcm: x^2-1; x^2+1; (x-1)^2; (x+1)^2; x^3-1; x^3+1}
q: Of `3x^2-11x+6`, `2x^2-7x+3`, and `6x^2-7x+2` (see Art. 113). {$ 6x^3-25x^2+23x-6 @lcm: 3x^2-11x+6; 2x^2-7x+3; 6x^2-7x+2}
== 15 | Algebraic Fractions | Definitions; lowest terms
art: 114 | Algebraic Fractions | Algebraic Fractions are represented in the same manner as common fractions in arithmetic. The quantity below the line is called the denominator, because it denominates, or shows the number of parts into which the unit is divided; the quantity above the line is called the numerator, because it numbers, or shows how many parts are taken. Thus, in the fraction `(a-b)/(c+d)`, a unit is supposed to be divided into `c+d` equal parts, and `a-b` of those parts are taken.
art: 115 | | The terms proper, improper, simple, compound, and complex, have the same meaning when applied to algebraic fractions, as to common numerical fractions.
art: 116 | An Entire Algebraic Quantity | An Entire Algebraic Quantity is one not expressed under the form of a fraction.
art: 117 | A Mixed Quantity | A Mixed Quantity is one composed of an entire quantity and a fraction.
art: 118 | Proposition | The value of a fraction is not altered, when both terms are multiplied or divided by the same quantity. Let `A/B=Q`. Then will `mA/(mB)=Q`. For, since the numerator of a fraction may always be considered a dividend, and the denominator a divisor, if we multiply the numerator by any quantity, as `m`, the quotient will be increased `m` times; if we multiply the denominator by `m`, the quotient will be diminished as much, or divided by `m`. Therefore, the value of the fraction is not changed. Or thus: `mA/(mB)=m^1m^-1A/B=m^0A/B=A/B` (Arts. 81, 82).
art: 119 | Case I: to reduce a fraction to its lowest terms | Rule. Divide both terms of the fraction by any quantity that will exactly divide them, and continue this process as long as possible. Or, divide both terms by their greatest common divisor. Or, resolve both terms into their prime factors, and then cancel those factors which are common. In algebraic fractions, the last is generally the best method. Thus, `10acx^2/(15bcx^3)=2acx^2/(3bcx^3)=2ax^2/(3bx^3)=2a/(3bx)`; or, dividing by `5cx^2`, `2a/(3bx)`.
mc: In `(a-b)/(c+d)`, the unit is divided into... | *`c+d` equal parts | `a-b` equal parts | `a` parts
mc: A quantity not written as a fraction is called... | *an entire quantity | a mixed quantity | a complex fraction
tf: The value of a fraction is not altered when both terms are multiplied by the same quantity. {T}
q: Reduce `10acx^2/(15bcx^3)` to its lowest terms. {$ 2a/(3bx) @ 10acx^2/(15bcx^3)}
q: Reduce `a^2x/(3a^3bx)`. {$ 1/(3ab) @ a^2x/(3a^3bx)}
q: Reduce `(ax+x^2)/(3bx-cx)`. {$ (a+x)/(3b-c) @ (ax+x^2)/(3bx-cx)}
q: Reduce `(3a^2+3ab)/(3a^2-3ab)`. {$ (a+b)/(a-b) @ (3a^2+3ab)/(3a^2-3ab)}
q: Reduce `(1-x)/(1-x^2)`. {$ 1/(1+x) @ (1-x)/(1-x^2)}
q: Reduce `(mnp-m^2p)/(m^2p+mp^2)`. {$ (n-m)/(m+p) @ (mnp-m^2p)/(m^2p+mp^2)}
q: Reduce `(2ax-4ax^2)/(6ax)`. {$ (1-2x)/3 @ (2ax-4ax^2)/(6ax)}
q: Reduce `(5a^2+5ax)/(a^2-x^2)`. {$ 5a/(a-x) @ (5a^2+5ax)/(a^2-x^2)}
q: Reduce `(x^2+2x-3)/(x^2+5x+6)`. {$ (x-1)/(x+2) @ (x^2+2x-3)/(x^2+5x+6)}
q: Reduce `(x^3-4x^2+5)/(x^3+1)`. {$ (x^2-5x+5)/(x^2-x+1) @ (x^3-4x^2+5)/(x^3+1)}
q: Reduce `(15x^3+35x^2+3x+7)/(27x^4+63x^3-12x^2-28x)`. {$ (5x^2+1)/(9x^3-4x) @ (15x^3+35x^2+3x+7)/(27x^4+63x^3-12x^2-28x)}
mc: Reduce `a^n/a^(n+1)`. | *`1/a` | `a` | `1/a^n`
art: 119 | By factoring | The following examples are to be solved by factoring, but the process requires care and practice. Thus, to reduce `(x^2+(a+c)x+ac)/(x^2+(b+c)x+bc)`: `x^2+(a+c)x+ac=x^2+ax+cx+ac=x(x+a)+c(x+a)=(x+c)(x+a)`. Also, `x^2+(b+c)x+bc=(x+c)(x+b)`; therefore the fraction becomes `(x+a)/(x+b)`.
q: Reduce `(x^2+(a+c)x+ac)/(x^2+(b+c)x+bc)` to its lowest terms. {$ (x+a)/(x+b) @ (x^2+(a+c)x+ac)/(x^2+(b+c)x+bc)}
q: Reduce `(ac+by+ay+bc)/(af+2bx+2ax+bf)`. {$ (c+y)/(f+2x) @ (ac+by+ay+bc)/(af+2bx+2ax+bf)}
q: Reduce `(x^8+x^6y^2+x^2y+y^3)/(x^4-y^4)`. {$ (x^6+y)/(x^2-y^2) @ (x^8+x^6y^2+x^2y+y^3)/(x^4-y^4)}
q: Reduce `(a^3+(a+b)ax+bx^2)/(a^4-b^2x^2)`. {$ (a+x)/(a^2-bx) @ (a^3+(a+b)ax+bx^2)/(a^4-b^2x^2)}
q: Reduce `(ax^m-bx^(m+1))/(a^2bx-b^3x^3)`. {$ x^(m-1)/(b(a+bx)) @ (ax^m-bx^(m+1))/(a^2bx-b^3x^3)}
art: 120 | Division with a fractional quotient | Exercises in division, in which the quotient is a fraction, and capable of being reduced.
q: Divide `2a^3x^2` by `5a^2x^2b`. {$ 2a/(5b) @ 2a^3x^2/(5a^2x^2b)}
q: Divide `ax+x^2` by `3bx-cx`. {$ (a+x)/(3b-c) @ (ax+x^2)/(3bx-cx)}
q: Divide `a^3-b^3` by `a^2-b^2`. {$ (a^2+ab+b^2)/(a+b) @ (a^3-b^3)/(a^2-b^2)}
q: Divide `a^3-b^3` by `(a-b)^2`. {$ (a^2+ab+b^2)/(a-b) @ (a^3-b^3)/(a-b)^2}
== 16 | Algebraic Fractions | Entire and mixed quantities; signs of fractions
art: 121 | Case II: to reduce a fraction to an entire or mixed quantity | Since the numerator of the fraction may be regarded as a dividend, and the denominator as the divisor, this is merely a case of division. Rule: divide the numerator by the denominator, for the entire part. If there be a remainder, place it over the denominator, for the fractional part, and reduce it to its lowest terms. Thus, `(a^3+a^2-ax^2)/(a^2-ax)=a+x+a^2/(a^2-ax)=a+x+a/(a-x)`.
q: Reduce `(a^3+a^2-ax^2)/(a^2-ax)` to an entire or mixed quantity. {$ a+x+a/(a-x) @ (a^3+a^2-ax^2)/(a^2-ax)}
q: Reduce `(ax-x^2)/a` to a mixed quantity. {$ x-x^2/a @ (ax-x^2)/a}
q: Reduce `(a^2+2b^2)/(a-b)`. {$ a+b+3b^2/(a-b) @ (a^2+2b^2)/(a-b)}
q: Reduce `(1+2x)/(1-3x)`. {$ 1+5x+15x^2/(1-3x) @ (1+2x)/(1-3x)}
q: Reduce `(x^3+bx^2)/(x^2-bx)`. {$ x+2bx/(x-b) | x+2b+2b^2/(x-b) @ (x^3+bx^2)/(x^2-bx)}
q: Reduce `(x^2z^2-z^2+xz-z-x+1)/(x^2-1)`. {$ z^2+(z-1)/(x+1) @ (x^2z^2-z^2+xz-z-x+1)/(x^2-1)}
art: 122 | Case III: to reduce a mixed quantity to the form of a fraction | This is, obviously, the reverse of Case II. Rule: 1. Multiply the entire part by the denominator of the fraction. 2. Add the numerator to the product, if the sign of the fraction be plus, or subtract it, if the sign be minus. 3. Place the result over the denominator.
art: 123 | The Signs of Fractions | Each of the several terms of the numerator and denominator of a fraction is preceded by the sign plus or minus, expressed or understood; and the fraction, taken as a whole, is also preceded by the sign plus or minus, expressed or understood. Thus, in the fraction `-(a^2-b^2)/(x+y)`, the sign of `a^2` is plus; of `b^2`, minus; while the sign of each term of the denominator is plus; but the sign of the fraction, taken as a whole, is minus.
art: 124 | | It is often convenient to change the signs of the numerator or denominator of a fraction, or both. By the rule for the signs in Division (Art. 69), `+ab/(+a)=+b`; or, changing the signs of both terms, `-ab/(-a)=+b`. If we change the sign of the numerator, `-ab/(+a)=-b`. If we change the sign of the denominator, `+ab/(-a)=-b`. Hence, 1. The signs of both terms of a fraction may be changed, without altering its value or changing its sign, as a whole. 2. If the sign of either term be changed, the sign of the fraction will be changed. 3. The signs of either term of a fraction may be changed, without altering its value, if the sign of the fraction be changed at the same time.
art: 124 | | Thus, `(a^2-x^2)/(a-x)=-(-a^2+x^2)/(a-x)=-(a^2-x^2)/(-a+x)=-(-a-x)=a+x`. And, `a-(a^2-x^2)/(a-x)=a+(-a^2+x^2)/(a-x)=a+(a^2-x^2)/(-a+x)=-x`. Applying the above principles, the sign of the fraction may be made plus, in all cases, if desired.
mc: If the sign of the numerator alone is changed, the sign of the fraction is... | *changed | unchanged | doubled
mc: `-ab/(-a)` is equal to... | *`+b` | `-b` | `ab`
tf: The signs of both terms of a fraction may be changed without altering its value. {T}
art: 124 | Exercises | Reduce the following quantities to a fractional form.
q: Reduce `2+3/5` to a fractional form. {13/5 @= 2+3/5}
q: Reduce `2-3/5` to a fractional form. {7/5 @= 2-3/5}
q: Reduce `a+x+(a^2-ax)/x` to a fractional form. {$ (a^2+x^2)/x @ a+x+(a^2-ax)/x}
q: Reduce `a^2-ax+x^2-2x^3/(a+x)`. {$ (a^3-x^3)/(a+x) @ a^2-ax+x^2-2x^3/(a+x)}
q: Reduce `2a-x+(a-x)^2/x`. {$ a^2/x @ 2a-x+(a-x)^2/x}
q: Reduce `a-a^2/(a+b)`. {$ ab/(a+b) @ a-a^2/(a+b)}
q: Reduce `a-x-(a^2+x^2)/(a+x)`. {$ -2x^2/(a+x) @ a-x-(a^2+x^2)/(a+x)}
q: Reduce `1-(x-y)^2/(x^2+y^2)`. {$ 2xy/(x^2+y^2) @ 1-(x-y)^2/(x^2+y^2)}
== 17 | Algebraic Fractions | Common denominator; a fraction with a given denominator
art: 125 | Case IV: to reduce fractions of different denominators to a common denominator | Let it be required to reduce `a/m`, `b/n`, and `c/r` to a common denominator. If we multiply both terms of the first fraction by `nr`, of the second by `mr`, and of the third by `mn`, we have `anr/(mnr)`, `bmr/(mnr)`, and `cmn/(mnr)`. As the terms of each fraction have thus been multiplied by the same quantity, the value of the fractions has not been changed (Art. 118).
art: 125 | Rule | Multiply both terms of each fraction by the product of all the denominators, except its own. Or, 1. Multiply each numerator by the product of all the denominators except its own, for the new numerators. 2. Multiply all the denominators together for the common denominator.
q: Reduce `1/x`, `2/y`, and `3/z` to a common denominator. What is the denominator? {$ xyz}
q: And the three numerators? {$ yz @ (1/x)*xyz}, {$ 2xz @ (2/y)*xyz}, and {$ 3xy @ (3/z)*xyz}
q: Reduce `a/b` and `b/a` to a common denominator `ab`: the numerators are {$ a^2 @ (a/b)*ab} and {$ b^2 @ (b/a)*ab}
q: Reduce `x/(x-a)` and `a/(x+a)` to the common denominator `x^2-a^2`: the numerators are {$ x^2+ax @ x/(x-a)*(x^2-a^2)} and {$ ax-a^2 @ a/(x+a)*(x^2-a^2)}
art: 126 | The least common denominator | It frequently happens, that the denominators of the fractions to be reduced contain a common factor. In such cases the preceding rule does not give the least common denominator. Let it be required to reduce `a/m`, `b/(mn)`, and `c/(nr)` to their least common denominator. Since the denominators contain only three prime factors, `m`, `n`, and `r`, the least common denominator will contain these three factors, and no others; that is, it will be `mnr`, the L.C.M. of `m`, `mn`, and `nr`. To reduce each fraction to another whose denominator shall be `mnr`, we must multiply both terms of the first fraction by `nr`, of the second by `r`, and of the third by `m`; these multipliers are obtained by dividing the L.C.M. of the given denominators by the several denominators.
art: 126 | Rule | 1. Find the L.C.M. of all the denominators; this will be the common denominator. 2. Divide the L.C.M. by the first of the given denominators, and multiply the quotient by the first of the given numerators; the product will be the first of the required numerators. 3. Proceed thus to find each of the other numerators.
q: Reduce `a/(6xy)`, `b/(3x)`, and `c/(2y)` to the least common denominator `6xy`: the numerators are {$ a @ a/(6xy)*6xy}, {$ 2by @ b/(3x)*6xy}, and {$ 3cx @ c/(2y)*6xy}
q: Reduce `x/(a+b)`, `y/(a-b)`, and `z/(a^2-b^2)` to the least common denominator `a^2-b^2`: the numerators are {$ x(a-b) @ x/(a+b)*(a^2-b^2)}, {$ y(a+b) @ y/(a-b)*(a^2-b^2)}, and {$ z}
q: Reduce `(m-n)/(m+n)`, `(m+n)/(m-n)`, and `m^2n^2/(m^2-n^2)` to the least common denominator `m^2-n^2`: the numerators are {$ (m-n)^2 @ (m-n)/(m+n)*(m^2-n^2)}, {$ (m+n)^2 @ (m+n)/(m-n)*(m^2-n^2)}, and {$ m^2n^2}
art: 127 | To reduce an entire quantity to the form of a fraction having a given denominator | Rule: multiply the entire quantity by the given denominator, and write the product over it.
q: Reduce `x` to a fraction whose denominator is `a`: the numerator is {$ ax @ x*a}
q: Reduce `2az` to a fraction whose denominator is `z^2`: the numerator is {$ 2az^3 @ 2az*z^2}
q: Reduce `x+y` to a fraction whose denominator is `x-y`: the numerator is {$ x^2-y^2 @ (x+y)(x-y)}
art: 128 | To convert a fraction to an equivalent one having a given denominator | Rule: divide the given denominator by the denominator of the given fraction, and multiply both terms by the quotient.
q: Convert `3/7` to an equivalent fraction having 49 for its denominator: the numerator is {21 @= 3*49/7}
q: Convert `a/3` and `5/c` to equivalent fractions having the denominator `9c^2`: the numerators are {$ 3ac^2 @ (a/3)*9c^2} and {$ 45c @ (5/c)*9c^2}
q: Convert `(a+b)/(a-b)` and `(a-b)/(a+b)` to equivalent fractions having the denominator `a^2-b^2`: the numerators are {$ (a+b)^2 @ (a+b)/(a-b)*(a^2-b^2)} and {$ (a-b)^2 @ (a-b)/(a+b)*(a^2-b^2)}
== 18 | Algebraic Fractions | Addition and subtraction of fractions
art: 129 | Case V: addition of fractions | Required to find the value of `a/d`, `b/d`, and `c/d`. Since in each of these fractions the unit is supposed to be divided into `d` parts, it is evident that their sum will be expressed by the fraction `(a+b+c)/d`. Rule for the Addition of Fractions: 1. Reduce the fractions, if necessary, to a common denominator. 2. Add the numerators, and write their sum over the common denominator.
art: 130 | Subtraction of fractions | Let it be required to subtract `b/d` from `a/d`. The unit being, in each case, divided into the same parts, the difference will evidently be expressed by `(a-b)/d`. Rule for the Subtraction of Fractions: 1. Reduce the fractions, if necessary, to a common denominator. 2. Subtract the numerator of the subtrahend from the numerator of the minuend, and write the remainder over the common denominator.
q: Add `a/b` and `3a/(4b)` together. {$ 7a/(4b) @ a/b+3a/(4b)}
q: Add `a/b` and `b/a` together. {$ (a^2+b^2)/(ab) @ a/b+b/a}
q: Add `1/(1+x)` and `1/(1-x)` together. {$ 2/(1-x^2) @ 1/(1+x)+1/(1-x)}
q: Find the value of `c/x+b/x^3+a/x^5`. {$ (a+bx^2+cx^4)/x^5 @ c/x+b/x^3+a/x^5}
q: Find the value of `b/d+(ad-bc)/(d(c+dx))`. {$ (a+bx)/(c+dx) @ b/d+(ad-bc)/(d(c+dx))}
q: Find the value of `p/(ab)+q/(ac)+r/(bc)`. {$ (pc+qb+ra)/(abc) @ p/(ab)+q/(ac)+r/(bc)}
q: Of `x/(x+y)+y/(x-y)`. {$ (x^2+y^2)/(x^2-y^2) @ x/(x+y)+y/(x-y)}
q: Of `1/(4(1+x))+1/(4(1-x))+1/(2(1+x^2))`. {$ 1/(1-x^4) @ 1/(4(1+x))+1/(4(1-x))+1/(2(1+x^2))}
q: Of `(p-q)/(pq)+(r-p)/(pr)+(q-r)/(qr)`. {$ 0 @ (p-q)/(pq)+(r-p)/(pr)+(q-r)/(qr)}
q: Of `1/(4a^3(a+x))+1/(4a^3(a-x))+1/(2a^2(a^2+x^2))`. {$ 1/(a^4-x^4) @ 1/(4a^3(a+x))+1/(4a^3(a-x))+1/(2a^2(a^2+x^2))}
q: Of `1/(a(a-b)(a-c))+1/(b(b-a)(b-c))+1/(c(c-a)(c-b))`. {$ 1/(abc) @ 1/(a(a-b)(a-c))+1/(b(b-a)(b-c))+1/(c(c-a)(c-b))}
art: 130 | Subtraction | Subtract the second fraction, in the following, from the first.
q: `5x/(7a)` and `3y/7`. {$ (5x-3ay)/(7a) @ 5x/(7a)-3y/7}
q: `1/(a-b)` and `1/(a+b)`. {$ 2b/(a^2-b^2) @ 1/(a-b)-1/(a+b)}
q: `(p+q)/(p-q)` and `(p-q)/(p+q)`. {$ 4pq/(p^2-q^2) @ (p+q)/(p-q)-(p-q)/(p+q)}
q: `(n-1)/n` and `n/(n-1)`. {$ (1-2n)/(n^2-n) @ (n-1)/n-n/(n-1)}
q: `1/(1-x)` and `2/(1-x^2)`. {$ -1/(1+x) @ 1/(1-x)-2/(1-x^2)}
q: `1/((x+1)(x+2))` and `1/((x+1)(x+2)(x+3))`. {$ 1/((x+1)(x+3)) @ 1/((x+1)(x+2))-1/((x+1)(x+2)(x+3))}
q: `a/c` and `(ad-bc)x/(c(c+dx))`. {$ (a+bx)/(c+dx) @ a/c-(ad-bc)x/(c(c+dx))}
q: `(1/2)(3m+2n)/(3m-2n)` and `(1/2)(3m-2n)/(3m+2n)`. {$ 12mn/(9m^2-4n^2) @ (1/2)(3m+2n)/(3m-2n)-(1/2)(3m-2n)/(3m+2n)}
q: `(a+c)/((a-b)(x-a))` and `(b+c)/((a-b)(x-b))`. {$ (x+c)/((x-a)(x-b)) @ (a+c)/((a-b)(x-a))-(b+c)/((a-b)(x-b))}
q: Find the value of `(4m-3n)/(3(1-n))-(m+3n)/(3(1-n))+2n/(1-n)`. {$ m/(1-n) @ (4m-3n)/(3(1-n))-(m+3n)/(3(1-n))+2n/(1-n)}
q: Of `(a-b)/(ab)-(a-c)/(ac)+(b-c)/(bc)`. {$ 0 @ (a-b)/(ab)-(a-c)/(ac)+(b-c)/(bc)}
q: Of `(x+y)/y-x/(x+y)-(x^3-x^2y)/(x^2y-y^3)`. {1 @= (x+y)/y-x/(x+y)-(x^3-x^2y)/(x^2y-y^3)}
q: Of `1/(x-1)-1/(2(x+1))-(x+3)/(2(x^2+1))`. {$ (x+3)/(x^4-1) @ 1/(x-1)-1/(2(x+1))-(x+3)/(2(x^2+1))}
== 19 | Algebraic Fractions | Multiplication and division of fractions
art: 131 | Case VI: multiplication of fractions | Required to find the product of `a/b` by `c/d`. Here, as in arithmetic, we take the part of `a/b` which is expressed by `1/d`, and then multiply by `c`. Thus, the `1/d` part of `a/b` is `a/(bd)`, and `c` times `a/(bd)` is `ac/(bd)` (Art. 118). Or thus, `a/b` and `c/d` = `ab^-1` and `cd^-1` (Art. 81); multiplying, we have `ab^-1cd^-1=ac/(bd)`. Rule: multiply the numerators together for a new numerator, and the denominators together for a new denominator.
art: 131 | Remarks | 1st. To multiply a fraction by an integral quantity, reduce the latter to the form of a fraction, by writing unity beneath it; or, multiply the numerator by the integer. 2d. If either of the factors is a mixed quantity, reduce it to an improper fraction. 3d. When the numerators and denominators have common factors, let such factors be first separated, and then canceled. Thus, `2a^2/(a^2-b^2)*(a+b)^2/(4a^2b)=2a^2(a+b)(a+b)/((a+b)(a-b)4a^2b)=(a+b)/(2b(a-b))`.
q: Multiply `3x/4` by `4x/(3y)`. {$ x^2/y @ 3x/4*4x/(3y)}
q: Multiply `8a^2b/c` by `c^2d/(8a^3)`. {$ bcd/a @ 8a^2b/c*c^2d/(8a^3)}
q: Multiply `a-x^2/a` by `a/x+x/a`. {$ (a^4-x^4)/(a^2x) @ (a-x^2/a)(a/x+x/a)}
q: Multiply `1-(x-y)/(x+y)` by `2+2y/(x-y)`. {$ 4xy/(x^2-y^2) @ (1-(x-y)/(x+y))(2+2y/(x-y))}
q: Multiply `(1+a+a^2)/(1-b+b^2)` by `(1-a)/(1+b)`. {$ (1-a^3)/(1+b^3) @ (1+a+a^2)/(1-b+b^2)*(1-a)/(1+b)}
q: Multiply `(x^2+3x+2)/(x^2+2x+1)` by `(x^2+5x+4)/(x^2+7x+12)`. {$ (x+2)/(x+3) @ (x^2+3x+2)/(x^2+2x+1)*(x^2+5x+4)/(x^2+7x+12)}
q: Find the product of `4ax/(3by)`, `(a^2-x^2)/(c^2-x^2)`, and `(bc+bx)/(a^2-ax)`. {$ 4x(a+x)/(3y(c-x)) @ 4ax/(3by)*(a^2-x^2)/(c^2-x^2)*(bc+bx)/(a^2-ax)}
q: Of `(a^2-b^2)/(x+y)`, `(x^2-y^2)/(a-b)`, and `a^2/(x-y)^2`. {$ a^2(a+b)/(x-y) @ (a^2-b^2)/(x+y)*(x^2-y^2)/(a-b)*a^2/(x-y)^2}
q: Multiply `x+1+1/x` by `x-1+1/x`. {$ x^2+1+1/x^2 @ (x+1+1/x)(x-1+1/x)}
q: Multiply `4a/(3x)+3x/(2b)` by `2b/(3x)+3x/(4a)`. {$ 8ab/(9x^2)+2+9x^2/(8ab) @ (4a/(3x)+3x/(2b))(2b/(3x)+3x/(4a))}
q: Multiply `(pr+(pq+qr)x+q^2x^2)/(p-qx)` by `(ps+(pt-qs)x-qtx^2)/(p+qx)`. {$ rs+(rt+qs)x+qtx^2 @ (pr+(pq+qr)x+q^2x^2)/(p-qx)*(ps+(pt-qs)x-qtx^2)/(p+qx)}
q: Find the value of `(a/b+b/a)(c/d+d/c)-(a/b-b/a)(c/d-d/c)`. {$ 2bc/(ad)+2ad/(bc) @ (a/b+b/a)(c/d+d/c)-(a/b-b/a)(c/d-d/c)}
art: 132 | Case VII: division of fractions | Required to find the quotient of `a/b` by `c/d`. Here, as in arithmetic, the quotient of `a/b` by `1/d` is `ad/b`, and the quotient of `a/b` by `c` times `1/d`, or `c/d`, is `ad/b` divided by `c`, or `ad/(bc)`. Or thus, `a/b` and `c/d` = `ab^-1` and `cd^-1` (Art. 81). Dividing, we have `ab^-1/(cd^-1)=ad/(bc)`. Rule: invert the divisor, and proceed as in multiplication of fractions. To divide a fraction by an integral quantity, reduce the latter to the form of a fraction, by writing unity beneath it; or, multiply the denominator by the integer.
q: Required, in its simplest form, the quotient of `ab^2c^3/(x^2y)` divided by `a^3b^2c/(xy^2)`. {$ c^2y/(a^2x) @ (ab^2c^3/(x^2y))/(a^3b^2c/(xy^2))}
q: Of `(a+b)/(a+c)` divided by `(a-c)/(a-b)`. {$ (a^2-b^2)/(a^2-c^2) @ ((a+b)/(a+c))/((a-c)/(a-b))}
q: Of `(x^3-a^2x)/a^2` divided by `(ax-a^2)/x`. {$ (x^3+ax^2)/a^3 @ ((x^3-a^2x)/a^2)/((ax-a^2)/x)}
q: Of `(1+1/a)` divided by `(1-1/a^2)`. {$ a/(a-1) @ (1+1/a)/(1-1/a^2)}
q: Of `(x^3+y^3)/(x^2-y^2)` divided by `(x^2-xy+y^2)/(x-y)`. {$ 1 @ ((x^3+y^3)/(x^2-y^2))/((x^2-xy+y^2)/(x-y))}
q: Of `(a^4-x^4)/(a^2-2ax+x^2)` divided by `(a^2x+x^3)/(a^3-x^3)`. {$ ((a+x)/x)(a^2+ax+x^2) @ ((a^4-x^4)/(a^2-2ax+x^2))/((a^2x+x^3)/(a^3-x^3))}
q: Of `(1/(1+x)+x/(1-x))` divided by `(1/(1-x)-x/(1+x))`. {$ 1 @ (1/(1+x)+x/(1-x))/(1/(1-x)-x/(1+x))}
q: Of `3x/(2x-2)` divided by `2x/(x-1)`. {3/4 @= (3x/(2x-2))/(2x/(x-1))}
q: Of `(x+2x/(x-3))` divided by `(x-2x/(x-3))`. {$ (x-1)/(x-5) @ (x+2x/(x-3))/(x-2x/(x-3))}
q: Of `(x^4-1/x^4)` divided by `(x-1/x)`. {$ x^3+1/x^3+x+1/x @ (x^4-1/x^4)/(x-1/x)}
== 20 | Algebraic Fractions | Complex fractions; fractions into series
art: 133 | To reduce a complex fraction to a simple one | This is merely a case of division, in which the dividend and divisor are either fractions or mixed quantities. Thus, `(a+b/c)/(m-n/r)` is the same as to divide `a+b/c` by `m-n/r`: `(a+b/c)÷(m-n/r)=(ac+b)/c÷(mr-n)/r=(ac+b)/c*r/(mr-n)=(acr+br)/(cmr-cn)`. Or, the following method, obviously true, will generally be found more convenient: multiply both terms of the complex fraction by the product of the denominators, or by their L.C.M. Thus, in the above, multiplying by `cr`, we have, at once, `(acr+br)/(cmr-cn)`.
q: Reduce `(a+b/c)/(m-n/r)` to a simple fraction. {$ (acr+br)/(cmr-cn) @ (a+b/c)/(m-n/r)}
q: Reduce `(3x/(2x-2))/(2x/(x-1))`. {3/4 @= (3x/(2x-2))/(2x/(x-1))}
q: Reduce `(a/b+c/d)/(e/f-g/h)`. {$ fh(ad+bc)/(bd(eh-fg)) @ (a/b+c/d)/(e/f-g/h)}
q: Reduce `((a+1)/(a-1)+(a-1)/(a+1))/((a+1)/(a-1)-(a-1)/(a+1))`. {$ (a^2+1)/(2a) @ ((a+1)/(a-1)+(a-1)/(a+1))/((a+1)/(a-1)-(a-1)/(a+1))}
q: Reduce `(a+b+b^2/a)/(a+b+a^2/b)`. {$ b/a @ (a+b+b^2/a)/(a+b+a^2/b)}
art: 134 | Resolution of fractions into series | An Infinite Series consists of an unlimited number of terms which observe the same law. The Law of a Series is a relation existing between its terms, such that when some of them are known the others may be found. Thus, in the infinite series `1-1/x+1/x^2-1/x^3+`, etc., any term may be found by multiplying the preceding term by `-1/x`. Any proper algebraic fraction, whose denominator is a polynomial, may, by division, be resolved into an infinite series.
art: 134 | Example | Convert the fraction `(1-x)/(1+x)` into an infinite series. Dividing `1-x` by `1+x`, the quotient is `1-2x+2x^2-2x^3+`, etc. It is evident that the law of this series is, that each term, after the second, is equal to the preceding term multiplied by `-x`.
q: Convert `(1-x)/(1+x)` into an infinite series: type its first 4 terms, one at a time. {list: 1, -2x, 2x^2, -2x^3}
q: Resolve `1/(1+r^2)` into an infinite series: its first 5 terms. {list: 1, -r^2, r^4, -r^6, r^8}
q: Resolve `1/(1-r+r^2)` into an infinite series: its first 6 terms. {list: 1, r, -r^3, -r^4, r^6, r^7}
q: Resolve `a/(a+b)` into an infinite series: its first 4 terms. {list: 1, -b/a, b^2/a^2, -b^3/a^3}
mc: In the series `1-2x+2x^2-2x^3+`, etc., each term after the second is the preceding term multiplied by... | *`-x` | `x` | `-2x`
== 21 | Algebraic Fractions | Miscellaneous propositions and exercises
art: 135 | Miscellaneous Propositions in Fractions | The answer to some general question, that is, the solution to a literal equation, may happen to be a fraction: e.g., we may have `x=a/b`. When the two terms of the fraction are finite numbers, the fraction, being the ratio of two finite numbers, has a determinate value. But the values of the numerator and denominator may be changed, by reason of some suppositions as to the values of the known numbers involved in the question, thus giving rise to anomalous results requiring explanation.
art: 136 | | 1. Thus, suppose `x=a/b`. If, while the denominator remains constant, the numerator changes, the value of the fraction varies directly with the numerator: if `a` decreases, the fraction decreases; if `a` becomes 0, the fraction likewise becomes 0, that is, `0/b=0`. Also, if `a` increases, `b` being constant, the fraction increases; if `a` becomes ∞, the fraction becomes ∞. 2. If the denominator changes while the numerator remains constant, the value of the fraction varies inversely; that is, if `b` decreases, the value of the fraction increases, and, vice versa, if `b` increases, the value of the fraction decreases; if `b` becomes 0, the fraction becomes ∞, or `a/0=∞`; if, on the other hand, `b` becomes ∞, the fraction becomes 0.
art: 137 | | If the numerator and denominator are both rendered zero simultaneously, the solution assumes the form `x=0/0`. In this case, the unknown number `x` is said to be indeterminate, inasmuch as it may evidently, at this stage of the investigation, have any value whatever; since the only condition imposed upon it is, that it shall give, when multiplied by zero, a product equal to zero. Hence, the form `0/0` has been called the symbol of indetermination. Nevertheless, it may, and indeed generally does, happen that the indetermination is only apparent, being due to the presence, in numerator and denominator, of a common factor which the particular hypothesis reduces to zero, and which if suppressed before making the hypothesis, will leave the result in a determinate form.
art: 137 | | Thus, suppose some equation has given us `x=(a^2-b^2)/(a-b)`: if we make `b=a`, we have `x=0/0`; if, however, we cancel the common factor `a-b`, and then make `b=a`, we have `x=2a`. So, if `x=(a^2-1)/(a^2+a-2)`: for `a=1`, we have `x=0/0`; but cancelling the common factor `a-1` before making `a=1`, gives `x=2/3`. These considerations show that it is not safe to assume the symbol `0/0` as indicating absolute indetermination, until we have ascertained whether the result has not been caused by the presence of a common factor which becomes zero under the particular supposition imposed. Finally, all of these symbols are to be interpreted as mere abbreviations; otherwise, they are without meaning.
mc: In `x=a/b`, if `b` becomes 0 while `a` stays the same, the fraction becomes... | *∞ | 0 | 1
mc: The form `0/0` is called the symbol of... | *indetermination | infinity | impossibility
q: If `x=(a^2-1)/(a^2+a-2)`, what is `x` when `a=1`, after canceling the common factor? {2/3 @= (1+1)/(1+2)}
q: If `x=(a^2-b^2)/(a-b)`, what is `x` when `b=a`, after canceling the common factor? {$ 2a @ a+a}
art: 138 | Theorem | If the same quantity be added to both terms of a proper fraction, the new fraction resulting will be greater than the first; but if the same quantity be added to both terms of an improper fraction, the new fraction resulting will be less than the first. Let `m` represent the quantity to be added to each term of any fraction, as `a/b`; then, the resulting fraction is `(a+m)/(b+m)`. Reducing `a/b` and `(a+m)/(b+m)` to a common denominator, we have `(ab+am)/(b^2+bm)` and `(ab+bm)/(b^2+bm)`. Since the denominators are the same, that fraction which has the greater numerator is the greater. Now, if `a/b` is a proper fraction, or if `a` is less than `b`, the second fraction is obviously greater; but if it is improper, and `a` greater than `b`, the second is less than the first.
art: 139 | Theorem | If the same quantity be subtracted from both terms of a proper fraction, the new fraction resulting will be less than the first; but if the same quantity be subtracted from both terms of an improper fraction, the new fraction resulting will be greater than the first. Reducing `a/b` and `(a-m)/(b-m)` to a common denominator, we have `(ab-am)/(b^2-bm)` and `(ab-bm)/(b^2-bm)`. Reasoning as in the preceding theorem, when the original fraction is proper, the second fraction is evidently less than the first; when improper, it is greater.
tf: Adding the same number to both terms of `3/4` gives a greater fraction. {T}
tf: Adding the same number to both terms of `5/4` gives a greater fraction. {F}
tf: Subtracting the same number from both terms of a proper fraction gives a greater fraction. {F}
art: 139 | Miscellaneous Exercises | 1. Prove that `x/(x-3)-(x-3)/x+x/(x+3)-(x+3)/x=18/(x^2-9)`. 2. Prove that `(a^2+a+1)/((a-b)(a-c))+(b^2+b+1)/((b-a)(b-c))+(c^2+c+1)/((c-a)(c-b))=1`. 5. Prove that the sum or difference of any two quantities, divided by their product, is equal to the sum or difference of their reciprocals. 6. If `(a^2+h^2)/((a-b)(a-c))+(b^2+h^2)/((b-a)(b-c))+(c^2+h^2)/((c-a)(c-b))=1`, prove that when the terms are multiplied respectively by `b+c`, `a+c`, and `a+b`, the sum is 0; and that when multiplied respectively by `bc`, `ac`, and `ab`, it is `h^2`.
tf: `x/(x-3)-(x-3)/x+x/(x+3)-(x+3)/x=18/(x^2-9)` for every value of `x`. {T}
tf: `(a+b)/(ab)=1/a+1/b`. {T}
q: Find the value of `(x+2x/(x-3))÷(x-2x/(x-3))`, when `x=5 1/2`. {9 @= (5.5+11/2.5)/(5.5-11/2.5)}
q: Find the value of `(x+2a)/(x-2a)+(x+2b)/(x-2b)`, when `x=4ab/(a+b)`. {$ 2 @ (4ab/(a+b)+2a)/(4ab/(a+b)-2a)+(4ab/(a+b)+2b)/(4ab/(a+b)-2b)}
== 22 | Simple Equations | Definitions and elementary principles
art: 140 | An Equation | An Equation is an algebraic expression, stating the equality between two quantities. Thus, `x-5=3` is an equation, stating that if 5 be subtracted from `x`, the remainder will be 3.
art: 141 | Members | Every equation is composed of two parts, separated from each other by the sign of equality. The First Member of an equation is the quantity on the left of the sign of equality. The Second Member is the quantity on the right of the sign of equality. Each member of an equation is composed of one or more terms.
art: 142 | Known and unknown quantities | There are generally two classes of quantities in an equation, the known and the unknown. The Known Quantities are represented either by numbers or the first letters of the alphabet; as, `a`, `b`, `c`, etc. The Unknown Quantities are represented by the last letters of the alphabet; as, `x`, `y`, `z`, etc.
art: 143 | Degree | Equations are divided into degrees, called first, second, third, and so on. The Degree of an equation depends on the highest power of the unknown quantity which it contains. A Simple Equation, or an equation of the first degree, is one that contains no power of the unknown quantity higher than the first. A Quadratic Equation, or an equation of the second degree, is one in which the highest power of the unknown quantity is a square. Similarly, we have equations of the third degree, fourth degree, and so on. Those of the third degree are generally called cubic equations; and those of the fourth degree, biquadratic equations. Thus, `ax-b=c` is of the 1st degree; `x^2+2px=q`, of the 2d, or quadratic; `x^3-px=q`, of the 3d, or cubic; `x^4+ax^3+px=q`, of the 4th, or biquadratic.
art: 143 | | When any equation contains more than one unknown quantity, its degree is equal to the greatest sum of the exponents of the unknown quantity, in any of its terms. Thus, `xy+ax-by=c` is an equation of the 2d degree; `x^2y+x^2-cx=a`, of the 3d degree.
art: 144 | Complete and incomplete | A Complete Equation of any degree is one that contains all the powers of the unknown quantity, from 0 up to the given degree. An Incomplete Equation is one in which one or more terms are wanting. Thus, `x^2+px+q=0` is a complete equation of the second degree, the term `q` being equivalent to `qx^0`, since `x^0=1`. `x^3+px^2+qx+r=0` is a complete equation of the third degree. `ax^2=q` is an incomplete equation of the second degree; `x^3+px=q` is an incomplete equation of the third degree.
art: 145 | An Identical Equation | An Identical Equation is one in which the two members are identical; or, one in which one of the members is the result of the operations indicated in the other. Thus, `ax-b=ax-b`, `8x-3x=5x`, `(x+3)(x-3)=x^2-9` are identical equations. Equations are also distinguished as numerical and literal. A Numerical Equation is one in which all the known quantities are expressed by numbers; as, `2x^2+3x=10x+15`. A Literal Equation is one in which the known quantities are represented by letters, or by letters and numbers; as, `ax+b=cx+d`, and `ax+b=3x+5`.
art: 146 | To solve an equation | Every equation may be regarded as the statement, in algebraic language, of a particular question. Thus, `x-5=9` may be regarded as the statement of the following question: to find a number from which, if 5 be subtracted, the remainder shall be 9. To Solve an Equation is to find the value of the unknown quantity. An equation is said to be verified when the value of the unknown quantity, being substituted for it, the two members are rendered equal to each other. Thus, in the equation `x-5=9`, if 14, which is the true value of `x`, be substituted instead of it, we have `14-5=9`, or `9=9`.
art: 147 | The root | The value of the unknown quantity, in any equation, is called the root of that equation.
art: 148 | Axioms | All the rules employed in the solution of equations are founded on this evident principle: if we perform the same operation on two equal quantities, the results will be equal. 1. If, to two equal quantities, the same quantity be added, the sums will be equal. 2. If, from two equal quantities, the same quantity be subtracted, the remainders will be equal. 3. If two equal quantities be multiplied by the same quantity, the products will be equal. 4. If two equal quantities be divided by the same quantity, the quotients will be equal. 5. If two equal quantities be raised to the same power, the results will be equal. 6. If the same root of two equal quantities be extracted, the results will be equal.
art: 149 | | There are two operations of constant use in the solution of equations. These are Transposition, and Clearing an Equation of Fractions.
mc: The quantity on the left of the sign of equality is called the... | *first member | second member | root
mc: `x^3-px=q` is an equation of the... | *third degree, or cubic | second degree | first degree
mc: `xy+ax-by=c` is an equation of the... | *second degree | first degree | third degree
mc: `ax^2=q` is... | *an incomplete equation of the second degree | a complete equation of the second degree | a simple equation
mc: `(x+3)(x-3)=x^2-9` is... | *an identical equation | a simple equation | an incomplete equation
mc: `ax+b=cx+d` is... | *a literal equation | a numerical equation | an identical equation
mc: The value of the unknown quantity in an equation is called its... | *root | member | degree
mc: An equation of the fourth degree is called... | *biquadratic | cubic | quadratic
q: Verify `x-5=9`: what is the root? {14 @x: x-5=9}
tf: If two equal quantities be divided by the same quantity, the quotients will be equal. {T}
== 23 | Simple Equations | Transposition; clearing of fractions
art: 150 | Transposition | Suppose we have the equation `x-b=c`. By Axiom 1, we may add any quantity to both members of this equation without destroying the equality. Adding `b` to both sides, we have `x-b+b=c+b`; or, `x=c+b`, since `-b+b=0`. Comparing this result with the original equation, we find that it is the same as if we had removed the term `b` to the other side of the equation, with its sign changed. Again, take the equation `x+b=c`. Subtracting `b` from both sides, `x+b-b=c-b`; or, `x=c-b`. Rule of Transposition: any quantity may be transposed from one side of an equation to the other, if, at the same time, its sign be changed.
art: 151 | To Clear an Equation of Fractions | Let it be required to clear `x/(ab)-x/(bc)=d` of fractions. Since, by Ax. 3, we may multiply both members by any quantity without destroying the equality, we first multiply by `ab`, the denominator of the first fraction. This gives `x-abx/(bc)=abd`. Multiplying both members again by `bc`, we have `bcx-abx=ab^2cd` (1). Dividing both members by `b`, `cx-ax=abcd` (2). If, instead of multiplying successively by `ab` and `bc`, we had, at once, multiplied by `ab*bc`, or `ab^2c`, we would have obtained the form (1) by one operation. By multiplying both members by `abc`, the L.C.M. of the denominators, we would have obtained the reduced form (2). Of these three methods, the third is the most simple.
art: 151 | Rule for Clearing an Equation of Fractions | Find the L.C.M. of all the denominators, and multiply each term of the equation by it. When a fraction, whose denominator is to be removed, is preceded by a minus sign, the signs of all the terms in the numerator must be changed. See Art. 46, 2d. Thus, `2x-(x-3)/5=(x-3)/2` gives `20x-(2x-6)=5x-15`, or `20x-2x+6=5x-15`.
mc: Transposing `b` in `x+b=c` gives... | *`x=c-b` | `x=c+b` | `x=b-c`
mc: To clear an equation of fractions in the simplest way, multiply each term by... | *the L.C.M. of the denominators | the product of the denominators | the first denominator
art: 151 | Exercises | Clear the following equations of fractions. The cleared equations of the book are: 2. `4x-3x=12`. 3. `3x+2x=60`. 4. `6x-3x+2x=84`. 5. `20x-2x+6=5x-15`. 6. `12x-3x+6=60-2x-4`. 7. `cx+a^2x-b^2x=abcm`. 8. `ax-a^2-bx+ab-ax+a^2-bx+ab=2nb`.
q: To clear `x/3-x/4=1` of fractions, multiply each term by... {$ 12 @lcm: 3; 4}
q: Clear `x/3-x/4=1` of fractions. {$ 4x-3x=12 @ x/3-x/4=1}
q: To clear `x/4+x/6=5`, multiply by... {$ 12 @lcm: 4; 6}
q: Clear it of fractions. {$ 3x+2x=60 @ x/4+x/6=5}
q: To clear `x/4-x/8+x/12=3 1/2`, multiply by... {$ 24 @lcm: 4; 8; 12; 2}
q: Clear it of fractions. {$ 6x-3x+2x=84 @ x/4-x/8+x/12=7/2}
q: To clear `2x-(x-3)/5=(x-3)/2`, multiply by... {$ 10 @lcm: 5; 2}
q: Clear it of fractions. {$ 20x-2x+6=5x-15 @ 2x-(x-3)/5=(x-3)/2}
q: To clear `x-(x-2)/4=5-(x+2)/6`, multiply by... {$ 12 @lcm: 4; 6}
q: Clear it of fractions. {$ 12x-3x+6=60-2x-4 @ x-(x-2)/4=5-(x+2)/6}
q: To clear `x/(ab)+ax/(bc)-bx/(ac)=m`, multiply by... {$ abc @lcm: ab; bc; ac}
q: Clear it of fractions. {$ cx+a^2x-b^2x=abcm @ x/(ab)+a*x/(bc)-b*x/(ac)=m}
q: To clear `(x-a)/(a+b)-(x-a)/(a-b)=2nb/(a^2-b^2)`, multiply by... {$ a^2-b^2 @lcm: a+b; a-b; a^2-b^2}
q: Clear it of fractions. {$ ax-a^2-bx+ab-ax+a^2-bx+ab=2nb @ (x-a)/(a+b)-(x-a)/(a-b)=2n*b/(a^2-b^2)}
== 24 | Simple Equations | Solution of simple equations
art: 152 | Solving | The unknown quantity in an equation may be combined with the known quantities, either by addition, subtraction, multiplication, or division; or by two or more of these different methods. 1. In `a+x=b`, the unknown quantity is connected by addition. By subtracting `a` from each side, `x=b-a`. 2. In `x-a=b`, by adding `a` to each side, `x=b+a`. 3. In `ax=b`, by dividing each side by `a`, `x=b/a`. 4. In `x/a=b`, by multiplying each side by `a`, `x=ab`. When the unknown quantity is connected by addition, it is to be separated by subtraction; when connected by subtraction, it is separated by addition; when connected by multiplication, by division; when connected by division, by multiplication.
art: 152 | Example 5 | Find the value of `x` in `3x-(24-2x)/7=x+8`. Clearing of fractions, `21x-(24-2x)=7x+56`, or `21x-24+2x=7x+56`. Transposing, `21x+2x-7x=56+24`; reducing, `16x=80`; dividing by 16, `x=5`. In this solution there are three steps: 1st. Clearing the equation of fractions; 2d. Transposition; and 3d. Reducing like terms, and dividing by the coefficient of `x`. Let the value of `x` be substituted instead of `x` in the original equation, and, if it is the true value, the two members will be equal to each other. This is called verification: `3*5-(24-2*5)/7=5+8`; or, `15-2=5+8`; or, `13=13`.
art: 152 | Example 6 | Find the value of `x` in `x-(x+a)/(ab)=d+x/(bc)`. 1st step, `abcx-cx-ac=abcd+ax`. 2d step, `abcx-cx-ax=abcd+ac`. Factoring, `(abc-c-a)x=ac(bd+1)`. 3d step, `x=ac(bd+1)/(abc-c-a)`.
art: 153 | Rule for the Solution of a Simple Equation | 1. If necessary, clear the equation of fractions, and perform all the operations indicated. 2. Transpose all the terms containing the unknown quantity to one side, and the known quantities to the other. 3. Reduce each member to its simplest form. 4. Divide both sides by the coefficient of the unknown quantity.
mc: When the unknown quantity is connected by multiplication, it is separated by... | *division | multiplication | addition
q: Find `x` in `a+x=b`. {$ b-a @x: a+x=b}
q: Find `x` in `x/a=b`. {$ ab @x: x/a=b}
q: Find `x` in `3x-(24-2x)/7=x+8`. {5 @x: 3x-(24-2x)/7=x+8}
q: Find `x` in `x-(x+a)/(ab)=d+x/(bc)`. {$ ac(bd+1)/(abc-c-a) @x: x-(x+a)/(ab)=d+x/(bc)}
art: 153 | Exercises | Find the value of the unknown quantity in the following. Example 7: `(3x+7)/14-(2x-7)/21+2 3/4=(x-4)/4`. 1st step, `18x+42-8x+28+231=21x-84`; 2d step, `18x-8x-21x=-231-42-28-84`; 3d step, `-11x=-385`, `x=35`.
q: `(3x+7)/14-(2x-7)/21+2 3/4=(x-4)/4` {35 @x: (3x+7)/14-(2x-7)/21+11/4=(x-4)/4}
q: `5(x+1)-2=3(x+5)` {6 @x: 5(x+1)-2=3(x+5)}
q: `3(x-2)+4=4(3-x)` {2 @x: 3(x-2)+4=4(3-x)}
q: `5-3(4-x)+4(3-2x)=0` {1 @x: 5-3(4-x)+4(3-2x)=0}
q: `x/2+x/3=x/4+7` {12 @x: x/2+x/3=x/4+7}
q: `x/2+x/3-x/4+x/5=7 5/6` {10 @x: x/2+x/3-x/4+x/5=7+5/6}
q: `1/x+1/(2x)-1/(3x)=7/3` {1/2 @x: 1/x+1/(2x)-1/(3x)=7/3}
q: `(3x+1)/2-2x/3=10+(x-1)/6` {14 @x: (3x+1)/2-2x/3=10+(x-1)/6}
q: `(x-7 1/2)/2=(3x-9)/4+(27-5x)/3` {7 7/17 @x: (x-15/2)/2=(3x-9)/4+(27-5x)/3}
q: `5x-(2x-1)/3+1=3x+(x+2)/2+7` {8 @x: 5x-(2x-1)/3+1=3x+(x+2)/2+7}
q: `(7x+9)/8-(3x+1)/7=(9x-13)/4-(249-9x)/14` {9 @x: (7x+9)/8-(3x+1)/7=(9x-13)/4-(249-9x)/14}
q: `(1/3)(2x-10)-(1/11)(3x-40)=15-(1/5)(57-x)` {17 @x: (1/3)(2x-10)-(1/11)(3x-40)=15-(1/5)(57-x)}
q: `(1/4)(4+(3/2)x)-(1/7)(2x-1/3)=31/28` {2/3 @x: (1/4)(4+(3/2)x)-(1/7)(2x-1/3)=31/28}
q: `3 1/3*(28-(x/8+24))=3 1/2*(2 1/3+x/4)` {4 @x: (10/3)(28-(x/8+24))=(7/2)(7/3+x/4)}
q: `(1/2)(x-51/26)-(2/13)(1-3x)=x-(1/39)(5x-(1-.3x)/.4)` {11 @x: (1/2)(x-51/26)-(2/13)(1-3x)=x-(1/39)(5x-(1-0.3x)/0.4)}
art: 153 | Compound denominators | When one or more of the denominators is a compound quantity, as in the two following examples, it is generally best to multiply all the terms by the L.C.M. of the other denominators, collect the terms, and proceed as before.
q: `(9x+3)/27+(3x-6)/(2x-5)=2/3+(3x+22)/9` {3 @x: (9x+3)/27+(3x-6)/(2x-5)=2/3+(3x+22)/9}
q: `(3x-1)/(x+2)+(6+x)/4-(3x-9)/12=2 1/4+(3x+9)/(x+7)` {5 @x: (3x-1)/(x+2)+(6+x)/4-(3x-9)/12=9/4+(3x+9)/(x+7)}
q: `bx+2x-a=3x-2c` {$ (a-2c)/(b-1) @x: bx+2x-a=3x-2c}
q: `a^2x+b^3=b^2x+a^3` {$ (a^2+ab+b^2)/(a+b) @x: a^2x+b^3=b^2x+a^3}
q: `ax+b^2=a^2+bx` {$ a+b @x: ax+b^2=a^2+bx}
q: `bx/a-d/c=a/b-cx/d` {$ ad/(bc) @x: bx/a-d/c=a/b-cx/d}
q: `(a-b)/(x-c)=(a+b)/(x+2c)` {$ (c/(2b))(3a-b) @x: (a-b)/(x-c)=(a+b)/(x+2c)}
q: `x/a-1-dx/c+3ab=0` {$ ac(1-3ab)/(c-ad) @x: x/a-1-dx/c+3ab=0}
q: `(1/3)(x-a)-(1/5)(2x-3b)-(1/2)(a-x)=10a+11b` {$ 25a+24b @x: (1/3)(x-a)-(1/5)(2x-3b)-(1/2)(a-x)=10a+11b}
q: `1/(ab-ax)+1/(bc-bx)=1/(ac-ax)` {$ b(a-b+c)/a @x: 1/(ab-ax)+1/(bc-bx)=1/(ac-ax)}
== 25 | Simple Equations | Questions producing simple equations, part 1
art: 154 | Problems | The solution of a problem by algebra consists of two distinct parts: 1st. Expressing the conditions of the problem in algebraic language; that is, forming the equation. 2d. Solving the equation; that is, finding the value of the unknown quantity. Sometimes the proposed problem furnishes the equation directly; and sometimes it is necessary, from the conditions given, to deduce others, from which to form it. In the one case, the conditions are said to be explicit; in the other, implied. It is impossible to give a precise rule by means of which every question may be readily stated in the form of an equation. The first step is, to understand fully the nature of the question. After this, the equation may generally be formed by the following Rule: denote the required quantity by one of the final letters of the alphabet; then, by means of signs, indicate the same operations that it would be necessary to perform with the answer, to verify it.
mc: Conditions that must be deduced from the question are called... | *implied | explicit | identical
mc: Forming the equation means... | *expressing the conditions of the problem in algebraic language | finding the value of the unknown quantity | verifying the answer
q: Find two numbers such, that their sum shall be 50, and their difference 12. The less is {19 @x: x+x+12=50} the greater {31 @= 19+12}
sol: Let x denote the least of the two required numbers. Then x + 12 = the greater, and x + x + 12 = 50. Transposing, x + x = 50 - 12; reducing, 2x = 38; x = 19, the less number; and x + 12 = 31, the greater. Verification: 31 + 19 = 50, and 31 - 19 = 12.
q: What number is that whose 1/3 exceeds its 1/5 by 6? {45 @x: x/3-x/5=6}
sol: Let x = the required number. Then x/3 - x/5 = 6. Clearing, 5x - 3x = 90; reducing, 2x = 90; x = 45. Verification: 1/3 of 45 = 15, 1/5 of 45 = 9; 15 - 9 = 6.
q: A can perform a piece of work in 6 days, and B in 8 days; in what time will both together finish it? (days) {3 3/7 @x: 1/6+1/8=1/x}
sol: Since A can perform the work in 6 days, he will perform 1/6 of it in one day; reasoning the same way with B, and since 1/x will represent the part of the work which both perform in one day, 1/6 + 1/8 = 1/x. Then 8x + 6x = 48; x = 3 3/7 days.
q: Divide $500 among A, B, and C, so that B shall have $20 more than A, and C $75 more than A. A's share is {135 @x: x+x+20+x+75=500} B's {155 @= 135+20} C's {210 @= 135+75}
sol: Let x = A's share; x + 20 = B's; and x + 75 = C's. Then x + x + 20 + x + 75 = 500. Reducing, 3x + 95 = 500; 3x = 405; x = 135.
q: A person in play lost a fourth of his money, and then won back $3; after which he lost a third of what he now had, and then won back $2; lastly, he lost a seventh of what he then had, and after this found he had but $12 remaining; what had he at first? (dollars) {20 @x: (6/7)((2/3)((3/4)x+3)+2)=12}
sol: Let x = money he had at first. After the 1st game he had 3x/4 + 3; after the 2d, x/2 + 4; after the 3d, 3x/7 + 24/7 = 12; from which x = $20.
q: Out of a cask of wine which had leaked away 1/5, 35 gallons were drawn, and then, being gauged, it was 1/3 full; how much did it hold? (gallons) {75 @x: x-(x/5+35)=x/3}
q: A laborer was engaged for 20 days. For each day that he worked, he received 50 cents and his boarding; and for each day that he was idle, he paid 25 cents for his boarding. At the expiration of the time, he received $4; how many days did he work? {12 @x: 50x-25(20-x)=400} How many days was he idle? {8 @= 20-12}
q: What two numbers are as 3 to 5, to each of which, if 9 be added, the sums shall be to each other as 6 to 7? {3 @x: 7(x+9)=6(5x/3+9)} and {5 @= 5*3/3}
art: 154 | Ratios | When, as in the above example, two or more unknown quantities have to each other a given ratio, assume each of them a multiple of some other unknown quantity, so that they shall have to each other the given ratio. Thus, let `3x` = the first, and `5x` = the second number. Then, `3x+9:5x+9::6:7`; and in every proportion, the product of the means is equal to the product of the extremes; hence, `6(5x+9)=7(3x+9)`.
q: A courier, who traveled at the rate of 31 1/2 miles in 5 hours, was dispatched from a certain city; 8 hours after his departure, another courier was sent to overtake him, who traveled at the rate of 22 1/2 miles in 3 hours. In what time did he overtake the first? (hours) {42 @x: 45x/6=(8+x)*63/10} At what distance from the place of departure? (miles) {315 @= 45*42/6}
q: A smuggler had a quantity of brandy, which he expected would sell for 198 shillings; after he had sold 10 gallons, a revenue officer seized one third of the remainder, in consequence of which, what he sold brought him only 162 shillings. Required the number of gallons he had. {22 @x: ((x-10)/3)*(198/x)=36} and the price per gallon (shillings). {9 @= 198/22}
q: There are three numbers whose sum is 133; the second is twice the first, and the third twice the second. Required the numbers. {19 @x: x+2x+4x=133}, {38 @= 2*19}, and {76 @= 4*19}
q: There are three numbers whose sum is 187; the second is 3 times, and the third 4 1/2 times, the first. Required the numbers. {22 @x: x+3x+4.5x=187}, {66 @= 3*22}, and {99 @= 4.5*22}
q: There are two numbers, of which the first is 3 1/2 times the second, and their difference is 100. Required the numbers. The second is {40 @x: 3.5x-x=100} the first {140 @= 3.5*40}
q: Two numbers are to each other as 3 to 7; if 16 be added to the first and subtracted from the second, the sum will be to the difference as 7 to 3. What are the numbers? {12 @x: 3(x+16)=7(7x/3-16)} and {28 @= 7*12/3}
== 26 | Simple Equations | Questions producing simple equations, part 2
q: What two numbers are to each other as 2 to 3, to each of which if 6 be added the sums will be as 4 to 5? {6 @x: 5(x+6)=4(3x/2+6)} and {9 @= 3*6/2}
q: A person, at the time of his marriage, was three times as old as his wife, but 15 years after he was only twice as old. What were their ages on their wedding day? The man {45 @x: x+15=2(x/3+15)} the wife {15 @= 45/3}
q: A bill of $34 was paid in half dollars and dimes, and the number of pieces of both sorts was 100; how many were there of each? Half dollars {60 @x: 50x+10(100-x)=3400} dimes {40 @= 100-60}
q: There are three numbers whose sum is 156; the second is 3 1/2 times the first, and the third is equal to the remainder left, after subtracting the difference of the first and second from 100. Required the numbers. {28 @x: x+3.5x+100-2.5x=156}, {98 @= 3.5*28}, and {30 @= 100-2.5*28}
q: What number is that, whose half, third, and fourth parts, taken together, are equal to 52? {48 @x: x/2+x/3+x/4=52}
q: What number is that, which being increased by its six sevenths, and diminished by 20, shall be equal to 45? {35 @x: x+6x/7-20=45}
q: What number is that, to which if its third and fourth parts be added, the sum will exceed its sixth part by 51? {36 @x: x+x/3+x/4-x/6=51}
q: Find a number, which, being multiplied by 4, becomes as much above 40 as it is now below it. {16 @x: 4x-40=40-x}
q: What number is that, to which if 16 be added, 4 times the sum will be equal to 10 times the number increased by 1? {9 @x: 4(x+16)=10(x+1)}
q: If a certain number be multiplied by 4, and 20 be added to the product the sum will be 32. What is the number? {3 @x: 4x+20=32}
q: If 5 be subtracted from three fourths of a certain number the remainder will be equal to the number divided by 3. Required the number. {12 @x: 3x/4-5=x/3}
q: The rent of an estate is greater by 8 % than it was last year. The rent this year is $1890. What was it last year? (dollars) {1750 @x: x+8x/100=1890}
art: 154 | Interest | Observe that the interest on any sum of money is found by multiplying the principal by the rate per cent., and dividing by 100.
q: An estate is divided as follows: the eldest child receives one fourth, the second 20 %, and the third 15 % of the whole. The remainder, which is $2168, is given to the widow. Required the value of the estate. {5420 @x: x-x/4-20x/100-15x/100=2168} The share of each child: {1355 @= 5420/4}, {1084 @= 5420*20/100}, and {813 @= 5420*15/100}
q: The sum of two numbers is 30; and if the less be subtracted from the greater, one fourth of the remainder will be 3. Required the numbers. The less {9 @x: ((30-x)-x)/4=3} the greater {21 @= 30-9}
q: A laborer was engaged for 28 days, upon the condition that for every day he worked he was to receive 75 cents, and for every day he was absent, he was to forfeit 25 cents. At the end of his time he received $12. How many days did he work? {19 @x: 75x-25(28-x)=1200}
q: At what time between two and three o'clock will the hour and minute hands of a watch be together? (minutes after 2) {10 10/11 @x: x=12(x-10)}
sol: The face of a watch is divided into 60 minute spaces, and the minute hand moves twelve times as fast as the hour hand. Let x = the distance from XII to the point of meeting, which is also the number of minutes after 2 when the hands are together. Then x - 10 = the distance the hour hand has gone after 2 o'clock; x = 12(x - 10) = 12x - 120; 11x = 120; x = 10 10/11 min., or the hands are together 10 min. 54 6/11 sec. after 2 o'clock.
q: The hour and minute hand of a clock are together at noon; when are they next together? (minutes after 1 o'clock) {5 5/11 @x: x=5+x/12}
q: At what time between 8 and 9 o'clock are the hour and minute hands of a watch opposite to each other? (minutes after 8) {10 10/11 @x: 40+x/12-x=30}
q: A has three times as much money as B, but if B give A $50, then A will have four times as much as B. Find the money of each. A {750 @x: x+50=4(x/3-50)} B {250 @= 750/3}
q: From a bag of money which contained a certain sum, there was taken $20 more than its half; from the remainder, $30 more than its third part; and from the remainder, $40 more than its fourth part, and then there was nothing left. What sum did it contain? (dollars) {290 @x: (3/4)((2/3)(x/2-20)-30)-40=0}
q: A merchant gains the first year, 15 % on his capital; the second year, 20 % on the capital at the close of the first; and the third year, 25 % on the capital at the close of the second; when he finds that he has cleared $1000.50. Required his capital. (dollars) {1380 @x: x*1.15*1.2*1.25-x=1000.5}
q: A is twice as old as B; 22 years ago, he was three times as old. What is A's age? {88 @x: x-22=3(x/2-22)}
q: A person buys 4 houses; for the second, he gives half as much again as for the first; for the third, half as much again as for the second; and for the fourth, as much as for the first and third together: he pays $8000 for them all. Required the cost of each. {1000 @x: x+1.5x+2.25x+3.25x=8000}, {1500 @= 1.5*1000}, {2250 @= 2.25*1000}, and {3250 @= 3.25*1000}
q: A cistern is filled in 24 minutes by 3 pipes, the first of which conveys 8 gallons more, and the second 7 gallons less, than the third every 3 minutes. The cistern holds 1050 gallons. How much flows through each pipe in a minute? (gallons) {17 5/36 @x: 24(x+(x-5)+(x-8/3))=1050}, {12 5/36 @= 17+5/36-5}, and {14 17/36 @= 17+5/36-8/3}
q: A can do a piece of work in 3 days, B in 6 days, and C in 9 days. Find the time in which all together can perform it. (days) {1 7/11 @x: 1/3+1/6+1/9=1/x}
q: If A does a piece of work in 10 days, which A and B can do together in 7 days, how long would it take B to do it alone? (days) {23 1/3 @x: 1/10+1/x=1/7}
q: A performs 2/7 of a piece of work in 4 days; he then receives the assistance of B, and the two together finish it in 6 days. Required the time in which each can do it alone. A {14 @x: 4/x=2/7} B {21 @x: 6(1/14+1/x)=5/7}
q: A person bought an equal number of sheep, cows, and oxen, for $330; each sheep cost $3, each cow $12, and each ox $18. Required the number of each. {10 @x: 3x+12x+18x=330}
q: A sum of money is to be divided among five persons, A, B, C, D, and E. B received $10 less than A; C, $16 more than B; D, $5 less than C; E, $15 more than D; and the shares of the last two are equal to the sum of the shares of the other three. Required the share of each. A {21 @x: (x+1)+(x+16)=x+(x-10)+(x+6)} B {11 @= 21-10} C {27 @= 11+16} D {22 @= 27-5} E {37 @= 22+15}
q: A bought eggs at 18 cts. a dozen, but had he bought 5 more for the same money, they would have cost him 2 1/2 cts. a dozen less. How many did he buy? {31 @x: 18x=(x+5)*15.5}
q: A person bought a number of sheep for $94; having lost 7 of them, he sold 1/4 of the remainder at prime cost, for $20. How many had he at first? {47 @x: ((x-7)/4)*(94/x)=20}
q: There are two places, 154 miles distant from each other, from which two persons, A and B, set out at the same instant, to meet on the road. A travels at the rate of 3 mi. in 2 hr., and B at the rate of 5 mi. in 4 hr. How long did each travel before they met? (hours) {56 @x: 3x/2+5x/4=154} How far did A travel? {84 @= 3*56/2} B? {70 @= 5*56/4}
q: A person bought a chaise, horse, and harness, for $450; the horse came to twice the price of the harness, and the chaise to twice the price of the horse and harness. What was the cost of each? Chaise {300 @= 6*50} horse {100 @= 2*50} harness {50 @x: x+2x+2(x+2x)=450}
q: There is a fish whose tail weighs 9 lbs.; his head weighs as much as his tail and half his body, and his body weighs as much as his head and his tail. What is his whole weight? (lbs.) {72 @x: x=9+(9+x/4)+x/2}
q: Find that number, which, multiplied by 5, and 24 taken from the product, the remainder divided by 6, and 13 added to the quotient, will still give the same number. {54 @x: (5x-24)/6+13=x}
q: In a bag containing eagles and dollars, there are three times as many eagles as dollars; but if 8 eagles and as many dollars be taken away, there will be left five times as many eagles as dollars. How many were there of each? Eagles {48 @= 3*16} dollars {16 @x: 3x-8=5(x-8)}
q: If 10 apples cost a cent, and 25 pears cost 2 cents, and you buy 100 apples and pears for 9 1/2 cents, how many of each will you have? Apples {75 @x: x/10+2(100-x)/25=9.5} pears {25 @= 100-75}
q: Suppose that for every 8 sheep a farmer keeps, he should plow an acre of land, and allow one acre of pasture for every 5 sheep, how many sheep may he keep on 325 acres? {1000 @x: x/8+x/5=325}
q: A person has just 2 hours spare time; how far may he ride in a stage which travels 12 miles an hour, so as to return home in time, walking back at the rate of 4 miles an hour? (miles) {6 @x: x/12+x/4=2}
q: If 65 lbs. of sea-water contain 2 lbs. of salt, how much fresh water must be added to these 65 lbs., in order that the quantity of salt contained in 25 lbs. of the new mixture shall be reduced to 1/4 of a lb.? (lbs.) {135 @x: 2/(65+x)=(1/4)/25}
q: A mass of copper and tin weighs 80 lbs.; and for every 7 lbs. of copper, there are 3 lbs. of tin. How much copper must be added to the mass, that for every 11 lbs. of copper there may be 4 lbs. of tin? (lbs.) {10 @x: 4(56+x)=11*24}
q: A merchant maintained himself for three years, at a cost of $250 a year; and in each of those years augmented that part of his stock which was not so expended, by 1/3 thereof. At the end of the third year his original stock was doubled. What was that stock? (dollars) {3700 @x: (4/3)((4/3)((4/3)(x-250)-250)-250)=2x}
== 27 | Simple Equations | Two unknown quantities; elimination
art: 155 | Two unknown quantities | When an equation contains two or more unknown quantities, the value of any one of them is entirely dependent on the rest, and can become known only when the values of the rest are given, or known. Thus, in the equation `x+y=a`, the value of `x` depends on the values of `y` and `a`, and can only become known when they are known; therefore, to find the value of any unknown quantity, we must obtain a single equation containing it and known quantities. Elimination is the process of deducing, from two or more equations containing two or more unknown quantities, a single equation containing only one unknown quantity. There are three principal methods of elimination: 1st. Elimination by Substitution. 2d. Elimination by Comparison. 3d. Elimination by Addition and Subtraction.
art: 156 | Elimination by Substitution | Elimination by Substitution consists in finding the value of one of the unknown quantities in one of the equations, and substituting this value in the other equation. Let it be required to find `x` and `y` in `2x+3y=33` (1) and `4x+5y=59` (2). From (1), `x=(33-3y)/2`. Substituting this value of `x` in (2), `4((33-3y)/2)+5y=59`; `66-6y+5y=59`; `-y=-7`; `y=7`; `x=(33-3*7)/2=6`. In general, from `ax+by=c` and `a'x+b'y=c'` we find `y=(ac'-a'c)/(ab'-a'b)` and `x=(b'c-bc')/(ab'-a'b)`.
art: 156 | Rule | Find an expression for the value of one of the unknown quantities in either equation, and substitute this value, instead of the same unknown quantity, in the other equation; there will thus be formed a new equation, containing only one unknown quantity. This method is always to be preferred where the value of one of the unknown quantities may be found in terms of the other.
q: By substitution: `3x-5y=2` and `2x+7y=22`. x = {4} y = {2}
chk: x=4, y=2 | 3x-5y=2 | 2x+7y=22
q: `5x-3(x-y)=13` and `x-y=4`. x = {5} y = {1}
chk: x=5, y=1 | 5x-3(x-y)=13 | x-y=4
q: `4x=64-3y` and `2x+3y=44`. x = {10} y = {8}
chk: x=10, y=8 | 4x=64-3y | 2x+3y=44
q: `5x-7y=0` and `4x+3y=8y+3`. x = {7} y = {5}
chk: x=7, y=5 | 5x-7y=0 | 4x+3y=8y+3
q: `ax+by=c-d` and `mx=ny`. x = {$ n(c-d)/(an+bm)} y = {$ m(c-d)/(an+bm)}
chk: x=n(c-d)/(an+bm), y=m(c-d)/(an+bm) | ax+by=c-d | mx=ny
art: 157 | Elimination by Comparison | Elimination by Comparison consists in finding the value of the same unknown quantity in two different equations, and then placing these values equal to each other. Taking `2x+3y=33` and `4x+5y=59`: from (1), `x=(33-3y)/2`; from (2), `x=(59-5y)/4`. Placing these values of `x` equal to each other, `(59-5y)/4=(33-3y)/2`; `59-5y=66-6y`; `y=7`. Rule: find an expression for the value of the same unknown quantity in each of the given equations, and place these values equal to each other; there will thus be formed a new equation, containing only one unknown quantity. This method is generally to be preferred where the equations are literal.
q: By comparison: `3x-2y=9` and `5x+4y=37`. x = {5} y = {3}
chk: x=5, y=3 | 3x-2y=9 | 5x+4y=37
q: `7x+y=10y+7` and `x+y=2y+3`. x = {10} y = {7}
chk: x=10, y=7 | 7x+y=10y+7 | x+y=2y+3
q: `4x+9y=51` and `8x-13y=9`. x = {6} y = {3}
chk: x=6, y=3 | 4x+9y=51 | 8x-13y=9
q: `mx=ny` and `x+y=a`. x = {$ an/(m+n)} y = {$ am/(m+n)}
chk: x=an/(m+n), y=am/(m+n) | mx=ny | x+y=a
q: `ax+by=p` and `cx+dy=q`. x = {$ (bq-dp)/(bc-ad)} y = {$ (aq-cp)/(ad-bc)}
chk: x=(bq-dp)/(bc-ad), y=(aq-cp)/(ad-bc) | ax+by=p | cx+dy=q
art: 158 | Elimination by Addition and Subtraction | This consists in multiplying or dividing two equations, so as to render the coefficient of one of the unknown quantities the same in both; and then, by addition or subtraction, causing the terms containing it to disappear. Taking `2x+3y=33` and `4x+5y=59`: multiplying (1) by 2, `4x+6y=66`; subtracting (2), `y=7`. If the signs of the coefficients of `x` had been different, the terms in `x` would have been canceled by adding. Rule: 1. Multiply or divide the equations, if necessary, so that one of the unknown quantities will have the same coefficient in both. 2. Take the difference, or the sum, of the equations, according as the signs of the equal terms are alike or unlike, and the resulting equation will contain only one unknown quantity. When the coefficients of the quantity to be eliminated are prime to each other, multiply each by the other; when they are not prime, multiply by such numbers as will produce their L.C.M. If the equations have fractional coefficients, they ought to be cleared, before applying the rule.
mc: Finding the value of the same unknown quantity in each equation, and placing these values equal, is elimination by... | *comparison | substitution | addition and subtraction
mc: Elimination by comparison is generally preferred when the equations are... | *literal | numerical | fractional
q: By addition and subtraction: `x+3y=10` and `3x+2y=9`. x = {1} y = {3}
chk: x=1, y=3 | x+3y=10 | 3x+2y=9
q: `2x+3y=18` and `3x-2y=1`. x = {3} y = {4}
chk: x=3, y=4 | 2x+3y=18 | 3x-2y=1
q: `2x-9y=11` and `3x-12y=15`. x = {$ 1} y = {$ -1}
chk: x=1, y=-1 | 2x-9y=11 | 3x-12y=15
q: `(4x+5y)/40=x-y` and `(2x-y)/3+2y=1/2`. x = {1/4} y = {1/5}
chk: x=1/4, y=1/5 | (4x+5y)/40=x-y | (2x-y)/3+2y=1/2
q: `x+ay=b` and `ax-by=c`. x = {$ (ac+b^2)/(a^2+b)} y = {$ (ab-c)/(a^2+b)}
chk: x=(ac+b^2)/(a^2+b), y=(ab-c)/(a^2+b) | x+ay=b | ax-by=c
art: 158 | Exercises | The following examples may be solved by either of the three methods of elimination.
q: `9x-4y=8` and `13x+7y=101`. x = {4} y = {7}
chk: x=4, y=7 | 9x-4y=8 | 13x+7y=101
q: `x-(1/7)(y-2)=5` and `4y-(1/3)(x+10)=3`. x = {5} y = {2}
chk: x=5, y=2 | x-(1/7)(y-2)=5 | 4y-(1/3)(x+10)=3
q: `x/3+y/5=8` and `x/9-y/10=1`. x = {18} y = {10}
chk: x=18, y=10 | x/3+y/5=8 | x/9-y/10=1
q: `4/(5+y)=5/(12+x)` and `2x+5y=35`. x = {2} y = {6 1/5}
chk: x=2, y=31/5 | 4/(5+y)=5/(12+x) | 2x+5y=35
q: `(2x+6)/(3y+2)=8/7` and `8x-4=9y`. x = {5} y = {4}
chk: x=5, y=4 | (2x+6)/(3y+2)=8/7 | 8x-4=9y
q: `(1/3)(x+y)+(1/4)(x-y)=59` and `5x-33y=0`. x = {99} y = {15}
chk: x=99, y=15 | (1/3)(x+y)+(1/4)(x-y)=59 | 5x-33y=0
q: `(3x+4y+3)/10-(2x+7-y)/15=5+(y-8)/5` and `(9y+5x-8)/12-(x+y)/4=(7x+6)/11`. x = {7} y = {9}
chk: x=7, y=9 | (3x+4y+3)/10-(2x+7-y)/15=5+(y-8)/5 | (9y+5x-8)/12-(x+y)/4=(7x+6)/11
q: `ax=by` and `x+y=c`. x = {$ bc/(a+b)} y = {$ ac/(a+b)}
chk: x=bc/(a+b), y=ac/(a+b) | ax=by | x+y=c
q: `3ax-2by=c` and `a^2x+b^2y=5bc`. x = {$ 11bc/(2a^2+3ab)} y = {$ (c/b)((15b-a)/(2a+3b))}
chk: x=11bc/(2a^2+3ab), y=(c/b)((15b-a)/(2a+3b)) | 3ax-2by=c | a^2x+b^2y=5bc
q: `m/x+n/y=a` and `n/x+m/y=b`. x = {$ (m^2-n^2)/(ma-nb)} y = {$ (m^2-n^2)/(mb-na)}
chk: x=(m^2-n^2)/(ma-nb), y=(m^2-n^2)/(mb-na) | m/x+n/y=a | n/x+m/y=b
q: `(a^2-b^2)(5x+3y)=(4a-b)2ab` and `a^2y-ab^2c/(a+b)+(a+b+c)bx=b^2y+(a+2b)ab`. x = {$ ab/(a+b)} y = {$ ab/(a-b)}
chk: x=ab/(a+b), y=ab/(a-b) | (a^2-b^2)(5x+3y)=(4a-b)2ab | a^2y-ab^2c/(a+b)+(a+b+c)bx=b^2y+(a+2b)ab
== 28 | Simple Equations | Problems with two unknown quantities, part 1
art: 159 | Problems with two unknowns | The questions contained in Art. 154 may all be solved by using one unknown symbol, although, in some cases, there were two or more unknown quantities. It frequently happens, however, that the conditions of a problem are such as to require the use of two or more symbols for the unknown quantities. In this case, the number of equations must be equal to the number of symbols, and the value of the unknown quantities may be found by either of the three methods of elimination.
art: 159 | Example 1 | The difference of two numbers is `a`, and the less is to the greater as `m` to `n`; required the numbers. By one unknown quantity: let `mx` = the less number, and `nx` = the greater. Then `nx-mx=a`; `x=a/(n-m)`; `mx=ma/(n-m)`, and `nx=na/(n-m)`. By two unknown quantities: let `x` = the less number, and `y` = the greater. Then `y-x=a` (1), and `x:y::m:n`, or `my=nx` (2). Since `my=nx`, `y=nx/m`; substituting this value of `y` in (1), we find as before `x=ma/(n-m)`, `y=na/(n-m)`.
q: The difference of two numbers is `a`, and the less is to the greater as `m` to `n`. The less is {$ ma/(n-m)} the greater {$ na/(n-m)}
chk: x=ma/(n-m), y=na/(n-m) | y-x=a | my=nx
art: 159 | Example 2 | The hour and minute hands of a watch are opposite at 6 o'clock; when are they next opposite? Let `x` = minute spaces moved over by the hour hand, and `y` = minute spaces moved over by the minute hand. Then, since the minute hand moves 12 times as fast as the hour hand, `y=12x` (1). But the minute hand must evidently pass over 60 minutes more than the hour hand; hence `y=x+60` (2). Substituting, `12x=x+60`; `11x=60`; `x=5 5/11` min.; `y=65 5/11` min. `=1` h. `5 5/11` m. Hence, the hands are next opposite at `5 5/11` m. past 7. In a similar manner the period of coincidence of the hands may be found.
q: The hands are opposite at 6 o'clock; how many minutes past 7 are they next opposite? {5 5/11 @x: 12x=x+60}
q: There is a number consisting of two digits, which divided by the sum of its digits, gives a quotient 7; but if the digits be written in an inverse order, and the number thence arising be divided by the sum of the digits +4, the quotient =3. Required the number. {84 @= 10*8+4}
chk: x=8, y=4 | (10x+y)/(x+y)=7 | (10y+x)/(x+y+4)=3
sol: Any number consisting of two places of figures is equal to 10 times the figure in the ten's place plus the figure in the unit's place. Let x = the tens' digit, and y = the units' digit. Then 10x + y = the number, and 10y + x = the number when the digits are reversed. Also, (10x + y)/(x + y) = 7, and (10y + x)/(x + y + 4) = 3; from these, x = 8 and y = 4.
q: A farmer sells to one man 5 sheep and 7 cows for $111, and to another, at the same rate, 7 sheep and 5 cows for $93. Required the price of a sheep {4} and of a cow. {13}
chk: x=4, y=13 | 5x+7y=111 | 7x+5y=93
q: If 7 lbs. of tea and 9 lbs. of coffee cost $5.20, and, at the same rate, 4 lbs. of tea and 11 lbs. of coffee cost $3.85, what is the price of a lb. of each? Tea (cents) {55} coffee (cents) {15}
chk: x=55, y=15 | 7x+9y=520 | 4x+11y=385
q: A and B are in trade together with different sums; if $50 be added to A's money, and $20 be taken from B's, they will have the same sum; but if A's money were 3 times, and B's 5 times as great as each really is, they would together have $2350. How much has each? A {250} B {320}
chk: x=250, y=320 | x+50=y-20 | 3x+5y=2350
q: A and B together have $9800; A invests the sixth part of his money in business, and B the fifth part, and then each has the same sum remaining. How much has each? A {4800} B {5000}
chk: x=4800, y=5000 | x+y=9800 | 5x/6=4y/5
q: Find a fraction, such that if the numerator and denominator be each increased by 1, the value is 1/2; but if each be diminished by 1, the value is 1/3. {3/7 @= 3/7}
chk: x=3, y=7 | (x+1)/(y+1)=1/2 | (x-1)/(y-1)=1/3
q: Find two numbers, such that 1/3 of the first exceeds 1/4 of the second by 3, and 1/4 of the first and 1/5 of the second are together equal to 10. {24} and {20}
chk: x=24, y=20 | x/3-y/4=3 | x/4+y/5=10
q: A grocer knows neither the weight nor the first cost of a box of tea he had purchased. He only recollects that if he had sold the whole at 30 cts. per lb., he would have gained $1, but if he had sold it at 22 cts. per lb., he would have lost $3. Required the number of lbs. in the box {50} and the first cost per lb. (cents) {28}
chk: x=50, y=28 | 30x-xy=100 | xy-22x=300
q: The rent of a field is a certain fixed number of bu. of wheat, and a fixed number of bu. of corn. When wheat is 55 cts., and corn 33 cts. per bu., the portions of rent by wheat and corn are equal; but when wheat is 65 cts. and corn 41 cts., the rent is increased by $1.40. What is the grain rent? Bushels of wheat {6} of corn {10}
chk: x=6, y=10 | 55x=33y | 65x+41y-(55x+33y)=140
== 29 | Simple Equations | Problems with two unknown quantities, part 2
q: The quantity of water which flows from an orifice is proportional to the area of the orifice, and the velocity of the water. Now, there are two orifices, the areas being as 5 to 13, and the velocities as 8 to 7; and from one there issued in a certain time 561 cubic feet more than from the other. How much water did each discharge? (cubic feet) {440 @x: 91x/40-x=561} and {1001 @= 91*440/40}
q: Find two numbers in the ratio of 5 to 7, to which two other required numbers, in the ratio of 3 to 5, being respectively added, the sums shall be in the ratio of 9 to 13; and the difference of those sums =16. {30} and {42}; {6} and {10}
chk: x=6, y=2 | 13(5x+3y)=9(7x+5y) | (7x+5y)-(5x+3y)=16
q: A boy spends 30 cts. in apples and pears, buying his apples at 4 and his pears at 5 for a ct.; he then finds that half his apples and 1/3 of his pears cost 13 cts. How many of each did he buy? Apples {72} pears {60}
chk: x=72, y=60 | x/4+y/5=30 | x/8+y/15=13
q: A farmer rents a farm for $245 per year; the tillable land being valued at $2 per acre, and the pasture at $1.40; now the number of acres of tillable, is to half the excess of the tillable above the pasture, as 28 to 9. How many acres are there of each? Tillable {98} pasture {35}
chk: x=98, y=35 | 2x+1.4y=245 | 9x=28(x-y)/2
q: Find that number of 2 figures to which, if the number formed by changing the places of the digits be added, the sum is 121; and if the less of the same two numbers be taken from the greater, the remainder is 9. {65} or {56}
chk: x=6, y=5 | 10x+y+10y+x=121 | (10x+y)-(10y+x)=9
q: To determine three numbers such that if 6 be added to the first and second, the sums will be in the ratio of 2 to 3; if 5 be added to the first and third, the sums will be in the ratio of 7 to 11; but if 36 be subtracted from the second and third, the remainders will be as 6 to 7. (Let `2x-6`, `3x-6`, and `y` be the numbers.) {30}, {48}, and {50}
chk: x=18, y=50 | 11(2x-6+5)=7(y+5) | 7(3x-6-36)=6(y-36)
q: Two persons, A and B, can perform a piece of work in 16 days. They work together for 4 days, when A, being called off, B is left to finish it, which he does in 36 days more. In what time could each do it separately? A (days) {24} B {48}
chk: x=24, y=48 | 1/x+1/y=1/16 | 4/16+36/y=1
q: A and B drink from a cask of beer for 2 hr., after which A falls asleep, and B drinks the remainder in 2 hr. and 48 min.; but if B had fallen asleep and A had continued to drink, it would have taken him 4 hr. and 40 min. to finish the cask. In what time could each singly drink the whole? A (hours) {10} B {6}
chk: x=10, y=6 | 2/x+2/y+(14/5)/y=1 | 2/x+2/y+(14/3)/x=1
q: Divide the fraction 8/5 into two parts, so that the numerators of the two parts taken together shall be equal to their denominators taken together. {1/2 @= 8/5-11/10} and {11/10}
q: A purse holds 19 crowns and 6 guineas. Now 4 crowns and 5 guineas fill 17/63 of it. How many of each will it hold? {21} crowns or {63} guineas
chk: x=21, y=63 | 19/x+6/y=1 | 4/x+5/y=17/63
q: When wheat was 5 shillings a bu. and rye 3 shillings, a man wanted to fill his sack with a mixture of rye and wheat for the money he had in his purse. If he bought 7 bu. of rye and laid out the rest of his money in wheat, he would want 2 bu. to fill his sack; but if he bought 6 bu. of wheat, and filled his sack with rye, he would have 6 shillings left. How must he lay out his money, and fill his sack? Bushels of wheat {9} and of rye {12}
chk: x=21, y=81 | 7+(y-21)/5+2=x | 30+3(x-6)=y-6 | 5*9+3*12=y | 9+12=x
== 30 | Simple Equations | Three or more unknown quantities
art: 160 | Three or more unknown quantities | Simple equations, involving three or more unknown quantities, may be solved by either of the three methods of elimination; but the third method is generally to be preferred. Given `5x-4y+2z=48` (1), `3x+3y-4z=24` (2), `2x-5y+3z=19` (3). To eliminate `z` from the first two equations, multiply (1) by 2, and add this to (2): `13x-5y=120` (5). To eliminate `z` from (1) and (3), multiply (1) by 3, and (3) by 2, and subtract: `11x-2y=106` (6). To eliminate `y` from (5) and (6), multiply (5) by 2, and (6) by 5, and subtract: `29x=290`; `x=10`. Then `110-2y=106`, whence `y=2`; and `50-8+2z=48`, whence `z=3`.
art: 160 | General Rule | 1st. Combine any one of the equations with each of the others, so as to eliminate the same unknown quantity; the number of equations and of unknown quantities will be one less. 2d. Combine any one of these new equations with each of the others, as before; the number of equations and of unknown quantities will be two less. 3d. Continue this series of operations until a single equation is obtained, with one unknown quantity, and find its value. 4th. Substitute this value in the derived equations, for the values of the other unknown quantities. In some particular instances, solutions may be obtained more easily and elegantly by other means.
q: Given `5x-4y+2z=48`, `3x+3y-4z=24`, `2x-5y+3z=19`. x = {10} y = {2} z = {3}
chk: x=10, y=2, z=3 | 5x-4y+2z=48 | 3x+3y-4z=24 | 2x-5y+3z=19
art: 160 | Example 2 | Given `-x+y+z=a` (1), `x-y+z=b` (2), `x+y-z=c` (3). By adding the three equations together, and calling `a+b+c=s`, we find `x+y+z=s` (4). Then, by subtracting (1), (2), and (3), respectively from (4), and dividing by 2, `x=(1/2)(s-a)=(1/2)(b+c)`, `y=(1/2)(a+c)`, `z=(1/2)(a+b)`.
q: Given `-x+y+z=a`, `x-y+z=b`, `x+y-z=c`. x = {$ (b+c)/2} y = {$ (a+c)/2} z = {$ (a+b)/2}
chk: x=(b+c)/2, y=(a+c)/2, z=(a+b)/2 | -x+y+z=a | x-y+z=b | x+y-z=c
q: `x+y+z=22`, `y+z+u=21`, `x+z+u=19`, `x+y+u=16`. x = {5} y = {7} z = {10} u = {4}
chk: x=5, y=7, z=10, u=4 | x+y+z=22 | y+z+u=21 | x+z+u=19 | x+y+u=16
art: 160 | Example 4 | Given `2x-y-z=12` (1), `3y-x-z=16` (2), `5z-x-y=24` (3). Put `x+y+z=s`, and add (1), (2), and (3) successively to the last equation. This gives `3x=s+12`, `4y=s+16`, `6z=s+24`. Multiplying these by 4, 3, and 2, and adding, `12(x+y+z)=9s+144`, or `12s=9s+144`; `3s=144`; `s=48`. Substituting, we find `x=20`, `y=16`, and `z=12`.
q: Given `2x-y-z=12`, `3y-x-z=16`, `5z-x-y=24`. x = {20} y = {16} z = {12}
chk: x=20, y=16, z=12 | 2x-y-z=12 | 3y-x-z=16 | 5z-x-y=24
q: `x+y+z=6`, `3x-y+2z=7`, `4x+3y-z=7`. x = {1} y = {2} z = {3}
chk: x=1, y=2, z=3 | x+y+z=6 | 3x-y+2z=7 | 4x+3y-z=7
q: `3x+4y-5z=32`, `4x-5y+3z=18`, `5x-3y-4z=2`. x = {10} y = {8} z = {6}
chk: x=10, y=8, z=6 | 3x+4y-5z=32 | 4x-5y+3z=18 | 5x-3y-4z=2
q: `x-9y+3z-10u=21`, `2x+7y-z-u=683`, `3x+y+5z+2u=195`, `4x-6y-2z-9u=516`. x = {$ 100} y = {$ 60} z = {$ -13} u = {$ -50}
chk: x=100, y=60, z=-13, u=-50 | x-9y+3z-10u=21 | 2x+7y-z-u=683 | 3x+y+5z+2u=195 | 4x-6y-2z-9u=516
q: `x+y/2=10-z/3`, `(1/2)(x+z)=9-y`, `(1/4)(x-z)=2y-7`. x = {7} y = {4} z = {3}
chk: x=7, y=4, z=3 | x+y/2=10-z/3 | (1/2)(x+z)=9-y | (1/4)(x-z)=2y-7
q: `9x-2z+u=41`, `7y-5z-t=12`, `4y-3x+2u=5`, `3y-4u+3t=7`, `7z-5u=11`. x = {5} y = {4} z = {3} u = {2} t = {1}
chk: x=5, y=4, z=3, u=2, t=1 | 9x-2z+u=41 | 7y-5z-t=12 | 4y-3x+2u=5 | 3y-4u+3t=7 | 7z-5u=11
art: 160 | Special methods | Examples to be solved by special methods. In the first, subtract (3) from (2), then combine the resulting equation with (1), to find `x` and `y`; `z` may be found similarly.
q: `1/x+1/y=a`, `1/x+1/z=b`, `1/y+1/z=c`. x = {$ 2/(a+b-c)} y = {$ 2/(a-b+c)} z = {$ 2/(b+c-a)}
chk: x=2/(a+b-c), y=2/(a-b+c), z=2/(b+c-a) | 1/x+1/y=a | 1/x+1/z=b | 1/y+1/z=c
q: `-x+y+z+v=a`, `x-y+z+v=b`, `x+y-z+v=c`, `x+y+z-v=d`; where `s=(1/2)(a+b+c+d)`. x = {$ (b+c+d-a)/4} (and `y`, `z`, `v` in the same way)
chk: x=(b+c+d-a)/4, y=(a+c+d-b)/4, z=(a+b+d-c)/4, v=(a+b+c-d)/4 | -x+y+z+v=a | x-y+z+v=b | x+y-z+v=c | x+y+z-v=d
== 31 | Simple Equations | Problems with three or more unknown quantities
art: 161 | Problems | For the method of forming the equations, see Arts. 154 and 159.
q: The stock of three traders amounts to $760; the shares of the first and second exceed that of the third by $240; and the sum of the second and third exceeds the first by $360; what is the share of each? {200}, {300}, and {260}
chk: x=200, y=300, z=260 | x+y+z=760 | x+y-z=240 | y+z-x=360
q: What three numbers are there, each greater than the preceding, whose sum is 20, and such that the sum of the first and second is to the sum of the second and third, as 4 is to 5; and the difference of the first and second, is to the difference of the first and third, as 2 to 3? {5}, {7}, and {8}
chk: x=5, y=7, z=8 | x+y+z=20 | 5(x+y)=4(y+z) | 3(y-x)=2(z-x)
q: Find four numbers, such that the sum of the first, second, and third shall be 13; the sum of the first, second, and fourth, 15; the sum of the first, third, and fourth, 18; and lastly, the sum of the second, third, and fourth, 20. {2}, {4}, {7}, {9}
chk: x=2, y=4, z=7, u=9 | x+y+z=13 | x+y+u=15 | x+z+u=18 | y+z+u=20
q: The sum of three digits composing a certain number is 16; the sum of the left and middle digits, is to the sum of the middle and right ones as 3 to 3 2/3; and if 198 be added to the number, the order of the digits will be inverted. Required the number. {547}
chk: x=5, y=4, z=7 | x+y+z=16 | (11/3)(x+y)=3(y+z) | 100x+10y+z+198=100z+10y+x
q: It is required to find three numbers such that 1/2 the first, 1/3 the second, and 1/4 the third, shall together make 46; 1/3 the first, 1/4 the second, and 1/5 the third, shall together make 35; and 1/4 the first, 1/5 the second, and 1/6 the third, shall together make 28 1/3. {12}, {60}, and {80}
chk: x=12, y=60, z=80 | x/2+y/3+z/4=46 | x/3+y/4+z/5=35 | x/4+y/5+z/6=85/3
q: The sum of three numbers, taken two and two, are `a`, `b`, and `c`. What are the numbers? {$ (a+b-c)/2}, {$ (a+c-b)/2}, and {$ (b+c-a)/2}
chk: x=(a+b-c)/2, y=(a+c-b)/2, z=(b+c-a)/2 | x+y=a | x+z=b | y+z=c
q: A person has four casks, the second of which being filled from the first, leaves the first 4/7 full. The third being filled from the second, leaves it 1/4 full; and when the third is emptied into the fourth, it is found to fill only 9/16 of it. But the first will fill the third and fourth and have fifteen quarts remaining. How many quarts does each hold? {140}, {60}, {45}, and {80}
chk: x=140, y=60, z=45, u=80 | x-y=4x/7 | y-z=y/4 | z=9u/16 | x=z+u+15
q: In the crew of a ship consisting of sailors and soldiers, there were 22 sailors to every 3 guns, and 10 sailors over; also the whole number of hands was 5 times the number of soldiers and guns together; but after an engagement, in which the slain were one fourth of the survivors, there wanted 5 men to be 13 men to every 2 guns. Required the number of guns {90}, soldiers {55}, and sailors {670}
chk: x=90, y=55, z=670 | z=22x/3+10 | z+y=5(y+x) | 4(z+y)/5+5=13x/2
== 32 | Supplement to Simple Equations | Generalization; formation of rules
art: 162 | Supplement to Simple Equations | The principles employed in algebraic equations may be variously applied. We may, for example, by their aid demonstrate several of the theorems in fractions. Thus, to prove that `ma/(mb)=a/b` (Art. 118), put `q=a/b`. Then `bq=a`, and `mbq=ma`; therefore `q=ma/(mb)`. Hence, since `q=a/b` and `q=ma/(mb)`, `ma/(mb)=a/b`. To prove that `a/b*c/d=ac/(bd)` (Art. 131), put `p=a/b` and `q=c/d`. Then `bp=a`, and `dq=c`. Multiplying the last two equations, member by member, `bdpq=ac`; therefore `pq=ac/(bd)`, which proves the rule.
art: 162 | Generalization | Literal Equations are those in which the known quantities are represented, either entirely or partly, by letters. Quantities represented by letters are termed general values, because the solution of one problem furnishes a general solution. A Formula is the answer to a problem, when the known quantities are represented by letters. A Rule is a formula expressed in ordinary language. By the application of Algebra to the solution of general questions, many useful and interesting truths and rules may be established.
art: 163 | Example | Divide a given number `a` into three parts, having to each other the same ratio as the numbers `m`, `n`, and `p`. Let `mx`, `nx`, and `px`, represent the required parts. Then `mx+nx+px=a`, and `x=a/(m+n+p)`; from which we obtain `mx=ma/(m+n+p)`, `nx=na/(m+n+p)`, and `px=pa/(m+n+p)`. Rule for Dividing a Given Number into Parts having to each other a Given Ratio: multiply the given number by each term of the ratios respectively, and divide the products by the sum of the numbers expressing the ratios.
mc: The answer to a problem, when the known quantities are represented by letters, is called a... | *formula | rule | root
mc: A formula expressed in ordinary language is called a... | *rule | formula | literal equation
q: Divide 69 into three parts, having to each other the same ratio as the numbers 5, 7, and 11. {15 @= 69*5/23}, {21 @= 69*7/23}, and {33 @= 69*11/23}
q: Divide 38 1/2 into four parts, having to each other the same ratio as the fractional numbers 1/2, 1/3, 1/4, and 1/5. {15 @= 38.5*30/77}, {10 @= 38.5*20/77}, {7 1/2 @= 38.5*15/77}, and {6 @= 38.5*12/77}
art: 163 | General examples | Solve the following general examples, express the formula in ordinary language, so as to form a general rule, and apply the rule or the formula, to the solution of the numerical problems.
q: The sum of two numbers is `a`, and their difference `b`. Required the numbers. Greater {$ a/2+b/2} less {$ a/2-b/2}
chk: x=a/2+b/2, y=a/2-b/2 | x+y=a | x-y=b
q: The joint capital of A and B in a firm, is $16000; but A's investment is $2000 more than B's. Required the capital of each. A's {9000 @= 16000/2+2000/2} B's {7000 @= 16000/2-2000/2}
q: The sum of two angles is 120° 44′ 52″, and their difference is 26° 32′ 18″. Required the greater angle: {73}° {38}′ {35}″
chk: x=73*3600+38*60+35, y=47*3600+6*60+17 | x+y=120*3600+44*60+52 | x-y=26*3600+32*60+18
q: And the less angle: {47}° {6}′ {17}″
q: The difference of two numbers is `a`, and the greater is to the less as `m` to `n`. Find the numbers. {$ ma/(m-n)} and {$ na/(m-n)}
chk: x=ma/(m-n), y=na/(m-n) | x-y=a | nx=my
q: The difference in capacity of two cisterns is 678 gal., and the greater is to the less as 7 to 5. How much does each hold? (gallons) Greater {2373 @= 7*678/2} less {1695 @= 5*678/2}
q: The sum of two numbers is `a`, and their sum is to their difference as `m` to `n`. Required the numbers. Greater {$ (m+n)a/(2m)} less {$ (m-n)a/(2m)}
chk: x=(m+n)a/(2m), y=(m-n)a/(2m) | x+y=a | n(x+y)=m(x-y)
q: An estate, valued at $8745, was divided between a son and daughter in such a manner that the sum of their shares was to the difference as 5 to 3. What was the share of each? Son's {6996} daughter's {1749}
chk: x=6996, y=1749 | x+y=8745 | 3(x+y)=5(x-y)
q: Divide the number `a` into three such parts, that the second shall exceed the first by `b`, and the third exceed the second by `c`. {$ (a-2b-c)/3}, {$ (a+b-c)/3}, {$ (a+b+2c)/3}
chk: x=(a-2b-c)/3, y=(a+b-c)/3, z=(a+b+2c)/3 | x+y+z=a | y-x=b | z-y=c
q: At a certain election the whole number of votes cast was 602. B received 84 more votes than A, and C 56 more than B. How many did each receive? A {126 @x: x+x+84+x+140=602} B {210 @= 126+84} C {266 @= 210+56}
q: Divide the number `a` into four such parts, that the first increased by `m`, the second diminished by `m`, the third multiplied by `m`, and the fourth divided by `m`, shall be all equal to each other. (Let the four parts be `x-m`, `x+m`, `x/m`, and `mx`.) {$ ma/(m+1)^2-m}, {$ ma/(m+1)^2+m}, {$ a/(m+1)^2}, {$ m^2a/(m+1)^2}
chk: x=ma/(m+1)^2-m, y=ma/(m+1)^2+m, z=a/(m+1)^2, u=m^2a/(m+1)^2 | x+y+z+u=a | x+m=y-m | x+m=mz | x+m=u/m
q: Divide the number 245 into four parts, such that the first increased by 6, the second diminished by 6, the third multiplied by 6, and the fourth divided by 6, shall be all equal to each other. {24}, {36}, {5}, and {180}
chk: x=24, y=36, z=5, u=180 | x+y+z+u=245 | x+6=y-6 | x+6=6z | x+6=u/6
q: A person has just `a` hours at his disposal; how far may he ride in a coach which travels `b` miles an hour, so as to return home in time, walking back at the rate of `c` miles an hour? (miles) {$ abc/(b+c) @x: x/b+x/c=a}
q: A person finds that he can row a skiff 6 miles an hour with the current, and 3 miles an hour against it; how far can he pass down the stream, and yet return to the point from which he set out, in 8 hours? (miles) {16 @x: x/6+x/3=8}
q: Given the sum of two numbers `=a`, and the quotient of the greater divided by the less `=b`. Required the numbers. Less {$ a/(b+1)} greater {$ ab/(b+1)}
chk: x=a/(b+1), y=ab/(b+1) | x+y=a | y=bx
art: 163 | Rule | This gives the following simple rule: to find the less number, divide the sum of the numbers by their quotient increased by unity.
q: The sum of two numbers is 256, and the quotient of the greater by the less is 15. Required the numbers. {240 @= 256*15/16} and {16 @= 256/16}
q: A person distributed `a` cents among `n` beggars, giving `b` cents to some, and `c` to the rest. How many were there of each? At `b` cts. {$ (a-nc)/(b-c)} and at `c` cts. {$ (nb-a)/(b-c)}
chk: x=(a-nc)/(b-c), y=(nb-a)/(b-c) | x+y=n | bx+cy=a
q: A father divided $8500 among 7 children, giving to each son $1750, and to each daughter $500. How many of his children were sons {4 @x: 1750x+500(7-x)=8500} and how many daughters? {3 @= 7-4}
q: Divide the number `n` into two such parts, that the quotient of the greater divided by the less shall be `q`, with a remainder `r`. {$ (nq+r)/(1+q)} and {$ (n-r)/(1+q)}
chk: x=(nq+r)/(1+q), y=(n-r)/(1+q) | x+y=n | x=qy+r
q: Divide 1903 into two such parts that the quotient of the greater divided by the less shall be 12, with a remainder 5. {1757 @= (1903*12+5)/13} and {146 @= (1903-5)/13}
q: If A and B together can perform a piece of work in `a` days, A and C in `b` days, and B and C in `c` days: find the time in which each can perform it separately. A in {$ 2abc/(ac+bc-ab)} B in {$ 2abc/(ab+bc-ac)} C in {$ 2abc/(ab+ac-bc)} days
chk: x=2abc/(ac+bc-ab), y=2abc/(ab+bc-ac), z=2abc/(ab+ac-bc) | 1/x+1/y=1/a | 1/x+1/z=1/b | 1/y+1/z=1/c
q: A tank is supplied with water from three pumps. The first and second will fill it in 30 hours, the first and third in 40 hours, and the second and third in 50 hours. In what time can each fill it separately? (hours) First {52 4/23} second {70 10/17} third {171 3/7}
chk: x=1200/23, y=1200/17, z=1200/7 | 1/x+1/y=1/30 | 1/x+1/z=1/40 | 1/y+1/z=1/50
q: A, B, and C hold a pasture in common, for which they pay `s` dollars a year. A puts in `a` oxen for `m` months; B, `b` oxen for `n` months; and C, `c` oxen for `p` months. Required A's share of the rent. {$ mas/(ma+nb+pc)}
art: 163 | Compound Fellowship | B's share is `nbs/(ma+nb+pc)`, and C's `pcs/(ma+nb+pc)`. From these formulas is derived the rule of Compound Fellowship.
q: A, B, and C engage in business together. A put into the firm $600 for 30 weeks, B $500 for 40 weeks, and C $800 for 28 weeks. They then divided a profit of $1812 between them. What was each man's share? A's {540 @= 1812*18000/60400} B's {600 @= 1812*20000/60400} C's {672 @= 1812*22400/60400}
q: A mixture is made of `a` lb. of tea at `m` shillings per lb., `b` lb. at `n` shillings, and `c` lb. at `p` shillings: what will be its cost per lb.? {$ (ma+nb+pc)/(a+b+c) @x: (a+b+c)x=ma+nb+pc}
art: 163 | Alligation Medial | From this formula is derived the rule termed Alligation Medial.
q: A drover bought 10 cattle at $30 apiece, 12 at $40, and 8 at $90. What was the average price per head? (dollars) {50 @= (10*30+12*40+8*90)/30}
q: A waterman rows a given distance `a` and back again in `b` hours, and finds that he can row `c` miles with the current for `d` miles against it: required the time of rowing down the stream {$ bd/(c+d)} and up {$ bc/(c+d)}; the rate of the current {$ a(c^2-d^2)/(2bcd)}, and the rate of rowing {$ a(c+d)^2/(2bcd)}
chk: x=bd/(c+d), y=bc/(c+d), u=a(c+d)^2/(2bcd), v=a(c^2-d^2)/(2bcd) | x+y=b | a/x=u+v | a/y=u-v
q: A vessel sailed with the wind and tide 60 miles, and returned with the wind and against the tide. She reached the same point in 12 hours, and the rate of sailing out and in was as 5 to 3. Required the time out {4 1/2} and the time in (hours) {7 1/2}; the strength of the wind {10 2/3} and of the tide (miles per hour) {2 2/3}
chk: x=9/2, y=15/2, u=32/3, v=8/3 | x+y=12 | 3(60/x)=5(60/y) | u+v=60/x | u-v=60/y
== 33 | Supplement to Simple Equations | Negative solutions; discussion of problems; the couriers
art: 164 | Negative Solutions | It sometimes happens, in the solution of a problem, that the result has the minus sign. This is termed a negative solution. What number must be subtracted from 3 that the remainder may be 7? Let `x` = the number. Then `3-x=7`; whence `-x=7-3`, or `x=-4`. Now, −4 subtracted from 3, gives a remainder 7; and the answer, −4, is said to satisfy the question in an algebraic sense. The problem is evidently impossible in an arithmetical sense, and this impossibility is shown by the negative answer. But, since subtracting −4 is the same as adding +4 (Art. 48), the result is the answer to the following: What number must be added to 3, that the sum may be equal to 7?
art: 164 | | Let the question now be generalized: what number must be subtracted from `a`, that the remainder may be `b`? Then `a-x=b`; whence `x=a-b`. While `b` is less than `a`, the value of `x` will be positive; and the question will be consistent in an arithmetical sense. But if `b` becomes greater than `a`, the value of `x` will be negative; and the question will be consistent in its algebraic, but not in its arithmetical sense. The question, to be consistent in an arithmetical sense, should then read: What number must be added to `a` that the sum may be equal to `b`? From this we derive the following important general principles: 1st. A negative solution indicates some arithmetical inconsistency or absurdity in the question from which the equation was derived. 2d. When a negative solution is obtained, the question, to which it is the answer, may be so modified as to be consistent with arithmetical notions.
mc: A negative solution indicates... | *some arithmetical inconsistency in the question | that the problem has no answer at all | a mistake in the solving
q: What number must be subtracted from 3 that the remainder may be 7? {$ -4 @x: 3-x=7}
q: What number must be added to the number 30, that the sum may be 19? {$ -11 @x: 30+x=19}
q: The sum of two numbers is 9, and their difference 25; required the numbers. {$ 17} and {$ -8}
chk: x=17, y=-8 | x+y=9 | x-y=25
q: What number is that whose half subtracted from its third leaves a remainder 15? {$ -90 @x: x/3-x/2=15}
q: A father's age is 40 years; his son's age is 13 years; in how many years will the age of the father be 4 times that of the son? {$ -4 @x: 40+x=4(13+x)}
mc: The answer −4 to the last question means that the father's age was 4 times the son's... | *4 years ago | in 4 years | never
art: 165 | Discussion of Problems | After a question has been generalized and solved, we may inquire what values the results will have, when particular suppositions are made with regard to the known quantities. The determination of these values, and the examination of the various results, to which different suppositions give rise, constitute the discussion of the problem.
art: 165 | Example | After subtracting `b` from `a`, what number, multiplied by the remainder, will give a product equal to `c`? Then `(a-b)x=c`, and `x=c/(a-b)`. Let A denote, indefinitely, some quantity. I. When `b` is less than `a`, the value of `x` will be of the form +A. II. When `b` is greater than `a`, `a-b` will be negative, and the value of `x` of the form −A. III. When `b` is equal to `a`, the value of `x` is of the form `A/0`, or (Art. 136), `x=∞`. IV. When `c` is 0, and `b` either greater or less than `a`, `x` is of the form `0/A`, or `x=0`. V. When `b` is equal to `a`, and `c` is equal to 0, `x` is of the form `0/0`, which (Art. 137) is the symbol of indetermination.
mc: In `x=c/(a-b)`, when `b=a` and `c` is not 0, `x` is... | *∞ | 0 | indeterminate
mc: In `x=c/(a-b)`, when `b=a` and `c=0`, `x` is... | *indeterminate, `0/0` | ∞ | 0
art: 166 | Problem of the Couriers | The discussion of the following problem, originally proposed by Clairaut, will serve to illustrate further the preceding principles. Two couriers depart at the same time, from two places, A and B, distant `a` miles from each other; the former travels `m` miles an hour, and the latter `n` miles: where will they meet? There are two cases, according as the couriers travel toward each other, or in the same direction.
art: 166 | I. Toward each other | Let P be the point where they meet, `x`=AP, the distance which the first travels; then `a-x`=BP, the distance which the second travels. The distance each travels, divided by the number of miles traveled per hour, gives the number of hours he was traveling; they both travel the same number of hours; therefore `x/m=(a-x)/n`; `nx=ma-mx`; `x=ma/(m+n)`, and `a-x=na/(m+n)`. 1st. Suppose `m=n`; then `x=a/2`: if they travel at the same rate, each travels half the distance. 2d. Suppose `n=0`; then `x=a`: if the second courier remains at rest, the first travels the whole distance. 3d. Suppose `m>n`; then `x` will be greater than `a-x`, or P will be farther from A than B.
art: 166 | II. In the same direction | Each traveling from A toward P: `x`=AP, `x-a`=BP. Then `x/m=(x-a)/n`, and `x=ma/(m-n)`; `x-a=na/(m-n)`. 1st. If `m` is greater than `n`, the values of `x` and of `x-a` will both be positive: the couriers will meet on the right of both A and B. 2d. If `n` is greater than `m`, the values will be negative, which indicates that the place of meeting is at P′, on the left of A and B: they can not meet in the future, but we may suppose that they have met before. 3d. If `m=n`, then `x=ma/0=∞`: if the couriers travel at the same rate, the one can never overtake the other; they only meet at an infinite distance. 4th. If `a=0`, then `x=0`. 5th. If `m=n` and `a=0`, then `x=0/0`: they will be always together. 6th. If `n=0`, `x=a`. 7th. If `n=m/2`, then `x=2a`: the first travels twice the distance from A to B before overtaking the second.
q: Couriers traveling toward each other: how far does the first travel? {$ ma/(m+n) @x: x/m=(a-x)/n}
q: Couriers traveling in the same direction: how far does the first travel before they meet? {$ ma/(m-n) @x: x/m=(x-a)/n}
mc: Couriers in the same direction at the same rate meet... | *never, or at an infinite distance | at B | halfway
mc: If, in the same direction, `n=m/2`, the first courier travels before overtaking the second... | *twice the distance from A to B | half the distance from A to B | the distance from A to B
== 34 | Supplement to Simple Equations | Indetermination; impossible problems; one root; second powers
art: 167 | An Independent Equation | An Independent Equation is one in which the relation of the quantities which it contains can not be obtained directly from others with which it is compared. Thus, `x+3y=19` and `2x+5y=33` are independent of each other, since the one can not be obtained from the other in a direct manner. But `x+3y=19` and `2x+6y=38` are not independent, the second being derived directly from the first, by multiplying both sides by 2.
art: 168 | An Indeterminate Equation | An Indeterminate Equation is one that can be verified by different values of the same unknown quantity. Thus, if we have `x-y=3`, by transposition `x=3+y`. If we make `y=1`, then `x=4`; if `y=2`, then `x=5`; and so on. If we have two equations containing three unknown quantities, we may eliminate one of them; this will leave one equation containing two unknown quantities, which will be indeterminate. Thus, in `x+3y-5z=20` and `x-y+3z=16`, if we eliminate `x`, we have `y-2z=1`; whence `y=1+2z`. If we make `z=1`, then `y=3`, and `x=16`; if `z=2`, then `y=5`, and `x=15`. General Principle: when the number of unknown quantities exceeds the number of independent equations, the problem is indeterminate.
art: 168 | | A question that involves only one unknown quantity is sometimes indeterminate; the equation deduced from the conditions being identical (Art. 145). Thus: what number is that, whose 1/4 increased by the 1/6 is equal to the 11/20 diminished by the 2/15? Then `x/4+x/6=11x/20-2x/15`; clearing of fractions, `15x+10x=33x-8x`; or `25x=25x`, which will be verified by any value whatever of `x`.
art: 169 | Redundant and incompatible equations | When the number of equations is greater than the number of unknown quantities, as `2x+3y=23`, `3x-2y=2`, `5x+4y=40`, each of these equations being independent of the other two, one of them is unnecessary, since the values of `x` and `y` may be found from either two of them. When a problem contains more conditions than are necessary for determining the values of the unknown quantities, those that are unnecessary are termed redundant. The number of equations may exceed the number of unknown quantities, so that the values of the unknown quantities shall be incompatible with each other. Thus, `x+y=12`, `2x+y=17`, `3x+2y=30`: from (1) and (2), `x=5`, `y=7`; from (1) and (3), `x=6`, `y=6`; and from (2) and (3), `x=4`, `y=9`. Only two of these equations can be true at the same time.
mc: `x+3y=19` and `2x+6y=38` are... | *not independent | independent | incompatible
mc: When the number of unknown quantities exceeds the number of independent equations, the problem is... | *indeterminate | impossible | redundant
mc: Conditions more than are necessary to find the unknown quantities are called... | *redundant | incompatible | indeterminate
q: In `x+3y-5z=20` and `x-y+3z=16`, if `z=1`, then y = {3} and x = {16}
chk: x=16, y=3, z=1 | x+3y-5z=20 | x-y+3z=16
art: 169 | Examples to illustrate the preceding principles | 1. What number is that, which being divided successively by `m` and `n`, and the first quotient subtracted from the second, the remainder shall be `q`? Ans. `x=mnq/(m-n)`. What supposition will give a negative solution? Will any supposition give an infinite solution? An indeterminate solution? 2. Two boats, A and B, set out at the same time, one from C to L, and the other from L to C; the boat A runs `m` miles, and the boat B, `n` miles per hour. Where will they meet, supposing it to be `a` miles from C to L? Ans. `ma/(m+n)` mi. from C, or `na/(m+n)` mi. from L.
q: What number is that, which being divided successively by `m` and `n`, and the first quotient subtracted from the second, the remainder shall be `q`? {$ mnq/(m-n) @x: x/n-x/m=q}
q: Two boats set out at the same time, A from C to L, and B from L to C, `a` miles apart; A runs `m` miles, and B `n` miles per hour. How far from C will they meet? {$ ma/(m+n) @x: x/m=(a-x)/n}
q: Given `2x-y=2`, `5x-3y=3`, `3x+2y=17`, `4x+3y=24`; to find `x` and `y`. x = {3} y = {4} How many of the equations are redundant? {2}
chk: x=3, y=4 | 2x-y=2 | 5x-3y=3 | 3x+2y=17 | 4x+3y=24
tf: The equations `x+2y=11`, `2x-y=7`, `3x-y=17`, `x+3y=19` are incompatible. {T}
art: 170 | A Simple Equation has but One Root | Any simple equation involving only one unknown quantity, `x`, may be reduced to the form `mx=n`; for all the terms containing `x` may be reduced to one term, and all the known quantities to one term; whence `x=n/m`. Now, since `n` divided by `m` can give but one quotient, we infer that a simple equation has but one root; that is, there is but one value that will verify the equation.
art: 171 | Examples involving the second power of the unknown quantity | It sometimes happens in the solution of an equation, that the second or some higher power of the unknown quantity occurs, but in such a manner that it is easily removed. Thus, `(4+x)(x-5)=(x-2)^2`. Performing the operations indicated, `x^2-x-20=x^2-4x+4`. Omitting `x^2` on each side, and transposing, `3x=24`, or `x=8`.
q: `(4+x)(x-5)=(x-2)^2` {8 @x: (4+x)(x-5)=(x-2)^2}
q: `(2x+3)x/(2x+1)+1/(3x)=x+1` {1 @x: (2x+3)x/(2x+1)+1/(3x)=x+1}
q: `(3x^2-2x+1)/5=(7x-2)(3x-6)/35+9/10` {1 5/68 @x: (3x^2-2x+1)/5=(7x-2)(3x-6)/35+9/10}
q: `((4x+3)/(6x-43))(3x-19)=2x+19` {8 @x: ((4x+3)/(6x-43))(3x-19)=2x+19}
q: `a(b^2+x^2)/(bx)=ac+ax/b` {$ b/c @x: a(b^2+x^2)/(bx)=ac+ax/b}
q: `cx^m/(a+bx)=dx^m/(e+fx)` {$ (ad-ce)/(cf-bd) @x: c(e+fx)=d(a+bx)}
q: It is required to find a number which being divided into 2 and into 3 equal parts, 4 times the product of the 2 equal parts shall be equal to the continued product of the 3 equal parts. {27 @x: 4(x/2)^2=(x/3)^3}
q: A rectangular floor is of a certain size. If it were 5 feet broader and 4 feet longer, it would contain 116 feet more; but if it were 4 feet broader and 5 feet longer, it would contain 113 feet more. Required its length {12} and breadth (feet). {9}
chk: x=12, y=9 | (y+5)(x+4)=xy+116 | (y+4)(x+5)=xy+113
== 35 | Powers, Roots, Radicals, and Inequalities | Involution: powers of monomials; squares and cubes of binomials
art: 172 | Involution, or Formation of Powers | The Power of a number is the product obtained by multiplying it a certain number of times by itself. Any number is the first power of itself. When the number is taken twice as a factor, the product is called the second power or square of the number. When the number is taken three times as a factor, the product is called the third power or cube of the number. In like manner, the fourth, fifth, etc., powers of a number are the products arising from taking the number, as a factor, four times, five times, etc. The Index or Exponent of the power is the number which denotes the power. It is written to the right of the number, and a little above it.
art: 172 | Examples | `3=3^1=3`, the 1st power of 3. `3*3=3^2=9`, the 2d power of 3. `3*3*3=3^3=27`, the 3d power of 3. `3*3*3*3=3^4=81`, the 4th power of 3. `(2/3)^4=16/81`, the 4th power of `2/3`. `a*a*a*a=a^4`, the 4th power of `a`. `ac^2*ac^2*ac^2=(ac^2)^3=a^3c^6`, the 3d power of `ac^2`.
art: 172 | General Rule for Raising any Quantity to any Required Power | Multiply the given quantity by itself, until it is taken as a factor as many times as there are units in the exponent of the required power. As this frequently involves a tedious operation, it is best to divide the subject into distinct cases.
art: 172 | Case I. To raise a Monomial Quantity to any Power | A coefficient is involved by repeated multiplications, as in arithmetic, and the literal factors by repeated additions of the exponents. Thus, the 3d power of 3 is `3*3*3=27`, but the 3d power of `a^2` is `a^2*a^2*a^2=a^(2+2+2)=a^(2*3)=a^6`. If the quantity to be involved is positive, any power of that quantity will be positive. If it is negative, the even powers will be positive and the odd powers negative. Thus, `-a*-a=+a^2`, and `-a*-a*-a=-a^3`. The 4th power of `-a` is `+a^4`; the 5th power is `-a^5`; and so on.
art: 172 | Rule for Involving a Monomial | 1. Involve the coefficient by the rule of arithmetic. 2. Multiply the exponents of the literal factors by the exponent of the required power. 3. If the quantity be negative, make the even powers positive and the odd powers negative.
mc: An odd power of a negative quantity is... | *negative | positive | either, depending on the coefficient
mc: To raise `a^2` to the 3d power... | *multiply the exponent 2 by 3 | add 3 to the exponent | cube the letter and keep the exponent
q: Find the square of `5ax^2z^3`. {$ 25a^2x^4z^6 @ (5ax^2z^3)^2}
q: The square of `-3b^2cd`. {$ 9b^4c^2d^2 @ (-3b^2cd)^2}
q: The cube of `2x^2z`. {$ 8x^6z^3 @ (2x^2z)^3}
q: The cube of `-3a^3c^2`. {$ -27a^9c^6 @ (-3a^3c^2)^3}
q: The fourth power of `-2xz^2`. {$ 16x^4z^8 @ (-2xz^2)^4}
q: The fifth power of `-3a^2b^3`. {$ -243a^10b^15 @ (-3a^2b^3)^5}
q: The seventh power of `-m^2n`. {$ -m^14n^7 @ (-m^2n)^7}
q: The square of `a^mb^(2n)`. {$ a^(2m)b^(4n) @ (a^mb^(2n))^2}
q: The `n`th power of `xy^2z^p`. {$ x^ny^(2n)z^(np) @ (xy^2z^p)^n}
q: The square {$ (4/25)a^6x^(2m+4)y^(2p-2) @ ((2/5)a^3x^(m+2)y^(p-1))^2} and the cube {$ (8/125)a^9x^(3m+6)y^(3p-3) @ ((2/5)a^3x^(m+2)y^(p-1))^3} of `(2/5)a^3x^(m+2)y^(p-1)`.
q: The square of `ax/(bz^2)`. {$ a^2x^2/(b^2z^4) @ (ax/(bz^2))^2}
q: The cube of `2a^2/(3c^3)`. {$ 8a^6/(27c^9) @ (2a^2/(3c^3))^3}
art: 172 | Case II. To square a Binomial Quantity | The rule for this has already been given, Arts. 78 and 79. A quantity consisting of three or four terms may be squared on the same principle, by reducing it to the form of a binomial, squaring, and completing the operations indicated. Thus, `a+b-c=a+(b-c)`. Squaring, we have `a^2+2a(b-c)+(b-c)^2=a^2+2ab-2ac+b^2-2bc+c^2`. Also `a+b-c+d=(a+b)-(c-d)`. Squaring, `(a+b)^2-2(a+b)(c-d)+(c-d)^2=a^2+2ab+b^2-2ac-2bc+2ad+2bd+c^2-2cd+d^2`.
q: Find the square of `a-x`. {$ a^2-2ax+x^2 @ (a-x)^2}
q: The square of `x+y`. {$ x^2+2xy+y^2 @ (x+y)^2}
q: The square of `mx-nx^2`. {$ m^2x^2-2mnx^3+n^2x^4 @ (mx-nx^2)^2}
q: The square of `(2/3)a+(1/2)b`. {$ (4/9)a^2+(2/3)ab+(1/4)b^2 @ ((2/3)a+(1/2)b)^2}
q: The square of `(x+5y)/(m^2-n^2)`. {$ (x^2+10xy+25y^2)/(m^4-2m^2n^2+n^4) @ ((x+5y)/(m^2-n^2))^2}
q: Find the square of `x-1/x-1`. {$ x^2-2x+1/x^2+2/x-1 @ (x-1/x-1)^2}
art: 172 | Case III. To raise a Binomial to the Third Power | By trial, we find the cube of `a+b` to be `a^3+3a^2b+3ab^2+b^3`. Hence, the cube of a binomial is equal to the cube of the first term, plus three times the square of the first into the second, plus three times the first into the square of the second, plus the cube of the second. If the quantity is a residual, as `a-b`, the result will be the same, except that the signs will be alternately plus and minus. A quantity consisting of three or four terms may be cubed in the same manner, by reducing it to the form of a binomial. Thus, `(a-b+c)^3=[(a-b)+c]^3=(a-b)^3+3(a-b)^2c+3(a-b)c^2+c^3`, which last may be further expanded.
mc: The cube of `a-b` is... | *`a^3-3a^2b+3ab^2-b^3` | `a^3-b^3` | `a^3-3a^2b-3ab^2-b^3`
q: Find the cube of `x+y`. {$ x^3+3x^2y+3xy^2+y^3 @ (x+y)^3}
q: The cube of `2x-z`. {$ 8x^3-12x^2z+6xz^2-z^3 @ (2x-z)^3}
q: The cube of `3x+2y`. {$ 27x^3+54x^2y+36xy^2+8y^3 @ (3x+2y)^3}
q: The cube of `(m-n)/(m-2n)`. {$ (m^3-3m^2n+3mn^2-n^3)/(m^3-6m^2n+12mn^2-8n^3) @ ((m-n)/(m-2n))^3}
q: The cube of `(1/2)a-(1/3)b`. {$ (1/8)a^3-(1/4)a^2b+(1/6)ab^2-(1/27)b^3 @ ((1/2)a-(1/3)b)^3}
q: Involve `(x-1/x)^3`. {$ x^3-3x+3/x-1/x^3 @ (x-1/x)^3}
q: Involve `(e^x+e^(-x))^3`. {$ e^(3x)+3e^x+3e^(-x)+e^(-3x) @ (e^x+e^(-x))^3}
q: Involve `(x+y+z)^3`. {$ x^3+3x^2y+3x^2z+3xy^2+6xyz+3xz^2+y^3+3y^2z+3yz^2+z^3 @ (x+y+z)^3}
art: 172 | Case IV. To raise a Binomial to any Power | Rules for raising a binomial, or residual quantity, to the 4th, 5th, 6th, or to any higher power, may be formed on the same principle as those given under Case II and Case III. An easier method, however, was discovered by Sir Isaac Newton. Newton's Theorem: let `a+b` be raised to the sixth power by actual multiplication. The powers are `(a+b)^2=a^2+2ab+b^2`; `(a+b)^3=a^3+3a^2b+3ab^2+b^3`; `(a+b)^4=a^4+4a^3b+6a^2b^2+4ab^3+b^4`; `(a+b)^5=a^5+5a^4b+10a^3b^2+10a^2b^3+5ab^4+b^5`; `(a+b)^6=a^6+6a^5b+15a^4b^2+20a^3b^3+15a^2b^4+6ab^5+b^6`. If we involve `a-b`, the result will be the same, except that the signs of the terms will be alternately plus and minus.
art: 172 | Laws of Development | 1st. Number of Terms: the number of terms in any power of a binomial is one more than the exponent of the power. Thus, the 2d power has 3 terms, the 3d power 4 terms, etc. 2d. Signs of Terms: if both terms of the binomial are positive, all the terms will be positive. If the second term is negative, the 1st, 3d, etc., or the odd terms, will be positive, and the even terms negative. 3d. Exponents: the exponent of the leading letter is the same, in the first term, as the power to which the quantity is to be raised, and diminishes by unity in the succeeding terms, disappearing in the last. The following letter is not found in the first term, but enters the second with an exponent of one, which exponent increases, by unity, in the succeeding terms, until it equals, in the last term, the exponent of the power. Thus, `(a+b)^6=a^6+a^5b+a^4b^2+a^3b^3+a^2b^4+ab^5+b^6`, omitting coefficients. 4th. The Coefficients: the coefficient of the first and last terms is always unity; that of the second term is the same as the exponent of the leading letter in the first term. The coefficient of any other term may be found by the following rule: Multiply the coefficient of any term by the exponent of its leading letter, and divide the product by the number expressing the place of that term in the series, for the coefficient of the succeeding term. The coefficients of all terms equally distant from the first and last are equal.
art: 172 | Example | Let it be required to expand `(x+y)^7`. Literal factors: `x^7`, `x^6y`, `x^5y^2`, `x^4y^3`, `x^3y^4`, `x^2y^5`, `xy^6`, `y^7`. The coefficient of the 1st term is unity; of the 2d, 7; of the 3d, `7*6/2=21`. Continuing thus, we have for the complete expansion `x^7+7x^6y+21x^5y^2+35x^4y^3+35x^3y^4+21x^2y^5+7xy^6+y^7`. As a second example, let it be required to expand `(a-b)^6`. The first term will be `a^6`; the second, `6a^5b`. For the third, multiply 6 by 5, and divide the product by 2, for the coefficient, and annex the literal factors. This gives `15a^4b^2`. Multiplying 15 by 4 and dividing by 3, we have for the next term `20a^3b^3`. Continuing this process, we find the next term to be `15a^2b^4`, the next `6ab^5`, and the last `b^6`. Giving the proper signs, we have `a^6-6a^5b+15a^4b^2-20a^3b^3+15a^2b^4-6ab^5+b^6`.
art: 172 | Further facts | 1st. The sum of the exponents in every term is the same, and is always equal to the power of the binomial. 2d. If the power of the binomial be even, the number of terms will be odd; but if the power be odd, the number of terms will be even. In the former case, there will be one middle term, and in the latter two, to the left and right of which the coefficients are the same. Thus, for the 6th power the coefficients are 1, 6, 15, 20, 15, 6, 1; for the 7th power, 1, 7, 21, 35, 35, 21, 7, 1. 3d. The sum of the coefficients, in every case, is equal to 2 raised to the required power of the binomial. Thus, `1+6+15+20+15+6+1=64=2^6`, and `1+7+21+35+35+21+7+1=128=2^7`.
q: How many terms are there in `(a+b)^9`? {10 @= 9+1}
mc: In `(a-b)^5`, the even terms (2d, 4th) are... | *negative | positive | zero
q: In `(a+b)^6`, the third term is `15a^4b^2`. What is the coefficient of the fourth term? {20 @= 15*4/3}
q: Write the coefficients for the 7th power, in order. {list: 1, 7, 21, 35, 35, 21, 7, 1}
q: What is the sum of the coefficients of `(a+b)^7`? {128 @= 2^7}
q: Expand `(a+b)^4`. {$ a^4+4a^3b+6a^2b^2+4ab^3+b^4 @ (a+b)^4}
q: Expand `(x+y)^6`. {$ x^6+6x^5y+15x^4y^2+20x^3y^3+15x^2y^4+6xy^5+y^6 @ (x+y)^6}
q: Expand `(a-x)^5`. {$ a^5-5a^4x+10a^3x^2-10a^2x^3+5ax^4-x^5 @ (a-x)^5}
q: Expand `(a+x)^8`. {$ a^8+8a^7x+28a^6x^2+56a^5x^3+70a^4x^4+56a^3x^5+28a^2x^6+8ax^7+x^8 @ (a+x)^8}
q: Expand `(a-b)^9`. {$ a^9-9a^8b+36a^7b^2-84a^6b^3+126a^5b^4-126a^4b^5+84a^3b^6-36a^2b^7+9ab^8-b^9 @ (a-b)^9}
art: 172 | Terms with coefficients or exponents | If one or both of the terms of the binomial have a coefficient or exponent greater than unity, or more than one literal factor, the expansion may be made in the same way, after which the operations indicated must be completed. Thus, `(2x^3+5a^2)^4=(2x^3)^4+4(2x^3)^3(5a^2)+6(2x^3)^2(5a^2)^2+4(2x^3)(5a^2)^3+(5a^2)^4=16x^12+160x^9a^2+600x^6a^4+1000x^3a^6+625a^8`. Or, put `m=2x^3` and `n=5a^2`. Then `(2x^3+5a^2)^4=(m+n)^4=m^4+4m^3n+6m^2n^2+4mn^3+n^4`. Returning to the values of `m` and `n`, we have `m^4=(2x^3)^4=16x^12`; `4m^3n=4*8x^9*5a^2=160x^9a^2`; `6m^2n^2=6*4x^6*25a^4=600x^6a^4`; `4mn^3=4*2x^3*125a^6=1000x^3a^6`; `n^4=(5a^2)^4=625a^8`. In a similar manner, a quantity consisting of three or four terms may be involved, by first reducing it to the form of a binomial, as explained in Cases II and III.
q: Raise `x^2+3y^2` to the fifth power, or expand `(x^2+3y^2)^5`. {$ x^10+15x^8y^2+90x^6y^4+270x^4y^6+405x^2y^8+243y^10 @ (x^2+3y^2)^5}
q: Expand `(2a^2+ax)^3`. {$ 8a^6+12a^5x+6a^4x^2+a^3x^3 @ (2a^2+ax)^3}
q: Expand `(2a+3x)^4`. {$ 16a^4+96a^3x+216a^2x^2+216ax^3+81x^4 @ (2a+3x)^4}
q: Expand `((1/2)a-3b)^4`. {$ (1/16)a^4-(3/2)a^3b+(27/2)a^2b^2-54ab^3+81b^4 @ ((1/2)a-3b)^4}
q: Cube `a+2b-c`. {$ a^3+6a^2b-3a^2c+8b^3+12ab^2-12b^2c-c^3+3ac^2+6bc^2-12abc @ (a+2b-c)^3}
art: 172 | Example 6 | Expand `(a+b+c-d)^4`. Ans. `a^4+4a^3b+6a^2b^2+4ab^3+b^4+4a^3c+12a^2bc+12ab^2c+4b^3c-4a^3d-12a^2bd-12ab^2d-4b^3d+6a^2c^2+12abc^2+6b^2c^2-12a^2cd-24abcd-12b^2cd+6a^2d^2+12abd^2+6b^2d^2+4ac^3-12ac^2d+12acd^2-4ad^3+4bc^3-12bc^2d+12bcd^2-4bd^3+c^4-4c^3d+6c^2d^2-4cd^3+d^4`. In many cases, as in some of the examples above, it will sometimes be found most convenient to involve by repeated multiplications, under the general rule.
q: The answer to Example 6, `(a+b+c-d)^4`, has how many terms? {35 @= 7*6*5/6}
q: If `x+1/x=p`, then `x^3+1/x^3` = {$ p^3-3p}
chk: x=2, p=5/2 | x+1/x=p | x^3+1/x^3=p^3-3p
tf: If two numbers differ by unity, the difference of their squares is equal to the sum of the numbers. {T}
tf: The sum of the cubes of any three consecutive integral numbers is divisible by the sum of those numbers. {T}
art: 172 | Note | For a more general discussion of the Binomial Theorem, see Art. 310.
== 36 | Extraction of the Square Root | Square root of numbers and fractions; approximate square roots
art: 173 | The Root of a number | The Root of a number is a factor which multiplied by itself a certain number of times will produce the given number. The Second or Square Root of a number is that number which multiplied by itself, that is, taken twice as a factor, will produce the given number. The Extraction of the Square Root is the process of finding the second root of a given number.
art: 174 | Number of figures in the root | Take the first ten numbers and their squares: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10; and 1, 4, 9, 16, 25, 36, 49, 64, 81, 100. The square root of any number less than 100 is either one figure, or one figure and a fraction. Hence, when the number of places of figures in a number is not more than two, the number of places of figures in the square root will be one. The square root of 100 is 10; and of any number greater than 100 and less than 10000, the square root will consist of two places of figures. Hence, when the number of places of figures is more than two, and not more than four, the number of places of figures in the square root will be two. In the same manner, when the number of places is more than four, and not more than six, the number of places in the square root will be three, and so on.
q: How many places of figures will the square root of 59049 have? {3}
art: 175 | Tens and units | Every number may be regarded as being composed of tens and units. Thus, 76 consists of 7 tens and 6 units; and 576 consists of 57 tens and 6 units. If we represent the tens by `t`, and the units by `u`, any number will be represented by `t+u`, and its square by `(t+u)^2=t^2+2tu+u^2=t^2+(2t+u)u`. Hence, the square of any number is composed of two quantities, one of which is the square of the tens, and the other twice the tens plus the units multiplied by the units. Thus, the square of 25: 2 tens squared is `20^2=400`; 4 tens plus 5 units, multiplied by 5, is `(40+5)5=225`; and `400+225=625`.
art: 175 | Example 1 | Required to extract the square root of 625. Since the number consists of three places of figures, its root will consist of two places; we separate it into two periods, 6 and 25. The greatest square contained in 600 is the square of 2 tens (20), which is 400. Subtracting this from 625, the remainder is 225. The remainder consists of twice the tens plus the units, multiplied by the units, that is `(2t+u)u`, of which `t` is already found to be 2. The unit's figure forms no part of the double product of the tens by the units; hence, if we divide the remaining figures (22) by the double of the tens (4), the quotient will be the unit's figure, or a figure greater than it. Dividing 22 by 4 gives 5 for a quotient. Multiplying `40+5=45` by 5, the product is 225. As there is no remainder, 25 is the exact square root of 625. In squaring and doubling the tens, it is customary to omit the ciphers, and to add the unit's figure to the double of the tens, by merely writing it in the unit's place.
art: 175 | Example 2 | Required to extract the square root of 59049. Since this number consists of five places of figures, its square root will consist of three places; we separate it into three periods, 5, 90, 49. We first find the square root of 590 (24) on the same principle as in the preceding example. We next consider 24 as so many tens, and proceed to find the unit's figure (3) in the same way. The root is 243.
art: 175 | Rule for the Extraction of the Square Root of Numbers | 1st. Separate the given number into periods of two places each, beginning at the unit's place. (The left period will often contain but one figure.) 2d. Find the greatest square in the left period, and place its root on the right, after the manner of a quotient in division. Subtract the square of the root from the left period, and to the remainder bring down the next period for a dividend. 3d. Double the root already found, and place it on the left for a divisor. Find how many times the divisor is contained in the dividend, exclusive of the right hand figure, and place the figure in the root and also on the right of the divisor. 4th. Multiply the divisor thus increased by the last figure of the root; subtract the product from the dividend, and to the remainder bring down the next period for a new dividend. 5th. Double the whole root already found for a new divisor, and continue the operation as before, until all the periods are brought down. Note: if, in any case, the division can not be effected, place a cipher in the root and divisor, and bring down the next period.
art: 176 | Remainder and divisor | In extracting the square root of numbers, the remainder may sometimes be greater than the divisor, while the last figure of the root can not be increased. To explain this, let `a` and `a+1` be two consecutive numbers. Then `(a+1)^2=a^2+2a+1`, the square of the greater, and `a^2` is the square of the less. Their difference is `2a+1`. Hence, the difference of the squares of two consecutive numbers is equal to twice the less number, increased by unity. Therefore, when any remainder is less than twice the root already found, plus one, the last figure can not be increased.
q: Required the square root of 2601. {51}
chk: x=51 | x^2=2601
q: Required the square root of 7225. {85}
chk: x=85 | x^2=7225
q: Required the square root of 47089. {217}
chk: x=217 | x^2=47089
q: Required the square root of 390625. {625}
chk: x=625 | x^2=390625
q: Required the square root of 43046721. {6561}
chk: x=6561 | x^2=43046721
q: Required the square root of 49042009. {7003}
chk: x=7003 | x^2=49042009
q: Required the square root of 1061326084. {32578}
chk: x=32578 | x^2=1061326084
q: Required the square root of 943042681. {30709}
chk: x=30709 | x^2=943042681
art: 177 | Extraction of the Square Root of Fractions | Since `2/5*2/5=4/25`, the square root of `4/25` is `2/5`; that is, `√(4/25)=√4/√25=2/5`. Hence, the Rule for Extracting the Square Root of a Fraction: extract the square root of both terms. When the terms of a fraction are not perfect squares, they may sometimes be made so by reducing. Thus, find the square root of `20/45`. Here, `20/45=(4*5)/(9*5)`. By canceling the common factor 5, the fraction becomes `4/9`, the square root of which is `2/3`. When both terms are perfect squares, and contain a common factor, the reduction may be made either before or after the square root is extracted. Thus, `√(36/81)=6/9=2/3`; or, `36/81=4/9`, and `√(4/9)=2/3`.
q: Required the square root of `64/121`. {8/11}
chk: x=8/11 | x^2=64/121
q: Required the square root of `225/400`. {3/4}
chk: x=3/4 | x^2=225/400
q: Required the square root of `9747/10092`. {57/58}
chk: x=57/58 | x^2=9747/10092
q: Required the square root of `56169/1000000`. {237/1000}
chk: x=237/1000 | x^2=56169/1000000
art: 178 | Perfect and Imperfect Squares | A Perfect Square is a number whose square root can be exactly ascertained; as, 4, 9, 16, etc. An Imperfect Square is a number whose square root can not be exactly ascertained; as, 2, 3, 5, 6, etc. Since the difference of two consecutive square numbers, `a^2` and `a^2+2a+1`, is `2a+1`, there are always `2a` imperfect squares between them. Thus, between the square of 5 (25) and the square of 6 (36), there are 10 (`2a=2*5`) imperfect squares. A quantity, affected by a radical sign, whose root can not be exactly found, is called a radical, or surd, or irrational root; as, `√2`, `√5`, etc. The root of such a quantity, expressed with more or less accuracy in decimals, is called the approximate value, or approximate root. Thus, 1.414+ is the approximate value of `√2`.
q: How many imperfect squares are there between the square of 9 and the square of 10? {18 @= 2*9}
mc: `√5` is called... | *a radical, or surd | a perfect square | a fraction
art: 179 | The root of an imperfect square is not a fraction | It might be supposed that when the square root of a whole number can not be expressed by a whole number, it might be exactly equal to some fraction. Let `c` be an imperfect square, as 2, and, if possible, let its square root be a fraction, `a/b`, in its lowest terms. Then `√c=a/b`, and `c=a^2/b^2`, by squaring both sides. Now, by supposition, `a` and `b` have no common factor; therefore, their squares can have no common factor, since to square a number, we merely repeat its factors. Consequently, `a^2/b^2` must be in its lowest terms, and can not be equal to a whole number. Hence, the supposition that `√c=a/b` is false; therefore, the square root of an imperfect square can not be a fraction.
tf: The square root of an imperfect square, as 2, can be exactly equal to some fraction. {F}
art: 180 | Approximate Square Roots | Let it be required to find the square root of 5 to within `1/3`. If we reduce 5 to a fraction whose denominator is 9 (the square of 3), we have `5=45/9`. Now, the square root of `45/9` is greater than `6/3`, and less than `7/3`; hence, `6/3`, or 2, is the square root of 5 to within `1/3`. To generalize: to extract the square root of `a` to within `1/n`, write `a` under the form `an^2/n^2`, and denote the entire part of the square root of `an^2` by `r`. Then the square root of `an^2/n^2` will lie between `r/n` and `(r+1)/n`. But the difference between these is `1/n`; therefore, `r/n` represents the square root of `a` to within `1/n`.
art: 180 | Rule for Extracting the Square Root of a Whole Number to within a Given Fraction | 1. Multiply the given number by the square of the denominator of the fraction, which determines the degree of approximation. 2. Extract the square root of this product to the nearest unit, and divide the result by the denominator of the fraction.
q: Find the square root of 3 to within `1/3`. {1 2/3 @= 5/3}
q: Of 10 to within `1/4`. {3 @= 12/4}
q: Of 19 to within `1/6`. {4 1/3 @= 26/6}
q: Of 30 to within `1/10`. {5.4 @= 54/10}
q: Of 75 to within `1/100`. {8.66 @= 866/100}
art: 180 | Decimal approximation | Since the square of 10 is 100, the square of 100, 10000, and so on, the number of ciphers in the denominator of a decimal fraction is doubled by squaring it. Therefore, when the fraction which determines the degree of approximation is a decimal, add two ciphers for each decimal place required; and, after extracting the square root, point off from the right one place of decimals for each two ciphers added.
q: Find the square root of 3 to five places of decimals. {1.73205}
q: Find the square root of 7 to five places of decimals. {2.64575|2.64576}
q: Find the square root of 500 to six places of decimals. {22.360679|22.36068}
art: 181 | Approximate square root of a fraction | Required to find the square root of `4/7` to within `1/7`. `4/7=(4*7)/(7*7)=28/49`. The square root of `28/49` is greater than `5/7` and less than `6/7`; therefore, `5/7` is the square root of `4/7` to within less than `1/7`. Hence, to find the square root of a fraction to within one of its equal parts: Rule. Multiply the numerator by its denominator, extract the square root of the product to the nearest unit, and divide the result by the denominator.
q: Find the square root of `7/11` to within `1/11`. {8/11}
q: Find the square root of `17/20` to within `1/20`. {9/10 @= 18/20}
art: 181 | Decimals | Any decimal, or whole number and decimal, may be written in the form of a common fraction having its denominator a perfect square, by adding ciphers to both terms. Thus, `.3=3/10=30/100`; `.156=1560/10000`; `1.2=120/100`. Rule. 1. Annex ciphers to the decimal, until the number of decimal places shall be equal to double the number required in the root. 2. After extracting the root, point off from the right the required number of decimal places. When the denominator of a fraction is a perfect square, extract the square root of the numerator to as many places of decimals as are required, and divide the result by the square root of the denominator. Or, reduce the fraction to a decimal, and then extract its square root. When the denominator of the fraction is not a perfect square, the latter method should be used. Thus, `√(5/16)=2.23606/4=.55901+`; or, `5/16=.3125`, and `√.3125=.55901+`.
q: Find the square root of .4 to six places. {.632455|.632456}
q: Find the square root of 7.532 to five places. {2.74444|2.74445}
q: Find the square root of `5/16` to five places. {.55901|.55902}
q: Find the square root of `3/5` to six places. {.774596|.774597}
q: Find the square root of `1 1/4` to five places. {1.11803}
q: Find the square root of `3 5/8` to six places. {1.903943}
q: Find the square root of `11 2/9` to six places. {3.349958|3.349959}
== 37 | Extraction of the Square Root | Square root of monomials and polynomials
art: 182 | Square Root of Monomials | To square a monomial (Art. 172), we square its coefficient, and multiply each exponent by 2. Thus, `(3mn^2)^2=9m^2n^4`. Therefore, `√(9m^2n^4)=3mn^2`. Hence, the Rule for Extracting the Square Root of a Monomial: extract the square root of the coefficient as a number, and divide the exponent of each letter by 2.
art: 182 | Plus or minus | Since `+a*+a=+a^2` and `-a*-a=+a^2`, therefore `√(a^2)=+a`, or `-a`. Hence, the square root of any positive quantity is either plus or minus. This is expressed by writing the double sign before the root. Thus, `√(4a^2)=±2a`; read, plus or minus 2a. If a monomial is negative, the extraction of the square root is impossible, since the square of any quantity, either positive or negative, is necessarily positive. Thus, `√-4` and `√-b` are algebraic symbols which indicate impossible operations. Such expressions are termed imaginary quantities. In an equation of the second degree, they often indicate some absurdity, or impossibility in the equation or problem from which it was derived.
mc: The square root of `4a^2` is... | *`±2a` | only `2a` | `2a^2`
tf: The square root of a negative monomial, as `√-4`, is an imaginary quantity. {T}
q: Find the square root of `16x^2y^4` (the book's answer is plus or minus this). {$ 4xy^2 @sq: 16x^2y^4}
q: Find the square root of `25m^2n^2`. {$ 5mn @sq: 25m^2n^2}
q: Find the square root of `m^2x^4y^6z^8`. {$ mx^2y^3z^4 @sq: m^2x^4y^6z^8}
q: Find the square root of `1024a^2b^6z^10`. {$ 32ab^3z^5 @sq: 1024a^2b^6z^10}
art: 182 | Monomial fractions | Since `(a/b)^2=a/b*a/b=a^2/b^2`, therefore `√(a^2/b^2)=√(a^2)/√(b^2)=±a/b`. Hence, to find the square root of a monomial fraction, extract the square root of both terms.
q: Find the square root of `a^2b^4/(c^2d^6)`. {$ ab^2/(cd^3) @sq: a^2b^4/(c^2d^6)}
q: Find the square root of `4x^2y^2/(25a^2b^4)`. {$ 2xy/(5ab^2) @sq: 4x^2y^2/(25a^2b^4)}
art: 183 | Square Root of Polynomials | To find a rule, let us first see how the terms of any quantity are related to the terms of its square. `(a+b)^2=a^2+2ab+b^2=a^2+(2a+b)b`. `(a+b+c)^2=a^2+(2a+b)b+(2a+2b+c)c`. `(a+b+c+d)^2=a^2+(2a+b)b+(2a+2b+c)c+(2a+2b+2c+d)d`. Here `a`, `b`, `c`, `d` may represent any algebraic quantities whatever, integral or fractional, positive or negative. This gives the following law: the square of any polynomial is equal to the square of the first term, plus twice the first term, plus the second, multiplied by the second, plus twice the first and second terms, plus the third, multiplied by the third, plus twice the first, second, and third terms, plus the fourth, multiplied by the fourth, and so on.
art: 183 | Rule for Extracting the Square Root of a Polynomial | 1st. Arrange the polynomial with reference to a certain letter. 2d. Extract the square root of the first term, place the result on the right, and subtract its square from the given quantity. 3d. Divide the first term of the remainder by double the part of the root already found, and annex the result to both the root and the divisor. Multiply the divisor thus increased by the second term of the root, and subtract the product from the remainder. 4th. Double the terms of the root already found for a partial divisor, divide the first term of the remainder by the first term of the divisor, and proceed in a similar manner to find the other terms.
art: 183 | Example | Find the square root of `4x^2y^2+12x^2y+9x^2-30xy^2-20xy^3+25y^4`. Arranged with reference to `y`: `25y^4-20xy^3+4x^2y^2-30xy^2+12x^2y+9x^2`. The square root of `25y^4` is `5y^2`; subtracting its square leaves `-20xy^3+4x^2y^2-...`. Dividing `-20xy^3` by `10y^2` gives `-2xy`; the divisor `10y^2-2xy` times `-2xy` takes away `-20xy^3+4x^2y^2`. Dividing `-30xy^2` by `10y^2` gives `-3x`; the divisor `10y^2-4xy-3x` times `-3x` takes away the rest. The root is `5y^2-2xy-3x`. Arranged by the powers of `x`, the root found is `3x+2xy-5y^2`, which is correct also, since `√(a^2+2ax+x^2)=±(a+x)=a+x`, or `-a-x`.
q: Find the square root of `4x^2y^2+12x^2y+9x^2-30xy^2-20xy^3+25y^4`. {$ 5y^2-2xy-3x @sq: 4x^2y^2+12x^2y+9x^2-30xy^2-20xy^3+25y^4}
q: Find the square root of `x^2+6ax+9a^2`. {$ x+3a @sq: x^2+6ax+9a^2}
q: Find the square root of `16x^2-40xy+25y^2`. {$ 4x-5y @sq: 16x^2-40xy+25y^2}
q: Find the square root of `4x^2z^2-12xyz+9y^2`. {$ 2xz-3y @sq: 4x^2z^2-12xyz+9y^2}
q: Find the square root of `49a^(4m-6)-42a^(6m-2)+9a^(8m+2)`. {$ 7a^(2m-3)-3a^(4m+1) @sq: 49a^(4m-6)-42a^(6m-2)+9a^(8m+2)}
q: Find the square root of `1+2x+7x^2+6x^3+9x^4`. {$ 1+x+3x^2 @sq: 1+2x+7x^2+6x^3+9x^4}
q: Find the square root of `9a^4-12a^3b+34a^2b^2-20ab^3+25b^4`. {$ 3a^2-2ab+5b^2 @sq: 9a^4-12a^3b+34a^2b^2-20ab^3+25b^4}
q: Find the square root of `x^6+4x^5+10x^4+20x^3+25x^2+24x+16`. {$ x^3+2x^2+3x+4 @sq: x^6+4x^5+10x^4+20x^3+25x^2+24x+16}
q: Find the square root of `9x^2-6xy+30xz+6xt+y^2-10yz-2yt+25z^2+10zt+t^2`. {$ 3x-y+5z+t @sq: 9x^2-6xy+30xz+6xt+y^2-10yz-2yt+25z^2+10zt+t^2}
q: Find the square root of `x^4-2x^3+3x^2/2-x/2+1/16`. {$ x^2-x+1/4 @sq: x^4-2x^3+3x^2/2-x/2+1/16}
q: Find the square root of `25a^2b^2/4-5abc^2/3+c^4/9`. {$ 5ab/2-c^2/3 @sq: 25a^2b^2/4-5abc^2/3+c^4/9}
q: Find the square root of `1051x^2/25-6x/5-14x^3/5+9+49x^4`. {$ 7x^2-x/5+3 @sq: 1051x^2/25-6x/5-14x^3/5+9+49x^4}
q: Find the square root of `a^2/b^2-2+b^2/a^2`. {$ a/b-b/a @sq: a^2/b^2-2+b^2/a^2}
q: Reduce `(a-b)^4-2(a^2+b^2)(a-b)^2+2(a^4+b^4)` to its simplest form, and extract the square root. {$ a^2+b^2 @sq: (a-b)^4-2*(a^2+b^2)*(a-b)^2+2*(a^4+b^4)}
q: Find the square root of `1-x^2` to five terms: type the terms one at a time. {list: 1, -x^2/2, -x^4/8, -x^6/16, -5x^8/128}
q: Find the first five terms of the square root of `x^2+a^2`, one at a time. {list: x, a^2/(2x), -a^4/(8x^3), a^6/(16x^5), -5a^8/(128x^7)}
art: 184 | Useful remarks | 1st. No binomial can be a perfect square; for the square of a monomial is a monomial, and the square of a binomial is a trinomial. Thus, `a^2+b^2` is not a perfect square, but if we add to it, or subtract from it, `2ab`, it becomes the square of `a+b` or of `a-b`. 2d. In order that a trinomial may be a perfect square, the two extreme terms must be perfect squares, and the middle term double the product of the square roots of the extreme terms. Hence, to find the square root of a trinomial when it is a perfect square: extract the square roots of the extreme terms, and unite them by the sign of the second term. Thus, `a^2+4ax+4x^2` is a perfect square, and its square root is `a+2x`; `4x^2+8xy+9y^2` is not a perfect square.
tf: A binomial, as `a^2+b^2`, can be a perfect square. {F}
tf: `4x^2+8xy+9y^2` is a perfect square. {F}
q: Find the square root of the trinomial `a^2+4ax+4x^2`. {$ a+2x @sq: a^2+4ax+4x^2}
q: What must be added to `a^2+b^2` to make it the square of `a+b`? {$ 2ab}
== 38 | Extraction of the Cube Root | Cube root of numbers and fractions; approximate cube roots
art: 185 | The Cube Root | The Cube, or third power of a number, is the product arising from taking it three times as a factor (Art. 172). The Cube Root, or third root of a number, is one of three equal factors into which it may be resolved. To extract the cube root of a number, is to find a number which, taken three times as a factor, will produce the given number.
art: 186 | Number of figures in the cube root | The first ten numbers are 1, 2, 3, 4, 5, 6, 7, 8, 9, 10; their cubes are 1, 8, 27, 64, 125, 216, 343, 512, 729, 1000. We see from this that the cube of a number consisting of one place of figures does not exceed three places. Since the cube of 10 is 1000, and the cube of 99, which is less than 100, is less than 1000000, the cube of a number consisting of two places of figures has more than three places, and not more than six places of figures. Again, since the cube of 100 is 1000000, and the cube of 1000 is 1000000000, the cube of a number consisting of three places of figures has more than six places, and not more than nine places of figures. If, therefore, we begin at the unit's place of a number, and separate it into periods of three places each, the number of periods will show the number of places of figures in the root. The left period will often contain only one or two figures.
q: How many places of figures will the cube root of 44361864 have? {3}
art: 187 | The cube of tens and units | Let `t` be the tens, and `u` the units of a given number. Then `t+u` is the number, and `(t+u)^3` its cube. But `(t+u)^3=t^3+3t^2u+3tu^2+u^3=t^3+(3t^2+3tu+u^2)u`. Hence, the cube of any number consisting of tens and units, is equal to the cube of the tens, plus three times the square of the tens, plus three times the product of the tens and units, plus the square of the units, all three multiplied by the units.
art: 187 | Example 1 | Required to extract the cube root of 13824. Separating the number into periods by points, 13 and 824, we find there will be two figures in the root. The greatest cube in 13 (thousand) is 8 (thousand), the cube root of which is 2 (`t`); and its cube, 8 (thousand), corresponds to `t^3` in the formula. Subtracting this from the given number leaves 5824, which corresponds to `(3t^2+3tu+u^2)u`. The first term, `3t^2`, is sometimes termed the trial divisor, as it is used to find the unit's figure `u`. If we divide by `3t^2` we may obtain a figure too large, on account of omitting the terms `3tu+u^2`; then we must take one that is less. Since the square of tens is hundreds, in using three times the square of the ten's figure as a trial divisor, we omit the figures (24) in the unit's and ten's places of the dividend. 12 is contained in 58 four times. This gives 4 for the unit's figure, and the complete divisor `3t^2+3tu+u^2=1200+240+16=1456`. Multiplying this by 4, the product is 5824, which, subtracted from the first remainder, leaves 0, and shows that 24 is the exact cube root required.
art: 187 | Example 2 | Required to find the cube root of 44361864. After separating the number into periods, we find the cube root (35) of 44361 on the same principles as in the preceding example. Then, considering 35 as so many tens, we find the unit's figure (4) in the same way. In dividing by the trial divisor 27, to find the second figure, we first obtain 6, but this is found by trial to be too large. The root is 354.
art: 187 | Rule for the Extraction of the Cube Root of Numbers | 1st. Separate the given number into periods of three places each, beginning at the unit's place. (The left period will often contain but one or two figures.) 2d. Find the greatest cube in the left period, and place its root on the right, as in division. Subtract the cube of the root from the left period, and to the remainder bring down the next period for a dividend. 3d. Square the root already found, and multiply it by 3 for a trial divisor. Find how many times this divisor is contained in the dividend, omitting the unit's and ten's figures, and write the result in the root. Add together the trial divisor with two ciphers annexed; three times the product of the last figure of the root by the rest, with one cipher annexed; and the square of the last figure; the sum will be the complete divisor. 4th. Multiply the complete divisor by the last figure of the root, and subtract the product from the dividend, and to the remainder bring down the next period for a new dividend, and so proceed until all the periods are brought down.
q: Extract the cube root of 13824. {24}
chk: x=24 | x^3=13824
q: Extract the cube root of 12167. {23}
chk: x=23 | x^3=12167
q: Extract the cube root of 39304. {34}
chk: x=34 | x^3=39304
q: Extract the cube root of 493039. {79}
chk: x=79 | x^3=493039
q: Extract the cube root of 2097152. {128}
chk: x=128 | x^3=2097152
q: Extract the cube root of 127263527. {503}
chk: x=503 | x^3=127263527
q: Extract the cube root of 403583419. {739}
chk: x=739 | x^3=403583419
q: Extract the cube root of 158252632929. {5409}
chk: x=5409 | x^3=158252632929
art: 187 | Rule for Extracting the Cube Root of a Fraction | Reduce the fraction, if necessary, to its lowest terms, and extract the cube root of both terms.
q: Find the cube root of `64/125`. {4/5}
chk: x=4/5 | x^3=64/125
q: Find the cube root of `216/2744`. {3/7}
chk: x=3/7 | x^3=216/2744
art: 188 | Perfect and Imperfect Cubes | A Perfect Cube is a number whose cube root can be exactly ascertained; as, 8, 27, 64, etc. An Imperfect Cube is a number whose cube root can not be exactly ascertained; as, 2, 3, 4, etc. It may be shown, by a course of reasoning precisely similar to that employed in Art. 179, that the cube root of an imperfect cube can not be a fraction.
tf: The cube root of an imperfect cube, as 2, can be exactly equal to a fraction. {F}
art: 189 | Approximate Cube Roots | Let it be required to find the cube root of 6 to within `1/4`. `6=384/64`. Now, the cube root of 384 is greater than 7 and less than 8; therefore, the cube root of `384/64` is greater than `7/4` and less than `8/4`; hence, `7/4` is the cube root of 6 to within less than `1/4`. To generalize: to extract the cube root of `a` to within `1/n`, write `a=an^3/n^3`, and let `r` be the root of the greatest cube contained in `an^3`. Then the cube root of `an^3/n^3` is between `r/n` and `(r+1)/n`; and since the difference of these is `1/n`, `r/n` is the cube root of `a` to within `1/n`.
art: 189 | Rule for Extracting the Cube Root of a Whole Number to within a Given Fraction | Multiply the given number by the cube of the denominator of the fraction which determines the degree of approximation; extract the cube root of this product to the nearest unit, and divide the result by the denominator of the fraction.
q: Find the cube root of 6 to within `1/4`. {1 3/4 @= 7/4}
q: Find the cube root of 5 to within `1/5`. {1 3/5 @= 8/5}
q: Find the cube root of 10 to within `1/8`. {2 1/8 @= 17/8}
art: 189 | Decimal approximation | Since the cube of 10 is 1000, the cube of 100, 1000000, and so on, the number of ciphers in the cube of the denominator of a decimal fraction is equal to three times the number in the denominator itself. Therefore, when the fraction which determines the degree of approximation is a decimal, add three ciphers for each decimal place required; and after extracting the root, point off from the right one place of decimals for each three ciphers added.
q: Find the cube root of 2 to five places. {1.25992}
q: Find the cube root of 37 to six places. {3.332222|3.332221}
art: 189 | Decimals and fractions | By adding ciphers to both terms, any decimal, or whole number and decimal, may be written in the form of a fraction having its denominator a perfect cube; thus, `.2=200/1000`, `.25=250/1000`, `6.4=6400/1000`, and so on. Therefore, to find the cube root: annex ciphers to the given decimal, until the number of decimal places shall be equal to three times the number required in the root. Extract the root, and point off from the right the required number of decimal places. To find the cube root of a fraction or a mixed number, first reduce the fraction to a decimal.
q: Find the cube root of .4 to four places. {.7368}
q: Find the cube root of 34.3 to six places. {3.249112|3.249113}
q: Find the cube root of `5/9` to five places. {.82207}
q: Find the cube root of `5 104/105` to three places. {1.816}
q: Divide the cube root of `2515.456/32768` by the square root of the square root of 8.3521. {.25 @= 0.425/1.7}
== 39 | Extraction of the Cube Root | Cube root of monomials and polynomials; 4th, 6th, nth roots; signs of roots
art: 190 | Cube Root of Monomials | If we cube, for example, `2ax^2`, we have `(2ax^2)^3=8a^3x^6`; that is, we cube the coefficient, and multiply the exponent of each letter by 3. Hence, conversely, the Rule for Extracting the Cube Root of a Monomial: extract the cube root of the coefficient, and divide the exponent of each letter by 3.
q: Find the cube root of `8x^3z^6`. {$ 2xz^2 @pow3: 8x^3z^6}
q: Find the cube root of `27x^6y^15`. {$ 3x^2y^5 @pow3: 27x^6y^15}
q: Find the cube root of `-64a^3m^6`. {$ -4am^2 @pow3: -64a^3m^6}
q: Find the cube root of `a^(3m+3c)x^6`. {$ a^(m+c)x^2 @pow3: a^(3m+3c)x^6}
art: 190 | Monomial fractions | Since `(a/b)^3=a^3/b^3`, therefore `∛(a^3/b^3)=a/b`. Hence, to find the cube root of a monomial fraction, extract the cube root of both terms.
q: Find the cube root of `8a^3/(27x^6)`. {$ 2a/(3x^2) @pow3: 8a^3/(27x^6)}
q: Find the cube root of `-64x^3y^6/(125m^3n^9)`. {$ -4xy^2/(5mn^3) @pow3: -64x^3y^6/(125m^3n^9)}
art: 191 | Cube Root of Polynomials | Let us first examine the relation that exists between a polynomial and its cube. `(a+b)^3=a^3+3a^2b+3ab^2+b^3=a^3+(3a^2+3ab+b^2)b`. `(a+b+c)^3=(a+b)^3+(3(a+b)^2+3(a+b)c+c^2)c`. Hence, the cube of a polynomial is formed according to the following law: the cube of a polynomial is equal to the cube of the first term, plus three times the square of the first term, plus three times the product of the first term by the second, plus the square of the second, all three multiplied by the second, plus three times the square of the first two terms, plus three times the product of the first two terms by the third, plus the square of the third, all three multiplied by the third, and so on.
art: 191 | Rule for Extracting the Cube Root of a Polynomial | 1st. Arrange the polynomial with reference to a certain letter. 2d. Extract the cube root of the first term for the first term of the root, and subtract its cube from the given polynomial. 3d. Take three times the square of the first term of the root, and call it a trial divisor for finding each of the remaining terms of the root. Find how often the trial divisor is contained in the first term of the remainder; this will give the second term of the root. Then form a complete divisor by adding together three times the square of the first term of the root, plus three times the product of the first term by the second, plus the square of the second. Multiply these by the second term of the root, and subtract the product from the first remainder. 4th. Again, find how often the trial divisor is contained in the first term of the remainder; this will give the third term of the root. Then form a complete divisor as before, by adding together three times the square of the first and second terms, plus three times the product of the first and second terms by the third, plus the square of the third. Multiply these by the third term of the root, and subtract the product from the last remainder. 5th. Continue thus till all the terms of the root are found.
art: 191 | Example | Find the cube root of `x^6-6x^5+12x^4+3a^2x^4-8x^3-12a^2x^3+12a^2x^2+3a^4x^2-6a^4x+a^6`. We first extract the cube root of `x^6`, which gives `x^2` for the first term of the root. Then 3 times the square of this, `3x^4`, is the trial divisor for finding the remaining terms. Dividing `-6x^5` by `3x^4` gives `-2x`, the second term of the root. The complete divisor is `3(x^2)^2+3(x^2*-2x)+(-2x)^2=3x^4-6x^3+4x^2`. Multiplying this by `-2x` and subtracting, the first term of the second remainder is `+3a^2x^4`, which divided by the trial divisor gives `+a^2` for the third term of the root. The root is `x^2-2x+a^2`.
art: 191 | Second Method | The following rule, applicable both to numerical and algebraic quantities, may be found more convenient in some cases. 1. Arrange the polynomial, as in the previous rule. 2. Extract the cube root of the first term, etc., as before. 3. Find the trial divisor and 2d term of the root, as before. 4. Cube the root already found, and subtract the result from the given polynomial. 5. Divide the first term of the remainder by the same trial divisor for the third term of the root. Cube the root already found, and subtract the result from the given polynomial. Continue this process until a quantity is found in the root which will be equal, when cubed, to the given polynomial. Remarks: a second method for extracting the square root, similar to the above, might be given, but it is less simple than the common rule. The process of cubing the root may be conducted by Newton's Theorem, as explained in Art. 172.
q: Find the cube root of `x^6-6x^5+12x^4+3a^2x^4-8x^3-12a^2x^3+12a^2x^2+3a^4x^2-6a^4x+a^6`. {$ x^2-2x+a^2 @pow3: x^6-6x^5+12x^4+3a^2x^4-8x^3-12a^2x^3+12a^2x^2+3a^4x^2-6a^4x+a^6}
q: Find the cube root of `a^3+24a^2b+192ab^2+512b^3`. {$ a+8b @pow3: a^3+24a^2b+192ab^2+512b^3}
q: Find the cube root of `8a^3-84a^2x+294ax^2-343x^3`. {$ 2a-7x @pow3: 8a^3-84a^2x+294ax^2-343x^3}
q: Find the cube root of `a^6-6a^5+15a^4-20a^3+15a^2-6a+1`. {$ a^2-2a+1 @pow3: a^6-6a^5+15a^4-20a^3+15a^2-6a+1}
q: Find the cube root of `x^6-9x^5+39x^4-99x^3+156x^2-144x+64`. {$ x^2-3x+4 @pow3: x^6-9x^5+39x^4-99x^3+156x^2-144x+64}
q: Find the cube root of `(a+1)^(6n)x^3-6ca^p(a+1)^(4n)x^2+12c^2a^(2p)(a+1)^(2n)x-8c^3a^(3p)`. {$ (a+1)^(2n)x-2ca^p @pow3: (a+1)^(6n)*x^3-6c*a^p*(a+1)^(4n)*x^2+12c^2*a^(2p)*(a+1)^(2n)*x-8c^3*a^(3p)}
q: Find the first three terms of the cube root of `1-x`, one at a time. {list: 1, -x/3, -x^2/9}
art: 192 | Fourth, Sixth, nth Roots | The fourth root of a number is one of four equal factors into which the number may be resolved; and, in general, the nth root of a number is one of the n equal factors into which the number may be resolved. When the degree of the root to be extracted is a multiple of two or more numbers, as 4, 6, etc., the root can be obtained by extracting the roots of more simple degrees. To explain this, we remark that `(a^3)^4=a^12`, and in general `(a^m)^n=a^(mn)`. Hence, the nth power of the mth power of a number is equal to the mnth power of the number. Reciprocally, the mnth root of a number is equal to the nth root of the mth root of that number. From this, it follows that the 4th root of `a` is `√(√a)`; the 6th root of `a` is the cube root of the square root of `a`, or the square root of the cube root; in like manner the 8th root of `a` is `√(√(√a))`, and so on.
q: Find the 4th root of 65536. {16}
chk: x=16 | x^4=65536
q: Find the 4th root of 13107.9601. {10.7}
chk: x=10.7 | x^4=13107.9601
q: Find the 6th root of 2985984. {12}
chk: x=12 | x^6=2985984
q: Find the 8th root of 214358881. {11}
chk: x=11 | x^8=214358881
q: Find the 4th root of `81a^4x^8`. {$ 3ax^2 @pow4: 81a^4x^8}
q: Find the 4th root of `a^4+4a^3bx+6a^2b^2x^2+4ab^3x^3+b^4x^4`. {$ a+bx @pow4: a^4+4a^3bx+6a^2b^2x^2+4ab^3x^3+b^4x^4}
q: Find the 4th root of `x^8-4x^6+10x^4-16x^2+19-16/x^2+10/x^4-4/x^6+1/x^8`. {$ x^2-1+1/x^2 @pow4: x^8-4x^6+10x^4-16x^2+19-16/x^2+10/x^4-4/x^6+1/x^8}
q: Find the 6th root of `a^6+1/a^6-6(a^4+1/a^4)+15(a^2+1/a^2)-20`. {$ a-1/a @pow6: a^6+1/a^6-6*(a^4+1/a^4)+15*(a^2+1/a^2)-20}
art: 193 | Signs of Roots | It has been shown already (Arts. 182, 183) that the square root of a monomial, or a polynomial, may be preceded either by the sign + or -. If we take the successive powers of `+a` and `-a`, we have `+a`, `+a^2`, `+a^3`, `+a^4`, and `-a`, `+a^2`, `-a^3`, `+a^4`, and so on. From this we see that every even power is positive, and that an odd power has the same sign as the root. Conversely, it is evident: 1st. That every odd root of a monomial must have the same sign as the monomial itself. Thus, `∛(8a^3)=2a`, `∛(-8a^3)=-2a`, and the 5th root of `-32a^10` is `-2a^2`. 2d. That an even root of a positive monomial may be either positive or negative. Thus, `∜(81a^4b^8)=±3ab^2`, and the 6th root of `64a^12` is `±2a^2`. 3d. That every even root of a negative monomial is impossible; since no quantity raised to a power of an even degree can give a negative result. Thus, `∜(-a^4)`, `∜-b` and the 6th root of `-c` are symbols of operations which can not be performed. They are imaginary expressions, like `√-a` and `√-b` (Art. 182).
tf: An odd root of a monomial has the same sign as the monomial itself. {T}
tf: An even root of a negative monomial, as `∜(-a^4)`, can be found exactly. {F}
mc: The 4th root of `81a^4b^8` is... | *`±3ab^2` | only `3ab^2` | `-3ab^2`
art: 194 | To Extract the nth Root of Any Quantity | In raising any monomial to the nth power (Art. 172), we raise the numeral coefficient to the nth power, and multiply each exponent by n; thus, `(2a^2b^4)^3=8a^6b^12`. Hence, conversely, to find the nth root of a monomial: extract the nth root of the coefficient, and divide the exponent of each letter by n. Rules for the extraction of any root of a numerical quantity, or algebraic polynomial, may be formed on the same principle as that of the cube root (Art. 191). Thus, since `(a+b)^4=a^4+(4a^3+6a^2b+4ab^2+b^3)b`, the trial divisor for the fourth root would be of the form `4a^3`, or four times the third power of the first term of the root, and the complete divisor of the form `4a^3+6a^2b+4ab^2+b^3`. For the fifth root, the trial divisor would be of the form `5a^4`, and so for any higher root. A more simple method would be like the Second Method for extracting the cube root: the trial divisors would be of the form `4a^3` for the 4th root, `5a^4` for the 5th root, `na^(n-1)` for the nth root, or, in general, n times the (n-1)th power of the first term of the root. Remark: in the following examples, find the root of the numeral coefficient by inspection. It is unnecessary to give rules for extracting the 5th, 7th, etc., roots of numbers, as these operations are readily performed by logarithms.
q: Find the 5th root of `-32a^5x^10`. {$ -2ax^2 @pow5: -32a^5x^10}
q: Find the 6th root of `729b^6c^18` (the book's answer is plus or minus this). {$ 3bc^3 @pow6: 729b^6c^18}
q: Find the 7th root of `128x^7y^14`. {$ 2xy^2 @pow7: 128x^7y^14}
q: Find the 8th root of `6561a^8b^16` (plus or minus). {$ 3ab^2 @pow8: 6561a^8b^16}
q: Find the 9th root of `-512x^9z^18`. {$ -2xz^2 @pow9: -512x^9z^18}
q: Find the 10th root of `1024b^10z^30` (plus or minus). {$ 2bz^3 @pow10: 1024b^10z^30}
q: Extract the nth root of `a^(4n)b^nc^(2n)`. {$ a^4bc^2}
q: Extract the 5th root of `32x^5-80x^4+80x^3-40x^2+10x-1`. {$ 2x-1 @pow5: 32x^5-80x^4+80x^3-40x^2+10x-1}
== 40 | Radical Quantities | Radicals: definitions; reduction to simplest form; common index
art: 195 | Rational and Radical Quantities | These quantities are generally called surds by English writers; while the French more properly term them radicals, from the Latin word radix, a root. A Rational Quantity is either not affected by the radical sign, or the root indicated can be exactly ascertained; thus, 2, `a`, `√4`, and `∛8` are rational quantities. A Radical Quantity is one affected by a radical sign, but whose indicated root can not be exactly expressed in numbers; thus, `√5=2.23606797` nearly.
mc: Which is a rational quantity? | *`∛8` | `√5` | `√2`
art: 196 | Perfect powers; fractional exponents | When a monomial is a perfect power of the nth degree, its numeral coefficient is a perfect power of that degree, and the exponent of each letter is divisible by n. Thus, `4a^2` is a perfect square, while `6a^2` is not; and `8a^6` is a perfect cube, while `6a^3`, `8a^2`, `7a^5`, etc., are not. In extracting any root, when the exact division of the exponent can not be performed, it may be indicated by a fraction. Thus, `√(a^3)` may be written `a^(3/2)`, and `∛(a^4)` may be written `a^(4/3)`; and, in general, the nth root of the mth power of `a` is `a^(m/n)`. Since `a` is the same as `a^1`, the square root of `a` may be expressed thus, `a^(1/2)`; the cube root thus, `a^(1/3)`; and the nth root thus, `a^(1/n)`. Hence, the numerator of the fractional exponent denotes the power of the quantity, and the denominator the root to be extracted. In this book a root higher than the 4th is typed as a fractional power: the 6th root of 4 is typed `4^(1/6)`.
mc: `∛(a^4)` may be written... | *`a^(4/3)` | `a^(3/4)` | `a^12`
mc: In `a^(m/n)`, the denominator `n` denotes... | *the root to be extracted | the power | the coefficient
art: 197 | Theorem | Any quantity affected with a fractional exponent may be transferred from one term of a fraction to the other, if, at the same time, the sign of its exponent be changed. This was established (Art. 81) when the exponent is integral. Let it be required to extract the cube root of `1/a^2`. As `1/a^2=a^-2`, therefore `∛(1/a^2)=∛(a^-2)`. But `∛(1/a^2)=1/a^(2/3)` and `∛(a^-2)=a^(-2/3)`. Therefore `1/a^(2/3)=a^(-2/3)`. In like manner, generally, `1/a^(m/n)=a^(-m/n)`.
tf: `1/a^(2/3)=a^(-2/3)` {T}
art: 198 | Coefficient; similar radicals | The Coefficient of the radical is the quantity which stands before the radical sign. Thus, in `a√b` and `2∛c`, the quantities `a` and 2 are called coefficients. Radicals are said to be of the same degree when they have the same index; as, `a^(2/3)` and `5^(2/3)`, or `∛(a^2)` and `∛(5^2)`. Similar radicals have the same index, and the same quantity under the radical sign; as, `a√b` and `c√b`; `3∛(a^2)` and `5∛(a^2)`. A radical quantity is raised to a power equal to the index of its root, by simply rejecting the radical sign with its index. Thus, the square of `√a` is `a`, the cube of `∛a` is `a`, the square of `√3` is 3, and so on.
mc: Which are similar radicals? | *`3∛(a^2)` and `5∛(a^2)` | `√a` and `∛a` | `a√b` and `a√c`
q: What is the cube of `∛(5a)`? {$ 5a}
art: 199 | Reduction of Radicals: Case I, to their simplest form | Reduction of radicals consists in changing the form of the quantities without altering their value. It is founded on the principle: the square root of the product of two or more factors is equal to the product of the square roots of those factors. That is, `√(ab)=√a*√b`; for squaring both members, `ab=a*b`. By this principle, `√36=√(4*9)=2*3`; `√144=√(9*16)=3*4`; `√8=√(4*2)=√4*√2=2√2`.
art: 199 | Rule for the Reduction of a Radical of the Second Degree to its Simplest Form | 1st. Separate the quantity to be reduced into two parts, one of which shall contain all the factors that are perfect squares, and the other the remaining factors. 2d. Extract the square root of the perfect square, and prefix it as a coefficient to the other part placed under the radical sign. To determine whether any numeral contains a factor that is a perfect square, divide it by either of the squares 4, 9, 16, etc.
q: Reduce `√12` to its simplest form. {$ 2√3 @sq: 12}
q: Reduce `√18`. {$ 3√2 @sq: 18}
q: Reduce `√45`. {$ 3√5 @sq: 45}
q: Reduce `√32`. {$ 4√2 @sq: 32}
q: Reduce `√(50a^3)`. {$ 5a√(2a) @sq: 50a^3}
q: Reduce `√(72a^2b^3)`. {$ 6ab√(2b) @sq: 72a^2b^3}
q: Reduce `√245`. {$ 7√5 @sq: 245}
q: Reduce `√448`. {$ 8√7 @sq: 448}
q: Reduce `√810`. {$ 9√10 @sq: 810}
q: Reduce `√(507b^3c^2)`. {$ 13bc√(3b) @sq: 507b^3c^2}
q: Reduce `√(1805a^4b^2)`. {$ 19a^2b√5 @sq: 1805a^4b^2}
art: 199 | Polynomials | In a similar manner, polynomials may sometimes be simplified. Thus, `√(3a^3-6a^2c+3ac^2)=√(3a(a^2-2ac+c^2))=(a-c)√(3a)`.
q: Reduce `√(a^3-a^2b)`. {$ a√(a-b) @sq: a^3-a^2b}
q: Reduce `√(ax^2-6ax+9a)`. {$ (x-3)√a @sq: ax^2-6ax+9a}
q: Reduce `√((x^2-y^2)(x+y))`. {$ (x+y)√(x-y) @sq: (x^2-y^2)*(x+y)}
art: 199 | Fractional radicals | To reduce a fractional radical to its simplest form: 1st. Render the denominator of the fraction a perfect square by multiplying or dividing both terms by the same quantity. 2d. Separate into two factors, one of which is a perfect square. 3d. Extract the square root of this factor, and write it as a coefficient to the other factor placed under the radical sign. Thus, `√(4/5)=√(20/25)=√(4/25*5)=(2/5)√5`; and `√(a/b)=√(ab/b^2)=√(1/b^2*ab)=(1/b)√(ab)`.
q: Reduce `√(4/5)` to its simplest form. {$ (2/5)√5 | 2√5/5 @sq: 4/5}
q: Reduce `√(a/b)` to its simplest form. {$ (1/b)√(ab) | √(ab)/b @sq: a/b}
q: Reduce `√(1/2)`. {$ (1/2)√2 | √2/2 @sq: 1/2}
q: Reduce `√(3/8)`. {$ (1/4)√6 | √6/4 @sq: 3/8}
q: Reduce `√(18/25)`. {$ (3/5)√2 | 3√2/5 @sq: 18/25}
q: Reduce `6√(1/12)`. {$ √3 @sq: 36/12}
q: Reduce `30√(3/10)`. {$ 3√30 @sq: 900*3/10}
q: Reduce `18√(5/72)`. {$ (3/2)√10 | 3√10/2 @sq: 324*5/72}
q: Reduce `√(c^2/b)`. {$ (c/b)√b | c√b/b @sq: c^2/b}
q: Reduce `√(3a/(5b))`. {$ (1/(5b))√(15ab) | √(15ab)/(5b) @sq: 3a/(5b)}
q: Reduce `√(a^3x^2/(4c^2y))`. {$ (ax/(2cy))√(ay) | ax√(ay)/(2cy) @sq: a^3x^2/(4c^2y)}
q: Reduce `(3xy^3/(98z^4))^(1/2)`. {$ (y/(14z^2))√(6xy) | y√(6xy)/(14z^2) @sq: 3xy^3/(98z^4)}
art: 200 | Radicals of any degree | The principle of Art. 199 is, evidently, applicable to radicals of any degree. Thus, `∛54=∛(27*2)=∛27*∛2=3∛2`. Similarly, `∛(2/3)=∛(2/3*3/3*3/3)=∛(18/27)=∛(1/27*18)=(1/3)∛18`.
q: Reduce `∛54` to its most simple form. {$ 3∛2 @pow3: 54}
q: Reduce `∛40`. {$ 2∛5 @pow3: 40}
q: Reduce `∛(81c^4)`. {$ 3c∛(3c) @pow3: 81c^4}
q: Reduce `∛(128a^6c^5)`. {$ 4a^2c∛(2c^2) @pow3: 128a^6c^5}
q: Reduce `∛(162m^4n^5)`. {$ 3mn∛(6mn^2) @pow3: 162m^4n^5}
q: Reduce `∜144` (the book writes the answer with a 4th root). {$ 2∜9 | 2√3 @pow4: 144}
q: Reduce `∛(1/2)`. {$ (1/2)∛4 | ∛4/2 @pow3: 1/2}
q: Reduce `∛(3/4)`. {$ (1/2)∛6 | ∛6/2 @pow3: 3/4}
q: Reduce `∛(1/6)`. {$ (1/6)∛36 | ∛36/6 @pow3: 1/6}
q: Reduce `∛(5/9)`. {$ (1/3)∛15 | ∛15/3 @pow3: 5/9}
q: Reduce `∜(2/3)`. {$ (1/3)∜54 | ∜54/3 @pow4: 2/3}
q: Reduce the 5th root of `3/4`, that is `(3/4)^(1/5)`. {$ (1/4)768^(1/5) @pow5: 3/4}
q: Reduce the 6th root of `1/2`, that is `(1/2)^(1/6)`. {$ (1/2)32^(1/6) @pow6: 1/2}
q: Reduce `∜162`. {$ 3∜2 @pow4: 162}
q: Reduce `∜3888`. {$ 6∜3 @pow4: 3888}
q: Reduce `∜(32a^5b^7)`. {$ 2ab∜(2ab^3) @pow4: 32a^5b^7}
q: Reduce the 5th root of `729a^6`, that is `(729a^6)^(1/5)`. {$ 3a(3a)^(1/5) @pow5: 729a^6}
art: 201 | The mnth root | The mnth root of any quantity may be simplified when it is a complete power of the mth or nth degree, as shown (Art. 192). Thus, `∜(9a^2)=√(√(9a^2))=√(3a)`. Also, the 6th root of `a^2-2ab+b^2` is the cube root of `√(a^2-2ab+b^2)`, which is `∛(a-b)`.
q: Reduce `∜(36a^2c^2)` to its simplest form. {$ √(6ac) @pow4: 36a^2c^2}
q: Reduce `∜(81m^2n^4)`. {$ 3n√m @pow4: 81m^2n^4}
q: Reduce the 6th root of `4a^2`. {$ ∛(2a) @pow6: 4a^2}
q: Reduce the 6th root of `16a^2c^4`. {$ ∛(4ac^2) @pow6: 16a^2c^4}
q: Reduce the 6th root of `125b^3`. {$ √(5b) @pow6: 125b^3}
art: 202 | Case II, to reduce a rational quantity to the form of a radical | If we square `a`, and then extract the square root of the square, the result is evidently `a`. That is, `a=√(a^2)=a^(2/2)`. In like manner, `a=∛(a^3)=a^(3/3)`, and generally, `a=(a^m)^(1/m)`. Hence, the Rule for reducing a Rational Quantity to the form of a Radical: raise the quantity to a power corresponding to the given root, and write it under the radical sign. Similarly, a coefficient may be passed under the radical sign. Thus, `2√3=√4*√3=√12`. Generally, `a*b^(1/m)=(a^m*b)^(1/m)`.
q: Reduce 6 to the form of the square root. {$ √36 @ 6}
q: Reduce -2 to the form of the cube root. {$ ∛-8 @ -2}
q: Reduce `3ax` to the form of the square root. {$ √(9a^2x^2) @ 3ax}
q: Reduce `m-n` to the form of the square root. {$ √(m^2-2mn+n^2) @ √((m-n)^2)}
q: Express `5√7` entirely under the radical sign. {$ √175 @ 5√7}
q: Express `a^2√b` entirely under the radical sign. {$ √(a^4b) @ a^2√b}
q: Pass the coefficient of the quantity `2∛5` under the radical sign. {$ ∛40 @ 2∛5}
art: 203 | Case III, to reduce radicals having different indices to equivalent radicals having a common index | This is done by multiplying both terms of the fractional exponent by the same number, which, evidently, does not change its value (Art. 118). Let it be required to reduce `∛(2a)` and `∜(3b)`, or `(2a)^(1/3)` and `(3b)^(1/4)`, to quantities of equal value, having the same index. `(2a)^(1/3)=(2a)^(4/12)=((2a)^4)^(1/12)=(16a^4)^(1/12)`. `(3b)^(1/4)=(3b)^(3/12)=((3b)^3)^(1/12)=(27b^3)^(1/12)`. Hence, the Rule: reduce the fractional exponents to a common denominator; then the numerator of each fraction will represent the power to which the corresponding quantity is to be raised, and the common denominator the index of the root to be extracted.
mc: `√3` and `∛2` reduced to a common index are... | *`27^(1/6)` and `4^(1/6)` | `9^(1/6)` and `8^(1/6)` | `3^(1/6)` and `2^(1/6)`
mc: `∛5` and `√4` reduced to a common index are... | *`25^(1/6)` and `64^(1/6)` | `125^(1/6)` and `16^(1/6)` | `5^(1/6)` and `4^(1/6)`
mc: `a^2` and `b^(1/2)` reduced to a common index are... | *`√(a^4)` and `√b` | `√(a^2)` and `√b` | `a^4` and `b`
mc: `∜a`, the 6th root of `5b`, and the 8th root of `6c`, reduced to a common index, are... | *`(a^6)^(1/24)`, `(625b^4)^(1/24)`, `(216c^3)^(1/24)` | `(a^4)^(1/24)`, `(25b^2)^(1/24)`, `(36c^2)^(1/24)` | `a^(1/24)`, `(5b)^(1/24)`, `(6c)^(1/24)`
mc: `√(a^3)`, `∛(a^2)`, and `∜(a^3)` reduced to a common index are... | *`(a^18)^(1/12)`, `(a^8)^(1/12)`, `(a^9)^(1/12)` | `(a^6)^(1/12)`, `(a^4)^(1/12)`, `(a^3)^(1/12)` | `(a^3)^(1/12)`, `(a^2)^(1/12)`, `(a^3)^(1/12)`
mc: `3^(2/3)`, `2^(3/4)`, and `5^(1/2)` reduced to a common index are... | *`6561^(1/12)`, `512^(1/12)`, `15625^(1/12)` | `9^(1/12)`, `8^(1/12)`, `5^(1/12)` | `81^(1/12)`, `64^(1/12)`, `125^(1/12)`
== 41 | Radical Quantities | Addition, subtraction, multiplication, division of radicals; rational denominators
art: 204 | Addition and Subtraction of Radicals | Required to find the sum of `3∛a` and `5∛a`. It is evident that 3 times and 5 times any quantity, must make 8 times that quantity; therefore, `3∛a+5∛a=8∛a`. But, if it were required to find the sum of `3√a` and `5∛a`, since `√a` and `∛a` are different quantities, we can only indicate their addition; thus, `3√a+5∛a`. Similarly, `3√2+7√2-4√2=6√2`. But `3√5` and `4√3` make `3√5+4√3`. So also `3√5` and `4∛5` make `3√5+4∛5`. Radicals that are not similar, may often be made so; thus, `√12` and `√27` are equal to `2√3` and `3√3`, and their sum is `5√3`. The same principles apply to the subtraction of radicals.
art: 204 | Rule for the Addition of Radicals | 1st. Reduce the radicals to their simplest forms, and, if necessary, to a common index. 2d. If the radicals are similar, find the sum of their coefficients, and prefix it to the common radical; but if they are not similar, connect them by their proper signs. Rule for the Subtraction of Radicals: change the sign of the subtrahend, and proceed as in addition of radicals.
q: Find the sum of `3∛a` and `5∛a`. {$ 8∛a @ 3∛a+5∛a}
q: Find the sum of `√448` and `√112`. {$ 12√7 @ √448+√112}
q: Find the sum of `∛24` and `∛81`. {$ 5∛3 @ ∛24+∛81}
q: Find the sum of `∛48` and `∛162`. {$ 5∛6 @ ∛48+∛162}
q: Find the sum of `√(18a^5b^3)` and `√(50a^3b^3)`. {$ (3a^2b+5ab)√(2ab) @ √(18a^5b^3)+√(50a^3b^3)}
q: Subtract `√180` from `√405`. {$ 3√5 @ √405-√180}
q: Subtract `∛40` from `∛135`. {$ ∛5 @ ∛135-∛40}
q: Perform the operations: `√243+√27+√48`. {$ 16√3 @ √243+√27+√48}
q: `√24+√54-√96` {$ √6 @ √24+√54-√96}
q: `√128-2√50+√72-√18` {$ √2 @ √128-2√50+√72-√18}
q: `√(48ab^2)+b√(75a)+√(3a(a-9b)^2)` (take `a-9b` positive) {$ a√(3a) @ 4b√(3a)+5b√(3a)+(a-9b)√(3a)}
q: `2√(5/3)+(1/6)√60+√15+√(3/5)` {$ (11/5)√15 | 11√15/5 @ 2√(5/3)+(1/6)√60+√15+√(3/5)}
q: `∛128-∛686-∛16+4∛250` {$ 15∛2 @ ∛128-∛686-∛16+4∛250}
q: `2∛(1/4)+8∛(1/32)` {$ 3∛2 @ 2∛(1/4)+8∛(1/32)}
q: `6(4a^2)^(1/6)+2∛(2a)+(8a^3)^(1/9)` (the 6th and 9th roots) {$ 9∛(2a) @ 6∛(2a)+2∛(2a)+∛(2a)}
q: `2√3-(1/2)√12+4√27-2√(3/16)` {$ (25/2)√3 | 25√3/2 @ 2√3-(1/2)√12+4√27-2√(3/16)}
q: `∜16+∛81-∛-512+∛192-7(9)^(1/6)` (the last is the 6th root of 9) {10}
chk: x=10 | x=∜16+∛81-∛(-512)+∛192-7*9^(1/6)
q: `√(ab^3/c^2)+(1/(2c))√(a^3b-4a^2b^2+4ab^3)` (take `a-2b` positive) {$ (a/(2c))√(ab) | a√(ab)/(2c) @ (b/c)√(ab)+((a-2b)/(2c))√(ab)}
art: 205 | Multiplication and Division of Radicals | The rule for the multiplication of radicals is founded on the principle (Art. 200) that the product of the nth root of two or more quantities is equal to the nth root of their product. That is, the nth root of `a` times the nth root of `b` is the nth root of `ab`. Hence (Art. 53), `a√b*c√d=ac√(bd)`. The rule for division is founded on the principle that the quotient of the nth roots of two quantities is equal to the nth root of their quotient. Raising both sides to the nth power, we have `a/b=a/b`, which shows that the equation is true.
art: 205 | Rules for the Multiplication and Division of Radicals | If the radicals have different indices, reduce them to the same index. Then, I. To Multiply: multiply the coefficients together for the coefficient of the product, and also the parts under the radical for the radical part of the product. II. To Divide: divide the coefficient of the dividend by the coefficient of the divisor for the coefficient of the quotient, and the radical part of the dividend by the radical part of the divisor for the radical part of the quotient.
art: 205 | Examples | 1. Multiply `2√(ab)` by `3a√(abc)`: `6a√(a^2b^2c)=6a*ab√c=6a^2b√c`. 2. Divide `4a√(ab)` by `2√(ac)`: `(4a/2)√(ab/(ac))=2a√(b/c)=2a√(bc/c^2)=(2a/c)√(bc)`. 3. Multiply `2∛3` by `3√2`: `2∛3=2*3^(2/6)=2(9)^(1/6)`; `3√2=3*2^(3/6)=3(8)^(1/6)`; multiplying, `6(72)^(1/6)`. 4. Divide `6√2` by `3∛2`: `6√2=6(8)^(1/6)` and `3∛2=3(4)^(1/6)`; dividing, we have `2(2)^(1/6)`.
q: Multiply `2√(ab)` by `3a√(abc)`. {$ 6a^2b√c @ 2√(ab)*3a√(abc)}
q: Divide `4a√(ab)` by `2√(ac)`. {$ (2a/c)√(bc) | 2a√(bc)/c @ 4a√(ab)/(2√(ac))}
q: Multiply `2∛3` by `3√2` (type the 6th root as a power). {$ 6*72^(1/6) @ 2∛3*3√2}
q: Divide `6√2` by `3∛2` (type the 6th root as a power). {$ 2*2^(1/6) @ 6√2/(3∛2)}
q: Multiply `3√12` by `5√18`. {$ 90√6 @ 3√12*5√18}
q: Multiply `4∛12` by `3∛4`. {$ 24∛6 @ 4∛12*3∛4}
q: Multiply together `5√3`, `7√(8/3)`, and `√2`. {140}
chk: x=140 | x=5√3*7√(8/3)*√2
q: Multiply `3∛b` by `4∜a` (a 12th root, typed as a power). {$ 12(a^3b^4)^(1/12) @ 3∛b*4∜a}
q: Multiply together `√2`, `∛3`, and `∜5` (a 12th root). {$ 648000^(1/12) @ √2*∛3*∜5}
q: Multiply together `x^(1/(2n))`, `x^(2/n)`, and `x^(3/(3n))`, the 2nth root of `x`, the nth root of `x^2`, and the 3nth root of `x^3`. {$ (x^7)^(1/(2n)) | x^(7/(2n)) @ x^(1/(2n))*x^(2/n)*x^(3/(3n))}
q: Divide `√40` by `√2`. {$ 2√5 @ √40/√2}
q: Divide `6√54` by `3√2`. {$ 6√3 @ 6√54/(3√2)}
q: Divide `70∛9` by `7∛18`. {$ 5∛4 @ 70∛9/(7∛18)}
q: Divide `72^(1/6)` (the 6th root of 72) by `√2`. {$ ∛3 @ 72^(1/6)/√2}
q: Divide `4∛9` by `2√3` (a 6th root). {$ 2*3^(1/6) @ 4∛9/(2√3)}
q: Divide `72^(1/6)` by `∛3`. {$ √2 @ 72^(1/6)/∛3}
q: Divide `∜(b/a)` by `∜(a/b)`. {$ √(b/a) | √(ab)/a @ ∜(b/a)/∜(a/b)}
art: 205 | Polynomials containing radicals | Polynomials containing radicals may also be multiplied; thus, multiply `3+√5` by `2-√5`: `6+2√5-3√5-5=1-√5`.
q: Multiply `3+√5` by `2-√5`. {$ 1-√5 @ (3+√5)*(2-√5)}
q: Multiply `√2+1` by `√2-1`. {$ 1 @ (√2+1)*(√2-1)}
q: Multiply `11√2-4√15` by `√6+√5`. {$ 2√3-√10 @ (11√2-4√15)*(√6+√5)}
q: Raise `√2+√3` to the 4th power. {$ 49+20√6 @ (√2+√3)^4}
q: Multiply `∛(12+√19)` by `∛(12-√19)`. {5}
chk: x=5 | x=∛(12+√19)*∛(12-√19)
q: Multiply `x^2-x√2+1` by `x^2+x√2+1`. {$ x^4+1 @ (x^2-x√2+1)*(x^2+x√2+1)}
q: Multiply `(x^2+1)(x^2-x√3+1)(x^2+x√3+1)`. {$ x^6+1 @ (x^2+1)*(x^2-x√3+1)*(x^2+x√3+1)}
art: 206 | Rational denominators | To reduce a fraction whose denominator contains radicals, to an equivalent fraction having a rational denominator: when the denominator is a monomial, as `a/√b`, it will become rational if we multiply both terms by `√b`. Thus, `a/√b=a√b/b`. Again, if the denominator is `∛a`, if we multiply both terms by `∛(a^2)`, the denominator will become `∛(a^3)=a`. In like manner, if the denominator is the nth root of `a^m`, it will become rational by multiplying it by the nth root of `a^(n-m)`. Therefore, when the denominator of the fraction is a monomial, multiply both terms by such a factor as will render the exponent of the quantity under the radical equal to the index of the radical.
art: 206 | Binomial denominators | Since the sum of two quantities, multiplied by their difference, is equal to the difference of their squares (Art. 80), if the fraction is of the form `a/(b+√c)`, and we multiply both terms by `b-√c`, the denominator will be rational. Thus, `a/(b+√c)=a(b-√c)/((b+√c)(b-√c))=(ab-a√c)/(b^2-c)`. If the denominator is `b-√c`, the multiplier will be `b+√c`. If the denominator is `√b-√c`, the multiplier will be `√b+√c`; and if it is `√b+√c`, the multiplier will be `√b-√c`. If the denominator is of the form `√a+√b+√c`, it may be rendered rational by two successive multiplications. The first will result in a quantity of the form `m-√n`, which may be made rational as before.
q: Reduce `1/√3` to an equivalent fraction having a rational denominator. {$ √3/3 | (1/3)√3 @ 1/√3}
q: Reduce `√3/√6`. {$ √2/2 | (1/2)√2 @ √3/√6}
q: Reduce `2/∛3`. {$ (2/3)∛9 | 2∛9/3 @ 2/∛3}
q: Reduce `6/(4^3)^(1/5)`, six over the 5th root of `4^3` (type the 5th root as a power). {$ (3/2)16^(1/5) | 3*16^(1/5)/2 @ 6/(4^3)^(1/5)}
q: Reduce `(8-5√2)/(3-2√2)`. {$ 4+√2 @ (8-5√2)/(3-2√2)}
q: Reduce `(√3+√2)/(√3-√2)`. {$ 5+2√6 @ (√3+√2)/(√3-√2)}
q: Reduce `(3√5-2√2)/(2√5-√18)`. {$ 9+(5/2)√10 | 9+5√10/2 @ (3√5-2√2)/(2√5-√18)}
q: Reduce `(3+4√3)/(√6+√2-√5)`. {$ √6+√2+√5 @ (3+4√3)/(√6+√2-√5)}
q: Simplify `1/(x+√(x^2-1))+1/(x-√(x^2-1))`. {$ 2x}
q: Simplify `(√(x^2+1)+√(x^2-1))/(√(x^2+1)-√(x^2-1))+(√(x^2+1)-√(x^2-1))/(√(x^2+1)+√(x^2-1))`. {$ 2x^2}
art: 206 | Remark | By the preceding transformations, the process of finding the numerical value of a fractional radical is very much abridged. Thus, to find the value of `2/√5`, we may divide 2 by the square root of 5, which is 2.2360679+. But `2/√5=2√5/5`, the true value of which is found by multiplying 2.2360679 by 2, and dividing the result by 5.
q: Find the numerical value of `2/√5` to six places. {.894427}
q: Find the numerical value of `1/√2` to six places. {.707106|.707107}
q: Reduce `(√20+√12)/(√5-√3)` to its simplest form, and find its numerical value to six places. {15.745966|15.745967}
== 42 | Radical Quantities | Powers and roots of radicals; imaginary quantities
art: 207 | Powers of Radicals | Let it be required to raise `∜(3a)` to the 3d power. Taking `∜(3a)` as a factor three times, we have `∜(3a)*∜(3a)*∜(3a)=∜(27a^3)`. So, the mth root of `a`, taken as a factor n times, is the mth root of `a^n`. Hence, the Rule for raising a Radical Quantity to any Power: raise the quantity under the radical to the given power, and affect the result with the primitive radical sign. If the quantity has a coefficient, it must also be raised to the given power. Thus, the 4th power of `2∛(3a^2)` is `16∛(81a^8)`. This, by reduction, becomes `16∛(27a^6*3a^2)=48a^2∛(3a^2)`.
art: 207 | Simplification | If the index of the radical is a multiple of the exponent of the power, the operation may be simplified. Thus, `(∜(2a))^2=(√(√(2a)))^2=√(2a)` (Art. 192). In general, the mnth root of `a`, raised to the nth power, is the mth root of `a`. Hence, if the index of the radical is divisible by the exponent of the power, we may perform this division, and leave the quantity under the radical sign unchanged. Thus, to raise the 8th root of `3a` to the 4th power, we have the 8th root of `81a^4`, which is `√(3a)`; or, dividing 8 by 4, we obtain at once `√(3a)`.
q: Raise `∛(2a)` to the 4th power. {$ 2a∛(2a) @ (∛(2a))^4}
q: Raise `3∛(2ab^2)` to the 4th power. {$ 162ab^2∛(2ab^2) @ (3∛(2ab^2))^4}
q: Raise `∜(ac^2)` to the 2d power. {$ c√a @ (∜(ac^2))^2}
q: Raise `√(ac^2)` to the 4th power. {$ a^2c^4 @ (√(ac^2))^4}
q: Raise `(3c^2)^(1/6)`, the 6th root of `3c^2`, to the 3d power. {$ c√3 @ ((3c^2)^(1/6))^3}
q: Raise `√(x-y)` to the 3d power. {$ (x-y)√(x-y) @ (√(x-y))^3}
art: 208 | Roots of Radicals | Since the mth root of the nth root of `a` is the mnth root of `a` (Art. 192), therefore, to extract the roots of radicals, we have the Rule: multiply the index of the radical by the index of the root to be extracted, and leave the quantity under the radical sign unchanged. Thus, the square root of `∛(2a)` is the 6th root of `2a`. If the radical has a coefficient, its root must also be extracted. If the quantity under the radical is a perfect power of the same degree as the root to be extracted, the process may be simplified. Thus, `∛(∛(8a^3))` is equal (Art. 192) to `∛(∛(8a^3))=∛(2a)`.
q: Extract the cube root of `√(a^2b)` (a 6th root, typed as a power). {$ (a^2b)^(1/6) @ (√(a^2b))^(1/3)}
q: The 4th root of `16a^8∛(2c)` (a 12th root, typed as a power). {$ 2a^2(2c)^(1/12) @pow4: 16a^8∛(2c)}
q: The square root of `∛(49a^2)`. {$ ∛(7a) @sq: ∛(49a^2)}
q: The cube root of `64∜(8a^6)`. {$ 4∜(2a^2) @pow3: 64∜(8a^6)}
q: The cube root of `(m+n)√(m+n)`. {$ √(m+n) @pow3: (m+n)√(m+n)}
art: 209 | Imaginary, or Impossible Quantities | An imaginary quantity (Arts. 182, 193) is an even root of a negative quantity. Thus, `√-a` and `∜(-b^4)` are imaginary quantities. The rules for the multiplication and division of radicals (Art. 205) require some modification when imaginary quantities are to be multiplied or divided. Thus, by the rule, `√-a*√-a=√(-a*-a)=√(a^2)=±a`. But, since the square root of any quantity multiplied by the square root itself, must give the original quantity (Art. 198), therefore, `√-a*√-a=-a`.
tf: `√-a*√-a=-a` {T}
art: 210 | Resolving imaginary quantities | Every imaginary quantity may be resolved into two factors, one a real quantity, and the other the imaginary expression `√-1`, or an expression containing it. This is evident, if we consider that every negative quantity may be regarded as the product of two factors, one of which is -1. Thus, `-a=a*-1`, `-b^2=b^2*-1`, and so on. Hence, `√(-a^2)=√(a^2*-1)=√(a^2)*√-1=±a√-1`. Since the square root of any quantity, multiplied by the square root itself, must give the original quantity, therefore `(√-1)^2=√-1*√-1=-1`. Also, `(√-1)^3=(√-1)^2*√-1=-1√-1=-√-1`, and `(√-1)^4=(√-1)^2(√-1)^2=(-1)(-1)=+1`. Attention to this principle will render all the algebraic operations, with imaginary quantities, easily performed. Thus, `√-a*√-b=√a*√-1*√b*√-1=√(ab)*(√-1)^2=-√(ab)`.
q: What is `(√-1)^3`? {$ -√-1 @ (√-1)^3}
q: What is `(√-1)^4`? {$ 1 @ (√-1)^4}
art: 210 | Binomials with imaginary terms | If it be required to find the product of `a+b√-1` by `a-b√-1`, we have `a^2+ab√-1-ab√-1+b^2=a^2+b^2`. Since `a^2+b^2=(a+b√-1)(a-b√-1)`, any binomial whose terms are positive may be resolved into two factors, one of which is the sum and the other the difference of a real and an imaginary quantity. Thus, `m+n=(√m+√n*√-1)(√m-√n*√-1)`.
q: Multiply `a+b√-1` by `a-b√-1`. {$ a^2+b^2 @ (a+b√-1)*(a-b√-1)}
q: Multiply `√(-a^2)` by `√(-b^2)`. {$ -ab @ a√-1*b√-1}
q: Find the 3d power of `a√-1`. {$ -a^3√-1 @ (a√-1)^3}
q: Find the 4th power of `a√-1`. {$ a^4 @ (a√-1)^4}
q: Multiply `2√-3` by `3√-2`. {$ -6√6 @ 2√-3*3√-2}
q: Divide `6√-3` by `2√-4`. {$ (3/2)√3 | 3√3/2 @ 6√-3/(2√-4)}
q: Simplify the fraction `(1+√-1)/(1-√-1)`. {$ √-1 @ (1+√-1)/(1-√-1)}
q: Find the continued product of `x+a`, `x+a√-1`, `x-a`, and `x-a√-1`. {$ x^4-a^4 @ (x+a)*(x+a√-1)*(x-a)*(x-a√-1)}
q: Of what number are `24+7√-1` and `24-7√-1` the imaginary factors? {$ 625 @ (24+7√-1)*(24-7√-1)}
== 43 | Fractional Exponents | Theory; multiplication, division, powers and roots with fractional exponents
art: 211 | Theory of Fractional Exponents | The rules for integral exponents in multiplication, division, involution, and evolution (Arts. 56, 70, 172, and 194) are equally applicable when the exponents are fractional. Fractional exponents have their origin (Art. 196) in the extraction of roots, when the exponent of the power is not divisible by the index of the root. Thus, the cube root of `a^2` is `a^(2/3)`. So the nth root of `a^m` is `a^(m/n)`. The forms `a^(2/3)`, `a^(4/3)`, and `a^(-m/n)` may be read a to the power of two thirds, a to the power of four thirds, and a to the power of minus m over n; or, a exponent two thirds, and so on.
mc: The nth root of `a^m` is... | *`a^(m/n)` | `a^(n/m)` | `a^(mn)`
art: 212 | Multiplication | It has been shown (Art. 56) that the exponent of any letter in the product is equal to the sum of its exponents in the two factors. The same rule applies when the exponents are fractional. Let it be required to multiply `a^(2/3)` by `a^(4/5)`. `a^(2/3)=a^(10/15)`, the 15th root of `a^10`, and `a^(4/5)=a^(12/15)`, the 15th root of `a^12` (Art. 205). Their product is the 15th root of `a^(10+12)=a^22`, that is, `a^(22/15)`. But this result is the same as that obtained by adding the exponents together: `a^(2/3)*a^(4/5)=a^(2/3+4/5)=a^(22/15)`. Hence, where the exponents of a quantity are fractional, To Multiply, the Rule: add the exponents. Again, to multiply `a^(-3/4)` by `a^(5/6)`: adding `-3/4` and `5/6`, we have `1/12`. Hence, the product is `a^(1/12)`, or the 12th root of `a`.
q: Multiply `a^(2/3)` by `a^(4/5)`. {$ a^(22/15) @ a^(2/3)*a^(4/5)}
q: Multiply `a^(-3/4)` by `a^(5/6)`. {$ a^(1/12) @ a^(-3/4)*a^(5/6)}
art: 213 | Division | By an explanation similar to that given in the preceding article, where the exponents of a quantity are fractional, To Divide, the Rule: subtract the exponent of the divisor from the exponent of the dividend.
q: Perform the operation `a^(1/2)*a^(2/3)`. {$ a^(7/6) @ a^(1/2)*a^(2/3)}
q: `a^(-1/2)*a^(2/3)` {$ a^(1/6) @ a^(-1/2)*a^(2/3)}
q: `a^(3/4)c^-1*a^2c^(3/5)` {$ a^(11/4)c^(-2/5) @ a^(3/4)*c^-1*a^2*c^(3/5)}
q: `(ay/x)^(1/2)*(bx/y^2)^(1/3)*(y^2/(a^3b^2))^(1/6)` {$ (y/x)^(1/6) @ (a*y/x)^(1/2)*(b*x/y^2)^(1/3)*(y^2/(a^3*b^2))^(1/6)}
q: `(a^(2/3)+a^(1/3)b^(1/3)+b^(2/3))(a^(1/3)-b^(1/3))` {$ a-b @ (a^(2/3)+a^(1/3)*b^(1/3)+b^(2/3))*(a^(1/3)-b^(1/3))}
q: `(x^(1/4)y+y^(2/3))(x^(1/4)-y^(-1/3))` {$ x^(1/2)y-y^(1/3) @ (x^(1/4)*y+y^(2/3))*(x^(1/4)-y^(-1/3))}
q: `(a+b)^(1/m)*(a+b)^(1/n)*(a-b)^(1/m)*(a-b)^(1/n)` {$ (a^2-b^2)^((m+n)/(mn)) @ (a+b)^(1/m)*(a+b)^(1/n)*(a-b)^(1/m)*(a-b)^(1/n)}
q: `x^(2/3)/x^(1/4)` {$ x^(5/12) @ x^(2/3)/x^(1/4)}
q: `x^(3/m)y^n/(x^(2/n)y^m)` {$ x^((3n-2m)/(mn))y^(n-m) @ x^(3/m)*y^n/(x^(2/n)*y^m)}
q: `(a^(3/4)-b^(3/4))/(a^(1/4)-b^(1/4))` {$ a^(1/2)+a^(1/4)b^(1/4)+b^(1/2) @ (a^(3/4)-b^(3/4))/(a^(1/4)-b^(1/4))}
q: `(a-b^2)/(a^(3/4)+a^(1/2)b^(1/2)+a^(1/4)b+b^(3/2))` {$ a^(1/4)-b^(1/2) @ (a-b^2)/(a^(3/4)+a^(1/2)*b^(1/2)+a^(1/4)*b+b^(3/2))}
art: 214 | Powers and Roots of Quantities with Fractional Exponents | Since the mth power of a quantity is the product of m factors, each equal to the quantity (Art. 172), to raise `a^(1/n)` to the mth power, we have `a^(1/n)*a^(1/n)*...` to m factors `=a^(m/n)`. Hence, to raise a quantity affected with a fractional exponent to any power, the Rule: multiply the fractional exponent by the exponent of the power. Thus, `(a^(1/2)b^(1/3))^4=a^(4/2)b^(4/3)=a^2b^(4/3)`.
art: 215 | Roots | Conversely, to extract any root of a quantity affected by a fractional exponent, the Rule: divide the exponent by the index of the root. Thus, the mth root of `a^(m/n)` is `a^(m/n*1/m)=a^(1/n)`.
q: Raise `a^(1/2)b^(1/3)` to the 4th power. {$ a^2b^(4/3) @ (a^(1/2)*b^(1/3))^4}
q: Raise `-2x^(1/2)y^(1/3)z^(1/4)` to the 3d power. {$ -8x^(3/2)yz^(3/4) @ (-2x^(1/2)*y^(1/3)*z^(1/4))^3}
q: Raise `-2x^(1/2)y^(1/3)z^(1/4)` to the 4th power. {$ 16x^2y^(4/3)z @ (-2x^(1/2)*y^(1/3)*z^(1/4))^4}
q: Raise `-2x^(1/2)y^(1/3)z^(1/4)` to the 6th power. {$ 64x^3y^2z^(3/2) @ (-2x^(1/2)*y^(1/3)*z^(1/4))^6}
q: Find the square of `a-(ax-a^2)^(1/2)`. {$ ax-2a(ax-a^2)^(1/2) @ (a-(a*x-a^2)^(1/2))^2}
q: Find the cube of `a^(1/3)x^-1+a^(-1/3)x`. {$ ax^-3+3a^(1/3)x^-1+3a^(-1/3)x+a^-1x^3 @ (a^(1/3)*x^-1+a^(-1/3)*x)^3}
q: Find the cube root of `(27a^3x)^(1/2)`. {$ 3^(1/2)a^(1/2)x^(1/6) | (3ax^(1/3))^(1/2) @pow3: (27a^3*x)^(1/2)}
q: Find the cube root of `(27a^3x)^(1/3)`. {$ (3ax^(1/3))^(1/3) | 3^(1/3)a^(1/3)x^(1/9) @pow3: (27a^3*x)^(1/3)}
q: Find the square root of `5x^3-4x(5cx)^(1/2)+4c`. {$ 5^(1/2)x^(3/2)-2c^(1/2) @sq: 5x^3-4x*(5c*x)^(1/2)+4c}
q: Find the cube root of `(1/8)a^3-(3/2)a^2b^(1/2)+6ab-8b^(3/2)`. {$ (1/2)a-2b^(1/2) @pow3: (1/8)a^3-(3/2)a^2*b^(1/2)+6a*b-8b^(3/2)}
== 44 | Equations Containing Radicals | Simple equations containing radicals
art: 216 | Equations Containing Radicals | In the solution of questions containing radicals, the method to be pursued will often depend on the judgment of the pupil, as many of them can be solved in different ways, and the shortest processes can only be learned from practice. 1st. When the equation to be solved contains only one radical expression, transpose it to one side of the equation and the rational terms to the other; then involve both sides to a power corresponding to the radical sign. Example: given `∛(a^3+x)-a=c`, to find `x`. Transposing, `∛(a^3+x)=c+a`; cubing, `a^3+x=c^3+3ac^2+3a^2c+a^3`; whence, `x=c^3+3ac^2+3a^2c`.
q: Given `∛(a^3+x)-a=c`, find `x`. x = {$ c^3+3ac^2+3a^2c @x: ∛(a^3+x)-a=c}
art: 216 | Radicals under radicals | 2d. When a radical expression occurs under the radical sign, the operation of involution must be repeated. Example: given `√(x-√(1-x))=1-√x`, to find `x`. Squaring, `x-√(1-x)=1-2√x+x`; canceling `x` on each side, and squaring again, `1-x=1-4√x+4x`. Canceling 1 on each side, transposing, squaring, and reducing, we find `x=16/25`.
q: Given `√(x-√(1-x))=1-√x`, find `x`. x = {16/25}
chk: x=16/25 | √(x-√(1-x))=1-√x
art: 216 | Two radicals | 3d. When there are two or more radical expressions, it is generally preferable to make one of them stand alone before performing the process of involution. Example: given `√(x+9)-√x=1`, to find `x`. Transposing `-√x`, we have `√(x+9)=1+√x`. Squaring each side, `x+9=1+2√x+x`. Canceling `x` on each side, transposing, and dividing by 2, `√x=4`; hence, `x=16`. In some cases, however, it is preferable, when an equation contains two radical expressions, to retain them both on the same side. Thus, the equation `√((x+a)/(x-a))+√((x-a)/(x+a))=b` will be cleared of radicals at once, by squaring each side; and `x=ab/√(b^2-4)`.
q: Given `√(x+9)-√x=1`, find `x`. x = {16}
chk: x=16 | √(x+9)-√x=1
q: Given `√((x+a)/(x-a))+√((x-a)/(x+a))=b`, find `x`. x = {$ ab/√(b^2-4) @x: 4x^2=b^2(x^2-a^2)}
q: Find `x`: `√(x+5)+3=8-√x`. x = {4}
chk: x=4 | √(x+5)+3=8-√x
q: Find `x`: `√(1+√(3+√(6x)))=2`. x = {6}
chk: x=6 | √(1+√(3+√(6x)))=2
q: Find `x`: `√(x+a)=√x+a` (the book's answer; it fits when `a` is less than 1). x = {$ (a-1)^2/4 @x: 4x=(1-a)^2}
q: Find `x`: `√(2x-3a)+√(2x)=3√a`. x = {$ 2a @x: √(2x-3a)+√(2x)=3√a}
q: Find `x`: `√(13+√(7+√(3+√x)))=4`. x = {1}
chk: x=1 | √(13+√(7+√(3+√x)))=4
q: Find `x`: `√(2+x)+√x=4/√(2+x)`. x = {2/3}
chk: x=2/3 | √(2+x)+√x=4/√(2+x)
q: Find `x`: `√(a+x)+√(a/x)=√x` (the book's answer, found by squaring). x = {$ a/(a+2√a) @x: x^2+a*x=(x-√a)^2}
q: Find `x`: `√(x+13)-√(x-11)=2`. x = {36}
chk: x=36 | √(x+13)-√(x-11)=2
q: Find `x`: `a√x+b√x-c√x=d`. x = {$ d^2/(a+b-c)^2 @x: (a+b-c)^2*x=d^2}
q: Find `x`: `(x-ax)/√x=√x/x`. x = {$ 1/(1-a) @x: x*(1-a)=1}
q: Find `x`: `x+a=√(a^2+x√(b^2+x^2))`. x = {$ (b^2-4a^2)/(4a) @x: x+a=√(a^2+x√(b^2+x^2))}
q: Find `x`: `(x-4)/(√x+2)=5√x-8+3√x/2`. x = {144/121}
chk: x=144/121 | (x-4)/(√x+2)=5√x-8+3√x/2
q: Find `x`: `(x-a)/(√x+√a)=(√x-√a)/3+2√a`. x = {$ 16a @x: (x-a)/(√x+√a)=(√x-√a)/3+2√a}
q: Find `x`: `(3x-1)/(√(3x)+1)=1+(√(3x)-1)/2`. x = {3}
chk: x=3 | (3x-1)/(√(3x)+1)=1+(√(3x)-1)/2
q: Find `x`: `√(4a+x)=2√(b+x)-√x`. x = {$ (b-a)^2/(2a-b) @x: x^2+b*x=(b+x-a)^2}
q: Find `x`: `√(b/(a+x))+√(c/(a-x))=∜(4bc/(a^2-x^2))`. x = {$ a(b+c)/(b-c) @x: b(a-x)+c(a+x)=0}
q: Find `x`: `(√(x+a)+√x)/(√(x+a)-√x)=c`. x = {$ a(c-1)^2/(4c) @x: (x+a)(c-1)^2=x(c+1)^2}
q: Find `x`: `√(√x+3)-√(√x-3)=√(2√x)`. x = {9}
chk: x=9 | √(√x+3)-√(√x-3)=√(2√x)
q: Find `x`: `1/x+1/a=√(1/a^2+√(1/(b^2x^2)+1/x^4))`. x = {$ 4ab^2/(a^2-4b^2) @x: 4/(a*x)+4/a^2=1/b^2}
q: Find `x`: `√((1+a)^2+(1-a)x)+√((1-a)^2+(1+a)x)=2a`. x = {8}
chk: x=8 | √((1+4)^2+(1-4)x)+√((1-4)^2+(1+4)x)=2*4
== 45 | Inequalities | Inequalities: propositions and examples
art: 217 | Inequalities | In the discussion of problems, it often becomes necessary to compare quantities that are unequal, and to operate upon them so as to determine the values of the unknown quantities, or to establish certain relations between them. In most cases the methods of operating on equations apply to inequalities, but there are some exceptions.
art: 218 | Negative quantities; same and contrary sense | In the theory of inequalities, it is convenient to consider negative quantities less than zero. In comparing two negative quantities, that is considered the least which contains the greatest number of units; thus, `0>-1`, and `-3>-5`. Two inequalities are said to subsist in the same sense, when the greater quantity stands on the right in both, or on the left in both; as, `5>3` and `7>4`. Two inequalities are said to subsist in a contrary sense, when the greater stands on the right in one and on the left in the other; as, `5>1` and `4<8`.
tf: `-3>-5` {T}
mc: `5>3` and `7>4` subsist in... | *the same sense | a contrary sense
art: 219 | Proposition I | If the same quantity, or equal quantities, be added to or subtracted from both members of an inequality, the resulting inequality will continue in the same sense. Thus, `7>5`; adding 4 to each member, `11>9`; subtracting 4 from each member, `3>1`. Also, `-5<-3`; and by adding and subtracting 4, `-1<+1`, and `-9<-7`. Similarly, if `a>b`, then `a+c>b+c`, or `a-c>b-c`. Hence, any quantity may be transposed from one side of an inequality to the other, if at the same time its sign be changed.
art: 220 | Proposition II | If two inequalities exist in the same sense, the corresponding members may be added together, and the resulting inequality will exist in the same sense. Thus, if `7>6`, and `5>4`; then, `7+5>6+4`, or `12>10`. When two inequalities exist in the same sense, if we subtract the corresponding members, the resulting inequality will exist, sometimes in the same, and sometimes in a contrary sense. First, `7>3` and `4>1`: subtracting, `3>2`, the same sense. Second, `10>9` and `8>3`: subtracting, `2<6`, a contrary sense. In general, if `a>b` and `c>d`, then, according to the particular values of `a`, `b`, `c`, and `d`, we may have `a-c>b-d`, `a-c<b-d`, or `a-c=b-d`.
tf: When two inequalities in the same sense are subtracted, the result is always in the same sense. {F}
art: 221 | Proposition III | If the two members of an inequality be multiplied or divided by a positive number, the resulting inequality will exist in the same sense. Thus, `8>4` and `8*3>4*3`, or `24>12`. Also, `8/2>4/2`, or `4>2`. This principle enables us to clear an inequality of fractions. If the multiplier be a negative number, the resulting inequality will exist in a contrary sense. Thus, `-3<-1`, but `-3*-2>-1*-2`, or `6>2`.
art: 222 | Proposition IV | The signs of all the terms of both members of an inequality may be changed, if at the same time we establish the resulting inequality in a contrary sense. For this is the same as multiplying both members by -1.
tf: Multiplying both members of an inequality by a negative number keeps it in the same sense. {F}
art: 223 | Proposition V | Both members of a positive inequality may be raised to the same power, or have the same root extracted, and the resulting inequality will exist in the same sense. Thus, `2<3` and `2^2<3^2`, `2^3<3^3`; or `4<9`, `8<27`; and so on. Also, `25>16`, and `√25>√16`, or `5>4`. But if the signs of both members of an inequality are not positive, the resulting inequality may exist in the same, or in a contrary sense. Thus, `3>-2`, and `3^2>(-2)^2`, or `9>4`. But, `-3<-2`, and `(-3)^2>(-2)^2`, or `9>4`.
mc: `-3<-2`. Squaring both members gives... | *`9>4`, a contrary sense | `9<4`, the same sense
art: 223 | Example 1 | Five times a certain whole number increased by 4, is greater than twice the number increased by 19; and 5 times the number diminished by 4, is less than 4 times the number increased by 4. Required the number. Let `x` be the number. Then `5x+4>2x+19` and `5x-4<4x+4`. From the first, `5x-2x>19-4` by transposing, `3x>15`, and `x>5` by dividing both members by 3. From the second, `5x-4x<4+4` by transposing, `x<8`. Hence, the number is greater than 5 and less than 8, consequently either 6 or 7 will fulfill the conditions.
q: In Example 1, the whole number is greater than 5 and less than 8. It may be {6} or {7}.
q: If `4x-7<2x+3`, and `3x+1>13-x`, find the whole number `x`. x = {4}
q: Find the limit of `x` in `7x-3>32`. {$ x>5 @ x>35/7}
q: Find the limit of `x` in the inequality `5+(1/3)x<8+(1/4)x`. {$ x<36 @ x<3*12}
art: 223 | Example 5 | Show that `(a+c+e)/(b+d+f)` is greater than the least, and less than the greatest of the fractions `a/b`, `c/d`, `e/f`, each letter representing a positive quantity. Suppose `a/b` to be the greatest, and `c/d` the least, of the fractions. Then `a/b>c/d`, `c/d=c/d`, `e/f>c/d`; and `a/b=a/b`, `c/d<a/b`, `e/f<a/b`. Hence `a>bc/d`, `c=dc/d`, `e>fc/d`, and `a=ab/b`, `c<da/b`, `e<fa/b` (Art. 221). Adding, `a+c+e>(b+d+f)c/d` and `a+c+e<(b+d+f)a/b` (Arts. 219, 220). Hence, `(a+c+e)/(b+d+f)>c/d`, and `(a+c+e)/(b+d+f)<a/b`.
art: 223 | Example 6 | It is required to prove that the sum of the squares of any two unequal magnitudes is always greater than twice their product. Since the square of every quantity, whether positive or negative, is positive, it follows that `(a-b)^2`, or `a^2-2ab+b^2>0`. Adding `+2ab` to each side (Art. 219), `a^2+b^2>2ab`, which was required to be proved. Most of the inequalities usually met with, are made to depend ultimately upon this principle.
tf: For any two unequal magnitudes, `a^2+b^2>2ab`. {T}
mc: Which is greater, `√5+√14` or `√3+3√2`? | *`√5+√14` | `√3+3√2`
q: Given `(1/4)(x+2)+(1/3)x<(1/2)(x-4)+3` and `>(1/2)(x+1)+1/3`, find the whole number `x`. x = {5}
q: The double of a certain number increased by 7, is not greater than 19, and its triple diminished by 5, is not less than 13. Required the number. {6}
art: 223 | Exercises to prove | Show that every fraction plus the fraction inverted, is greater than 2; that is, that `a/b+b/a>2` (from `a^2+b^2>2ab`, dividing by `ab`). Show that `a^2+b^2+c^2>ab+ac+bc`, unless `a=b=c`. Show that `abc>(a+b-c)(a+c-b)(b+c-a)`, unless `a=b=c`.
tf: `a/b+b/a>2` when `a` and `b` are positive and unequal. {T}
mc: If `x^2=a^2+b^2`, and `y^2=c^2+d^2`, which is greater, `xy` or `ac+bd`? | *`xy` | `ac+bd`
== 46 | Quadratic Equations | Pure quadratic equations; questions producing them
art: 224 | Quadratic Equations | A Quadratic Equation, or an equation of the second degree, is one in which the greatest exponent of the unknown quantity is 2; as, `x^2+x=a`. An equation containing two or more unknown quantities, in which the greatest sum of the exponents of the unknown quantities in one term is 2, is also a Quadratic Equation; as, `xy=a`, `xy-x-y=c`.
art: 225 | Pure and Affected | Quadratic equations, containing only one unknown quantity, are divided into two classes, pure and affected. A Pure Quadratic Equation is one that contains only the second power of the unknown quantity, and known terms; as, `x^2+2=47-4x^2`, and `ax^2+b=cx^2-d`. A pure quadratic equation is also called an incomplete equation of the second degree. An Affected Quadratic Equation is one that contains both the first and second power of the unknown quantity, and known terms; as, `5x^2+7x=34`, and `ax^2-bx^2+cx-dx=e-f`. An affected quadratic equation is also called a complete equation of the second degree.
mc: `5x^2+7x=34` is... | *an affected quadratic equation | a pure quadratic equation | a simple equation
art: 226 | General forms | The general form of a pure equation is `ax^2=b`. The general form of an affected equation is `ax^2+bx=c`. Every quadratic equation containing only one unknown quantity may be reduced to one of these forms. For, in a pure equation, all the terms containing `x^2` may be collected into one term of the form `ax^2`; and all the known quantities into another, as `b`. So, in an affected equation, all the terms containing `x^2` may be reduced to one term, as `ax^2`; and those containing `x` to one, as `bx`; and the known terms to one, as `c`.
art: 227 | Pure Quadratic Equations | 1. Let it be required to find the value of `x` in the equation `(1/3)x^2-3+(5/12)x^2=12 3/4-x^2`. Clearing of fractions, `4x^2-36+5x^2=153-12x^2`; transposing and reducing, `21x^2=189`; dividing, `x^2=9`; extracting the square root of both members, `x=±3`; that is, `x=+3`, or `x=-3`. Since the square of -3 is the same as the square of +3, the value `x=-3` will give the same result as `x=+3`. 2. Given `ax^2+b=d+cx^2`, to find the value of `x`. Transposing, `ax^2-cx^2=d-b`; factoring, `(a-c)x^2=d-b`; dividing, `x^2=(d-b)/(a-c)`; and `x=±√((d-b)/(a-c))`.
art: 227 | Rule for the Solution of a Pure Equation | Reduce the equation to the form `ax^2=b`. Divide by the coefficient of `x^2`, and extract the square root of both members.
q: Find `x` in `(1/3)x^2-3+(5/12)x^2=12 3/4-x^2`. x = plus or minus {3 @x: (1/3)x^2-3+(5/12)x^2=51/4-x^2}
q: Given `ax^2+b=d+cx^2`, find `x`. x = plus or minus {$ √((d-b)/(a-c)) @x: a*x^2+b=d+c*x^2}
art: 228 | Two roots | If we solve the equation `ax^2=b`, we have `x=±√(b/a)`; that is, `x=+√(b/a)`, and `x=-√(b/a)`. The equation may be verified by substituting either of these values of `x`. Hence, we infer, 1st. That in every pure equation the unknown quantity has two values, or roots, and only two. 2d. That these roots are equal in value, but have contrary signs.
tf: In every pure equation the unknown quantity has two roots, equal in value but with contrary signs. {T}
q: Find `x` in `11x^2-44=5x^2+10`. x = plus or minus {3 @x: 11x^2-44=5x^2+10}
q: Find `x` in `(1/3)(x^2-12)=(1/4)x^2-1`. x = plus or minus {6 @x: (1/3)(x^2-12)=(1/4)x^2-1}
q: Find `x` in `(x+2)^2=4x+5`. x = plus or minus {1 @x: (x+2)^2=4x+5}
q: Find `x` in `8/(1-2x)+8/(1+2x)=25`. x = plus or minus {.3 @x: 8/(1-2x)+8/(1+2x)=25}
q: Find `x` in `(x+7)/(x^2-7x)-(x-7)/(x^2+7x)=7/(x^2-73)`. x = plus or minus {9 @x: (x+7)/(x^2-7x)-(x-7)/(x^2+7x)=7/(x^2-73)}
q: Find `x` in `a/(b+x)+a/(b-x)=c`. x = plus or minus {$ (1/c)√(b^2c^2-2abc) | √(b^2c^2-2abc)/c @x: a/(b+x)+a/(b-x)=c}
q: Find `x` in `x√(6+x^2)=1+x^2` (the positive root). x = {1/2 @x: x√(6+x^2)=1+x^2}
q: Find `x` in `x+√(a^2+x^2)=2a^2/√(a^2+x^2)` (the positive root). x = {$ (a/3)√3 | a√3/3 @x: x+√(a^2+x^2)=2a^2/√(a^2+x^2)}
q: Find `x` in `2/(x+√(2-x^2))+2/(x-√(2-x^2))=x`. x = plus or minus {$ √3 @x: 2/(x+√(2-x^2))+2/(x-√(2-x^2))=x}
q: Find `x` in `(a-√(a^2-x^2))/(a+√(a^2-x^2))=b`. x = plus or minus {$ 2a√b/(b+1) @x: x^2(b+1)^2=4a^2b}
art: 229 | Questions Producing Pure Equations | For the statement of the equation, see Art. 154. 1. What two numbers have the ratio of 2 to 5, the sum of whose squares is 261? Let `2x` and `5x` be the numbers. Then `4x^2+25x^2=29x^2=261`; whence `x^2=9`, and `x=3`. Hence, `2x=6`, and `5x=15`, the required numbers.
q: What two numbers have the ratio of 2 to 5, the sum of whose squares is 261? {6} and {15}
chk: x=6, y=15 | x/y=2/5 | x^2+y^2=261
q: The square of a certain number diminished by 17, is equal to 130 diminished by twice the square of the number. Required the number. {7}
chk: x=7 | x^2-17=130-2x^2
q: Required a certain number, which being subtracted from 10 and the remainder multiplied by the number itself, gives the same product as 10 times the remainder after subtracting `6 2/5` from the number. {8}
chk: x=8 | (10-x)x=10(x-32/5)
q: What number is that, the `1/3` part of whose square being subtracted from 30, leaves a remainder equal to `1/4` of its square increased by 9? {6}
chk: x=6 | 30-x^2/3=x^2/4+9
q: There are two numbers whose difference is `2/9` of the greater, and the difference of their squares is 128; find them. {18} and {14}
chk: x=18, y=14 | x-y=2x/9 | x^2-y^2=128
art: 229 | Example 6 | Divide 21 into two such parts, that the square of the less shall be to that of the greater as 4 to 25. Let `x` and `21-x` be the parts. Then `x^2:(21-x)^2::4:25`; or, `25x^2=4(21-x)^2`; extracting the square root, `5x=2(21-x)`; whence, `x=6`, and `21-x=15`.
q: Divide 21 into two such parts, that the square of the less shall be to that of the greater as 4 to 25. The less is {6} and the greater {15}.
chk: x=6 | 25x^2=4(21-x)^2
q: Divide 14 into two such parts, that the quotient of the greater divided by the less, shall be to the quotient of the less by the greater, as 16 to 9. The greater is {8} and the less {6}.
chk: x=8 | 9(x/(14-x))=16((14-x)/x)
q: What number is that which being added to 20 and subtracted from 20, the product of the sum and difference shall be 319? {9}
chk: x=9 | (20+x)(20-x)=319
q: Find two numbers, whose product is 126, and the quotient of the greater by the less `3 1/2`. The less is {6} and the greater {21}.
chk: x=6, y=21 | x*y=126 | y/x=7/2
q: The product of two numbers is `p`, and their quotient `q`. Required the numbers. {$ √(pq)} and {$ √(p/q) | √(pq)/q}
chk: x=√(pq), y=√(p/q) | x*y=p | x/y=q
q: The sum of the squares of two numbers is 370, and the difference of their squares 208. Required the numbers. {9} and {17}
chk: x=17, y=9 | x^2+y^2=370 | x^2-y^2=208
q: The sum of the squares of two numbers is `c`, and the difference of their squares `d`. Required the numbers. {$ (1/2)√(2(c+d)) | √(2(c+d))/2 @ √((c+d)/2)} and {$ (1/2)√(2(c-d)) | √(2(c-d))/2 @ √((c-d)/2)}
q: A certain sum of money is lent at 5 per cent per annum. If we multiply the number of dollars in the principal by the number of dollars in the interest for 3 months, the product is 720. What is the sum lent, in dollars? {240}
chk: x=240 | x*(x*0.05/4)=720
q: It is required to find 3 numbers, such that the product of the 1st and 2d `=a`, the product of the 1st and 3d `=b`, and the sum of the squares of the 2d and 3d `=c`. The first is {$ √((a^2+b^2)/c)}, the second {$ a√(c/(a^2+b^2))}, and the third {$ b√(c/(a^2+b^2))}.
chk: x=√((a^2+b^2)/c), y=a√(c/(a^2+b^2)), z=b√(c/(a^2+b^2)) | x*y=a | x*z=b | y^2+z^2=c
art: 229 | Example 15 | The spaces through which a body falls in different periods of time, being to each other as the squares of those times, in how many seconds will a body fall through 400 ft., the space it falls through in one second being 16.1 ft.? Let `x` be the required number of seconds. Then `16.1:400::1^2:x^2`; whence, `x=4.98+` sec.
q: In what time will a body fall 1000 ft., if it falls 16.1 ft. in one second? Give the seconds to two decimal places. {7.88}
art: 229 | Example 16 | What two numbers are as 3 to 5, and the sum of whose cubes is 1216? Let `3x` and `5x` be the numbers. Then `27x^3+125x^3=152x^3=1216`; whence, `x^3=8`, and `x=∛8=2`. Hence the numbers are 6 and 10. This is properly a pure equation of the third degree; but questions producing such equations are generally arranged with those of the second degree.
q: What two numbers are as 3 to 5, and the sum of whose cubes is 1216? {6} and {10}
chk: x=6, y=10 | 5x=3y | x^3+y^3=1216
q: A money safe contains a certain number of drawers. In each drawer there are as many divisions as there are drawers, and in each division there are four times as many dollars as there are drawers. The whole sum in the safe is $5324; what is the number of drawers? {11}
chk: x=11 | 4x^3=5324
q: A and B set out to meet each other; A leaving the town C at the same time that B left D. They traveled the direct road from C to D, and on meeting, it appeared that A had traveled 18 miles more than B; and that A could have gone B's journey in `15 3/4` days, but B would have been 28 days in performing A's journey. What is the distance between C and D? {126} miles
chk: x=126 | 63/4*((x+18)/2)^2=28*((x-18)/2)^2
q: Two men, A and B, engaged to work for a certain number of days at different rates. At the end of the time, A, who had played 4 days, received 75 shillings; but B, who had played 7 days, received only 48 shillings. Had B played only 4 days, and A 7 days, they would have received the same sum. For how many days were they engaged? {19}
chk: x=19 | 48(x-4)/(x-7)=75(x-7)/(x-4)
q: A vintner draws a certain quantity of wine out of a full vessel that holds 256 gal.; and then filling the vessel with water, draws off the same number of gal. as before, and so on for four draughts; when there were only 81 gal. of pure wine left. How much wine did he draw each time? {64}, {48}, {36}, and {27} gal.
chk: x=64 | 256(1-x/256)^4=81
== 47 | Quadratic Equations | Affected quadratics: completing the square; the Hindoo method
art: 230 | Affected Quadratic Equations | 1. Required to find the value of `x` in the equation `x^2-6x+9=4`. It is evident, from Art. 184, that the first member of this equation is a perfect square. By extracting the square root of both members, we find `x-3=±2`; whence, `x=3±2=3+2=5`, or `3-2=1`. Verification: `5^2-6(5)+9=4`; that is, `25-30+9=4`. `1^2-6(1)+9=4`; that is, `1-6+9=4`. Hence, `x` has two values, +5 and +1, either of which verifies the equation.
q: Find `x` in `x^2-6x+9=4`. x = {$ 5 @x: x^2-6x+9=4} or {$ 1 @x: x^2-6x+9=4}
art: 230 | Example 2 | Required to find the value of `x` in the equation `x^2-6x=27`. As the left member of this equation is not a perfect square, we can not find the value of `x` by extracting the square root, as in the preceding example. We may, however, render the first member a perfect square by adding 9 to it. This may be done provided the same number be added to the other member, to preserve the equality. The equation then becomes `x^2-6x+9=36`. Extracting the square root, `x-3=±6`. Whence, `x=3±6=+9`, or `-3`, either of which values of `x` will verify the equation.
q: Find `x` in `x^2-6x=27`. x = {$ 9 @x: x^2-6x=27} or {$ -3 @x: x^2-6x=27}
art: 231 | Completing the square | Since every affected equation (Art. 226) may be reduced to the form `ax^2+bx=c`, dividing both sides by `a`, `x^2+(b/a)x=c/a`. For the sake of simplicity, let `b/a=2p`, and `c/a=q`. As each of these fractions may be either positive or negative, the equation must assume one of the four following forms: (1) `x^2+2px=q`; (2) `x^2-2px=q`; (3) `x^2+2px=-q`; (4) `x^2-2px=-q`. Hence, every affected equation may be reduced to the form `x^2±2px=±q`. We may consider `x^2+2px` as the first two terms of the square of a binomial, the third term being unknown or lost. Extracting the root of `x^2`, we find that the first term of the binomial must be `x`. We next observe that `2px` is twice the product of the first term by the second; therefore, `p`, which is half the coefficient of `x`, is the second term of the binomial, and its square, `p^2`, added to `x^2+2px`, will render it a perfect square. But, to preserve the equality, we must add the same quantity to both sides. This gives `x^2+2px+p^2=q+p^2`; extracting the square root, `x+p=±√(q+p^2)`; transposing, `x=-p±√(q+p^2)`. In each of the remaining three forms, the square may be completed on the same principle: (2) `x=+p±√(q+p^2)`; (3) `x=-p±√(-q+p^2)`; (4) `x=+p±√(-q+p^2)`.
mc: To complete the square of `x^2+2px`, add... | *`p^2`, the square of half the coefficient of `x` | `2p` | `4p^2`
art: 231 | Rule for the Solution of an Affected Equation | 1st. Reduce the equation, by clearing of fractions and transposition, to the form `ax^2+bx=c`. 2d. If the coefficient of `x^2` is minus, change the signs of all the terms, or multiply each term by -1. 3d. Divide each side of the equation by the coefficient of `x^2`. 4th. Add to each member the square of half the coefficient of `x`. 5th. Extract the square root of both sides, transpose the known term to the second member, and find the value of `x`. Remark: although from the equation `x^2=m^2`, we have `±x=±m`, that is, `+x=+m`, `+x=-m`, `-x=+m`, and `-x=-m`, it is evident that equations (1) and (4) are the same equation, as also (2) and (3). Hence, `+x=±m` embraces all the values of `x`. For the same reason it is necessary to take only the plus sign of the square root of `(x+p)^2`.
art: 231 | Examples | 1. Given `17x-2x^2=32-3x`, to find `x`. Transposing, `-2x^2+20x=32`; changing signs, and reducing, `x^2-10x=-16`; completing the square by adding `(10/2)^2=25` to both sides, `x^2-10x+25=-16+25=9`; extracting the root, `x-5=±3`; whence, `x=5±3=8`, or 2. 2. Given `3x^2-2x=65`: dividing by 3, `x^2-(2/3)x=65/3`; completing the square, `x^2-(2/3)x+(1/3)^2=65/3+(1/3)^2=196/9`; extracting the root, `x-1/3=±14/3`; whence, `x=1/3±14/3=5`, or `-4 1/3`. 3. Given `4a^2-2x^2+2ax=18ab-18b^2`: transposing, `-2x^2+2ax=-4a^2+18ab-18b^2`; dividing by -2, `x^2-ax=2a^2-9ab+9b^2`; completing the square, `x^2-ax+a^2/4=9a^2/4-9ab+9b^2`; extracting the root, `x-a/2=±(3a/2-3b)`; whence, `x=2a-3b`, or `-a+3b`.
q: Given `17x-2x^2=32-3x`, find `x`. x = {$ 8 @x: 17x-2x^2=32-3x} or {$ 2 @x: 17x-2x^2=32-3x}
q: Given `3x^2-2x=65`, find `x`. x = {$ 5 @x: 3x^2-2x=65} or {$ -13/3 @x: 3x^2-2x=65}
q: Given `4a^2-2x^2+2ax=18ab-18b^2`, find `x`. x = {$ 2a-3b @x: 4a^2-2x^2+2a*x=18a*b-18b^2} or {$ -a+3b @x: 4a^2-2x^2+2a*x=18a*b-18b^2}
art: 231 | Example 4 | Given `x+√(5x+10)=8`, to find `x`. By transposition, `√(5x+10)=8-x`; by squaring, `5x+10=64-16x+x^2`; or, `x^2-21x=-54`. Completing the square, `x^2-21x+(21/2)^2=441/4-54=225/4`; extracting the root, `x-21/2=±15/2`; whence, `x=21/2±15/2=36/2=18`, or `6/2=3`. These two values of `x` are the roots of the equation `x^2-21x=-54`, but they will not both verify the original equation. For, the proposed equation might have been `x±√(5x+10)=8`; and the operations which have been employed would result in the same equation, `x^2-21x=-54`, whether the sign of the radical part be + or -. Hence, in the equation `x+√(5x+10)=8`, the value of `x` is 3; but in the equation `x-√(5x+10)=8`, the value is 18.
q: In `x+√(5x+10)=8`, which value of `x` verifies the equation? x = {3 @x: x+√(5x+10)=8}
q: And in `x-√(5x+10)=8`? x = {18 @x: x-√(5x+10)=8}
q: Find `x`: `x^2+4x=60`. x = {$ 6 @x: x^2+4x=60} or {$ -10 @x: x^2+4x=60}
q: `x^2-4x=60` x = {$ 10 @x: x^2-4x=60} or {$ -6 @x: x^2-4x=60}
q: `x^2+16x=-60` x = {$ -6 @x: x^2+16x=-60} or {$ -10 @x: x^2+16x=-60}
q: `x^2-16x=-60` x = {$ 6 @x: x^2-16x=-60} or {$ 10 @x: x^2-16x=-60}
q: `x^2-6x=6x+28` x = {$ 14 @x: x^2-6x=6x+28} or {$ -2 @x: x^2-6x=6x+28}
q: `x^2/10+350-12x=0` x = {$ 70 @x: x^2/10+350-12x=0} or {$ 50 @x: x^2/10+350-12x=0}
q: `2x=4+6/x` x = {$ 3 @x: 2x=4+6/x} or {$ -1 @x: 2x=4+6/x}
q: `3x^2+10x=57` x = {$ 3 @x: 3x^2+10x=57} or {$ -19/3 @x: 3x^2+10x=57}
q: `(x-1)(x-2)=1` (one answer with ±) x = {$ 3/2±(1/2)√5 @x: (x-1)(x-2)=1}
q: `(1/2)x^2-(1/4)x+2=9` x = {$ 4 @x: (1/2)x^2-(1/4)x+2=9} or {$ -7/2 @x: (1/2)x^2-(1/4)x+2=9}
q: `x=1+110/x` x = {$ 11 @x: x=1+110/x} or {$ -10 @x: x=1+110/x}
q: `(x+22)/3-4/x=(9x-6)/2` x = {$ 2 @x: (x+22)/3-4/x=(9x-6)/2} or {$ 12/25 @x: (x+22)/3-4/x=(9x-6)/2}
q: `2x^2/3+3 1/2=x/2+8` x = {$ 3 @x: 2x^2/3+7/2=x/2+8} or {$ -9/4 @x: 2x^2/3+7/2=x/2+8}
q: `17x^2+19x=1848` (the book writes `9 15/17`) x = {$ 168/17 @x: 17x^2+19x=1848} or {$ -11 @x: 17x^2+19x=1848}
q: Find `z`: `z^2/3-z/10+1/6=1/5`. z = {$ 1/2 @z: z^2/3-z/10+1/6=1/5} or {$ -1/5 @z: z^2/3-z/10+1/6=1/5}
q: `3x-(1/4)x^2=10` (one answer with ±) x = {$ 6±2√-1 @x: 3x-(1/4)x^2=10}
q: `1/(x^2-3x)+1/(x^2+4x)=9/(8x)` x = {$ 4 @x: 1/(x^2-3x)+1/(x^2+4x)=9/(8x)} or {$ -29/9 @x: 1/(x^2-3x)+1/(x^2+4x)=9/(8x)}
q: `(x+4)/3-(7-x)/(x-3)=(4x+7)/9-1` x = {$ 21 @x: (x+4)/3-(7-x)/(x-3)=(4x+7)/9-1} or {$ 5 @x: (x+4)/3-(7-x)/(x-3)=(4x+7)/9-1}
q: `x+1/x=4/√3` x = {$ √3 @x: x+1/x=4/√3} or {$ (1/3)√3 | √3/3 @x: x+1/x=4/√3}
q: `(x+1/x)/(x-1/x)+(1+1/x)/(1-1/x)=13/4` x = {$ 3 @x: (x+1/x)/(x-1/x)+(1+1/x)/(1-1/x)=13/4} or {$ -7/5 @x: (x+1/x)/(x-1/x)+(1+1/x)/(1-1/x)=13/4}
q: `x/a+a/x-2/a=0` (one answer with ±) x = {$ 1±√(1-a^2) @x: x/a+a/x-2/a=0}
q: `(a^2-b^2)/c=2ax-cx^2` (one answer with ±) x = {$ (a±b)/c @x: (a^2-b^2)/c=2a*x-c*x^2}
q: `x^2-(a+b)x+ab=0` x = {$ a @x: x^2-(a+b)x+a*b=0} or {$ b @x: x^2-(a+b)x+a*b=0}
q: `(a-b)x^2-(a+b)x+2b=0` x = {$ 1 @x: (a-b)x^2-(a+b)x+2b=0} or {$ 2b/(a-b) @x: (a-b)x^2-(a+b)x+2b=0}
q: `mqx^2-mnx+pqx-np=0` x = {$ n/q @x: m*q*x^2-m*n*x+p*q*x-n*p=0} or {$ -p/m @x: m*q*x^2-m*n*x+p*q*x-n*p=0}
q: `x^2/(a^(1/2)+b^(1/2))-(a^(1/2)-b^(1/2))x=1/((ab^2)^(-1/2)+(a^2b)^(-1/2))` x = {$ a @x: x^2/(a^(1/2)+b^(1/2))-(a^(1/2)-b^(1/2))*x=1/((a*b^2)^(-1/2)+(a^2*b)^(-1/2))} or {$ -b @x: x^2/(a^(1/2)+b^(1/2))-(a^(1/2)-b^(1/2))*x=1/((a*b^2)^(-1/2)+(a^2*b)^(-1/2))}
q: `adx-acx^2=bcx-bd` x = {$ d/c @x: a*d*x-a*c*x^2=b*c*x-b*d} or {$ -b/a @x: a*d*x-a*c*x^2=b*c*x-b*d}
q: `√(x+5)=12/√(x+12)` (the book gives both roots of the cleared equation) x = {$ 4 @x: √(x+5)=12/√(x+12)} or {$ -21 @x: x^2+17x=84}
q: `(√(4x)+2)/(4+√x)=(4-√x)/√x` x = {4 @x: (√(4x)+2)/(4+√x)=(4-√x)/√x}
q: `√(x^3)-2√x=x` x = {4 @x: √(x^3)-2√x=x}
q: `√(x+a)-√(x+b)=√(2x)` (one answer with ±) x = {$ -(a+b)/2±(1/2)√(2a^2+2b^2) @x: 4x^2+4(a+b)x+4a*b=(a+b)^2}
q: `√(a+x)+√(a-x)=12a/(5√(a+x))` x = {$ 4a/5 @x: √(a+x)+√(a-x)=12a/(5√(a+x))} or {$ 3a/5 @x: √(a+x)+√(a-x)=12a/(5√(a+x))}
art: 232 | Hindoo Method of Solving Quadratics | When an equation is brought to the form `ax^2+bx=c`, it may be reduced to a simple equation, without dividing by the coefficient of `x^2`, thus avoiding fractions. If we multiply every term of the equation `ax^2+bx=c`, by four times the coefficient of the first term, and add to both sides the square of the coefficient of the second term, we shall have `4a^2x^2+4abx+b^2=4ac+b^2`. Now, the first member of this equation is a perfect square, and by extracting the square root of both sides, we have `2ax+b=±√(4ac+b^2)`, which is a simple equation. Hence, the Hindoo Rule: 1st. Reduce the equation to the form `ax^2+bx=c`. 2d. Multiply both sides by four times the coefficient of `x^2`. 3d. Add the square of the coefficient of `x` to each side, extract the square root, and finish the solution. Example: given `2x^2-5x=3`. Multiplying both sides by 8, `16x^2-40x=24`. Adding to each side 25, `16x^2-40x+25=49`. Extracting the root, `4x-5=±7`; whence, `x=3`, or `-1/2`.
mc: In the Hindoo method, multiply both sides of `ax^2+bx=c` by... | *`4a`, four times the coefficient of `x^2` | `a` | `b^2`
q: By the Hindoo rule: `2x^2-5x=3`. x = {$ 3 @x: 2x^2-5x=3} or {$ -1/2 @x: 2x^2-5x=3}
q: `3x^2+5x=2` x = {$ 1/3 @x: 3x^2+5x=2} or {$ -2 @x: 3x^2+5x=2}
q: `x^2+x=30` x = {$ 5 @x: x^2+x=30} or {$ -6 @x: x^2+x=30}
q: `x^2-x=72` x = {$ 9 @x: x^2-x=72} or {$ -8 @x: x^2-x=72}
q: `40/(x-5)+27/x=13` x = {$ 9 @x: 40/(x-5)+27/x=13} or {$ 15/13 @x: 40/(x-5)+27/x=13}
art: 232 | A shorter rule | By an inspection of the forms given in Art. 231, it will be seen that the value of the unknown quantity may be found without the formality of completing the square, by the following Rule: reduce the equation to the form `x^2+2px=q`. The unknown quantity will then be equal to one half the coefficient of its first power taken with a contrary sign, plus or minus the square root of the square of the number last written together with the known quantity in the second member of the equation taken with its proper sign. Thus, let `x^2+16x=-60`. Then, `x=-8±√(64-60)=-8±√4=-8±2`; `x=-6`, or `-10`. After some exercise in completing the square, it is best to employ this last method.
== 48 | Quadratic Equations | Problems producing affected equations
art: 233 | Problems Producing Affected Equations | 1. A person bought a certain number of sheep for $40, and if he had bought 2 more for the same sum they would have cost $1 apiece less. Required the number of sheep, and the price of each. Let `x` be the number of sheep. Then `40/x` is the price of one, and `40/(x+2)` the price of one on the second supposition. Therefore, `40/(x+2)=40/x-1`, by the question. Solving this equation, `x=-1±9=8`, or `-10`, number of sheep. And `40/x=40/8=$5`, price of each. Also, `40/x=40/-10=-4`. The negative value, -10, to fulfill the conditions of the question in an arithmetical sense, must be modified, on the principles explained in Art. 164, thus: a person sells a certain number of sheep for $40. If he had sold 2 fewer for the same sum he would have received $1 apiece more for them. Required the number sold.
q: A person bought a certain number of sheep for $40, and if he had bought 2 more for the same sum they would have cost $1 apiece less. He bought {8} sheep at {5} dollars each.
chk: x=8 | 40/(x+2)=40/x-1
art: 233 | Example 2 | Find a number such, that if 17 times the number be diminished by its square, the remainder shall be 70. Let `x` be the number. Then `17x-x^2=70`, or `x^2-17x=-70`. Whence, `x=7`, or 10. In this case, both values of `x` satisfy the question in its arithmetical sense. Thus, `17*7-7^2=119-49=70`, or `17*10-10^2=170-100=70`.
q: Find a number such, that if 17 times the number be diminished by its square, the remainder shall be 70. The number is {7} or {10}.
chk: x=7 | 17x-x^2=70
chk: x=10 | 17x-x^2=70
art: 233 | Example 3 | Of a number of bees, after `8/9`, and the square root of `1/2` of them, had flown away, there were two remaining; what was the number at first? To avoid radicals, let `2x^2` represent the number of bees at first. Then `16x^2/9+x+2=2x^2`. Whence, `x=6`, or `-1 1/2`; but the latter value, being fractional, though satisfying the equation, is excluded by the nature of the question; the number of bees is `2*6^2=72`.
q: Of a number of bees, after `8/9`, and the square root of `1/2` of them, had flown away, there were two remaining; what was the number at first? {72}
chk: x=72 | 8x/9+√(x/2)+2=x
art: 233 | Example 4 | Divide `a` into two parts, whose product shall be `b^2`. Let `x` be one part; then `a-x` is the other. Therefore, `x(a-x)`, or `ax-x^2=b^2`. Whence, `x=(1/2)(a±√(a^2-4b^2))`; that is, `x=(1/2)(a+√(a^2-4b^2))`, and `a-x=(1/2)(a-√(a^2-4b^2))`, are the parts required, and the two parts are the same, whether the upper or lower sign of the radical quantity be used. Thus, if the number `a` is 20, and `b` 8, the parts are 16 and 4, or 4 and 16. The forms of these results enable us to determine the limits under which the problem is possible; for it is evident that if `4b^2` be greater than `a^2`, `√(a^2-4b^2)` becomes imaginary. The extreme possible case will be, when `√(a^2-4b^2)=0`, in which case `x=(1/2)a`, and `a-x=(1/2)a`; also, `b^2=(1/4)a^2`, and `b=(1/2)a`. In the following examples, that value of the unknown quantity only is given, which satisfies the conditions of the question in an arithmetical sense.
q: Divide `a` into two parts, whose product shall be `b^2`. One part is {$ a/2+(1/2)√(a^2-4b^2) | (1/2)(a+√(a^2-4b^2)) @x: a*x-x^2=b^2} and the other {$ a/2-(1/2)√(a^2-4b^2) | (1/2)(a-√(a^2-4b^2)) @x: a*x-x^2=b^2}
q: If `a` is 20, and `b` 8, the two parts are {16} and {4}.
chk: x=16, y=4 | x+y=20 | x*y=64
mc: Dividing `a` into two parts whose product is `b^2` is impossible when... | *`4b^2` is greater than `a^2` | `a` is greater than `2b` | `b` is negative
q: What two numbers are those whose sum is 20 and product 36? {2} and {18}
chk: x=2, y=18 | x+y=20 | x*y=36
q: Divide 15 into two such parts that their product shall be to the sum of their squares as 2 to 5. {5} and {10}
chk: x=5 | 5x(15-x)=2(x^2+(15-x)^2)
q: Find a number such, that if you subtract it from 10, and multiply the remainder by the number itself, the product shall be 21. {7} or {3}
chk: x=7 | (10-x)x=21
chk: x=3 | (10-x)x=21
q: Divide 24 into two such parts that their product shall be equal to 35 times their difference. {10} and {14}
chk: x=10 | x(24-x)=35(24-2x)
q: Divide the number 346 into two such parts that the sum of their square roots shall be 26. (Let `x` be the square root of one of the parts, and `26-x` of the other.) {121} and {225}
chk: x=121, y=225 | x+y=346 | √x+√y=26
q: What number added to its square root gives 132? {121}
chk: x=121 | x+√x=132
q: What number exceeds its square root by `48 3/4`? {56 1/4}
chk: x=225/4 | x-√x=195/4
q: What two numbers are those, whose sum is 41, and the sum of whose squares is 901? {15} and {26}
chk: x=15, y=26 | x+y=41 | x^2+y^2=901
q: What two numbers are those, whose difference is 8, and the sum of whose squares is 544? {12} and {20}
chk: x=12, y=20 | y-x=8 | x^2+y^2=544
q: A merchant sold a piece of cloth for $24, and gained as much per cent as the cloth cost him. Required the first cost, in dollars. {20}
chk: x=20 | x+x*x/100=24
q: Two persons, A and B, had a distance of 39 miles to travel, and they started at the same time; but A, by traveling `1/4` of a mile an hour more than B, arrived one hour before him; find their rates of traveling. A {3 1/4} and B {3} mi. per hr.
chk: x=3 | 39/x-39/(x+1/4)=1
q: A and B distribute $1200 each among a number of persons; A gives to 40 persons more than B, and B gives $5 apiece to each person more than A; find the number of persons. A gives to {120} and B to {80}.
chk: x=80 | 1200/x-1200/(x+40)=5
q: From two towns, distant from each other 320 miles, two persons, A and B, set out at the same instant to meet each other; A traveled 8 miles a day more than B, and the number of days before they met was equal to half the number of miles B went in a day; how many miles did each travel per day? A {24} and B {16} mi.
chk: x=16 | (x/2)(x+x+8)=320
q: A set out from C toward D, and traveled 7 miles a day. After he had gone 32 miles, B set out from D toward C, and went every day `1/19` of the whole journey; and after he had traveled as many days as he went miles in one day, he met A. Required the distance from C to D. {76} or {152} miles
chk: x=76 | 32+7(x/19)+(x/19)^2=x
chk: x=152 | 32+7(x/19)+(x/19)^2=x
q: A grazier bought a certain number of oxen for $240, and after losing 3 sold the remainder for $8 a head more than they cost him, thus gaining $59 by his bargain. What number did he buy? {16}
chk: x=16 | (x-3)(240/x+8)=240+59
q: Divide the number 100 into two such parts that their product may be equal to the difference of their squares. Give each to three decimal places. {38.197} and {61.803}
q: Two persons, A and B, jointly invested $500 in business; A let his money remain 5 months, and B only 2, and each received back $450, capital and profit. How much did each advance? A {200} dollars, B {300} dollars
chk: x=200 | (450-x)/(5x)=(450-(500-x))/(2(500-x))
q: It is required to divide each of the numbers 11 and 17 into two parts, so that the product of the first parts of each may be 45, and of the second parts 48. (Represent the four parts by `x`, `11-x`, `45/x`, and `17-45/x`.) 11 = {5} + {6}, and 17 = {9} + {8}
chk: x=5 | (11-x)(17-45/x)=48
q: Divide each of the numbers 21 and 30 into two parts, so that the first part of 21 may be three times as great as the first part of 30; and that the sum of the squares of the remaining parts may be 585. 21 = {18} + {3}, and 30 = {6} + {24}
chk: x=6 | (21-3x)^2+(30-x)^2=585
q: Divide each of the numbers 19 and 29 into two parts, so that the difference of the squares of the first parts of each may be 72, and the difference of the squares of the remaining parts 180. 19 = {7} + {12}, and 29 = {11} + {18}
chk: x=7, y=11 | y^2-x^2=72 | (29-y)^2-(19-x)^2=180
== 49 | Quadratic Equations | Discussion of the general equation: properties of the roots; imaginary roots; particular cases
art: 234 | Discussion of the General Equation in Quadratics | The discussion of the general equation in quadratics consists in investigating its general properties, and in interpreting the results derived from making particular suppositions on the different quantities which it contains. Taking the general form (Art. 231), `x^2+2px=q`, and completing the square, we have `x^2+2px+p^2=q+p^2`. Now, `x^2+2px+p^2=(x+p)^2`. For the sake of simplicity, put `q+p^2=m^2`; that is, `√(q+p^2)=m`. Then `(x+p)^2=m^2`; transposing, `(x+p)^2-m^2=0`. But, since the left member is the difference of two squares, it may be resolved into two factors (Art. 93); this gives `(x+p+m)(x+p-m)=0`. Now, this equation can be satisfied in two ways, and in only two; that is, by making either of the factors equal to 0. If we make the second factor equal to zero, `x+p-m=0`, or `x=-p+m=-p+√(q+p^2)`. If we make the first factor equal to zero, `x+p+m=0`, or `x=-p-m=-p-√(q+p^2)`. Hence, Property 1st: every quadratic equation has two roots (or values of the unknown quantity), and only two.
art: 234 | Property 2d | From the equation `(x+p+m)(x+p-m)=0`, we derive Property 2d: every affected equation, reduced to the form `x^2+2px=q`, may be decomposed into two binomial factors, of which the first term in each is `x`, and the second, the two roots with the signs changed. Thus, the two roots of the equation `x^2-7x+10=0`, are `x=2` and `x=5`. Hence, `x^2-7x+10=(x-2)(x-5)`. It is now evident that the direct method of resolving a quadratic trinomial into its factors, is to place it equal to zero, and then find the roots of the resulting equation. By reversing the operation, we can readily form an equation whose roots shall have any given values. Thus, let it be required to form an equation whose roots shall be -3 and 4. We must have `x=-3`, or `x+3=0`, and `x=4`, or `x-4=0`. Hence, `(x+3)(x-4)=0`; or, `x^2-x-12=0`; or, `x^2-x=12`, which is an equation whose roots are -3 and +4.
tf: Every quadratic equation has two roots, and only two. {T}
q: Resolve `x^2-7x+10` into factors by finding the roots of `x^2-7x+10=0`. {$ (x-2)(x-5)}
q: Find an equation whose roots are 4 and 5. {$ x^2-9x=-20 @ (x-4)(x-5)=0}
chk: x=4 | x^2-9x=-20
chk: x=5 | x^2-9x=-20
q: Find an equation whose roots are `-1/2` and `+1/3`. {$ x^2+(1/6)x=1/6 | x^2+x/6=1/6 @ (x+1/2)(x-1/3)=0}
chk: x=-1/2 | x^2+x/6=1/6
chk: x=1/3 | x^2+x/6=1/6
q: Find an equation, without fractional coefficients, whose roots are `2/3` and `4/5`. {$ 15x^2-22x=-8 @ (3x-2)(5x-4)=0}
chk: x=2/3 | 15x^2-22x=-8
chk: x=4/5 | 15x^2-22x=-8
q: Find an equation whose roots are `m+n` and `m-n`. {$ x^2-2mx=n^2-m^2 @ (x-m-n)(x-m+n)=0}
chk: x=m+n | x^2-2m*x=n^2-m^2
chk: x=m-n | x^2-2m*x=n^2-m^2
art: 234 | Properties 3d and 4th | Resuming the equation `x^2+2px=q`, and denoting the two roots by `x'` and `x''`, we have `x'=-p+√(q+p^2)` and `x''=-p-√(q+p^2)`. Adding, `x'+x''=-2p`. But `-2p` is the coefficient of `x`, taken with a contrary sign. Hence, Property 3d: the sum of the two roots of a quadratic equation, reduced to the form `x^2+2px=q`, is equal to the coefficient of the first power of `x`, taken with a contrary sign. If we take the product of the roots, we have `x'x''=p^2-(q+p^2)=-q`. But `-q` is the known term of the equation, taken with a contrary sign. Hence, Property 4th: the product of the two roots of a quadratic equation, reduced to the form `x^2+2px=q`, is equal to the known term taken with a contrary sign. In the preceding demonstrations, we have regarded `2p` and `q` as both positive; but the same conclusions will be obtained by taking them both negative, or one positive and the other negative.
q: Without solving it, what is the sum of the two roots of `x^2-9x=-20`? {9}
q: And their product? {20}
mc: The product of the two roots of `x^2+2px=q` is... | *`-q`, the known term with a contrary sign | `q` | `-2p`
art: 235 | Sign and magnitude of the roots | We shall now consider the essential sign, and numerical magnitude, of the roots in each of the four forms. It is evident that the value of `√(q+p^2)` must be greater than `p`, since the square root of `p^2` alone, is `p`. But the value of `√(-q+p^2)` must be less than `p`, since it is the square root of a quantity less than `p^2`. Hence: 1st form, `x^2+2px=q`: `x'=-p+√(q+p^2)` and `x''=-p-√(q+p^2)`; the first root is essentially positive, the second essentially negative; and the first is numerically less than the second. 2d form, `x^2-2px=q`: `x'=p+√(q+p^2)` and `x''=p-√(q+p^2)`; the first root is essentially positive, the second essentially negative; and the first is numerically greater than the second. 3d form, `x^2+2px=-q`: `x'=-p+√(-q+p^2)` and `x''=-p-√(-q+p^2)`; both roots are essentially negative, and the first is numerically less than the second. 4th form, `x^2-2px=-q`: `x'=p+√(-q+p^2)` and `x''=p-√(-q+p^2)`; both roots are essentially positive, and the first is numerically greater than the second.
mc: In the 4th form, `x^2-2px=-q`, the two roots are... | *both positive | both negative | one positive and one negative
mc: In the 1st form, `x^2+2px=q`, the two roots are... | *one positive and one negative | both positive | both negative
art: 236 | When the roots become imaginary, and why | In the third and fourth forms, the radical part is `√(-q+p^2)`. Now, when `q` is greater than `p^2`, this is essentially negative, and the extraction of the root is impossible (Art. 193). Hence, when the known term is negative, and greater than the square of half the coefficient of the first power of `x`, the roots are imaginary. To show why the roots are imaginary, we must prove that when a number is divided into two equal parts, their product is greater than that of any other two parts into which the number can be divided. Or, the product of any two unequal numbers is less than the square of half their sum. Let `2p` represent any number, and let the parts into which it is supposed to be divided, be `p+z` and `p-z`. The product of these parts is `(p+z)(p-z)=p^2-z^2`. Now, this product is evidently the greatest, when `z^2` is the least; that is, when `z^2=0`, or `z=0`. But when `z` is 0, the parts are `p` and `p`, which proves the proposition. Now, it has been shown (Art. 234, Properties 3d and 4th) that `2p` is equal to the sum of the two roots, and that `q` is equal to their product. But, when `q` is greater than `p^2`, we have the product of two numbers greater than the square of half their sum, which, by the preceding principle, is impossible. If, then, any problem furnishes an equation of the form `x^2±2px=-q`, in which `q` is greater than `p^2`, the conditions are incompatible with each other.
tf: The product of two unequal numbers is less than the square of half their sum. {T}
q: Let it be required to divide the number 8 into two parts, whose product shall be 18. Let `x` and `8-x` be the parts. Then `x(8-x)=18`, or `x^2-8x=-18`. Find `x` (one answer with ±). x = {$ 4±√-2 @x: x^2-8x=-18}
q: These values show that the problem is impossible. By the preceding theorem, what is the greatest product of two parts of 8? {16}
art: 237 | Examination of Particular Cases | 1st. If, in the third and fourth forms, where `q` is negative, we suppose `q=p^2`, the radical `√(-q+p^2)` becomes 0, and `x=-p` in one, and `+p` in the other. It is then said, the two roots are equal. In fact, if we substitute `p^2` for `q`, the equation in the 3d form becomes `x^2+2px+p^2=0`. Hence, `(x+p)^2`, or `(x+p)(x+p)=0`. The first member is the product of two equal factors, either of which, placed equal to zero, gives the same value for `x`. 2d. If, in the general equation, `x^2+2px=q`, we suppose `q=0`, the two values of `x` reduce to `x=-p+p=0`, and `x=-p-p=-2p`. In fact, the equation is then of the form `x^2+2px=0`, or `x(x+2p)=0`, which can be satisfied only by making `x=0`, or `x+2p=0`; whence, `x=0`, or `x=-2p`. 3d. If, in the general equation, we suppose `2p=0`, we have `x^2=q`; whence, `x=±√q`. In this case, the two values of `x` are equal and have contrary signs, real, if `q` is positive, as in the first and second forms, and imaginary, if `q` is negative, as in the third and fourth forms. Under this supposition the equation contains only two terms, and belongs to the class treated of in Art. 228. 4th. If `2p=0`, and `q=0`, the equations reduce to `x^2=0`, and give the two values of `x`, in all the forms, each equal to 0.
q: The two roots of `x^2-6x=-9` are equal. Each is x = {3 @x: x^2-6x=-9}
q: Find the roots of `x^2+5x=0`. x = {$ 0 @x: x^2+5x=0} or {$ -5 @x: x^2+5x=0}
== 50 | Quadratic Equations | A singular case; the problem of the lights; examples for discussion
art: 238 | A singular case | There remains a singular case to be examined, which is sometimes met with in the solution of problems producing quadratic equations. To discuss it, take the equation `ax^2+bx=c`. Solving this equation, the values of `x` are `x=(-b+√(b^2+4ac))/(2a)` and `x=(-b-√(b^2+4ac))/(2a)`. If, now, we suppose `a=0`, these values become `x=(-b+b)/0=0/0` and `x=(-b-b)/0=-2b/0=∞`. That is, one value of `x` is indeterminate and the other infinite (Arts. 136, 137). But if we suppose `a=0` in the given equation, we have `bx=c`, and `x=c/b`. We now propose to show that the indeterminate value is the same as the one last found, and that the infinite value simply expresses an impossibility. If we multiply both terms of the second member of the equation `x=(-b+√(b^2+4ac))/(2a)` by `-b-√(b^2+4ac)`, we have `x=(b^2-(b^2+4ac))/(2a(-b-√(b^2+4ac)))=-4ac/(2a(-b-√(b^2+4ac)))`; or, by dividing both terms by `2a`, and making `a=0`, `x=-2c/(-b-√(b^2+4ac))=-2c/(-2b)=c/b`. Hence, we see, that the value of `x=0/0`, is really `c/b`, and arises from having made the factor, `2a`, equal to zero (Art. 136). By supposing `a=0`, the equation `ax^2+bx=c`, reduces to `bx=c`, an equation of the first degree, which can have but one root. The supposition that it is two, gives one value infinite, which is equivalent to saying, the equation has but one finite root. If we had at the same time `a=0`, `b=0`, `c=0`, the equation would be altogether indeterminate. This is the only case of indetermination occurring in quadratic equations.
mc: If `a=0` in `ax^2+bx=c`, the finite root is... | *`c/b` | `0` | `-b/a`
art: 239 | Problem of the Lights | It is required to find, in a line BC, which joins two lights, B and C, of different intensities, a point which is illuminated equally by each. It is a principle in optics, that the intensity of the same light at different distances, is inversely as the square of the distance. Let `a` be the distance BC between the two lights; let `b` be the intensity of the light B at the distance of 1 ft. from B; let `c` be the intensity of the light C at the distance of 1 ft. from C. Let P be the point required, and let BP `=x`; then CP `=a-x`. By the principle above stated, since the intensity of the light B at the distance of 1 foot, is `b`, at 2, 3, 4 feet, it must be `b/4`, `b/9`, `b/16`; hence, the intensity of B and of C, at the distance of `x` and of `a-x` feet, must be `b/x^2` and `c/(a-x)^2`. But, by the conditions of the problem, these two intensities are equal. Hence, we have for the equation of the problem `b/x^2=c/(a-x)^2`, which reduces to `(a-x)^2/x^2=c/b`; whence, `(a-x)/x=+√c/√b`, or `-√c/√b`. This gives the following results: 1st. `x=a√b/(√b+√c)`; whence, `a-x=a√c/(√b+√c)`. 2d. `x=a√b/(√b-√c)`; whence, `a-x=-a√c/(√b-√c)`.
q: In the problem of the lights, the first value of `x` is... {$ a√b/(√b+√c) @x: b(a-x)^2=c*x^2}
q: And the second value of `x`? {$ a√b/(√b-√c) @x: b(a-x)^2=c*x^2}
art: 239 | I. Let b>c | The first value of `x`, `a√b/(√b+√c)`, is positive, and less than `a`, for `√b/(√b+√c)` is a proper fraction. Hence, this value gives for the point illuminated equally, a point P situated between B and C. We perceive, also, that the point P is nearer to C than B; for, since `b>c`, we have `√b+√b>√b+√c`, or `2√b>√b+√c`, and `√b/(√b+√c)>1/2`, and, consequently, `a√b/(√b+√c)>a/2`. This is manifestly correct, for the required point must be nearer the light of less intensity. The corresponding value of `a-x`, `a√c/(√b+√c)`, is positive, and evidently less than `a/2`. The second value of `x`, `a√b/(√b-√c)`, is positive, and greater than `a`; for `√b>√b-√c`, so `√b/(√b-√c)>1`, and `a√b/(√b-√c)>a`. This value gives a point P' situated on the prolongation of BC, and in the same direction from B as before. In fact, since the two lights emit rays in all directions, there will be a point P', to the right of C, and nearer the light of less intensity, which is illuminated equally by the two lights. The second value of `a-x`, `-a√c/(√b-√c)`, is negative, as it ought to be, and represents the distance CP' in the opposite direction from C (Art. 47).
art: 239 | II. Let b<c | The first value of `x`, `a√b/(√b+√c)`, is positive, and less than `a/2`, for `√b+√c>√b+√b`, so `√b/(√b+√c)<1/2`. The corresponding value of `a-x`, `a√c/(√b+√c)`, is greater than `a/2` and positive. These values of `x`, and `a-x`, show that the point P is situated between B and C, but nearer to B than C. This is evidently a true result, since, under the present supposition, the intensity of the light B is less than that of the light C. The second value of `x`, `a√b/(√b-√c)`, or `-a√b/(√c-√b)`, is essentially negative, and represents a point P'', in the opposite direction from B. As the intensity of the light B is now supposed to be less than that at C, there is, obviously, another such point of equal illumination. The corresponding value of `a-x` is `a√c/(√c-√b)`. It is positive and greater than `a`; this represents CP'', and is the sum of the distances CB and BP'', in the same direction from C as before.
art: 239 | III, IV, V | III. Let `b=c`. The first values of `x` and of `a-x`, reduce to `a/2`, which shows that the point illuminated equally is at the middle of the line BC, a result manifestly true, upon the supposition that the intensities of the two lights are equal. The other two values are reduced to `a√b/0=∞` (Art. 136). This result is manifestly true, for the intensities of the two lights being supposed equal, there is no point at any finite distance, except the point P, which is equally illuminated by both. IV. Let `b=c`, and `a=0`. The first system of values of `x` and `a-x`, become 0. This is evidently correct, for when the distance BC becomes 0, the distances BP and CP also become 0. The second system of values of `x` and `a-x`, become `0/0`; this is the symbol of indetermination (Art. 137). This result is also correct, for if the two lights are equal, and placed at the same point, every point on either side of them will be illuminated equally by each. V. Let `a=0`, `b` not being `=c`. All the values of `x` and `a-x` reduce to 0; hence, there is no point equally illuminated by each. In other words, the solution of the problem fails in this case, as it evidently should. This might also have been inferred from the original equation; for if we put `a=0`, `b/x^2=c/(x-a)^2` becomes `b/x^2=c/x^2`, which can never be true except when `b=c`, as in Case IV.
mc: If the two lights are equal (`b=c`), the point equally lit between them is... | *at the middle of BC, `a/2` from B | nearer to B | nowhere
mc: If `b>c`, the point P between the lights is... | *nearer to C, the light of less intensity | nearer to B | at the middle
art: 239 | Examples for discussion and illustration | In these examples, discuss each answer: what the negative or imaginary values show, and how the question may be changed so that a negative answer, taken positively, is correct in an arithmetical sense.
q: Required a number such, that twice its square, increased by 8 times the number itself, shall be 90. x = {$ 5 @x: 2x^2+8x=90} or {$ -9 @x: 2x^2+8x=90}
q: The difference of two numbers is 4, and their product 21. Required the numbers. The less is {$ 3} and the greater {$ 7}, or the less {$ -7} and the greater {$ -3}.
chk: x=3, y=7 | y-x=4 | x*y=21
chk: x=-7, y=-3 | y-x=4 | x*y=21
q: A man bought a watch, which he afterward sold for $16. His loss per cent. on the first cost of the watch, was the same as the number of dollars which he paid for it. What did he pay for the watch, in dollars? {20} or {80}
chk: x=20 | x-x*x/100=16
chk: x=80 | x-x*x/100=16
q: Required a number such, that the square of the number increased by 6 times the number, and this sum, increased by 7, the result shall be 2. x = {$ -1 @x: x^2+6x+7=2} or {$ -5 @x: x^2+6x+7=2}
q: Divide the number 10 into two such parts, that the product shall be 24. {4} and {6}
chk: x=4, y=6 | x+y=10 | x*y=24
q: Divide the number 10 into two such parts, that the product shall be 26 (one answer with ±; the result shows the problem is impossible). {$ 5±√-1 @x: x(10-x)=26}
q: The mass of the earth is 80 times that of the moon, and their mean distance asunder 240000 miles. The attraction of gravitation being directly as the quantity of matter, and inversely as the square of the distance from the center of attraction, at what point on the line passing through the centers of these bodies are the forces of attraction equal? (Use the values of `x` on page 208, with `a=240000`, `b=80`, `c=1`; give miles to one decimal place.) Between them: {215865.5} miles from the earth and {24134.5} from the moon; or {270210.4} miles from the earth and {30210.4} beyond the moon.
== 51 | Quadratic Equations | Trinomial equations; binomial surds; square root of A±√B; equations of the 4th degree
art: 240 | Trinomial Equations | A Trinomial Equation is one consisting of three terms, the general form of which is `ax^m+bx^n=c`. Every trinomial equation of the form `x^(2n)+2px^n=q`; that is, every equation of three terms containing only two powers of the unknown quantity, and in which one of the exponents is double the other, can be solved in the same manner as an affected equation. As an example, let it be required to find the value of `x` in the equation `x^4-2px^2=q`. Completing the square, `x^4-2px^2+p^2=q+p^2`; `x^2-p=±√(q+p^2)`; `x^2=p±√(q+p^2)`; therefore `x=±√(p±√(q+p^2))`.
art: 241 | Binomial Surds | Expressions of the form `A±√B`, like the value of `x^2` just found, or of the form `√A±√B`, are called Binomial Surds. The first of these forms frequently results from the solution of trinomial equations of the fourth degree; and as it is sometimes possible to reduce it to a more simple form by extracting the square root, it is necessary to consider the subject here. If we square `2±√3`, we have `4±4√3+3`, which, by reduction, becomes `7±4√3`. Hence, `√(7±4√3)=2±√3`. In the same way it may be shown that `√(5±2√6)=√2±√3`. It thus appears that the form `A±√B` may sometimes result from squaring a binomial of the form `a±√b`, or `√a±√b`, and uniting the extreme terms, which are necessarily rational, into one. In such cases, A is the sum of the squares of the two terms of the root, and `√B` is twice their product. To find the root, therefore, put `x^2+y^2=A` and `2xy=√B`, and proceed to find `x` and `y`, the terms of the root. Thus, to extract the square root of `7-4√3`: put `x^2+y^2=7` (1), and `2xy=4√3`. Adding, `x^2+2xy+y^2=7+4√3`; subtracting, `x^2-2xy+y^2=7-4√3`. Extracting the root, `x+y=√(7+4√3)` (2), `x-y=√(7-4√3)` (3). Multiplying (2) by (3), `x^2-y^2=√(49-48)=√1=1` (4). By adding and subtracting (1) and (4), we have `2x^2=8`, `x=2`, and `2y^2=6`, `y=√3`. Hence, `2-√3` is the root to be found.
q: Extract the square root of `7-4√3`. {$ 2-√3 @sq: 7-4√3}
q: Extract the square root of `15+6√6`. {$ 3+√6 @sq: 15+6√6}
q: Of `34-24√2`. {$ 4-3√2 @sq: 34-24√2}
q: Of `14+4√6`. {$ √2+2√3 @sq: 14+4√6}
art: 241 | Two theorems | The square root of `A±√B` may always be found in a simple form, when `A^2-B` is a perfect square. Theorem I: the value of a quadratic surd can not be partly rational and partly irrational. For, if possible, let `√x=a+√b`; squaring both sides, `x=a^2+2a√b+b`, so `√b=(x-a^2-b)/(2a)`; that is, an irrational quantity is equal to a rational quantity, which is impossible. Theorem II: in any equation of the form `x±√y=a±√b`, the rational quantities on opposite sides are equal, and also the irrational quantities. For if `x` does not `=a`, let `x=a+m`; therefore `a+m±√y=a±√b`, so `m+√y=√b`; that is, the value of a quadratic surd is partly rational and partly irrational, which has been shown by Th. I to be impossible; hence, `x=a`, and `√y=√b`.
art: 241 | Formula for the square root of A+√B | Assume `√(A+√B)=√x+√y`. Squaring, `A+√B=x+y+2√(xy)`. By Th. II, `x+y=A` (1); and `2√(xy)=√B` (2). Squaring equations (1) and (2), `x^2+2xy+y^2=A^2` and `4xy=B`; subtracting, `x^2-2xy+y^2=A^2-B`; or, `(x-y)^2=A^2-B`. Let `A^2-B` be a perfect square `=C^2`; then `C=√(A^2-B)`. Therefore `x-y=C`; but `x+y=A`; whence `x=(A+C)/2` and `y=(A-C)/2`. Hence, (K) `√(A+√B)=±(√((A+C)/2)+√((A-C)/2))`, and (L) `√(A-√B)=±(√((A+C)/2)-√((A-C)/2))`. By substituting particular values for the general ones in these formulas, examples may be easily solved. Example: extract the square root of `31+10√6`. Here `A=31`, `√B=10√6`; so `A^2-B=C^2=961-600=361`, and `C=19`. `A+C=50`, `A-C=12`. Then `√(31+10√6)=√(50/2)+√(12/2)=5+√6`. Proof: `(5+√6)^2=25+10√6+6=31+10√6`.
q: Extract the square root of `31+10√6`. {$ 5+√6 @sq: 31+10√6}
q: In the formula, when `A=31` and `√B=10√6`, what is `C`? {19}
q: Reduce `√(np+2m^2-2m√(np+m^2))` to its simplest form. (Here `A=np+2m^2`, `B=4m^2(np+m^2)`, `C=np`.) {$ √(np+m^2)-m @sq: n*p+2m^2-2m√(n*p+m^2)}
q: Find the square root of `11+6√2`. {$ 3+√2 @sq: 11+6√2}
q: Of `3+2√2`. {$ √2+1 @sq: 3+2√2}
q: Of `17+2√60`. {$ 2√3+√5 @sq: 17+2√60}
q: Of `x-2√(x-1)` (take `x` greater than 2). {$ √(x-1)-1 @sq: x-2√(x-1)}
q: Of `2a√-1` (here A=0). {$ √a(1+√-1) | √a+√a√-1 @sq: 2a√-1}
q: Of `x+y+z+2√(xz+yz)`. {$ √(x+y)+√z @sq: x+y+z+2√(x*z+y*z)}
q: Find the value of `√(28+10√3)+√(67-16√3)`. {13}
chk: x=13 | x=√(28+10√3)+√(67-16√3)
art: 241 | Remark | When `A^2-B` is not a perfect square, or when the binomial surd is of the form `√A±√B`, the root will be more complex than the original form. By the above method the square root of any binomial or residual, as `a+b`, `a-b`, `a^2+b^2`, etc., may also be found, in a complex form.
art: 242 | Trinomial Equations, continued | The general form of trinomial equations is `x^(2n)+2px^n=q`; but there are several varieties of this form, of which the principal are: `x+√x=q`, `x^4+px^2=q`, `x^n+px^(n/2)=q`, `x^(3n)+px^(3n/2)=q`, `x^(4n)+px^(2n)=q`, `(x^2+px+q)^2+b(x^2+px+q)=r`, and `(x^2+px+q)^(2n)+b(x^2+px+q)^n=k`. Some of these varieties, if developed, would produce very complicated expressions, yet they may all be solved by the general method given in Art. 240. 1. Given `x^6-6x^3=16`. Assume `x^3=y`; then `x^6=y^2`, and `y^2-6y=16`; whence `y=8`, or -2. Therefore `x^3=8`, or -2; and `x=2`, or `-∛2`. Or, completing the square, `x^6-6x^3+9=25`; `x^3-3=±5`; `x^3=8` or -2. It will be shown hereafter (Art. 396) that in such examples there are four values of `x` not determined.
q: Given `x^6-6x^3=16`, find the two real values of `x`. x = {$ 2 @x: x^6-6x^3=16} or {$ -∛2 @x: x^6-6x^3=16}
art: 242 | Examples 2-4 | 2. Given `5x-4√x=33`. Assume `√x=y`; then `x=y^2`, and `5y^2-4y=33`; whence `y=3`, or `-11/5`; consequently `x=9`, or `121/25`. 3. Given `√(x+12)+∜(x+12)=6`. Assume `∜(x+12)=y`; then `√(x+12)=y^2`, and `y^2+y=6`; whence `y=2`, or -3; therefore `∜(x+12)=2`, or -3; whence `x+12=16`, or 81; and `x=4`, or 69. 4. Given `3x^2+√(3x^2+1)=55`. Adding 1 to each member, `3x^2+1+√(3x^2+1)=56`. The equation may now be solved like the preceding. The values of `x` are +4, -4, `+√21`, and `-√21`. In each of these, the second value comes from the negative root (`√x=-11/5`, `∜(x+12)=-3`, `√(3x^2+1)=-8`), so it verifies the equation only if the radical is taken negative.
q: Given `5x-4√x=33`, find `x` (the value with `√x` positive). x = {9 @x: 5x-4√x=33}
q: Given `√(x+12)+∜(x+12)=6`, find `x` (the value with the roots positive). x = {4 @x: √(x+12)+∜(x+12)=6}
q: Given `3x^2+√(3x^2+1)=55`, find `x` (with the root positive). x = plus or minus {4 @x: 3x^2+√(3x^2+1)=55}
q: Find the values of `x`: `x^4-25x^2=-144`. x = plus or minus {3 @x: x^4-25x^2=-144} or plus or minus {4 @x: x^4-25x^2=-144}
q: `5x^4+7x^2=6732` (the book writes the second as `±(1/10)√-3740`) x = plus or minus {6 @x: 5x^4+7x^2=6732} or plus or minus {$ (1/5)√-935 @x: 5x^4+7x^2=6732}
q: `9x^6-11x^3=488` x = {$ 2 @x: 9x^6-11x^3=488} or {$ (1/3)∛-183 @x: 9x^6-11x^3=488}
q: `x^3-x^(3/2)=15500` (the real value; the book also gives `(-124)^(2/3)`, from `x^(3/2)=-124`) x = {25 @x: x^3-x^(3/2)=15500}
q: `x^(5/3)+x^(5/6)=1056` (the real value; the book also gives `(-33)^(6/5)`, from `x^(5/6)=-33`) x = {64 @x: x^(5/3)+x^(5/6)=1056}
q: `x+5=√(x+5)+6` (the book gives 4, and -1 from `√(x+5)=-2`) x = {4 @x: x+5=√(x+5)+6} or {$ -1 @x: (x+5-6)^2=x+5}
q: `2√(x^2-3x+11)=x^2-3x+8` (the book also gives `3/2±(1/2)√-31`, from the negative root) x = {2 @x: 2√(x^2-3x+11)=x^2-3x+8} or {1 @x: 2√(x^2-3x+11)=x^2-3x+8}
q: `x^2-7x+√(x^2-7x+18)=24` (the book also gives `(1/2)(7±√173)`, from the negative root) x = {9 @x: x^2-7x+√(x^2-7x+18)=24} or {$ -2 @x: x^2-7x+√(x^2-7x+18)=24}
q: `(x^2-9)^2=3+11(x^2-2)` x = plus or minus {5 @x: (x^2-9)^2=3+11(x^2-2)} or plus or minus {2 @x: (x^2-9)^2=3+11(x^2-2)}
q: `(x+8/x)^2+x=42-8/x` x = {4 @x: (x+8/x)^2+x=42-8/x} or {2 @x: (x+8/x)^2+x=42-8/x} or {$ -7/2±(1/2)√17 @x: (x+8/x)^2+x=42-8/x}
q: `x^4(1+1/(3x))^2-(3x^2+x)=70` x = {$ 3 @x: x^4(1+1/(3x))^2-(3x^2+x)=70} or {$ -10/3 @x: x^4(1+1/(3x))^2-(3x^2+x)=70} or {$ -1/6±(1/6)√-251 @x: x^4(1+1/(3x))^2-(3x^2+x)=70}
q: `x√(6/x-x)=(1+x^2)/√x` (the positive values) x = {$ √(1+(1/2)√2) @x: x√(6/x-x)=(1+x^2)/√x} or {$ √(1-(1/2)√2) @x: x√(6/x-x)=(1+x^2)/√x}
art: 242 | Substituting twice | Sometimes it may be necessary to substitute a new letter two or more times, or to complete the square, without substitution, three or more times. The following is an example: `x^4+5x^2+4√(x^4+5x^2)=60`. The book's answers are `x=±2`, `±3√-1`, and `±√((5/2)(-1±√17))`; the last four come from `√(x^4+5x^2)=-10`.
q: Find `x` in `x^4+5x^2+4√(x^4+5x^2)=60` (from `√(x^4+5x^2)=6`). x = plus or minus {2 @x: x^4+5x^2+4√(x^4+5x^2)=60} or plus or minus {$ 3√-1 @x: x^4+5x^2+4√(x^4+5x^2)=60}
art: 243 | A hidden compound term | Equations sometimes occur in which the compound term is not at first apparent, but which may be reduced to the form of a trinomial equation by the following method: extract the square root to two or three terms, and if we find a remainder (omitting known terms, if necessary) which is any multiple or any part of the root already found, the given equation may be reduced to a trinomial, of which the compound term will be the root already found. If the greatest exponent of the unknown quantity be not even, it must be made so by multiplying both members of the equation by the unknown quantity. Example: given `x^3-4ax^2-2a^2x+12a^3=16a^4/x`. Multiplying both sides by `x`, and transposing, `x^4-4ax^3-2a^2x^2+12a^3x-16a^4=0`. Extracting the square root, the root is `x^2-2ax` and the remainder `-6a^2x^2+12a^3x-16a^4`, or `-6a^2(x^2-2ax)-16a^4`. Hence, the given equation may be written thus: `(x^2-2ax)^2-6a^2(x^2-2ax)-16a^4=0`, or `(x^2-2ax)^2-6a^2(x^2-2ax)=16a^4`. Proceeding with the solution, we find `x=4a`, `-2a`, or `a±a√-1`.
q: Given `x^3-4ax^2-2a^2x+12a^3=16a^4/x`, find `x`. x = {$ 4a @x: x^3-4a*x^2-2a^2*x+12a^3=16a^4/x} or {$ -2a @x: x^3-4a*x^2-2a^2*x+12a^3=16a^4/x} or {$ a±a√-1 @x: x^3-4a*x^2-2a^2*x+12a^3=16a^4/x}
q: `x^4-2x^3-2x^2+3x=108` x = {$ 4 @x: x^4-2x^3-2x^2+3x=108} or {$ -3 @x: x^4-2x^3-2x^2+3x=108} or {$ 1/2±(1/2)√-35 @x: x^4-2x^3-2x^2+3x=108}
q: `x^4-2x^3+x=30` x = {$ 3 @x: x^4-2x^3+x=30} or {$ -2 @x: x^4-2x^3+x=30} or {$ 1/2±(1/2)√-19 @x: x^4-2x^3+x=30}
q: `x^3-6x^2+11x-6=0` x = {1 @x: x^3-6x^2+11x-6=0} or {2 @x: x^3-6x^2+11x-6=0} or {3 @x: x^3-6x^2+11x-6=0}
q: `x^4-6x^3+5x^2+12x=60` x = {$ 5 @x: x^4-6x^3+5x^2+12x=60} or {$ -2 @x: x^4-6x^3+5x^2+12x=60} or {$ 3/2±(1/2)√-15 @x: x^4-6x^3+5x^2+12x=60}
q: `x^4-8x^3+10x^2+24x=-5` x = {$ 5 @x: x^4-8x^3+10x^2+24x=-5} or {$ -1 @x: x^4-8x^3+10x^2+24x=-5} or {$ 2±√5 @x: x^4-8x^3+10x^2+24x=-5}
q: `4x^4+x/2=4x^3+33` x = {$ 2 @x: 4x^4+x/2=4x^3+33} or {$ -3/2 @x: 4x^4+x/2=4x^3+33} or {$ 1/4±(1/4)√-43 @x: 4x^4+x/2=4x^3+33}
q: `x/14-30/(7x^3)+(12+x/2)/(3x)=7/(2x^2)+1 1/6` x = {$ 4 @x: x/14-30/(7x^3)+(12+x/2)/(3x)=7/(2x^2)+7/6} or {$ 3 @x: x/14-30/(7x^3)+(12+x/2)/(3x)=7/(2x^2)+7/6} or {$ 7/2±(1/2)√69 @x: x/14-30/(7x^3)+(12+x/2)/(3x)=7/(2x^2)+7/6}
== 52 | Quadratic Equations | Simultaneous quadratic equations: pure and affected
art: 244 | Simultaneous Quadratic Equations | Quadratic equations, containing two or more unknown quantities, may be divided into two classes, pure and affected. Pure Equations embrace those that may be solved without completing the square. Affected Equations embrace those in the solution of which it is necessary to complete the square. The same equations may sometimes be solved by both methods.
art: 245 | Pure Equations | Pure equations may in general be reduced to the solution of one of the following forms, or pairs of equations: (1) `x+y=a`, `xy=b`; (2) `x-y=c`, `xy=b`; (3) `x^2+y^2=a`, `x^2-y^2=b`. To solve `x+y=a` (1), and `xy=b` (2), we must find `x-y`. Squaring Eq. (1), `x^2+2xy+y^2=a^2`; multiplying Eq. (2) by 4, `4xy=4b`; subtracting, `x^2-2xy+y^2=a^2-4b`, or `(x-y)^2=a^2-4b`; whence, `x-y=±√(a^2-4b)`; but `x+y=a`. Adding, and dividing by 2, `x=(1/2)a±(1/2)√(a^2-4b)`. Subtracting, and dividing by 2, `y=(1/2)a∓(1/2)√(a^2-4b)`. The pair of equations (2) is solved in the same manner, except that in finding `x+y` we must add 4 times the second equation to the square of the first. The pair of equations (3) is solved merely by adding and subtracting, then dividing by 2 and extracting the square root.
art: 245 | How to answer | Most of these pairs of equations have two or more solutions, a value of `x` with its own value of `y`. Type the solutions in any order: each `x` with its own `y`.
art: 245 | Example 1 | Given `x^2+y^2=25`, and `x+y=7`, to find `x` and `y`. Squaring the 2d Eq., `x^2+2xy+y^2=49`; but `x^2+y^2=25` (1); subtracting, `2xy=24` (2). Taking (2) from (1), `x^2-2xy+y^2=1`; whence `x-y=±1` (3). But `x+y=7` (4). Adding and subtracting (3) and (4), and dividing by 2, `x=4`, or 3; and `y=3`, or 4.
q: Given `x^2+y^2=25` and `x+y=7`: x = {4}, y = {3}; or x = {3}, y = {4}.
chk: x=4, y=3 | x^2+y^2=25 | x+y=7
art: 245 | Example 2 | Given `x^2+xy+y^2=91` (1), and `x+√(xy)+y=13` (2). Divide Eq. (1) by (2): `x-√(xy)+y=7` (3). By subtracting, `2√(xy)=6`; whence `√(xy)=3`, and `xy=9` (4). By adding (2) and (3), `x+y=10` (5). Squaring (5), `x^2+2xy+y^2=100`; multiplying (4) by 4, `4xy=36`; so `x^2-2xy+y^2=64`, and `x-y=±8`. But `x+y=10`; whence `x=9`, or 1; and `y=1`, or 9. Equations of higher degrees than the second, that can be solved by simple methods, are usually classed with pure equations of the second degree.
q: Given `x^2+xy+y^2=91` and `x+√(xy)+y=13`: x = {9}, y = {1}; or x = {1}, y = {9}.
chk: x=9, y=1 | x^2+x*y+y^2=91 | x+√(x*y)+y=13
art: 245 | Example 3 | Given `x^(1/4)+y^(1/5)=6`, and `x^(3/4)+y^(3/5)=126`. In all cases of fractional exponents, the operations may be simplified by making such substitutions as will render the exponents integral. To do this, put the lowest power of each unknown quantity equal to the first power of a new letter. Let `x^(1/4)=P`, and `y^(1/5)=Q`; then `x^(3/4)=P^3`, and `y^(3/5)=Q^3`. The given equations become `P+Q=6` (1), `P^3+Q^3=126` (2). Dividing Eq. (2) by (1), `P^2-PQ+Q^2=21`; squaring Eq. (1), `P^2+2PQ+Q^2=36`; subtracting, `3PQ=15`, so `PQ=5`. Having `P+Q=6` and `PQ=5`, we readily find `P=5` or 1, and `Q=1` or 5. Whence, `x=625`, or 1; and `y=1`, or 3125.
q: Given `x^(1/4)+y^(1/5)=6` and `x^(3/4)+y^(3/5)=126`: x = {625}, y = {1}; or x = {1}, y = {3125}.
chk: x=625, y=1 | x^(1/4)+y^(1/5)=6 | x^(3/4)+y^(3/5)=126
chk: x=1, y=3125 | x^(1/4)+y^(1/5)=6 | x^(3/4)+y^(3/5)=126
art: 245 | Example 4 | Given `(x-y)(x^2-y^2)=160` (1), `(x+y)(x^2+y^2)=580` (2). By multiplying, `x^3-x^2y-xy^2+y^3=160` and `x^3+x^2y+xy^2+y^3=580`; subtracting, `2x^2y+2xy^2=420` (3). Add (3) to (2): `x^3+3x^2y+3xy^2+y^3=1000`. Extract the cube root: `x+y=10`. From (3), `xy(x+y)=210`; so `xy=21`. From `x+y=10` and `xy=21`, we readily find `x=7`, or 3; and `y=3`, or 7.
q: Given `(x-y)(x^2-y^2)=160` and `(x+y)(x^2+y^2)=580`: x = {7}, y = {3}; or x = {3}, y = {7}.
chk: x=7, y=3 | (x-y)(x^2-y^2)=160 | (x+y)(x^2+y^2)=580
q: Solve `x-y=2`, `x^2+y^2=394`: x = {15}, y = {13}; or x = {$ -13}, y = {$ -15}.
chk: x=15, y=13 | x-y=2 | x^2+y^2=394
chk: x=-13, y=-15 | x-y=2 | x^2+y^2=394
q: Solve `x^2+y^2=13`, `xy=6`: x = plus or minus {3}, y = plus or minus {2} (the same signs).
chk: x=3, y=2 | x^2+y^2=13 | x*y=6
chk: x=-3, y=-2 | x^2+y^2=13 | x*y=6
q: Solve `2x+y=7`, `4x^2+y^2=25`: x = {2}, y = {3}; or x = {3/2}, y = {4}.
chk: x=2, y=3 | 2x+y=7 | 4x^2+y^2=25
chk: x=3/2, y=4 | 2x+y=7 | 4x^2+y^2=25
q: Solve `x^2-y^2=16`, `x-y=2`: x = {5}, y = {3}
chk: x=5, y=3 | x^2-y^2=16 | x-y=2
q: Solve `x+y=11`, `x^3+y^3=407`: x = {7}, y = {4}; or x = {4}, y = {7}.
chk: x=7, y=4 | x+y=11 | x^3+y^3=407
q: Solve `7(x^3+y^3)=9(x^3-y^3)`, `x^2y-y^2x=16`: x = {4}, y = {2}
chk: x=4, y=2 | 7(x^3+y^3)=9(x^3-y^3) | x^2*y-y^2*x=16
q: Solve `x^2+xy=84`, `x^2-y^2=24`: x = plus or minus {7}, y = plus or minus {5} (the same signs).
chk: x=7, y=5 | x^2+x*y=84 | x^2-y^2=24
chk: x=-7, y=-5 | x^2+x*y=84 | x^2-y^2=24
q: Solve `x^3+y^3=152`, `x^2-xy+y^2=19`: x = {5}, y = {3}; or x = {3}, y = {5}.
chk: x=5, y=3 | x^3+y^3=152 | x^2-x*y+y^2=19
q: Solve `x^2+y^2+xy=208`, `x+y=16`: x = {12}, y = {4}; or x = {4}, y = {12}.
chk: x=12, y=4 | x^2+y^2+x*y=208 | x+y=16
q: Solve `x^3-y^3=7xy`, `x-y=2`: x = {4}, y = {2}; or x = {$ -2}, y = {$ -4}.
chk: x=4, y=2 | x^3-y^3=7x*y | x-y=2
chk: x=-2, y=-4 | x^3-y^3=7x*y | x-y=2
q: Solve `x^4+x^2y^2+y^4=91`, `x^2+xy+y^2=13`: x = plus or minus {3}, y = plus or minus {1}; or x = plus or minus {1}, y = plus or minus {3} (the same signs).
chk: x=3, y=1 | x^4+x^2*y^2+y^4=91 | x^2+x*y+y^2=13
chk: x=-1, y=-3 | x^4+x^2*y^2+y^4=91 | x^2+x*y+y^2=13
q: Solve `x-y=√x+√y`, `x^(3/2)-y^(3/2)=37` (the book also gives x = 9, y = 16, which does not fit the first equation with the roots positive): x = {16}, y = {9}
chk: x=16, y=9 | x-y=√x+√y | x^(3/2)-y^(3/2)=37
q: Solve `x^(1/4)+y^(1/3)=5`, `x^(2/4)+y^(2/3)=13`: x = {81}, y = {8}; or x = {16}, y = {27}.
chk: x=16, y=27 | x^(1/4)+y^(1/3)=5 | x^(1/2)+y^(2/3)=13
chk: x=81, y=8 | x^(1/4)+y^(1/3)=5 | x^(1/2)+y^(2/3)=13
q: Solve `x^(1/3)+y^(1/3)=5`, `x+y=35`: x = {27}, y = {8}; or x = {8}, y = {27}.
chk: x=8, y=27 | x^(1/3)+y^(1/3)=5 | x+y=35
q: Solve `x^(1/2)+y^(1/2)=4`, `x^(3/2)+y^(3/2)=28`: x = {9}, y = {1}; or x = {1}, y = {9}.
chk: x=9, y=1 | x^(1/2)+y^(1/2)=4 | x^(3/2)+y^(3/2)=28
q: Solve `x^3+y^3=351`, `xy=14`: x = {7}, y = {2}; or x = {2}, y = {7}.
chk: x=7, y=2 | x^3+y^3=351 | x*y=14
q: Solve `x+y=4`, `x^4+y^4=82`: x = {3}, y = {1}; or x = {1}, y = {3}.
chk: x=3, y=1 | x+y=4 | x^4+y^4=82
q: Solve `x(y+z)=a`, `y(x+z)=b`, `z(x+y)=c` (the positive values). x = {$ √((a+c-b)(a+b-c)/(2(b+c-a)))}, y = {$ √((a+b-c)(b+c-a)/(2(a+c-b)))}, z = {$ √((b+c-a)(a+c-b)/(2(a+b-c)))}
art: 246 | Affected Equations | The most general form of quadratic equations, containing two unknown quantities, is `ax^2+bxy+cx+dy^2+ey+f=0`. By arranging the terms according to the powers of `x`, and dividing by the coefficient of the first term, two quadratic equations containing two unknown quantities may be reduced to the forms `x^2+(ay+b)x+cy^2+dy+e=0` (1) and `x^2+(a'y+b')x+c'y^2+d'y+e'=0` (2). To find the values of either of the unknown quantities, we must eliminate the other. By subtracting the second equation from the first, and calling the differences `a''`, `b''`, etc., we have `(a''y+b'')x+c''y^2+d''y+e''=0`, whence `x=-(c''y^2+d''y+e'')/(a''y+b'')`. As this value of `x` contains `y^2`, that of `x^2` will evidently contain `y^4`, which value of `x^2`, substituted in the first equation, necessarily gives rise to an equation of the fourth degree. Hence, the solution of two quadratic equations, containing two unknown quantities, depends upon the solution of an equation of the fourth degree, containing one unknown quantity. As there are no direct methods of solving equations of any higher degree than the second, those of the class now under consideration can not be solved except in particular cases, and then only by indirect methods, or special artifices.
art: 247 | Two cases that are always quadratic | There are two cases in quadratics which may always be solved as equations of the second degree. Case I: when one of the equations rises only to the first degree. Given `ax+by=c` (1), `dx^2+exy+fy^2+gx+hy=k` (2). From eq. (1), we may obtain a value of `x` in terms of `y`. Substituting this value, for `x` and `x^2` in (2), the new equation will evidently contain only `y` and `y^2`. Case II: when both equations are homogeneous (Art. 30). Given `ax^2+bxy+cy^2=d` (1), `a'x^2+b'xy+c'y^2=d'` (2). Put `y=tx`, where `t` is a third unknown quantity, termed an auxiliary quantity. Substituting this value of `y` in the two equations, we have `x^2(a+bt+ct^2)=d` (3) and `x^2(a'+b't+c't^2)=d'` (4). From eq. (3), `x^2=d/(a+bt+ct^2)` (5); from eq. (4), `x^2=d'/(a'+b't+c't^2)` (6). Therefore `d(a'+b't+c't^2)=d'(a+bt+ct^2)`, a quadratic equation, from which the value of `t` may be found (Art. 231), and thence `x` from (5) or (6), and `y` from the equation `y=tx`.
mc: Two equations like `3x^2+xy=18` and `4y^2+3xy=54` are solved by putting... | *`y=tx`, since both are homogeneous | `x=y+1` | `x+y=s`
art: 248 | Symmetrical equations | When two quadratic equations are symmetrical with respect to the two unknown quantities, that is, when the two unknown quantities are similarly involved, they may frequently be solved by substituting for the unknown quantities the sum and difference of two others. Given `x+y=a` (1), `x^5+y^5=b` (2). Let `x=s+z`, and `y=s-z`; then `s=a/2` (3). Then `x^5+y^5=2s^5+20s^3z^2+10sz^4=b`. By substituting the value of `s=a/2`, and reducing, we find `z^4+(a^2/2)z^2=(16b-a^5)/(80a)`. Completing the square, we find the value of `z`; and from (3), that of `x` and `y`.
art: 249 | Adding a number to both members | An artifice that is often used with advantage, consists in adding such a number to both members of an equation as will render it a trinomial equation that can be resolved by completing the square (Art. 240). Example: given `x^2/y^2+y^2/x^2+x/y+y/x=27/4` (1), and `x^2+y^2=20` (2). Since `(x/y+y/x)^2=x^2/y^2+2+y^2/x^2`, add 2 to each side of eq. (1), and then `1/4` to complete the square. Therefore `(x/y+y/x)^2+(x/y+y/x)+1/4=27/4+2+1/4=9`; whence `x/y+y/x=±3-1/2=5/2`, or `-7/2`. Let `x/y+y/x=5/2`; then `(x^2+y^2)/(xy)`, or `20/(xy)=5/2`. Whence `xy=8`, and `2xy=16`. From the equations `x^2+y^2=20` and `2xy=16`, we readily find `x=±4`, and `y=±2`. By taking `x/y+y/x=-7/2`, two other values of `x` and `y` may be found.
q: In the example, with `x/y+y/x=5/2`, x = plus or minus {4}, y = plus or minus {2} (the same signs; the book also has x = ±2, y = ±4).
chk: x=4, y=2 | x^2/y^2+y^2/x^2+x/y+y/x=27/4 | x^2+y^2=20
art: 250 | Auxiliaries | It is often of advantage to consider the sum, difference, product, or quotient of the two unknown quantities as a single unknown quantity, and find its value. Thus, in the problem `4xy=96-x^2y^2`, `x+y=6` below, the value of `xy` should be found from the first equation, and in the problem `x^2/y^2+4x/y=85/9`, `x-y=2`, the value of `x/y`. Other auxiliaries and expedients may frequently be employed with advantage, but their use can only be learned by experience, judgment, and tact. Note: in some of the examples all the values of the unknown quantities are not given; those omitted are generally imaginary.
q: Solve `x^2+y^2+x+y=330`, `x^2-y^2+x-y=150`: x = {15}, y = {9}; or x = {$ -16}, y = {$ -10}.
chk: x=15, y=9 | x^2+y^2+x+y=330 | x^2-y^2+x-y=150
chk: x=-16, y=-10 | x^2+y^2+x+y=330 | x^2-y^2+x-y=150
q: Solve `x+4y=14`, `y^2+4x=2y+11`: x = {2}, y = {3}; or x = {$ -46}, y = {15}.
chk: x=2, y=3 | x+4y=14 | y^2+4x=2y+11
chk: x=-46, y=15 | x+4y=14 | y^2+4x=2y+11
q: Solve `2y-3x=14`, `3x^2+2(y-11)^2=14`: x = {2}, y = {10}; or x = {1 1/5}, y = {8 4/5}.
chk: x=2, y=10 | 2y-3x=14 | 3x^2+2(y-11)^2=14
chk: x=6/5, y=44/5 | 2y-3x=14 | 3x^2+2(y-11)^2=14
q: Solve `x-y=2`, `x/y-y/x=1 1/15`: x = {5}, y = {3}; or x = {3/4}, y = {$ -5/4}.
chk: x=5, y=3 | x-y=2 | x/y-y/x=16/15
chk: x=3/4, y=-5/4 | x-y=2 | x/y-y/x=16/15
q: Solve `3x^2+xy=18`, `4y^2+3xy=54`: x = plus or minus {2}, y = plus or minus {3} (the same signs); or x = plus or minus {$ 2√3}, y = minus or plus {$ 3√3}.
chk: x=2, y=3 | 3x^2+x*y=18 | 4y^2+3x*y=54
chk: x=2√3, y=-3√3 | 3x^2+x*y=18 | 4y^2+3x*y=54
q: Solve `x^2+xy=10`, `xy+2y^2=24`: x = plus or minus {2}, y = plus or minus {3} (the same signs); or x = plus or minus {$ 5√2}, y = minus or plus {$ 4√2}.
chk: x=2, y=3 | x^2+x*y=10 | x*y+2y^2=24
chk: x=5√2, y=-4√2 | x^2+x*y=10 | x*y+2y^2=24
q: Solve `4xy=96-x^2y^2`, `x+y=6`: x = {4}, y = {2}; or x = {2}, y = {4}; the others are `x=3±√21`, `y=3∓√21`.
chk: x=4, y=2 | 4x*y=96-x^2*y^2 | x+y=6
chk: x=3+√21, y=3-√21 | 4x*y=96-x^2*y^2 | x+y=6
q: Solve `x^2/y^2+4x/y=85/9`, `x-y=2`: x = {5}, y = {3}; or x = {17/10}, y = {$ -3/10}.
chk: x=5, y=3 | x^2/y^2+4x/y=85/9 | x-y=2
chk: x=17/10, y=-3/10 | x^2/y^2+4x/y=85/9 | x-y=2
q: Solve `x^2y^2=180-8xy`, `x+3y=11`: x = {6}, y = {5/3}; or x = {5}, y = {2}.
chk: x=5, y=2 | x^2*y^2=180-8x*y | x+3y=11
chk: x=6, y=5/3 | x^2*y^2=180-8x*y | x+3y=11
q: Solve `x+y+√(x+y)=12`, `x^2+y^2=41`: x = {5}, y = {4}; or x = {4}, y = {5}.
chk: x=5, y=4 | x+y+√(x+y)=12 | x^2+y^2=41
q: Solve `x+y+x^2+y^2=18`, `xy=6`: x = {3}, y = {2}; or x = {2}, y = {3}; the others are `x=-3±√3`, `y=-3∓√3`.
chk: x=3, y=2 | x+y+x^2+y^2=18 | x*y=6
chk: x=-3+√3, y=-3-√3 | x+y+x^2+y^2=18 | x*y=6
q: Solve `x^2+3x+y=73-2xy`, `y^2+3y+x=44`: x = {16}, y = {$ -7}; or x = {4}, y = {5}.
chk: x=4, y=5 | x^2+3x+y=73-2x*y | y^2+3y+x=44
chk: x=16, y=-7 | x^2+3x+y=73-2x*y | y^2+3y+x=44
q: Solve `xy+xy^2=12`, `x+xy^3=18`: x = {16}, y = {1/2}; or x = {2}, y = {2}.
chk: x=2, y=2 | x*y+x*y^2=12 | x+x*y^3=18
chk: x=16, y=1/2 | x*y+x*y^2=12 | x+x*y^3=18
q: Solve `x^2+y^2-x-y=78`, `x+y+xy=39`: x = {9}, y = {3}; or x = {3}, y = {9}.
chk: x=9, y=3 | x^2+y^2-x-y=78 | x+y+x*y=39
q: Solve `(3x/(x+y))^(1/2)+((x+y)/(3x))^(1/2)=2`, `xy-(x+y)=54`: x = {6}, y = {12}; or x = {$ -9/2}, y = {$ -9} (the book writes `-4 1/2`).
chk: x=6, y=12 | (3x/(x+y))^(1/2)+((x+y)/(3x))^(1/2)=2 | x*y-(x+y)=54
chk: x=-9/2, y=-9 | (3x/(x+y))^(1/2)+((x+y)/(3x))^(1/2)=2 | x*y-(x+y)=54
q: Solve `y/(x+y)^(3/2)+√(x+y)/y=17/(4√(x+y))`, `x=y^2+2`: x = {6}, y = {2}; or x = {3}, y = {1}.
chk: x=6, y=2 | y/(x+y)^(3/2)+√(x+y)/y=17/(4√(x+y)) | x=y^2+2
chk: x=3, y=1 | y/(x+y)^(3/2)+√(x+y)/y=17/(4√(x+y)) | x=y^2+2
== 53 | Quadratic Equations | Questions producing simultaneous quadratic equations
art: 251 | Questions Producing Simultaneous Quadratic Equations | These questions involve two or more unknown quantities. The first four may be solved by pure equations.
q: There are two numbers, whose sum multiplied by the less is equal to 4 times the greater, but whose sum multiplied by the greater is equal to 9 times the less. What are the numbers? The greater is {3.6} and the less {2.4}.
chk: x=3.6, y=2.4 | (x+y)y=4x | (x+y)x=9y
q: There is a number consisting of two digits, which being multiplied by the digit in the ten's place, the product is 46; but if the sum of the digits be multiplied by the same digit, the product is only 10. Required the number. {23}
chk: x=2, y=3 | (10x+y)x=46 | (x+y)x=10
q: What two numbers are those whose difference multiplied by the difference of their squares is 32, and whose sum multiplied by the sum of their squares is 272? {5} and {3}
chk: x=5, y=3 | (x-y)(x^2-y^2)=32 | (x+y)(x^2+y^2)=272
q: The product of two numbers is 10, and the sum of their cubes 133. Required the numbers. {2} and {5}
chk: x=2, y=5 | x*y=10 | x^3+y^3=133
q: What two numbers are those whose sum multiplied by the greater is 120, and whose difference multiplied by the less is 16? {2} and {10}
chk: x=2, y=10 | (x+y)y=120 | (y-x)x=16
q: Find two numbers whose sum added to the sum of their squares is 42, and whose product is 15. {3} and {5}
chk: x=3, y=5 | x+y+x^2+y^2=42 | x*y=15
q: Find two numbers such, that their product added to their sum shall be 47, and their sum taken from the sum of their squares shall leave 62. {5} and {7}
chk: x=5, y=7 | x*y+x+y=47 | x^2+y^2-(x+y)=62
q: Find two numbers such, that their sum, their product, and the difference of their squares, shall be all equal to each other. The greater is {$ 3/2+(1/2)√5} and the less {$ 1/2+(1/2)√5}.
chk: x=3/2+(1/2)√5, y=1/2+(1/2)√5 | x+y=x*y | x*y=x^2-y^2
q: Find two numbers whose product is equal to the difference of their squares, and the sum of whose squares is equal to the difference of their cubes. The greater is {$ (1/4)(5+√5) | 5/4+(1/4)√5} and the less {$ (1/2)√5 | √5/2}.
chk: x=(5+√5)/4, y=√5/2 | x*y=x^2-y^2 | x^2+y^2=x^3-y^3
q: A and B gained by trading $100. Half of A's stock was less than B's by $100, and A's gain was `3/20` of B's stock. Supposing the gains in proportion to the stock, required the stock and gain of each, in dollars. A's stock {600}, B's {400}; A's gain {60}, B's {40}.
chk: x=600, y=400 | x/2=y-100 | (3/20)y=100x/(x+y)
q: The product of two numbers added to their sum is 23; and 5 times their sum taken from the sum of their squares leaves 8. Required the numbers. {2} and {7}
chk: x=2, y=7 | x*y+x+y=23 | x^2+y^2-5(x+y)=8
q: There are three numbers, the difference of whose differences is 5; their sum is 44, and continued product 1950; find the numbers. {25}, {13}, {6}
chk: x=25, y=13, z=6 | (x-y)-(y-z)=5 | x+y+z=44 | x*y*z=1950
== 54 | Quadratic Equations | Formulas and general solutions; special solutions and artifices
art: 252 | Formulae | A General Solution to a problem producing a quadratic equation, like one in simple equations, gives rise to a formula (Art. 162), which expressed in ordinary language, furnishes a rule. Express each of the following formulae in the form of a rule, and solve the numerical example by it.
q: Investigate a formula for finding two numbers, `x` and `y`, of which the sum of their squares is `s`, and difference of the squares `d`. x = {$ (1/2)√(2(s+d)) | √(2(s+d))/2 @ √((s+d)/2)}, y = {$ (1/2)√(2(s-d)) | √(2(s-d))/2 @ √((s-d)/2)}
q: Example: find two numbers such that the sum and difference of their squares are respectively 208 and 80. {12} and {8}
chk: x=12, y=8 | x^2+y^2=208 | x^2-y^2=80
q: Investigate a formula for finding two numbers, `x` and `y`, of which the difference is `d`, and the product `p`. x = {$ (1/2)(d+√(d^2+4p)) | d/2+(1/2)√(d^2+4p)}, y = {$ (1/2)(-d+√(d^2+4p)) | -d/2+(1/2)√(d^2+4p)}
chk: x=(d+√(d^2+4p))/2, y=(-d+√(d^2+4p))/2 | x-y=d | x*y=p
q: Example: a man is 8 years older than his wife, and the product of the numbers expressing the age of each is 2100. How old are they? Man {50}, wife {42}.
chk: x=50, y=42 | x-y=8 | x*y=2100
q: Investigate a formula for finding a number, `x`, of which the sum of the number and its square root is `s`. x = {$ s+1/2-√(s+1/4) @x: x+√x=s}
q: Example: the sum of a number and its square root is 272; what is the number? {256}
chk: x=256 | x+√x=272
q: The same when the difference of the number `x`, and its square root is `d`. x = {$ d+1/2+√(d+1/4) @x: x-√x=d}
q: Example: find a number such that if its square root be subtracted from it, the remainder will be 132. {144}
chk: x=144 | x-√x=132
q: Given `x+y=s`, and `xy=p`, find the value of `x^2+y^2` in terms of `s` and `p`. {$ s^2-2p}
q: And of `x^3+y^3`. {$ s^3-3ps | s^3-3p*s}
q: And of `x^4+y^4`. {$ s^4-4ps^2+2p^2 | s^4-4p*s^2+2p^2}
q: Example: the sum of two numbers is 5, and their product 6. Required the sum of their squares {13}, of their cubes {35}, and of their fourth powers {97}.
chk: x=2, y=3 | x^2+y^2=13 | x^3+y^3=35 | x^4+y^4=97
art: 253 | Special Solutions and Examples | If an equation can be placed under the form `(x+a)X=0`, in which X represents an expression involving `x`, at least one value of the unknown quantity may be found. For since the equation will be satisfied by making either factor `=0`, we have `x+a=0`, and `X=0`. Therefore, `x=-a`, is one solution of the equation, and the other values of `x` will be found by solving, if possible, the equation `X=0`. Thus, the equation `x^3-x^2-4x+4=0`, may be placed under the form `(x-2)(x^2+x-2)=0`. Hence, `x-2=0`, or `x=+2`; and, from the other factor, we find `x=+1`, or -2. Skill in separating such an equation into its factors must be acquired by practice.
q: Find the three roots of `x^3-x^2-4x+4=0`. x = {$ 2 @x: x^3-x^2-4x+4=0} or {$ 1 @x: x^3-x^2-4x+4=0} or {$ -2 @x: x^3-x^2-4x+4=0}
art: 253 | Example 1 | Given `x-1=2+2/√x`, to find `x`. Since `x-1=(√x+1)(√x-1)` and `2+2/√x=(2/√x)(√x+1)`, therefore `(√x+1)(√x-1)=(2/√x)(√x+1)`. Therefore, `√x+1=0`, and `x=(-1)^2=1`. Also, `√x-1=2/√x`, by dividing by `√x+1`. Whence, `√x=2`, or -1; and `x=4`, or 1. (The value `x=1` comes from `√x=-1`.)
q: Given `x-1=2+2/√x`, find `x` (with `√x` positive). x = {4 @x: x-1=2+2/√x}
q: `x^3-3x=2` (add `2x` to each side) x = {$ -1 @x: x^3-3x=2} or {$ 2 @x: x^3-3x=2}
q: `x^2-2/(3x)=1 4/9` (transpose `4/9` and `2/(3x)`) x = {$ -2/3 @x: x^2-2/(3x)=13/9} or {$ 1/3±(1/3)√10 @x: x^2-2/(3x)=13/9}
q: `2x^3-x^2=1` x = {$ 1 @x: 2x^3-x^2=1} or {$ -1/4±(1/4)√-7 @x: 2x^3-x^2=1}
q: `x^3-3x^2+x+2=0` x = {$ 2 @x: x^3-3x^2+x+2=0} or {$ 1/2±(1/2)√5 @x: x^3-3x^2+x+2=0}
q: `x^3=6x+9` x = {$ 3 @x: x^3=6x+9} or {$ -3/2±(1/2)√-3 @x: x^3=6x+9}
q: `x+7x^(1/3)=22` (here `x+7x^(1/3)-22=(x-8)+7(x^(1/3)-2)`, and `x^(1/3)-2` is a divisor; the book also gives the imaginary roots `29±7√-10`) x = {8 @x: x+7x^(1/3)=22}
q: `x^4+(13/3)x^3-39x=81` x = plus or minus {3 @x: x^4+(13/3)x^3-39x=81} or {$ -13/6±(1/6)√-155 @x: x^4+(13/3)x^3-39x=81}
art: 253 | Making both sides perfect squares | An artifice that is frequently employed, consists in adding to each side of the equation, such a number or quantity as will render both sides perfect squares. Example: given `x=(12+8√x)/(x-5)`. Clearing of fractions, `x^2-5x=12+8√x`. Add `x+4` to each side, and extract the square root: `x-2=±(4+√x)`. From which we easily find `x=9`, 4, or `(1/2)(-3±√-7)`. (Only 9 verifies the given equation with `√x` positive; the others come from the minus sign or from `√x` negative.)
q: Given `x=(12+8√x)/(x-5)`, find `x` (with `√x` positive). x = {9 @x: x=(12+8√x)/(x-5)}
q: `x-3=(3+4√x)/x` (the root with `√x` positive; the book gives `(1/2)(7±√13)` and `(1/2)(-1±√-3)`) x = {$ 7/2+(1/2)√13 @x: x-3=(3+4√x)/x}
q: `49x^2/4+48/x^2-49=9+6/x` (add `1/x^2` to each side) x = {$ 2 @x: 49x^2/4+48/x^2-49=9+6/x} or {$ -8/7 @x: 49x^2/4+48/x^2-49=9+6/x} or {$ -3/7±(1/7)√93 @x: 49x^2/4+48/x^2-49=9+6/x}
q: `x^4+17x^3/2-34x=16` (transpose `34x`, and add `(17x/4)^2` to each side) x = plus or minus {2 @x: x^4+17x^3/2-34x=16} or {$ -8 @x: x^4+17x^3/2-34x=16} or {$ -1/2 @x: x^4+17x^3/2-34x=16}
q: `x^4(1+1/(3x))^2-(3x^2+x)=70` (divide by `x^4`, and add `9/(4x^4)` to each side; see the same example in Art. 242) x = {$ 3 @x: x^4(1+1/(3x))^2-(3x^2+x)=70} or {$ -10/3 @x: x^4(1+1/(3x))^2-(3x^2+x)=70} or {$ -1/6±(1/6)√-251 @x: x^4(1+1/(3x))^2-(3x^2+x)=70}
q: `18/x^2+(81-x^2)/(9x)=(x^2-65)/72` (multiply by 2, and add `8x/36+81/36` to each side) x = {$ 9 @x: 18/x^2+(81-x^2)/(9x)=(x^2-65)/72} or {$ -4 @x: 18/x^2+(81-x^2)/(9x)=(x^2-65)/72} or {$ -9 @x: 18/x^2+(81-x^2)/(9x)=(x^2-65)/72}
q: `27x^2-841/(3x^2)+17/3=232/(3x)-1/(3x^2)+5` (multiply both sides by 3, transpose `841/x^2` and `1/x^2`, and add 1 to each side) x = {$ 2 @x: 27x^2-841/(3x^2)+17/3=232/(3x)-1/(3x^2)+5} or {$ -14/9 @x: 27x^2-841/(3x^2)+17/3=232/(3x)-1/(3x^2)+5} or {$ -2/9±(1/9)√-266 @x: 27x^2-841/(3x^2)+17/3=232/(3x)-1/(3x^2)+5}
art: 253 | Other artifices | We shall now present a few solutions giving examples of other artifices. 16. Given `(1+x^4)/(1+x)^4=a`. Then `1+x^4=a(1+x)^4=a(1+4x+6x^2+4x^3+x^4)`, and `(1-a)(1+x^4)=4a(x+x^3)+6ax^2`. Dividing by `x^2`, `(1-a)(x^2+1/x^2)=4a(x+1/x)+6a`; so `(x+1/x)^2-(4a/(1-a))(x+1/x)=6a/(1-a)+2=(2+4a)/(1-a)`. Complete the square, and find the value of `x+1/x`, which is `(2a±√(2(1+a)))/(1-a)`; call this `2p`, and we then find `x=p±√(p^2-1)`. 17. Given `x^(x+y)=y^(4a)`, and `y^(x+y)=x^a`. From the 1st equation, `y=x^((x+y)/(4a))`; from the 2d, `y=x^(a/(x+y))`. Therefore `(x+y)/(4a)=a/(x+y)`, and `(x+y)^2=4a^2`, or `x+y=2a`. But `x^a=y^(2a)`, since `x+y=2a`; therefore `x=y^2`, and `y^2+y=2a`. Whence, `y=(1/2)(-1±√(8a+1))`, and `x=(1/2)(4a+1∓√(8a+1))`.
art: 253 | Sum and product as unknowns | When two unknown quantities are found in an equation, in the form of `x+y` and `xy`, it is generally expedient to put their sum `x+y=s`, and their product `xy=p`. 18. Given `(x+y)(xy+1)=18xy` (1), `(x^2+y^2)(x^2y^2+1)=208x^2y^2` (2). Let `x+y=s`, and `xy=p`; then `s(p+1)=18p` (1), and `(s^2-2p)(p^2+1)=208p^2` (2). From the square of (1), take (2), and after dividing by `2p`, we have `s^2+p^2+1=58p` (3). But `2s(p+1)=36p`, from (1), and `2p=2p`. Adding, `(s+p+1)^2=96p`, so `s+p+1=4√(6p)`. But `p+1=18p/s`; therefore `s=4√(6p)-18p/s`, or `s^2-4s√(6p)=-18p`; from which `s=3√(6p)`, or `√(6p)`. Then `p+1=4√(6p)-s=√(6p)`, or `3√(6p)`; whence `p=26±√675`, or `2±√3`. Having `x+y` and `xy`, the values of `x` and `y` are easily found (Art. 246); two of the values are `x=7±4√3`, `y=2∓√3`.
q: In example 18, with `x=7+4√3`, what is `y`? {$ 2-√3}
chk: x=7+4√3, y=2-√3 | (x+y)(x*y+1)=18x*y | (x^2+y^2)(x^2*y^2+1)=208x^2*y^2
q: `2(x+y)^3+1=(x^2+y^2)(xy+x^3+y^3)`, `x+y=3`: x = {2}, y = {1} (or the reverse).
chk: x=2, y=1 | 2(x+y)^3+1=(x^2+y^2)(x*y+x^3+y^3) | x+y=3
q: `1+x^3=a(1+x)^3` (one answer with ±) x = {$ (1+2a)/(2(1-a))±√(12a-3)/(2(1-a)) @x: 1+x^3=a(1+x)^3}
art: 253 | Example 21 | `a/x^2-(1/x)√(x-2a-a/x)=1`. The book's answer is `x=(1/4)(1±√(1-8a)±√(2±2(1-8a)^(1/2)+8a))`.
q: `x+y+xy(x+y)+x^2y^2=85`, `xy+(x+y)^2+xy(x+y)=97`: x = {6}, y = {1}; or x = {1}, y = {6}.
chk: x=6, y=1 | x+y+x*y*(x+y)+x^2*y^2=85 | x*y+(x+y)^2+x*y*(x+y)=97
q: `2c^2/d^2+ac/d-(a-b)(2c+ad)x/d=(a+b)cx/d-(a^2-b^2)x^2` x = {$ (2c+ad)/((a+b)d) @x: 2c^2/d^2+a*c/d-(a-b)(2c+a*d)x/d=(a+b)c*x/d-(a^2-b^2)x^2} or {$ c/((a-b)d) @x: 2c^2/d^2+a*c/d-(a-b)(2c+a*d)x/d=(a+b)c*x/d-(a^2-b^2)x^2}
q: `(x^3+1)(x^2+1)(x+1)=30x^3` (the real roots, one answer with ±) x = {$ 3/2±(1/2)√5 @x: (x^3+1)(x^2+1)(x+1)=30x^3}
q: `x^3+y^3=35`, `x^2+y^2=13`: x = {3}, y = {2}; or x = {2}, y = {3}; the others are x = `1±(1/2)√22`, y = `1∓(1/2)√22`.
chk: x=3, y=2 | x^3+y^3=35 | x^2+y^2=13
chk: x=1+(1/2)√22, y=1-(1/2)√22 | x^3+y^3=35 | x^2+y^2=13
art: 253 | Examples 26 and 27 | 26. Given `xyz/(x+y)=a`, `xyz/(x+z)=b`, `xyz/(y+z)=c`. The book's answers are `x=√(2abc(ac+bc-ab)/((ab+ac-bc)(ab+bc-ac)))`, `y=√(2abc(ab+bc-ac)/((ac+bc-ab)(ab+ac-bc)))`, `z=√(2abc(ab+ac-bc)/((ac+bc-ab)(ab+bc-ac)))`. 27. Given `(x^6+1)y=(y^2+1)x^3`, `(y^6+1)x=9(x^2+1)y^3`. The book's answers are `x=(1/2)(√(∛3+3)+√(∛3-1))` and `y=(1/2)(∛3·√(∛3+3)±√(3∛9-1))`.
== 55 | Ratio, Proportion, and Progressions | Ratio: kinds, terms, compound ratios, comparison of ratios
art: 254 | Two ways of comparing | Two quantities of the same kind may be compared in two ways. By considering, 1st. How much the one exceeds the other. 2d. How many times the one is contained in the other. The first method is termed comparison by difference; the second, comparison by quotient. The first is sometimes called Arithmetical ratio; the second, Geometrical ratio. If we compare 2 and 6, we find that 2 is four less than 6, or that 2 is contained in 6 three times. Also, the arithmetical ratio of `a` to `b` is `b-a`; the geometrical ratio of `a` to `b` is `b/a`. The term Ratio, unless it is otherwise stated, always signifies geometrical ratio.
q: What is the arithmetical ratio of 2 to 6? {4}
art: 255 | Ratio | Ratio is the quotient which arises from dividing one quantity by another of the same kind. Thus, the ratio of 2 to 6 is 3, and the ratio of `a` to `ma` is `m`. Note that in this book the ratio of `a` to `b` is `b/a`: the second term divided by the first.
q: What is the ratio of 2 to 6? {3}
q: What is the ratio of `a` to `ma`? {$ m}
art: 256 | Antecedent and consequent | When two numbers, as 2 and 6, are compared, the first is called the antecedent, and the second the consequent. When spoken of as one, they are called a couplet. When spoken of as two, they are called the terms of the ratio. Thus, 2 and 6 together form a couplet, of which 2 is the first term, and 6 the second term.
mc: In the ratio of 2 to 6, the number 6 is the... | *consequent | antecedent | couplet
art: 257 | How ratio is written | Ratio is expressed in two ways: 1st. In the form of a fraction, of which the antecedent is the denominator, and the consequent the numerator. Thus, the ratio of 2 to 6 is expressed by `6/2`; the ratio of `a` to `b`, by `b/a`. 2d. By placing two points between the terms. Thus, the ratio of 2 to 6, is written `2:6`; the ratio of `a` to `b`, `a:b`, etc.
art: 258 | Kinds of ratios | The ratio of two quantities may be either a whole number, a common fraction, or an interminate decimal. Thus, the ratio of 2 to 6 is `6/2`, or 3; of 10 to 4, is `2/5`. The ratio of 2 to `√5` is `√5/2`, or `2.236/2`, or `1.118+`.
q: What is the ratio of 10 to 4? {2/5}
q: What is the ratio of 2 to `√5`? {$ √5/2 | (1/2)√5}
art: 259 | Ratios as fractions | Since the ratio of two numbers is expressed by a fraction, of which the antecedent is the denominator, and the consequent the numerator, whatever is true with regard to a fraction is true with regard to the terms of a ratio. Hence, 1st. To multiply the consequent, or divide the antecedent of a ratio by any number, multiplies the ratio by that number. 2d. To divide the consequent or to multiply the antecedent of a ratio by any number, divides the ratio by that number. 3d. To multiply or divide both the antecedent and consequent of a ratio by any number, does not alter the ratio.
tf: Multiplying both terms of a ratio by the same number does not alter the ratio. {T}
mc: Multiplying the antecedent of a ratio by 2... | *divides the ratio by 2 | multiplies the ratio by 2 | does not alter it
art: 260 | Equality and inequality | When the terms of a ratio are equal to each other, the ratio is said to be a ratio of equality; when the second term is greater than the first, a ratio of greater inequality; when it is less, a ratio of less inequality. Thus, the ratio of 2 to 2 is a ratio of equality. The ratio of 2 to 3 is a ratio of greater inequality. The ratio of 3 to 2 is a ratio of less inequality. Hence, a ratio of equality may be expressed by 1; a ratio of greater inequality, by a number greater than 1; and a ratio of less inequality, by a number less than 1.
mc: The ratio of 3 to 2 is a ratio of... | *less inequality | greater inequality | equality
art: 261 | Compound ratios | When the corresponding terms of two or more ratios are multiplied together, the ratios are said to be compounded, and the result is termed a compound ratio. Thus, the ratio of `a` to `b`, compounded with the ratio of `c` to `d`, is `b/a*d/c=bd/(ac)`. A ratio compounded of two equal ratios is called a duplicate ratio; one compounded of three equal ratios, a triplicate ratio. Thus, the duplicate ratio of `b/a` is `b/a*b/a=b^2/a^2`; the triplicate ratio is `b^3/a^3`. The ratio of the square roots of two quantities is called a subduplicate ratio; that of the cube roots, a subtriplicate ratio. Thus, the subduplicate ratio of 4 to 9 is `3/2`; and that of `a` to `b` is `√b/√a`; the subtriplicate ratio of `a` to `b` is `∛b/∛a`.
q: What is the ratio of `a` to `b`, compounded with the ratio of `c` to `d`? {$ bd/(ac)}
q: What is the triplicate ratio of `b/a`? {$ b^3/a^3}
q: What is the subduplicate ratio of 4 to 9? {3/2}
q: What is the duplicate ratio of 2 to 3? {9/4}
art: 262 | Comparing ratios | Ratios may be compared with each other by reducing the fractions which represent them to a common denominator. Thus, the ratio of 2 to 7 is greater than the ratio of 3 to 10, for the fractions `7/2` and `10/3`, reduced to a common denominator, are `21/6` and `20/6`, and the first is greater than the second.
mc: Which is greater, the ratio of 2 to 7 or the ratio of 3 to 10? | *the ratio of 2 to 7 | the ratio of 3 to 10 | they are equal
== 56 | Ratio, Proportion, and Progressions | Proportion: definitions and propositions
art: 263 | Proportion | Proportion is an equality of ratios; that is, when two ratios are equal, their terms are said to be proportional. Thus, if the ratio of `a` to `b` is equal to the ratio of `c` to `d`; that is, if `b/a=d/c`; then, `a`, `b`, `c`, `d`, form a proportion. Proportion is written in two ways: 1st. By placing a double colon between the ratios; thus, `a:b::c:d`, read, a is to b as c is to d. 2d. By placing the sign of equality between the ratios; thus, `a:b=c:d`, read, the ratio of a to b equals the ratio of c to d. From the preceding definition it follows, that when four quantities are in proportion, the second divided by the first, must give the same quotient as the fourth divided by the third. This is the primary test of the proportionality of four quantities. Thus, if 3, 5, 6, 10, are the four terms of a proportion, so that `3:5::6:10`, we must have `5/3=10/6`. If these fractions are not equal to each other, the proportion is false. Thus, the proportion `3:8::2:5` is false, since `8/3>5/2`. Remark: the words ratio and proportion should not be confounded. Thus, two quantities are not in the proportion of 2 to 3, but in the ratio of 2 to 3. A ratio subsists between two quantities, a proportion between four.
tf: `3:8::2:5` is a true proportion. {F}
tf: `3:5::6:10` is a true proportion. {T}
art: 264 | Extremes and means | Each of the four quantities in a proportion is called a term. The first and last terms are called the extremes; the second and third terms, the means.
mc: In `a:b::c:d`, the means are... | *`b` and `c` | `a` and `d` | `a` and `c`
art: 265 | Antecedents, consequents, fourth proportional | Of four quantities in proportion, the first and third are called the antecedents, and the second and fourth, the consequents (Art. 257); and the last is said to be a fourth proportional to the other three taken in their order.
art: 266 | Mean proportional; continued proportion | Three quantities are in proportion when the first has the same ratio to the second, that the second has to the third. The middle term is a mean proportional between the other two. Thus, if `a:b::b:c`, then `b` is a mean proportional between `a` and `c`; and `c` is called a third proportional to `a` and `b`. When several quantities have the same ratio between each two that are consecutive, they are said to form a continued proportion.
art: 267 | Proposition I | In every proportion, the product of the means is equal to the product of the extremes. Let `a:b::c:d`. Since this is a true proportion, we must have (Art. 263) `b/a=d/c`. Clearing of fractions, `bc=ad`. Illustration by numbers: `2:6::5:15`; and `6*5=2*15`. Taking `bc=ad`, we find `d=bc/a`, `c=ad/b`, `b=ad/c`, `a=bc/d`. Hence, if any three terms of a proportion be given, the remaining term may be found. This proposition furnishes a more convenient test of proportionality than the method given in Art. 263. Thus, `2:3::5:8`, is not a true proportion, since `3*5` is not equal to `2*8`.
q: The first three terms of a proportion are `x+y`, `x^2-y^2`, and `x-y`; what is the fourth? {$ x^2-2xy+y^2 @ (x^2-y^2)(x-y)/(x+y)}
q: The 1st, 3d, and 4th terms of a proportion are `(m-n)^2`, `m^2-n^2`, and `m+n`; required the 2d. {$ m-n @ (m-n)^2(m+n)/(m^2-n^2)}
q: The 1st, 2d, and 4th terms of a proportion are `(a+√b)/(a-√b)`, `a^2-b`, and `(a-√b)(a^2-b)/(a+√b)`; required the 3d. {$ 1 @ ((a+√b)/(a-√b))*((a-√b)(a^2-b)/(a+√b))/(a^2-b)}
q: Find a fourth proportional to 2, 6, and 5. {15}
chk: x=15 | 6*5=2x
art: 268 | Proposition II | Conversely, if the product of two quantities is equal to the product of two others, two of them may be made the means, and the other two the extremes of a proportion. Let `bc=ad`. Dividing each of these equals by `ac`, we have `bc/(ac)=ad/(ac)`, or `b/a=d/c`. That is (Art. 263), `a:b::c:d`. By dividing each of the equals by `ab`, `cd`, `bd`, etc., we may have the proportion in other forms. Rule: take either factor on either side of the equation for the first term of the proportion, the two on the other side for the second and third, and the remaining factor for the fourth. Thus, from each of the equations `bc=ad`, and `3*12=4*9`, we may have the eight following forms: `a:b::c:d`, `3:4::9:12`; `a:c::b:d`, `3:9::4:12`; `d:b::c:a`, `12:4::9:3`; `d:c::b:a`, `12:9::4:3`; `b:a::d:c`, `4:3::12:9`; `b:d::a:c`, `4:12::3:9`; `c:a::d:b`, `9:3::12:4`; `c:d::a:b`, `9:12::3:4`.
mc: From `3*12=4*9`, which is a true proportion? | *`3:4::9:12` | `3:4::12:9` | `3:12::4:12`
art: 269 | Proposition III | If three quantities are in proportion, the product of the extremes is equal to the square of the mean. If `a:b::b:c`, then (Art. 267), `ac=bb=b^2`. It follows from Art. 268, that the converse of this proposition is also true. Thus, if `ac=b^2`, `a:b::b:c`. Hence, if the product of the first and third of three quantities is equal to the square of the second, the second is a mean proportional between the first and third.
q: Find a mean proportional between 4 and 9. {6}
chk: x=6 | x^2=4*9
art: 270 | Proposition IV, Alternation | If four quantities are in proportion, they will be in proportion by Alternation; that is, the first will be to the third as the second to the fourth. Let `a:b::c:d`. Then (Art. 263), `b/a=d/c`. Multiply both sides by `c`, `bc/a=d`; divide both sides by `b`, `c/a=d/b`. That is, `a:c::b:d`. If `2:6::10:30`; then, `2:10::6:30`.
art: 271 | Proposition V, Inversion | If four quantities are in proportion, they will be in proportion by Inversion; that is, the second will be to the first as the fourth to the third. Let `a:b::c:d`. Then `b/a=d/c`; inverting the fractions, `a/b=c/d`. That is, `b:a::d:c`. If `5:10::6:12`; then, `10:5::12:6`. It follows from this proposition, that the equation `b/a=d/c` may be converted into a proportion in either of two ways, thus: `a:b::c:d`, or `b:a::d:c`.
art: 272 | Proposition VI | If two sets of proportions have an antecedent and consequent in the one, equal to an antecedent and consequent in the other, the remaining terms will be proportional. Let `a:b::c:d` (1), and `a:b::e:f` (2); then will `c:d::e:f`. From (1), `b/a=d/c`; from (2), `b/a=f/e`. Hence, `d/c=f/e`; which gives `c:d::e:f`. If `4:8::10:20` and `4:8::6:12`; then, `10:20::6:12`.
art: 273 | Proposition VII, Composition | If four quantities are in proportion, they will be in proportion by Composition; that is, the sum of the first and second will be to the first or second, as the sum of the third and fourth is to the third or fourth. Let `a:b::c:d` (1); then will `a+b:b::c+d:d`. From (1), `b/a=d/c`; inverting the fractions, `a/b=c/d`; adding unity to both members, `a/b+1=c/d+1`; reducing to improper fractions, `(a+b)/b=(c+d)/d`. Hence (Art. 271), `a+b:b::c+d:d`. If `3:6::9:18`; then, `3+6:6::9+18:18`, or `9:6::27:18`. In a similar manner it may be shown that `a+b:a::c+d:c`.
art: 274 | Proposition VIII, Division | If four quantities are in proportion, they will be in proportion by Division; that is, the difference of the first and second will be to the first or second, as the difference of the third and fourth is to the third or fourth. Let `a:b::c:d` (1); then will `a-b:b::c-d:d`. From (1), `b/a=d/c`; inverting the fractions, `a/b=c/d`; subtracting unity from both members, `a/b-1=c/d-1`; reducing to improper fractions, `(a-b)/b=(c-d)/d`. This gives (Art. 271), `a-b:b::c-d:d`. If `18:6::30:10`; then, `18-6:6::30-10:10`, or `12:6::20:10`. In a similar manner it may be shown that `a-b:a::c-d:c`.
art: 275 | Proposition IX | If four quantities are in proportion, the sum of the first and second will be to their difference as the sum of the third and fourth is to their difference. Let `a:b::c:d` (1); then will `a+b:a-b::c+d:c-d`. From (1), by Composition and Division (Arts. 273, 274), `a+b:b::c+d:d`, and `a-b:b::c-d:d`. By alternation, `a+b:c+d::b:d`, and `a-b:c-d::b:d`. From which (Art. 272), `a+b:c+d::a-b:c-d`. Or, by alternation, `a+b:a-b::c+d:c-d`. If `6:2::12:4`; then, `6+2:6-2::12+4:12-4`, or `8:4::16:8`.
mc: If `a:b::c:d`, then by Composition... | *`a+b:b::c+d:d` | `a+b:c::b+d:d` | `a:b+c::d:b`
mc: If `18:6::30:10`, then by Division... | *`12:6::20:10` | `12:6::40:10` | `24:6::40:10`
art: 276 | Proposition X | If four quantities are in proportion, like powers or roots of those quantities will also be in proportion. Let `a:b::c:d`; then will `a^n:b^n::c^n:d^n`. From the 1st, `b/a=d/c`. Raising each of these equals to the nth power, `b^n/a^n=d^n/c^n`. That is, `a^n:b^n::c^n:d^n`, where n may be either a whole number or a fraction. If `2:6::10:30`; then, `2^2:6^2::10^2:30^2`, or `4:36::100:900`. If `8:27::64:216`; then `∛8:∛27::∛64:∛216`, or `2:3::4:6`.
q: If `2:6::10:30`, then `2^2:6^2::10^2:30^2`, or `4:36::100:` {900}
art: 277 | Proposition XI | If two sets of quantities are in proportion, the products of the corresponding terms will also be in proportion. Let `a:b::c:d` (1), and `m:n::r:s` (2); then will `am:bn::cr:ds`. For from (1), `b/a=d/c` (3); and from (2), `n/m=s/r` (4). Multiplying (3) by (4), `bn/(am)=ds/(cr)`; this gives `am:bn::cr:ds`.
== 57 | Ratio, Proportion, and Progressions | Sum of proportions; exercises and problems in proportion; harmonical proportion
art: 277 | Example | If `3:9::2:6`, and `5:15::4:12`; then, `15:135::8:72`.
art: 278 | Proposition XII | In any number of proportions having the same ratio, any antecedent is to its consequent as the sum of all the antecedents is to the sum of all the consequents. Let `a:b::c:d::m:n`, etc. Then `a:b::a+c+m:b+d+n`. Since `a:b::c:d`, we have `bc=ad` (Art. 267). Since `a:b::m:n`, we have `bm=an`. Also, `ab=ab`. The sum of these equalities gives `ab+bc+bm=ab+ad+an`. Factoring, `b(a+c+m)=a(b+d+n)`. This gives (Art. 268), `a:b::a+c+m:b+d+n`. If `5:10::2:4::3:6`, etc.; then, `5:10::5+2+3:10+4+6`, or `5:10::10:20`.
art: 278 | Exercises in Ratio and Proportion | Remember that in this book the ratio of `a` to `b` is `b/a`.
mc: Which is the greater ratio, that of 3 to 4, or `3^2` to `4^2`? | *the last | the first | they are equal
q: Compound the duplicate ratio of 2 to 3; the triplicate ratio of 3 to 4; and the subduplicate ratio of 64 to 36. The result is the ratio of 1 to {4}.
chk: x=4 | x=(9/4)*(64/27)*(6/8)
q: What quantity must be added to each of the terms of the ratio `m:n`, that it may become equal to `p:q`? {$ (mq-np)/(p-q) @x: (n+x)/(m+x)=q/p}
q: If the ratio of `a` to `b` is `2 2/3`, what is the ratio of `2a` to `b`? {1 1/3}
q: And of `3a` to `4b`? {3 5/9}
chk: x=32/9 | x=(4/3)*(8/3)
q: If the ratio of `a` to `b` is `1 2/3`, what is the ratio of `a+b` to `b`? {5/8}
q: And of `b-a` to `a`? {3/2}
q: If the ratio of `m` to `n` is `4/7`, what is the ratio of `m-n` to `6m`? {14}
q: And of `m-n` to `5n`? {6 2/3}
chk: x=20/3 | x=5(4/7)/(3/7)
q: If the ratio of `5y-8x` to `7x-5y` is 6, what is the ratio of `x` to `y`? `x:y` as {7} to {11}
chk: x=7, y=11 | (7x-5y)/(5y-8x)=6
mc: Which proportion is deducible from the equation `ab=a^2-x^2`? | *`a:a+x::a-x:b` | `a:b::a+x:a-x` | `a:x::b:a`
mc: If `x^2+y^2=2ax`, what is the ratio of `x` to `y`? | *`x:y::y:2a-x` | `x:y::2a:y` | `x:y::y:2a+x`
q: Four given numbers are represented by `a`, `b`, `c`, `d`; what quantity added to each will make them proportionals? {$ (bc-ad)/(a-b-c+d) @x: (b+x)(c+x)=(a+x)(d+x)}
q: Find `x` in terms of `y` from the proportions `x:y::a^3:b^3`, and `a:b::∛(c+x):∛(d+y)`. {$ cy/d @x: x*d=c*y}
art: 278 | Exercises to prove | If four numbers are proportionals, show that there is no number which being added to each, will leave the resulting four numbers proportionals. Prove that equal multiples of two quantities are to each other as the quantities themselves, or that `ma:mb::a:b`. Prove that like parts of two quantities are to each other as the quantities themselves, or that `a/n:b/n::a:b`. If `a:b::c:d`, prove that `ma:mb::nc:nd`, and also that `ma:nb::mc:nd`, `m` and `n` being any multiples. Prove that the quotients of the corresponding terms of two proportions are proportional.
art: 279 | Applications of proportion | 1. Resolve the number 24 into two factors, so that the sum of their cubes may be to the difference of their cubes as 35 to 19. Let `x` and `y` denote the required factors; then `xy=24`, and `x^3+y^3:x^3-y^3::35:19`. Therefore (Art. 275), `2x^3:2y^3::54:16`; or `x^3:y^3::27:8`; or (Art. 276), `x:y::3:2`. From which `y=(2/3)x`; then, substituting the value of `y` in the equation `xy=24`, we find `x=±6`; hence, `y=±4`. 2. Given `(∛(x+1)+∛(x-1))/(∛(x+1)-∛(x-1))=2`. Resolving this equation into a proportion, `∛(x+1)+∛(x-1):∛(x+1)-∛(x-1)::2:1`; so (Art. 275), `2∛(x+1):2∛(x-1)::3:1`, or `∛(x+1):∛(x-1)::3:1`; or (Art. 276), `x+1:x-1::27:1`; (Art. 275), `2x:2::28:26`; whence, `52x=56`, or `x=1 1/13`.
q: Resolve the number 24 into two factors, so that the sum of their cubes may be to the difference of their cubes as 35 to 19. {6} and {4}
chk: x=6, y=4 | x*y=24 | 19(x^3+y^3)=35(x^3-y^3)
q: Given `(∛(x+1)+∛(x-1))/(∛(x+1)-∛(x-1))=2`, find `x`. x = {1 1/13}
chk: x=14/13 | (∛(x+1)+∛(x-1))/(∛(x+1)-∛(x-1))=2
q: Solve `x+y:x-y::3:1`, `x^3-y^3=56`: x = {4}, y = {2}
chk: x=4, y=2 | x+y=3(x-y) | x^3-y^3=56
q: Solve `x+y:x::7:5`, `xy+y^2=126`: x = plus or minus {15}, y = plus or minus {6} (the same signs).
chk: x=15, y=6 | 5(x+y)=7x | x*y+y^2=126
q: Solve `(x+y)^2:(x-y)^2::64:1`, `xy=63`: x = plus or minus {9}, y = plus or minus {7} (the same signs).
chk: x=9, y=7 | (x+y)^2=64(x-y)^2 | x*y=63
q: Find `x`: `(a-√(a^2-x^2))/(a+√(a^2-x^2))=b`. x = plus or minus {$ 2a√b/(b+1) @x: x^2(b+1)^2=4a^2b}
q: Find `x`: `(√(a+x)-√(a-x))/(√(a+x)+√(a-x))=1/b`. x = {$ 2ab/(b^2+1) @x: (a+x)(b-1)^2=(a-x)(b+1)^2}
q: It is required to find two numbers whose product is 320, and the difference of whose cubes is to the cube of their difference, as 61 is to 1. {20} and {16}
chk: x=20, y=16 | x*y=320 | x^3-y^3=61(x-y)^3
art: 280 | Harmonical Proportion | Three or four quantities are in Harmonical Proportion when the first has the same ratio to the last, that the difference between the first and second has to the difference between the last and the last except one. Thus, `a`, `b`, `c`, are in harmonical proportion when `a:c::a-b:b-c`; and `a`, `b`, `c`, `d`, when `a:d::a-b:c-d`. 1. Let it be required to find a third harmonical proportional `x`, to two given numbers `a` and `b`. We have `a:x::a-b:b-x`; therefore (Art. 267), `a(b-x)=x(a-b)`; whence `x=ab/(2a-b)`.
q: Find a third harmonical proportional to `a` and `b`. {$ ab/(2a-b) @x: a(b-x)=x(a-b)}
q: Find a third harmonical proportional to 3 and 5. {15}
chk: x=15 | 3(5-x)=x(3-5)
q: Find a fourth harmonical proportional `x`, to three given numbers `a`, `b`, and `c`. x = {$ ac/(2a-b) @x: a(c-x)=x(a-b)}
== 58 | Ratio, Proportion, and Progressions | Variation
art: 281 | Variation | Variation, or, as it is sometimes termed, General Proportion, is merely an abridged form of common Proportion. Variable Quantities are such as admit of various values in the same computation. Constant, or Invariable Quantities have only one fixed value. One quantity is said to vary directly as another, when the two quantities depend upon each other in such a manner, that if one be changed the other is changed in the same ratio. Thus, the length of a shadow varies directly as the height of the object which casts it. Such a relation between A and B is expressed thus, A ∝ B, the symbol ∝ being used instead of varies, or varies as.
art: 282 | Four kinds of variation | There are four different kinds of Variation: I. A ∝ B. Here A is said to vary directly as B, or, simply A varies as B. Ex.: if a man works for a certain sum per day, the amount of his wages varies as the number of days in which he works. II. A ∝ 1/B. Here A is said to vary inversely as B. Ex.: the time in which a man may perform a journey will vary inversely as the rate of traveling. III. A ∝ BC. Here A is said to vary as B and C jointly. Ex.: the wages to be received by a workman will vary jointly as the number of days he works, and the wages per day. IV. A ∝ B/C. Here A is said to vary directly as B, and inversely as C. Ex.: the time occupied in a journey varies directly as the distance, and inversely as the rate of travel. These four kinds of variation may be otherwise modified; thus, A may vary as the square or cube of B, inversely as the square or cube, directly as the square and inversely as the cube, etc. Ex.: the intensity of the light shed by any luminous body upon an object will vary directly as the size of the luminous body, and inversely as the square of its distance from the object (see Art. 238).
mc: The time in which a man may perform a journey varies... | *inversely as the rate of traveling | directly as the rate of traveling | jointly as the distance and the rate
mc: The time occupied in a journey varies... | *directly as the distance, and inversely as the rate | jointly as the distance and the rate | inversely as the distance
art: 283 | Propositions | In the following articles, A, B, C, represent corresponding values of any variable quantities, and `a`, `b`, `c`, any other corresponding values of the same quantities. If one quantity vary as a second, and that second as a third, the first varies as the third. Let A ∝ B, and B ∝ C, then shall A ∝ C. For A : a :: B : b, and B : b :: C : c; therefore (Art. 272), A : a :: C : c; that is, A ∝ C. In a similar manner it may be proved that if A ∝ B, and B ∝ 1/C, that A ∝ 1/C.
art: 284 | Sum, difference, root of the product | If each of two quantities vary as a third, their sum, or their difference, or the square root of their product, will vary as the third. Let A ∝ C, and B ∝ C; then, A±B ∝ C; also, √(AB) ∝ C.
art: 285 | More propositions | By a similar method of reasoning, the following propositions may be proved. If one quantity vary as another, it will also vary as any multiple, or any part of the other: if A ∝ B, then A ∝ mB, or A ∝ B/m. If one quantity vary as another, any power or root of the former will vary as the same power or root of the latter: if A ∝ B, then Aⁿ ∝ Bⁿ, n being integral or fractional (Art. 286). If one quantity vary as another, and each of them be multiplied or divided by any quantity, variable or invariable, the products or quotients will vary as each other: if A ∝ B, then qA ∝ qB, and A/q ∝ B/q (Art. 287). If one quantity vary as two others jointly, either of the latter varies as the first directly, and the other inversely: if A ∝ BC, then B ∝ A/C, and C ∝ A/B (Art. 288). If A vary as B, A is equal to B multiplied by some constant quantity: if A ∝ B, then A = mB. If we know any corresponding values of A and B, the constant quantity `m` may be found (Art. 289).
tf: If A varies as B, then A is equal to B multiplied by some constant quantity. {T}
art: 290 | Variations as equations | In general, the simplest method of treating variations, is to convert them into equations. 1. Given that `y` ∝ the sum of two quantities, one of which varies as `x`, and the other as `x^2`, to find the corresponding equation. Because one part ∝ `x`, let this `=mx`, and the other part ∝ `x^2`, let it `=nx^2`. Therefore, `y=mx+nx^2`, where `m` and `n` are two unknown invariable quantities which can only be found when we know two pairs of corresponding values of `x` and `y`. 2. If `y=r+s`, where `r` ∝ `x` and `s` ∝ `1/x`, and if, when `x=1`, `y=6`, and when `x=2`, `y=9`, what is the equation between `x` and `y`? Let `r=mx`, and `s=n/x`; then `y=mx+n/x`. But if `x=1`, `y=6`, so `6=m+n`; and if `x=2`, `y=9`, so `9=2m+n/2`. Hence, `m=4`, `n=2`, and `y=4x+2/x`.
q: In Example 2, what is the equation between `x` and `y`? {$ y=4x+2/x}
chk: x=1, y=6 | y=4x+2/x
chk: x=2, y=9 | y=4x+2/x
q: If `y` varies as `x`, and when `x=2`, `y=4a`; find the equation between `x` and `y`. {$ y=2ax}
chk: x=2, y=4a | y=2a*x
q: If `y` varies as `1/x`, and when `x=1/2`, `y=8`; find the equation between `x` and `y`. {$ y=4/x}
chk: x=1/2, y=8 | y=4/x
q: If `y` = the sum of two quantities, one of which varies as `x`, and the other varies inversely as `x^2`; and when `x=1`, `y=6`, and when `x=2`, `y=5`; find the equation between `x` and `y`. {$ y=2x+4/x^2}
chk: x=1, y=6 | y=2x+4/x^2
chk: x=2, y=5 | y=2x+4/x^2
q: Given that `y` = the sum of three quantities, of which the 1st is invariable, the 2d varies as `x`, and the 3d varies as `x^2`. Also, when `x=1`, 2, 3, `y=6`, 11, 18, respectively; find `y` in terms of `x`. {$ y=3+2x+x^2}
chk: x=1, y=6 | y=3+2x+x^2
chk: x=2, y=11 | y=3+2x+x^2
chk: x=3, y=18 | y=3+2x+x^2
q: Given that `s` varies as `t^2`, when `f` is constant; and `s` varies as `f`, when `t` is constant; also, `2s=f`, when `t=1`. Find the equation between `f`, `s`, and `t`. {$ s=(1/2)ft^2 | 2s=ft^2}
chk: t=1, s=f/2 | s=(1/2)f*t^2
art: 290 | Remarks | 1. The above examples may all be proved. Thus, if in Ex. 5, we put `x=1` in the answer, `y` will equal 6. If we put `x=2`, `y=5`. 2. The Principles of Variation are extensively applied in mechanical philosophy.
== 59 | Ratio, Proportion, and Progressions | Arithmetical progression; inserting means
art: 291 | Arithmetical Progression | An Arithmetical Progression is a series of quantities which increase or decrease by a common difference. Thus, 1, 3, 5, 7, 9, etc., or 12, 9, 6, 3, etc., and `a`, `a+d`, `a+2d`, etc., `a`, `a-d`, `a-2d`, etc., are in Arithmetical Progression. The series is said to be increasing or decreasing, according as `d` is positive or negative.
art: 292 | Any term | To investigate a rule for finding any term of an arithmetical progression, take the series `a`, `a+d`, `a+2d`, `a+3d`, `a+4d`, etc., and `a`, `a-d`, `a-2d`, `a-3d`, `a-4d`, etc. It is manifest that the coefficient of `d` in any term is less by unity than the number of that term in the series; therefore, the nth term `=a+(n-1)d`. If we designate the nth term by `l`, we have `l=a+(n-1)d`, when the series is increasing, and `l=a-(n-1)d`, when the series is decreasing. Hence, the Rule for finding Any Term of an Arithmetical Series: multiply the common difference by the number of terms less one; when the series is increasing, add this product to the first term; when decreasing, subtract it from the first term. The equation `l=a+(n-1)d`, contains four variable quantities, any one of which may be found when the other three are known.
art: 293 | The sum | Having given the first term `a`, the common difference `d`, and the number of terms `n`, to find S, the sum of the series. If we take any arithmetical series, as `S=1+3+5+7+9+11`, and write the same series under it in an inverted order, `S=11+9+7+5+3+1`; adding, `2S=12+12+12+12+12+12`, that is, `2S=12` times the number of terms, `=12*6=72`; whence `S=36`, the sum of the series. To render this method general, let `l` be the last term, and write the series both in a direct and inverted order: `S=a+(a+d)+(a+2d)+...+l`, and `S=l+(l-d)+(l-2d)+...+a`. Adding, `2S=(l+a)+(l+a)+...`, `(l+a)` taken as many times as there are terms (`n`) in the series. Hence, `2S=(l+a)n`; `S=(l+a)n/2`. Hence, the Rule for finding the Sum of an Arithmetical Series: multiply half the sum of the two extremes by the number of terms. It also appears that the sum of the extremes is equal to the sum of any other two terms equally distant from the extremes.
art: 294 | The general problem | The equations `l=a+(n-1)d`, and `S=(a+l)n/2`, furnish the means of solving this general problem: knowing any three of the five quantities, `a`, `d`, `l`, `n`, S, which enter into an arithmetical series, to determine the other two. The book gives a table of the twenty cases. As it is not possible to retain these in the memory, it is best, in ordinary cases, to solve all examples in Arithmetical Progression by the above two formulae. Some of the table: `l=a+(n-1)d`; `S=(1/2)n(2a+(n-1)d)`; `S=(l+a)n/2`; `d=(l-a)/(n-1)`; `d=2(S-an)/(n(n-1))`; `n=(l-a)/d+1`; `n=2S/(l+a)`; `a=l-(n-1)d`; `a=S/n-(n-1)d/2`; `a=2S/n-l`.
q: Find the 15th term of the series 3, 7, 11, etc. (Here `a=3`, `n-1=14`, and `d=4`.) {59}
chk: x=59 | x=3+14*4
q: Find the 20th term of the series 5, 1, -3, etc. {$ -71}
chk: x=-71 | x=5+19*(-4)
q: Find the 8th term of the series `2/3`, `7/12`, `1/2`, etc. {1/12}
chk: x=1/12 | x=2/3+7*(-1/12)
q: Find the 30th term of the series -27, -20, -13, etc. {176}
chk: x=176 | x=-27+29*7
q: Find the nth term of `1+3+5+7`. {$ 2n-1}
q: Find the nth term of `2+2 1/3+2 2/3+`... {$ (1/3)(n+5) | (n+5)/3 @ 2+(n-1)/3}
q: Find the nth term of `13+12 2/3+12 1/3+`... {$ (1/3)(40-n) | (40-n)/3 @ 13-(n-1)/3}
q: Find the sum of `1+2+3+4`, etc., to 50 terms. {1275}
chk: x=1275 | x=(1+50)*25
q: Find the sum of `7+29/4+15/2+`, etc., to 16 terms. {142}
chk: x=142 | x=(16/2)(2*7+15/4)
q: Find the sum of `12+8+4+`, etc., to 20 terms. {$ -520}
chk: x=-520 | x=10(24+19*(-4))
q: Find the sum of `2+2 1/3+2 2/3+`, etc., to `n` terms. {$ (n/6)(n+11) | n(n+11)/6 @ (n/2)(4+(n-1)/3)}
q: Find the sum of `1/2-2/3-1 5/6-`, etc., to `n` terms. {$ (n/12)(13-7n) | n(13-7n)/12 @ (n/2)(1+(n-1)(-7/6))}
q: Find the sum of `(n-1)/n+(n-2)/n+(n-3)/n+`, etc., to `n` terms. {$ (n-1)/2 @ (n/2)((n-1)/n+0)}
q: If a falling body descends `16 1/12` feet the 1st sec., 3 times this distance the next, 5 times the next, and so on, how far will it fall the 30th sec.? {948 11/12} feet
chk: x=11387/12 | x=(193/12)*59
q: And how far altogether in half a minute? {14475} ft.
chk: x=14475 | x=(193/12)*900
q: Two hundred stones being placed on the ground in a straight line, at the distance of 2 feet from each other; how far will a person travel who shall bring them separately to a basket, which is placed 20 yards from the first stone, if he starts from the spot where the basket stands? Give the answer in feet (the book's answer is 19 miles, 4 fur., 640 ft.). {103600}
chk: x=103600 | x=2*(200/2)*(60+60+2*199)
art: 294 | Arithmetical means | Insert 3 arithmetical means between 2 and 14. Here, `a=2`, `l=14`, and `n=5`. From formula (1), we obtain `d=3`. Hence, the three means will be 5, 8, and 11. To solve this problem generally, let it be required to insert `m` arithmetical means between `a` and `l`. Since there are `m` terms between `a` and `l`, we shall have `n=m+2`, and formula (1) becomes `l=a+(m+1)d`. Hence, `d=(l-a)/(m+1)`. Therefore, the common difference will be equal to the difference of the extremes divided by the number of means plus one.
q: Insert 3 arithmetical means between 2 and 14. {list: 5, 8, 11}
q: Insert 4 arithmetical means between 3 and 18. {list: 6, 9, 12, 15}
q: Insert 9 arithmetical means between 1 and -1. {list: 4/5, 3/5, 2/5, 1/5, 0, -1/5, -2/5, -3/5, -4/5}
q: How many terms of the series 19, 17, 15, etc., amount to 91? (From formulas (2) and (1), find `n`; both values work, explain why.) n = {7} or {13}
chk: x=7 | (x/2)(38+(x-1)(-2))=91
chk: x=13 | (x/2)(38+(x-1)(-2))=91
q: How many terms of the series .034, .0344, .0348, etc., amount to 2.748? {60}
chk: x=60 | (x/2)(.068+(x-1)*.0004)=2.748
q: The sum of the first two terms of an arithmetical progression is 4, and the fifth term is 9; find the series (its first five terms). {list: 1, 3, 5, 7, 9}
q: The first two terms of an arithmetical progression being together `=18`, and the next three terms `=12`, how many terms must be taken to make 28? {4} or {7}
chk: x=4 | (x/2)(20+(x-1)(-2))=28
chk: x=7 | (x/2)(20+(x-1)(-2))=28
q: In the series 1, 3, 5, etc., the sum of `2r` terms : the sum of `r` terms :: `x:1`; determine the value of `x`. {4}
q: A sets out for a certain place, and travels 1 mile the first day, 2 the second, and so on. Five days afterward B sets out, and travels 12 miles a day. How long must B travel to overtake A? {3} days or {10} days (B passes A, then A passes B again).
chk: x=3 | 12x=(x+5)(x+6)/2
chk: x=10 | 12x=(x+5)(x+6)/2
q: And how far must B travel? {36} miles or {120} miles
== 60 | Ratio, Proportion, and Progressions | Geometrical progression; infinite series; geometric means
art: 295 | Geometrical Progression | A Geometrical Progression is a series of terms, each of which is derived from the preceding, by multiplying it by a constant quantity, termed the ratio. Thus, 1, 2, 4, 8, 16, etc., is an increasing geometrical progression, whose common ratio is 2. Also, 54, 18, 6, 2, etc., is a decreasing geometrical progression, whose common ratio is `1/3`. In general, `a`, `ar`, `ar^2`, `ar^3`, etc., is a geometrical progression, whose common ratio is `r`, and which is an increasing series when `r` is greater than 1; but a decreasing series when `r` is less than 1. It is evident that in any given geometrical series, the common ratio will be found by dividing any term by the term next preceding.
q: What is the common ratio of 54, 18, 6, 2, etc.? {1/3}
art: 296 | The last term | To find the last term of a geometrical progression. Let `a` denote the first term, `r` the common ratio, `l` the nth term, and S the sum of `n` terms; then the respective terms of the series will be `a`, `ar`, `ar^2`, `ar^3`, `ar^4`, ..., `ar^(n-1)`. That is, the exponent of `r`, in the second term, is 1, in the third term 2, in the fourth term 3, and so on. Hence, the nth term of the series will be `l=ar^(n-1)`. Hence, the Rule for finding the Last Term of a Geometrical Series: multiply the first term by the ratio raised to a power whose exponent is one less than the number of terms. Required to find the 6th term of the geometrical progression whose first term is 7, and common ratio 2: `2^5=32`; and `7*32=224`, the 6th term.
q: Find the 6th term of the geometrical progression whose first term is 7, and common ratio 2. {224}
chk: x=224 | x=7*2^5
art: 297 | The sum | To find the sum of all the terms of a geometrical progression. If we take the series, 1, 3, 9, 27, 81, and represent its sum by S; then, `S=1+3+9+27+81` (a). Multiplying by the ratio 3, `3S=3+9+27+81+243` (b). Subtracting (a) from (b), `3S-S=243-1`; whence, `S=121`. To generalize this method, let `a`, `ar`, `ar^2`, `ar^3`, etc., be any geometrical series, and S its sum; then, `S=a+ar+ar^2+ar^3+...+ar^(n-2)+ar^(n-1)`. Multiplying this equation by `r`, `rS=ar+ar^2+ar^3+...+ar^(n-1)+ar^n`. Subtracting, `rS-S=ar^n-a`; whence, `S=a(r^n-1)/(r-1)`. Since `l=ar^(n-1)`, we have `rl=ar^n`; therefore `S=(ar^n-a)/(r-1)=(rl-a)/(r-1)`. Hence, the Rule for finding the Sum of a Geometrical Series: multiply the last term by the ratio, from the product subtract the first term, and divide the remainder by the ratio less one. Find the sum of 6 terms of the progression 3, 12, 48, etc.: `l=3*4^5=3072`, so `S=(lr-a)/(r-1)=(3072*4-3)/(4-1)=4095`.
q: Find the sum of 6 terms of the progression 3, 12, 48, etc. {4095}
chk: x=4095 | x=(3072*4-3)/3
art: 298 | Decreasing progressions | If the ratio `r` is less than 1, the progression is decreasing, and the last term `l`, or `ar^(n-1)`, is less than `a`. In order that both terms of the fraction `(rl-a)/(r-1)`, or `(ar^n-a)/(r-1)` may be positive, change the signs of the terms (Art. 124), and `S=(a-rl)/(1-r)`, or `=(a-ar^n)/(1-r)`. Therefore, for finding the sum of the series, when the progression is decreasing, the Rule: multiply the last term by the ratio, subtract the product from the first term, and divide the remainder by one minus the ratio.
art: 299 | Infinite decreasing series | When the series is decreasing, and the number of terms infinite, `l` is infinitely small, or 0. Therefore, `rl=0`, and `S=(a-rl)/(1-r)` becomes `S=a/(1-r)`. Hence, the Rule for finding the Sum of an Infinite Decreasing Series: divide the first term by one minus the ratio. Find the sum of the infinite series `1+1/2+1/4+1/8+`, etc. Here, `a=1`, `r=1/2`, and `S=a/(1-r)=1/(1-1/2)=2`. That the sum of an infinite decreasing series may be finite, will easily appear from the following illustration: take a straight line, AK, and bisect it in B; bisect BK in C; CK in D, and so on continually; then will AK = AB+BC+CD+, etc., in infinitum, = AB+(1/2)AB+(1/4)AB, etc., in infinitum, = 2AB, which agrees with the example.
q: Find the sum of the infinite series `1+1/2+1/4+1/8+`, etc. {2}
art: 300 | The general problem | The equations `l=ar^(n-1)`, and `S=(ar^n-a)/(r-1)`, furnish this general problem: knowing any three of the five quantities `a`, `r`, `n`, `l`, and S, of a geometrical progression, to determine the other two. The book gives a table of all twenty cases; some of them need an equation higher than the second degree, and those for `n` need logarithms (Art. 382). The two formulae `l=ar^(n-1)` (1), and `S=(lr-a)/(r-1)` or `(a-lr)/(1-r)` (2), are, however, sufficient for the solution of all examples in Geometrical Progression, and may easily be retained in the memory.
q: Find the 8th term of the series 5, 10, 20, etc. {640}
chk: x=640 | x=5*2^7
q: The 7th term of the series 54, 27, `13 1/2`, etc. {27/32}
chk: x=27/32 | x=54*(1/2)^6
q: The 6th term of the series `3 3/8`, `2 1/4`, `1 1/2`, etc. {4/9}
chk: x=4/9 | x=(27/8)*(2/3)^5
q: The 7th term of the series -21, 14, `-9 1/3`, etc. {$ -448/243}
chk: x=-448/243 | x=-21*(-2/3)^6
q: The nth term of the series `1/3`, `1/2`, `3/4`, etc. {$ 3^(n-2)/2^(n-1) | (1/3)(3/2)^(n-1)}
q: Find the sum of `1+3+9+`, etc., to 9 terms. {9841}
chk: x=9841 | x=(3*6561-1)/2
q: Of `1+4+16+`, etc., to 8 terms. {21845}
chk: x=21845 | x=(4^8-1)/3
q: Of `8+20+50+`, etc., to 7 terms. {3249 7/8}
chk: x=25999/8 | x=8((5/2)^7-1)/(5/2-1)
q: Of `1+3+9+`, etc., to `n` terms. {$ (1/2)(3^n-1) | (3^n-1)/2}
q: Of `1-2+4-8+`, etc., to `n` terms (the book writes `(1/3)(1∓2^n)`: minus when `n` is odd, plus when even). {$ (1/3)(1-(-2)^n) | (1-(-2)^n)/3}
q: Of `x-y+y^2/x-y^3/x^2+`, etc., to `n` terms. {$ (x^2/(x+y))(1-(-y/x)^n) @ x(1-(-y/x)^n)/(1+y/x)}
q: The first term is 4, the last term 12500, and the number of terms 6. Required the ratio {5} and the sum of all the terms {15624}.
chk: x=5 | 4x^5=12500
chk: x=15624 | x=(12500*5-4)/4
art: 300 | Infinite series | Find the sum of an infinite number of terms of each of the following series.
q: Of `2/3+1/3+1/6+`, etc. {4/3}
chk: x=4/3 | x=(2/3)/(1-1/2)
q: Of `9+6+4+`, etc. {27}
chk: x=27 | x=9/(1-2/3)
q: Of `2/3-1/3+1/6-`, etc. {4/9}
chk: x=4/9 | x=(2/3)/(1+1/2)
q: Of `a+b+b^2/a+b^3/a^2+`, etc. {$ a^2/(a-b) @ a/(1-b/a)}
q: The sum of an infinite geometric series is 3, and the sum of its first two terms is `2 2/3`; find the series: its first three terms. {list: 2, 2/3, 2/9}
chk: x=2, y=1/3 | x/(1-y)=3 | x+x*y=8/3
q: The other series with the same sum and first two terms: its first three terms. {list: 4, -4/3, 4/9}
chk: x=4, y=-1/3 | x/(1-y)=3 | x+x*y=8/3
q: Find a geometric mean between 4 and 16. (Here `a=4`, `l=16`, and `n=3`; or (Art. 269) the mean `=√(4*16)`.) {8}
q: The first term of a geometric series is 3, the last term 96, and the number of terms 6; find the ratio {2}, and the intermediate terms {list: 6, 12, 24, 48}
chk: x=2 | 3x^5=96
art: 300 | Geometric means | If it be required to insert `m` geometrical means between two numbers, `a` and `l`, we have `n=m+2`; hence, `n-1=m+1`, and `r=(l/a)^(1/(m+1))`, the (m+1)th root of `l/a`. Or, we may employ formula (1).
q: Insert two geometric means between `16/27` and 2. {list: 8/9, 4/3}
q: Insert 7 geometric means between 2 and 13122. {list: 6, 18, 54, 162, 486, 1458, 4374}
== 61 | Ratio, Proportion, and Progressions | Circulating decimals; harmonical progression; problems in progressions
art: 301 | Circulating decimals | To find the value of Circulating Decimals; that is, decimals in which one or more figures are continually repeated. In such decimals the ratio is `1/10`, `1/100`, `1/1000`, etc., according as one, two, or more figures recur. Thus, `.253131...=25/100+(31/10^4+31/10^6+31/10^8+...)`. The part within the parenthesis is an infinite series, having `a=31/10000` and `r=1/100`. Hence (Art. 299), `S=31/9900`. Therefore `.253131...=25/100+31/9900=2506/9900=1253/4950`. This operation may be performed more simply, as follows. Let `S=.25313131...`; multiplying by 10000, `10000S=2531.3131...`; multiplying by 100, `100S=25.3131...`; subtracting, `9900S=2506`, so `S=2506/9900`.
q: Find the value of .636363... as a fraction. {7/11}
chk: x=7/11 | 99x=63
q: Find the value of .54123123... as a fraction. {18023/33300}
chk: x=18023/33300 | 99900x=54123-54
art: 302 | Harmonical Progression | Three or more quantities are said to be in Harmonical Progression, when their reciprocals are in arithmetical progression. Thus, 1, `1/3`, `1/5`, `1/7`, etc.; and `1/4`, `2/7`, `1/3`, `2/5`, etc., are in harmonical progression, because their reciprocals 1, 3, 5, 7, etc.; and 4, `3 1/2`, 3, `2 1/2`, etc., are in arithmetical progression.
q: The reciprocals of `1/4`, `2/7`, `1/3`, `2/5` are 4, `3 1/2`, 3, `2 1/2`. What is their common difference? {$ -1/2}
art: 303 | Proposition | If three quantities are in harmonical progression, the first term is to the third as the difference of the first and second is to the difference of the second and third. For if `a`, `b`, `c` are in harmonical progression, `1/a`, `1/b`, `1/c` are in arithmetical progression; therefore `1/b-1/a=1/c-1/b`. Hence, multiplying by `abc`, `ac-bc=ab-ac`; or `c(a-b)=a(b-c)`. This gives (Art. 268) `a:c::a-b:b-c`. Therefore a Harmonical Progression is a series of quantities in harmonical proportion (Art. 280); or such that if any three consecutive terms be taken, the first is to the third as the difference of the first and second is to the difference of the second and third. Hence, all problems with respect to numbers in harmonical progression may be solved by inverting them, and considering the reciprocals as quantities in arithmetical progression.
tf: If `a`, `b`, `c` are in harmonical progression, then `a:c::a-b:b-c`. {T}
art: 303 | Two formulas | 1. Given the first two terms of a harmonical progression, `a` and `b`, to find the nth term. Here `1/a`, `1/b`, and `1/l` become the first two and nth terms in formula (1) (Art. 294). Also `d=1/b-1/a=(a-b)/(ab)`. Therefore `1/l=1/a+(n-1)(a-b)/(ab)=((n-1)a-(n-2)b)/(ab)`; whence `l=ab/((n-1)a-(n-2)b)`. By means of this formula, when any two successive terms of a harmonical progression are given, any other term may be found. 2. Insert `m` harmonic means between `a` and `l`. Here, since `m=n-2`, and `m+1=n-1`, we have, as above, `1/l=1/a+(n-1)d`, and `d=(a-l)/((n-1)al)=(a-l)/((m+1)al)`; whence the arithmetical progression is found; and by inverting its terms, the harmonicals are also found.
q: The first two terms of a harmonical progression are `a` and `b`; find the nth term `l`. {$ ab/((n-1)a-(n-2)b) | ab/(na-a-nb+2b) @x: 1/x=1/a+(n-1)(1/b-1/a)}
q: Insert two harmonic means between 3 and 12. {list: 4, 6}
chk: x=4, y=6 | 1/x-1/3=1/y-1/x | 1/y-1/x=1/12-1/y
q: Insert two harmonic means between 2 and `1/5`. {list: 1/2, 2/7}
chk: x=1/2, y=2/7 | 1/x-1/2=1/y-1/x | 1/y-1/x=5-1/y
q: The first term of a harmonic series is `1/2`, and the 6th is `1/12`; find the intermediate terms. {list: 1/4, 1/6, 1/8, 1/10}
chk: x=1/4, y=1/10 | 1/x=2+2 | 1/y=2+4*2
art: 303 | A proof | `a`, `b`, `c` are in arithmetical progression, and `b`, `c`, `d` are in harmonical progression; prove that `a:b::c:d`. Since `b`, `c`, `d` are in harmonical progression, `2/c=1/b+1/d`, so `2bd=c(b+d)`. Since `a`, `b`, `c` are in arithmetical progression, `2b=a+c`, so `d(a+c)=c(b+d)`, or `ad=bc`; hence `a:b::c:d`.
tf: If `a`, `b`, `c` are in arithmetical progression, and `b`, `c`, `d` in harmonical progression, then `a:b::c:d`. {T}
art: 304 | Problems in progressions | Problems in Arithmetical and Geometrical Progression. Suggestion: when the number of terms in an arithmetic progression is odd, the common difference should be called `y`, and the middle term `x`; but when the number of terms is even, the common difference must be `2y`, and the two middle terms `x-y` and `x+y`. Type each answer's numbers one at a time, the least first.
q: The sum of 5 numbers in arithmetical progression is 35, and the sum of their squares 335; find the numbers. (Let `x-2y`, `x-y`, `x`, `x+y`, `x+2y` be the numbers.) {list: 1, 4, 7, 10, 13}
chk: x=7, y=3 | 5x=35 | 5x^2+10y^2=335
q: There are 4 numbers in arithmetic progression, and the sum of the squares of the extremes is 68, and of the means 52; find them. (Let `x-3y`, `x-y`, `x+y`, `x+3y` be the numbers.) {list: 2, 4, 6, 8}
chk: x=5, y=1 | (x-3y)^2+(x+3y)^2=68 | (x-y)^2+(x+y)^2=52
q: The sum of 3 numbers in arithmetical progression is 30, and the sum of their squares 308; find them. {list: 8, 10, 12}
chk: x=10, y=2 | 3x=30 | 3x^2+2y^2=308
q: There are 4 numbers in arithmetical progression, their sum is 26, and their product 880; find them. {list: 2, 5, 8, 11}
chk: x=13/2, y=3/2 | 4x=26 | (x-3y)(x-y)(x+y)(x+3y)=880
q: There are 3 numbers in geometrical progression, whose sum is 31; and the sum of the 1st and 2d : sum of 1st and 3d :: 3 : 13; find them. (Let `x` = 1st term and `y` = ratio; then `xy` and `xy^2` = 2d and 3d terms.) {list: 1, 5, 25}
chk: x=1, y=5 | x+x*y+x*y^2=31 | 13(x+x*y)=3(x+x*y^2)
q: The sum of the squares of 3 numbers in arithmetical progression is 83; and the square of the mean is greater by 4 than the product of the extremes; find them. {list: 3, 5, 7}
chk: x=5, y=2 | 3x^2+2y^2=83 | x^2=(x-y)(x+y)+4
q: Find 4 numbers in arithmetical progression, such that the product of the extremes = 27; of the means = 35. {list: 3, 5, 7, 9}
chk: x=6, y=1 | (x-3y)(x+3y)=27 | (x-y)(x+y)=35
q: There are 3 numbers in arithmetical progression, whose sum is 18; but if you multiply the first term by 2, the second by 3, and the third by 6, the products will be in geometrical progression; find them. {list: 3, 6, 9}
chk: x=6, y=3 | 3x=18 | (3x)^2=2(x-y)*6(x+y)
q: The sum of the fourth powers of three successive natural numbers is 962; find them. {list: 3, 4, 5}
chk: x=4 | (x-1)^4+x^4+(x+1)^4=962
q: The product of four successive natural numbers is 840; find them. {list: 4, 5, 6, 7}
chk: x=4 | x(x+1)(x+2)(x+3)=840
q: The product of four numbers in arithmetical progression is 280, and the sum of their squares 166; find them. {list: 1, 4, 7, 10}
chk: x=11/2, y=3/2 | (x-3y)(x-y)(x+y)(x+3y)=280 | 4x^2+20y^2=166
q: The sum of 9 numbers in arithmetical progression is 45, and the sum of their squares 285; find them. {list: 1, 2, 3, 4, 5, 6, 7, 8, 9}
chk: x=5, y=1 | 9x=45 | 9x^2+60y^2=285
q: The sum of 7 numbers in arithmetical progression is 35, and the sum of their cubes 1295; find them. {list: 2, 3, 4, 5, 6, 7, 8}
chk: x=5, y=1 | 7x=35 | 7x^3+84x*y^2=1295
art: 304 | A proof | Prove that when the arithmetical mean of two numbers is to the geometric mean :: 5 : 4, one of them is 4 times the other. Let the numbers be `x` and `y`; then `(x+y)/2:√(xy)::5:4`, so `4(x+y)=10√(xy)`; squaring, `4x^2+8xy+4y^2=25xy`, or `4x^2-17xy+4y^2=0`, that is, `(4x-y)(x-4y)=0`; so `y=4x` or `x=4y`.
tf: If the arithmetical mean of two numbers is to their geometric mean as 5 to 4, one of them is 4 times the other. {T}
q: The sum of 3 numbers in geometrical progression is 7; and the sum of their reciprocals is `7/4`; find them. {list: 1, 2, 4}
chk: x=2, y=2 | x/y+x+x*y=7 | y/x+1/x+1/(x*y)=7/4
art: 304 | Other forms | Suggestion: in solving difficult problems in geometrical progression, it is sometimes preferable to express them by other forms. Thus, for 3 numbers, use `x`, `√(xy)`, `y`; or `x^2`, `xy`, `y^2`; for four, `x^2/y`, `x`, `y`, `y^2/x`; for five, `x^3/y`, `x^2`, `xy`, `y^2`, `y^3/x`; for six, `x^3/y^2`, `x^2/y`, `x`, `y`, `y^2/x`, `y^3/x^2`. In all these cases the product of the first and third of any three, taken consecutively, is equal to the square of the second. To find the ratio in each case, divide any expression by the preceding.
q: There are 4 numbers in geometrical progression, the sum of the first and third is 10, and the sum of the second and fourth is 30; find them. {list: 1, 3, 9, 27}
chk: x=1, y=3 | x+x*y^2=10 | x*y+x*y^3=30
q: There are 4 numbers in geometrical progression, the sum of the extremes is 35, the sum of the means is 30; find them. {list: 8, 12, 18, 27}
chk: x=12, y=18 | x^2/y+y^2/x=35 | x+y=30
q: There are 4 numbers in arithmetical progression, which being increased by 2, 4, 8, and 15 respectively, the sums are in geometrical progression; find them. {list: 6, 8, 10, 12}
chk: x=6, y=2 | (x+y+4)^2=(x+2)(x+2y+8) | (x+2y+8)^2=(x+y+4)(x+3y+15)
q: There are 3 numbers in geometrical progression, whose continued product is 64, and the sum of their cubes 584; find them. {list: 2, 4, 8}
chk: x=4, y=2 | x^3=64 | (x/y)^3+x^3+(x*y)^3=584
== 62 | Permutations, Combinations, and Binomial Theorem | Permutations and combinations
art: 305 | Permutations | The Permutations of quantities are the different orders in which they can be arranged. Quantities may be arranged in sets of one and one, two and two, three and three, and so on. Thus, if we have three quantities, `a`, `b`, `c`, we may arrange them in sets of one: `a`, `b`, `c`; of two: `ab`, `ac`; `ba`, `bc`; `ca`, `cb`; of three: `abc`, `acb`; `bac`, `bca`; `cab`, `cba`.
q: How many permutations of the three letters `a`, `b`, `c` are there, taken two together? {6}
art: 306 | Number of permutations | To find the number of permutations that can be formed out of `n` letters, taken singly, taken two together, three together, ... and `r` together. Let `a`, `b`, `c`, `d`, ... `k` be the `n` letters; and let P1 denote the whole number of permutations where the letters are taken singly; P2 the whole number taken 2 together, ... and Pr the number taken `r` together. The number of permutations of `n` letters taken singly is evidently equal to the number of letters; that is, P1 = `n`. The number of permutations of `n` letters taken two together is `n(n-1)`. For since there are `n` quantities, if we remove `a`, there will remain `n-1` quantities; writing `a` before each of these, we shall have `ab`, `ac`, `ad`, ... `ak`, that is, `n-1` permutations in which `a` stands first. In the same manner there are `n-1` permutations in which `b` stands first, and so of each of the remaining letters. Or, for `n` letters, there are `n(n-1)` permutations taken two together; that is, P2 = `n(n-1)`. Hence, the number of permutations of `n` letters taken two together is equal to the number of letters, multiplied by the number less one. For example, if `n=4`, the number of permutations of `a`, `b`, `c`, `d`, taken two together, is `4*3=12`: `ab`, `ac`, `ad`, `ba`, `bc`, `bd`, `ca`, `cb`, `cd`, `da`, `db`, `dc`.
art: 306 | Three or more together | The number of permutations of `n` letters taken three together is `n(n-1)(n-2)`. For if we take the `n-1` letters `b`, `c`, `d`, ... `k`, the number of permutations taken two together, by the last paragraph, is `(n-1)(n-2)`. Let `a` be placed before each of these permutations; then there are `(n-1)(n-2)` permutations of `n` letters, taken three together, in which `a` stands first, and `(n-1)(n-2)` in which `b` stands first; and so for each of the `n` letters. Hence the whole number is P3 = `n(n-1)(n-2)`: the number of letters, multiplied by the number less one, multiplied by the number less two. If `n=4`, the number of permutations of `a`, `b`, `c`, `d`, taken three together, is `4*3*2=24`. Following the same method, P4 = `n(n-1)(n-2)(n-3)`. In each of the preceding results, the negative number in the last factor is less by unity than the number of letters in each permutation. Hence, for `n` things taken `r` together, Pr = `n(n-1)(n-2)...(n-r+1)`.
q: How many permutations of `a`, `b`, `c`, `d` are there, taken three together? {24 @= P(4,3)}
art: 306 | Corollary | If all the letters be taken together, then `r` becomes equal to `n`, and the last factor becomes 1; that is, Pn = `n(n-1)(n-2)...1`; or, inverting the order of the factors, Pn = `1*2*3...(n-1)n`. Hence, the number of permutations of `n` letters taken `n` together is equal to the product of the natural numbers from 1 up to `n`. Example: the permutations of three letters, `a`, `b`, `c`, taken three together, is `1*2*3=6`.
art: 307 | Repeated letters | If the same letter occur `p` times, the number of permutations in `n` letters, taken all together, is `(1*2*3...(n-1)n)/(1*2*3...p)`. Suppose these `p` letters to be all different. Then, for any particular position of the other letters, these `p` quantities, taken `p` together, will form `1*2*3...p` permutations from their interchange with each other; and when these letters are alike, these permutations are all reduced to one. As this is true for every position of the other letters, there will be altogether `1*2*3...p` times fewer permutations when they are alike than when they are all different. Thus, in the letters A, I, D, there are `1*2*3=6` permutations taken all together; but if I becomes D, then three of these permutations become identical with the remaining three, and the whole number for ADD taken all together is `(1*2*3)/(1*2)=3`. Corollary: in like manner, if the same letter occur `p` times, another letter `q` times, a third letter `r` times, and so on, the number of permutations taken all together is `(1*2*3...(n-1)n)/((1*2...p)(1*2...q)(1*2...r)...)`.
q: How many permutations can be made of the letters of ADD, taken all together? {3}
art: 308 | Combinations | The Combinations of quantities are the different collections that can be formed out of them, without reference to the order in which they are placed. Thus `ab`, `ac`, `bc` are the combinations of the letters `a`, `b`, `c`, taken two together; `ab` and `ba`, `ac` and `ca`, `bc` and `cb`, though different permutations, forming the same combination. Proposition: to find the number of combinations that can be formed out of `n` letters, taken singly, two together, three together, ... and `r` together. Let C1, C2, ... Cr denote these numbers. The number of combinations of `n` letters taken singly is evidently `n`; that is, C1 = `n`. The number of permutations of `n` letters taken two together is `n(n-1)`; but each combination, as `ab`, admits of `1*2` permutations, `ab`, `ba`; therefore there are `1*2` times as many permutations as combinations, and C2 = `n(n-1)/(1*2)`. Again, in `n` letters taken three together, the number of permutations is `n(n-1)(n-2)`; but each combination of three letters, as `abc`, admits of `1*2*3` permutations; therefore C3 = `n(n-1)(n-2)/(1*2*3)`. So, for `n` letters, each of which contains `r`, the number of combinations is Cr = `(n(n-1)(n-2)...(n-r+1))/(1*2*3...r)`.
q: How many combinations of the letters `a`, `b`, `c` are there, taken two together? {3}
art: 309 | Exercises | Intimately connected with the subject of the preceding articles is that of the Doctrine of Chances, or the Calculus of Probabilities. This, however, being too abstruse for an elementary treatise, is omitted in this work.
q: How many permutations of 2 letters each can be formed out of the letters `a`, `b`, `c`, `d`, `e`? {20 @= P(5,2)} How many of 3? {60 @= P(5,3)} Of 4? {120 @= P(5,4)}
q: How many combinations of 2 letters each can be formed out of the letters `a`, `b`, `c`, `d`, `e`? {10 @= C(5,2)} How many of 3? {10 @= C(5,3)} Of 4? {5 @= C(5,4)} Of 5? {1 @= C(5,5)}
q: In how many ways, taken all together, may the letters in the word NOT be written? {6 @= 3!} In the word HOME? {24 @= 4!}
q: How often can 6 persons change their places at dinner, so as not to sit twice in the same order? {720 @= 6!}
q: In how many different ways, taken all together, can the 7 prismatic colors be arranged? {5040 @= 7!}
q: In how many different ways can 6 letters be arranged when taken singly, 2 by 2, 3 by 3, and so on, till they are all taken? (Take the sum of the different permutations.) {1956 @= P(6,1)+P(6,2)+P(6,3)+P(6,4)+P(6,5)+P(6,6)}
q: How many different products can be formed with any two of the figures 3, 4, 5, 6? {6 @= C(4,2)}
q: The number of permutations of `n` things taken 4 together = 6 times the number taken 3 together; find `n`. {9 @x: x(x-1)(x-2)(x-3)=6x(x-1)(x-2)}
q: How many different sums of money can be formed with a cent, a three cent piece, a half dime, and a dime? (Take the sum of the different combinations of 4 things taken singly, 2 together, 3 together, and 4 together.) {15 @= C(4,1)+C(4,2)+C(4,3)+C(4,4)}
q: With the addition of a twenty-five cent piece, and a half dollar, to the coins in the last example, how many different sums of money may be formed? {63 @= 2^6-1}
q: At an election, where every voter may vote for any number of candidates not greater than the number to be elected, there are 4 candidates and only 3 persons to be chosen; in how many ways may a man vote? {14 @= C(4,1)+C(4,2)+C(4,3)}
q: On how many nights may a different guard of 4 men be posted out of 16? {1820 @= C(16,4)} And on how many of these will any particular man be on guard? {455 @= C(15,3)}
q: How many changes may be rung with 5 bells out of 8? {6720 @= P(8,5)} And how many with the whole peal? {40320 @= 8!}
q: Out of 17 consonants and 5 vowels, how many words can be formed, having two consonants and one vowel in each? {4080 @= C(17,2)*5*3!}
== 63 | Permutations, Combinations, and Binomial Theorem | Binomial theorem for a positive integral exponent
art: 310 | Binomial Theorem | We have already explained (Art. 172) the method of finding any power of a binomial, by repeated multiplication, and by Newton's Theorem, as proved experimentally. We shall now proceed from the theory of Combinations (Art. 308), to demonstrate the Binomial Theorem in its most general form. The Binomial Theorem teaches the method of developing into a series any binomial whose index is either integral or fractional, positive or negative; as `(a+x)^n`, `(a+x)^(-n)`, `(a+x)^(n/m)`, `(a+x)^(-n/m)`, where `a` or `x` may be either plus or minus. The following investigation applies only to the case where the exponent is positive and integral; the other cases will be considered hereafter (Art. 319).
art: 310 | The law of the coefficients | By actual multiplication, `(x+a)(x+b)=x^2+(a+b)x+ab`; `(x+a)(x+b)(x+c)=x^3+(a+b+c)x^2+(ab+ac+bc)x+abc`; and `(x+a)(x+b)(x+c)(x+d)=x^4+(a+b+c+d)x^3+(ab+ac+ad+bc+bd+cd)x^2+(abc+abd+acd+bcd)x+abcd`. Each product is a series of descending powers of `x`, with coefficients formed by this law: 1st, the exponent of the highest power of `x` is found in the first term, and is the same as the number of binomial factors, and the other exponents of `x` decrease by 1 in each succeeding term. 2d, the coefficient of the first term is 1; of the second, the sum of the quantities `a`, `b`, `c`, etc.; of the third, the sum of the products of every two of them; of the fourth, the sum of the products of every three, and so on; and of the last, the product of all the `n` quantities.
q: Multiply out `(x+a)(x+b)(x+c)`. {$ x^3+ax^2+bx^2+cx^2+abx+acx+bcx+abc @ (x+a)(x+b)(x+c)}
art: 310 | The law holds for any number | Suppose this law to hold for the product of `n` binomial factors, so that `(x+a)(x+b)...(x+k)=x^n+Ax^(n-1)+Bx^(n-2)+Cx^(n-3)+...+K`, where A = `a+b+c+...+k`, B = `ab+ac+ad+...`, C = `abc+abd+...`, and K = `abcd...k`. Multiplying both sides by a new factor `x+l`, the coefficients become `A+l`, `B+Al`, and so on to `Kl`; that is, `a+b+c+...+k+l`, then `ab+ac+...+al+bl+...+kl`, and last `abcd...kl`. So the same law still holds. Hence, if the law holds when `n` binomial factors are multiplied together, it will hold when `n+1` factors are taken; but it has been shown to hold up to 4 factors; therefore it is true for 5, then for 6, and so on for any number whatever.
art: 310 | The binomial formula | Now let `b`, `c`, `d`, etc., each `=a`. Then A = `a+a+a+...` to `n` terms `=na`; B = `a^2+a^2+...`, `a^2` taken as many times as the number of combinations of `n` things taken two together, which is `n(n-1)a^2/(1*2)`; C = `n(n-1)(n-2)a^3/(1*2*3)`; and K = `a^n`. Also, the product of the factors becomes `(x+a)^n`. Therefore `(x+a)^n=x^n+nax^(n-1)+(n(n-1))/(1*2)a^2x^(n-2)+(n(n-1)(n-2))/(1*2*3)a^3x^(n-3)+...+a^n`. By changing `x` to `a` and `a` to `x`, `(a+x)^n=a^n+na^(n-1)x+(n(n-1))/(1*2)a^(n-2)x^2+(n(n-1)(n-2))/(1*2*3)a^(n-3)x^3+...+x^n`. Let `a=1`; then, since every power of 1 is 1, `(1+x)^n=1+nx+(n(n-1))/(1*2)x^2+(n(n-1)(n-2))/(1*2*3)x^3+...+x^n`.
art: 310 | Corollaries 1-3 | Corollary 1: the sum of the exponents of `a` and `x` in each term `=n`. Corollary 2: if either term of the binomial is negative, every odd power of that term will be negative (Art. 193); therefore the terms which contain the odd powers will be negative: `(1-x)^n=1-nx+(n(n-1))/(1*2)x^2-(n(n-1)(n-2))/(1*2*3)x^3+`, etc. Corollary 3: since the last factors in the fraction which forms the coefficient are, for the 2d term `n/1`, for the 3d term `(n-1)/2`, for the 4th term `(n-2)/3`, etc., for the rth term they will be `(n-(r-2))/(r-1)`. Also, the exponents of `a` and `x` are in the 2d term `a^(n-1)x`, in the 3d term `a^(n-2)x^2`, in the 4th term `a^(n-3)x^3`; therefore in the rth term we shall have `a^(n-r+1)x^(r-1)`. Hence the general term of the series is `(n(n-1)(n-2)...(n-r+2))/(1*2*3...(r-1))a^(n-r+1)x^(r-1)`. This is called the general term, because by making `r=2`, 3, 4, etc., all the others can be deduced from it. Example: required the 5th term of `(a-x)^7`. Here `r=5` and `n=7`; therefore the term required is `(4*5*6*7)/(1*2*3*4)a^3(-x)^4=35a^3x^4`.
q: Required the 5th term of `(a-x)^7`. {$ 35a^3x^4 @ C(7,4)a^3x^4}
art: 310 | Corollaries 4-6 | Corollary 4: if `n` be a positive integer, and `r=n+2`, then `n-r+2` becomes 0, and the (n+2)th term vanishes; therefore the series consists of `n+1` terms altogether; that is, the number of terms is one greater than the exponent of the power to which the binomial is to be raised. Corollary 5: when the index of the binomial is a positive integer, the coefficients of the terms taken in an inverse order from the end of the series are equal to the coefficients of the corresponding terms taken in a direct order from the beginning; for `(a+x)^n` and `(x+a)^n` are the same binomial. Hence, in expanding such a binomial, the latter half of the expansion may be taken from the first half. Example: expand `(a-b)^5`. Here the number of terms is 6; therefore it is only necessary to find the coefficients of the first three: `(a-b)^5=a^5-5a^4b+(5*4)/(1*2)a^3b^2-10a^2b^3+5ab^4-b^5`. Corollary 6: the sum of the coefficients, where both terms are positive, is always equal to `2^n`; for if we make `x=a=1`, then `(x+a)^n=(1+1)^n=2^n`.
q: Expand `(a-b)^5`. {$ a^5-5a^4b+10a^3b^2-10a^2b^3+5ab^4-b^5 @ (a-b)^5}
q: How many terms has the expansion of `(a+x)^9`? {10}
q: What is the sum of the coefficients of `(a+x)^6`? {64 @= 2^6}
art: 311 | The next coefficient | From an inspection of the general expansion of `(a+x)^n`, it is evident that if the coefficient of any term be multiplied by the exponent of the first letter of the binomial in that term, and the product be divided by the number of the term, the quotient will be the coefficient of the next term. For examples, see Newton's Theorem, Art. 172.
art: 312 | Coefficients and exponents | To expand a binomial affected with coefficients or exponents, as `(2a^2-3b^3)^4`, see Newton's Theorem, Art. 172.
art: 313 | Polynomials | By means of the Binomial Theorem, we can raise any polynomial to any power. Thus, let it be required to raise `a-b+c` to the third power. Let `a-b=m`, etc., as already explained, Art. 172.
q: Expand `(a+b)^8`. {$ a^8+8a^7b+28a^6b^2+56a^5b^3+70a^4b^4+56a^3b^5+28a^2b^6+8ab^7+b^8 @ (a+b)^8}
q: Expand `(a-b)^7`. {$ a^7-7a^6b+21a^5b^2-35a^4b^3+35a^3b^4-21a^2b^5+7ab^6-b^7 @ (a-b)^7}
q: Expand `(5-4x)^4`. {$ 625-2000x+2400x^2-1280x^3+256x^4 @ (5-4x)^4}
q: Required the coefficient of `x^6` in the expansion of `(x+y)^10`. {210 @= C(10,6)}
q: Find the 5th term of the expansion of `(c^2-d^2)^12`. (See Cor. 3, Art. 310: instead of `a`, `x`, `n`, and `r`, substitute `c^2`, `-d^2`, 12, and 5.) {$ 495c^16d^8 @ C(12,4)(c^2)^8(-d^2)^4}
q: Find the 7th term of `(a^3+3ab)^9`. {$ 61236a^15b^6 @ C(9,6)(a^3)^3(3ab)^6}
q: Find the middle term of `(a^m+x^n)^12`. {$ 924a^(6m)x^(6n) @ C(12,6)(a^m)^6(x^n)^6}
q: Find the 8th term of `(1+x)^11`. {$ 330x^7 @ C(11,7)x^7}
q: Expand `(3ac-2bd)^5`. {$ 243a^5c^5-810a^4c^4bd+1080a^3c^3b^2d^2-720a^2c^2b^3d^3+240acb^4d^4-32b^5d^5 @ (3ac-2bd)^5}
q: Expand `(a+2b-c)^3`. {$ a^3+6a^2b+12ab^2+8b^3-3a^2c-12abc-12b^2c+3ac^2+6bc^2-c^3 @ (a+2b-c)^3}
tf: The sum of the coefficients of the odd terms of `(a+x)^n` is equal to the sum of the coefficients of the even terms. (Make `a=1` and `x=-1`: `(1-1)^n=0`.) {T}
== 64 | Indeterminate Coefficients and Series | Indeterminate coefficients; evolution by indeterminate coefficients
art: 314 | Indeterminate Coefficients | The method of developing algebraic expressions, by assuming a series with unknown coefficients, and finding the values of the assumed coefficients, is termed the method of Indeterminate Coefficients. It depends on the following Theorem: if `A+Bx+Cx^2+Dx^3+...=A'+B'x+C'x^2+D'x^3+...` for every possible value of `x` (A, B, A', B', etc., not containing `x`, and `x` being a variable quantity), we shall have A = A', B = B', C = C', etc.; that is, the coefficients of the terms involving the same powers of `x` in the two series are respectively equal. For, by transposing all the terms into the first member, we have `A-A'+(B-B')x+(C-C')x^2+...=0`. If `A-A'` is not equal to 0, let it be equal to some quantity `p`; then `(B-B')x+(C-C')x^2+...=-p`. Now, since A and A' are constant quantities, their difference `p` must be constant; but `-p` is a quantity which may evidently have various values, since it depends upon `x`; therefore the same quantity `p` is both fixed and variable, which is impossible. Hence `A-A'=0`, and A = A'. Then `(B-B')x+(C-C')x^2+...=0`; dividing each side by `x`, `B-B'+(C-C')x+...=0`; and reasoning as before, B = B'; and so on for the remaining coefficients of the like powers of `x`.
art: 314 | Corollary | If we have an equation of the form `A+Bx+Cx^2+Dx^3+Ex^4+...=0`, which is true for any value whatever of `x`, then A = 0, B = 0, C = 0, etc.; that is, each coefficient is separately equal to zero. For the right hand member may be put under the form `0+0x+0x^2+0x^3+...`; then, comparing the coefficients of the like powers of `x`, we have A = 0, B = 0, C = 0, etc.
tf: If `A+Bx+Cx^2=0` for every value of `x`, then each of A, B, and C is zero. {T}
art: 315 | Developing a fraction | Let it be required to develop `a/(a+bx)` into a series without a resort to division. The series will consist of the powers of `x` multiplied by certain undetermined coefficients, and `x` will not enter into the first term; therefore assume `a/(a+bx)=A+Bx+Cx^2+Dx^3+...`. Multiply both sides by `a+bx`, and arrange the terms according to the powers of `x`: `a=Aa+(Ba+Ab)x+(Ca+Bb)x^2+(Da+Cb)x^3+...`. By the preceding theorem and corollary, `a=Aa`, hence A = 1; `Ba+Ab=0`, so B = `-b/a`; `Ca+Bb=0`, so C = `b^2/a^2`; `Da+Cb=0`, so D = `-b^3/a^3`, etc. Substituting these values, `a/(a+bx)=1-(b/a)x+(b^2/a^2)x^2-(b^3/a^3)x^3+...`, the same as would be obtained by actual division.
q: Develop `a/(a+bx)` into a series: its first 4 terms. {list: 1, -bx/a, b^2x^2/a^2, -b^3x^3/a^3}
art: 316 | When the assumed form fails | A series with indeterminate coefficients is generally assumed to proceed according to the ascending integral and positive powers of `x`, beginning with `x^0`; but in many series this is not the case. The error in the assumption will then be shown, either by an impossible result, or by finding the coefficients of the terms which do not exist in the actual series equal to zero. Thus, if it be required to develop `1/(3x-x^2)`, and we assume the series to be `A+Bx+Cx^2+...`, we have, after clearing of fractions, `1=3Ax+(3B-A)x^2+(3C-B)x^3+...`, from which `1=0`, `3A=0`, etc. The first equation, `1=0`, being absurd, the expression can not be developed under the assumed form. But `1/(3x-x^2)=(1/x)*1/(3-x)`. Putting `1/(3-x)=A+Bx+Cx^2+...`, clearing of fractions, and equating the coefficients, we find A = `1/3`, B = `1/9`, C = `1/27`, D = `1/81`, etc. Hence `1/(3x-x^2)=x^(-1)/3+1/9+x/27+x^2/81+...`. Or, since the division of 1 by the first term of the denominator gives `1/(3x)`, or `(1/3)x^(-1)`, we ought to have assumed `1/(3x-x^2)=Ax^(-1)+B+Cx+Dx^2+...`. Again, if we assume `(1-x^2)/(1+x^2-x^4)=A+Bx+Cx^2+Dx^3+...`, we shall find the true series to be `1-2x^2+3x^4-5x^6+...`, the coefficients B, D, F, etc., becoming zero.
q: Develop `1/(3x-x^2)` into a series: its first 4 terms. {list: 1/(3x), 1/9, x/27, x^2/81}
q: Develop `(1-x^2)/(1+x^2-x^4)`: its first 4 terms that are not zero. {list: 1, -2x^2, 3x^4, -5x^6}
art: 317 | Evolution | Evolution by indeterminate coefficients. Example: extract the square root of `a^2+x^2`. Assume `√(a^2+x^2)=A+Bx+Cx^2+Dx^3+Ex^4+...`. Squaring both sides, `a^2+x^2=A^2+2ABx+(2AC+B^2)x^2+(2AD+2BC)x^3+(2AE+2BD+C^2)x^4+...`. Therefore `A^2=a^2`, `2AB=0`, `2AC+B^2=1`, `2AD+2BC=0`, etc. And A = `a`, B = 0, C = `1/(2a)`, D = 0, E = `-1/(8a^3)`, etc. Therefore `√(a^2+x^2)=a+x^2/(2a)-x^4/(8a^3)+...`
q: The square root of `a^2+x^2` as a series: its first 3 terms. {list: a, x^2/(2a), -x^4/(8a^3)}
== 65 | Indeterminate Coefficients and Series | Decomposition of rational fractions
art: 318 | Decomposition of Rational Fractions | Fractions whose denominators can be separated into certain factors may often be decomposed into other fractions whose denominators shall consist of one or more of these factors. To illustrate by an example: decompose `(5x-14)/(x^2-6x+8)` into two other fractions whose denominators shall be the factors of `x^2-6x+8`. Since `x^2-6x+8=(x-2)(x-4)` (Art. 234), assume `(5x-14)/(x^2-6x+8)=A/(x-2)+B/(x-4)`. Reducing the fractions to a common denominator, `(5x-14)/(x^2-6x+8)=(A(x-4)+B(x-2))/((x-2)(x-4))`; or `5x-14=A(x-4)+B(x-2)=(A+B)x-4A-2B`. Now, since this equation is true for any value whatever of `x`, we may equate the coefficients (Art. 314); this gives `A+B=5`; `-4A-2B=-14`; whence A = 2 and B = 3. And `(5x-14)/(x^2-6x+8)=2/(x-2)+3/(x-4)`.
q: In `(5x-14)/(x^2-6x+8)=A/(x-2)+B/(x-4)`, find A {2} and B {3}.
chk: x=5 | (5x-14)/(x^2-6x+8)=2/(x-2)+3/(x-4)
chk: x=7 | (5x-14)/(x^2-6x+8)=2/(x-2)+3/(x-4)
art: 318 | Exercises | By the method of Indeterminate Coefficients, show that the following are true. Type the terms one at a time.
q: Develop `(1+2x)/(1-3x)`: its first 4 terms. {list: 1, 5x, 15x^2, 45x^3}
q: Develop `(1+2x)/(1-x-x^2)`: its first 6 terms. {list: 1, 3x, 4x^2, 7x^3, 11x^4, 18x^5}
q: Develop `(1+x)/(1-x)^3`: its first 5 terms. (The book writes them `1^2+2^2x+3^2x^2+4^2x^3+5^2x^4`.) {list: 1, 4x, 9x^2, 16x^3, 25x^4}
q: Develop `√(1-x)`: its first 5 terms. (The book writes `1-x/2-x^2/(2*4)-(3x^3)/(2*4*6)-(3*5x^4)/(2*4*6*8)`.) {list: 1, -x/2, -x^2/8, -x^3/16, -5x^4/128}
q: Develop `√(1+x+x^2)`: its first 4 terms. {list: 1, x/2, 3x^2/8, -3x^3/16}
q: Decompose `(1+x)/(x-x^2)` into `A/x+B/(1-x)`: A {1} and B {2}.
chk: x=3 | (1+x)/(x-x^2)=1/x+2/(1-x)
chk: x=5 | (1+x)/(x-x^2)=1/x+2/(1-x)
q: Decompose `(x+1)/(x^2-7x+12)` into `A/(x-4)+B/(x-3)`: A {5} and B {$ -4}.
chk: x=6 | (x+1)/(x^2-7x+12)=5/(x-4)-4/(x-3)
chk: x=7 | (x+1)/(x^2-7x+12)=5/(x-4)-4/(x-3)
q: Decompose `x^2/((x^2-1)(x-2))` into `A/(x-2)+B/(x-1)+C/(x+1)`: A {4/3}, B {$ -1/2}, and C {1/6}.
chk: x=3 | x^2/((x^2-1)(x-2))=4/(3(x-2))-1/(2(x-1))+1/(6(x+1))
chk: x=5 | x^2/((x^2-1)(x-2))=4/(3(x-2))-1/(2(x-1))+1/(6(x+1))
chk: x=7 | x^2/((x^2-1)(x-2))=4/(3(x-2))-1/(2(x-1))+1/(6(x+1))
== 66 | Indeterminate Coefficients and Series | Binomial theorem for any exponent; roots by it; limit of error
art: 319 | Binomial Theorem, any exponent | We shall now prove the truth of the Binomial Theorem generally; that is, to show that `(a+b)^n=a^n+na^(n-1)b+(n(n-1))/(1*2)a^(n-2)b^2+(n(n-1)(n-2))/(1*2*3)a^(n-3)b^3+...`, whether `n` be integral or fractional, positive or negative. Since `a+b=a(1+b/a)`, `(a+b)^n=a^n(1+x)^n`, if `x=b/a`. Hence, if we can find the law of the expansion of `(1+x)^n`, we may obtain that of `(a+b)^n` by writing `b/a` for `x` and multiplying by `a^n`. The proof may be divided into two parts: 1st, to show that `(1+x)^n=1+nx+...`; 2d, to find the general law of the coefficients.
art: 319 | First: the second term | To prove that the coefficient of the second term of the expansion of `(1+x)^n` is `n`, whether `n` be integral or fractional, positive or negative. Let the index be positive and integral; by multiplication, `(1+x)^2=1+2x+...` and `(1+x)^3=1+3x+...`. Assume `(1+x)^(n-1)=1+(n-1)x+...`; multiplying both sides by `1+x`, `(1+x)^n=1+nx+...`. Hence, if the proposition is true for any one index `n-1`, it will be true for the next higher index `n`; it is true for 3, therefore for 4, for 5, and so on: by continued induction it is always true when `n` is integral and positive. Next, let `n` be a fraction `p/q`, and let `(1+x)^(p/q)=1+ax+...`. Raising both sides to the qth power, `(1+x)^p=(1+ax+...)^q`, or `1+px+...=1+qax+...`. By equating the coefficients of the like powers of `x` (Art. 314), `p=qa`, so `a=p/q`, and `(1+x)^(p/q)=1+(p/q)x+...`. Lastly, let `n` be negative; then (Art. 81) `(1+x)^(-n)=1/(1+x)^n=1/(1+nx+...)=1-nx+...`, by division. Therefore `(1+x)^n=1+nx+...`, whatever be the value of `n`.
art: 319 | Second: the law of the coefficients | Let `(1+x)^n=1+nx+Bx^2+Cx^3+Dx^4+...`, where B, C, D, etc., depend upon `n`. For `x` put `x+z`, and consider `(x+z)` as one term; expanding each power of `x+z` by the first part, `(1+x+z)^n=(1+x)^n+(n+2Bx+3Cx^2+4Dx^3+...)z+...` (A). But, considering `1+x` as one term, `(1+x+z)^n=(1+x)^n+n(1+x)^(n-1)z+...` (B). Equating the coefficients of `z` in (A) and (B), `n+2Bx+3Cx^2+4Dx^3+...=n(1+x)^(n-1)`. Multiplying both sides by `1+x` and equating the coefficients of the same powers of `x`: `2B+n=n^2`, so B = `n(n-1)/(1*2)`; `3C+2B=Bn`, so C = `n(n-1)(n-2)/(1*2*3)`; `4D+3C=nC`, so D = `n(n-1)(n-2)(n-3)/(1*2*3*4)`; and so on. Therefore `(1+x)^n=1+nx+(n(n-1))/(1*2)x^2+(n(n-1)(n-2))/(1*2*3)x^3+...`, and putting `b/a` for `x`, `(a+b)^n=a^n+na^(n-1)b+(n(n-1))/(1*2)a^(n-2)b^2+...`. If `-b` be put for `b`, the odd powers of `-b` are negative (Art. 193): `(a-b)^n=a^n-na^(n-1)b+(n(n-1))/(1*2)a^(n-2)b^2-...`; which establishes the Binomial Theorem in its most general form.
tf: The binomial formula `(1+x)^n=1+nx+(n(n-1))/(1*2)x^2+...` holds whether `n` is integral or fractional, positive or negative. {T}
art: 320 | The greatest term | To find the numerically greatest term in the expansion of `(a+b)^n`. I. If `n` is a positive integer: from Cor. 3, Art. 310, the (r+1)th term is formed from the rth by multiplying by `((n-r+1)/r)(b/a)`, or `((n+1)/r-1)(b/a)`, and this multiplier diminishes as `r` increases; while it is greater than 1, each term is greater than the preceding. The rth term will be the greatest when `r` is first greater than `(n+1)b/(a+b)`. If `(n+1)b/(a+b)` is a whole number, and we take `r` equal to it, the rth term = the (r+1)th, and each of these is greater than any other term. II. If `n` is a positive fraction: if `b/a>1` there is no greatest term, for the series will diverge; but if `b/a<1`, the greatest term may be found as in I. III. If `n` be negative, either an integer or a fraction greater than 1: the multiplier may be written `-((n+r-1)/r)(b/a)`; disregarding its sign, the rth term will be the greatest when `r` is first greater than `b(n-1)/(a-b)`. If `b(n-1)/(a-b)` is a whole number there are two equal terms each greater than any other; and, as in II, if `b/a>1` there is no greatest term. IV. If `n` be negative and less than 1, and `b/a<1`, the first term is the greatest. Note: if `b` is negative, since it is the numerical value of the term that is to be considered, we may disregard the sign of `b` and apply the appropriate one of the preceding rules.
q: Find the greatest term in the expansion of `(2+5/3)^6`. Here `(n+1)b/(a+b)=35/11`, so `r=4` gives the greatest term, `(6*5*4)/(1*2*3)*2^3*5^3/3^3`. Its value: {20000/27 @= 20*8*125/27} (the book prints 20000/81, a misprint)
q: Which term is the greatest in the expansion of `(1+3/4)^(10/3)`? The term number: {2}
chk: x=13/7 | x=(13/3)(3/4)/(7/4)
q: In the expansion of `(2/3+5/3)^6`, which two terms are equal and greater than any other? The {5}th and the {6}th
chk: x=5 | x=7*(5/3)/(7/3)
q: Find the greatest term in the expansion of `(1+1/5)^(-12)`. Here `(n-1)b/(a-b)=11/4`, so `r=3` gives the greatest term, `(12*13)/(1*2)*1/5^2`. Its value: {78/25 @= (12*13/2)/25}
chk: x=11/4 | x=11*(1/5)/(4/5)
q: In the expansion of `(1+5/7)^(-3)`, `(n-1)b/(a-b)=5`; which two terms are equal, each greater than any other? The {5}th and the {6}th
chk: x=5 | x=2*(5/7)/(2/7)
q: Which term is the greatest in the expansion of `(1-7/12)^(-8/3)`? The term number: {3}
chk: x=7/3 | x=(5/3)(7/12)/(5/12)
art: 321 | Applying the theorem | In the application of the Binomial Theorem, it is merely necessary to take the general formula `(a+b)^n=a^n+na^(n-1)b+...`, substitute the given quantities in the formula, and then reduce each term to its most simple form. Example 1: find the expansion of `(1+x)^(1/2)`. Here `a=1`, `b=x`, `n=1/2`; so `(1+x)^(1/2)=1+(1/2)x+((1/2)(1/2-1))/(1*2)x^2+((1/2)(1/2-1)(1/2-2))/(1*2*3)x^3+...=1+(1/2)x-(1*1)/(2*4)x^2+(1*1*3)/(2*4*6)x^3-(1*1*3*5)/(2*4*6*8)x^4+...` Example 2: develop `(1-x)^(-1/2)`. Here `a=1`, `b=-x`, `n=-1/2`; so `(1-x)^(-1/2)=1+(1/2)x+(1*3)/(2*4)x^2+(1*3*5)/(2*4*6)x^3+...`
q: Expand `(1+x)^(1/2)`: its first 5 terms. {list: 1, x/2, -x^2/8, x^3/16, -5x^4/128}
q: Expand `(1-x)^(-1/2)`: its first 4 terms. {list: 1, x/2, 3x^2/8, 5x^3/16}
art: 321 | Reduce to the form (1+x)^n | As the general formula `(1+x)^n=1±nx+(n(n-1))/(1*2)x^2±...` is more easily retained in the memory, and is less complicated, it is generally most convenient to reduce the quantity to be expanded to this form. Thus, develop `√(a+b)` into a series. Since `a+b=a(1+b/a)`, `√(a+b)=√a(1+b/a)^(1/2)`. Here `x=b/a`, `n=1/2`; and `(1+b/a)^(1/2)=1+(1/2)(b/a)-(1/(2*4))(b^2/a^2)+((1*3)/(2*4*6))(b^3/a^3)-...`. Hence `√(a+b)=√a(1+b/(2a)-b^2/(8a^2)+b^3/(16a^3)-(5b^4)/(128a^4)+...)`.
q: `√(a+b)=√a(1+...)`: type the first 5 terms inside the bracket. {list: 1, b/(2a), -b^2/(8a^2), b^3/(16a^3), -5b^4/(128a^4)}
art: 321 | Exercises | Expand the following by the Binomial Theorem. Type the terms one at a time.
q: `1/(1-x)=(1-x)^(-1)`: its first 5 terms. {list: 1, x, x^2, x^3, x^4}
q: `1/(1-x)^2=(1-x)^(-2)`: its first 5 terms. {list: 1, 2x, 3x^2, 4x^3, 5x^4}
q: `a^2/(a+x)^2=a^2(a+x)^(-2)=(1+x/a)^(-2)`: its first 5 terms. {list: 1, -2x/a, 3x^2/a^2, -4x^3/a^3, 5x^4/a^4}
q: `∛(1-x^3)`: its first 4 terms. {list: 1, -x^3/3, -x^6/9, -5x^9/81}
q: `√(a^2+x)`: its first 5 terms. {list: a, x/(2a), -x^2/(8a^3), x^3/(16a^5), -5x^4/(128a^7)}
q: `(a^3-x)^(1/3)`: its first 5 terms. {list: a, -x/(3a^2), -x^2/(9a^5), -5x^3/(81a^8), -10x^4/(243a^11)}
q: `(1+2x)^(1/2)`: its first 5 terms. {list: 1, x, -x^2/2, x^3/2, -5x^4/8}
q: `√(a^2-x^2)`: its first 5 terms. {list: a, -x^2/(2a), -x^4/(8a^3), -x^6/(16a^5), -5x^8/(128a^7)}
q: `∛(a+x)=∛a(1+...)`: the first 5 terms inside the bracket. {list: 1, x/(3a), -x^2/(9a^2), 5x^3/(81a^3), -10x^4/(243a^4)}
q: `(a^3+x^3)^(1/3)=a(1+...)`: the first 4 terms inside the bracket. (The book writes them `1+x^3/(3a^3)-(2x^6)/(3*6a^6)+(2*5x^9)/(3*6*9a^9)`.) {list: 1, x^3/(3a^3), -x^6/(9a^6), 5x^9/(81a^9)}
q: `∛9=∛(8+1)=2+(2/3)(1/8)-(2/9)(1/8^2)+(10/81)(1/8^3)-...`: type the first 4 terms as plain fractions. {list: 2, 1/12, -1/288, 5/20736}
q: `(a^3-x^3)^(1/3)=a(1-...)`: the first 4 terms inside the bracket. {list: 1, -x^3/(3a^3), -x^6/(9a^6), -5x^9/(81a^9)}
q: `a^3/(a^3-x^3)^(2/3)`: its first 4 terms. (Here `a^3/(a^3-x^3)^(2/3)=a^3(a^3)^(-2/3)(1-x^3/a^3)^(-2/3)=a(1-x^3/a^3)^(-2/3)`.) {list: a, 2x^3/(3a^2), 5x^6/(9a^5), 40x^9/(81a^8)}
art: 322 | Approximate roots | To find the approximate roots of numbers by the Binomial Theorem. Let N represent any proposed number whose nth root is required; take `a` such that `a^n` is the nearest perfect nth power to N, so that `N=a^n±b`, `b` being small compared with `a`, and + or - according as N is greater or less than `a^n`. Then the nth root of N is `a(1±b/a^n)^(1/n)`, which, by writing `b/a^n` for `x` in the general formula, is `a(1±(1/n)(b/a^n)-(1/n)((n-1)/(2n))(b/a^n)^2±(1/n)((n-1)/(2n))((2n-1)/(3n))(b/a^n)^3-...)`. Of this series a few terms only, when `b` is small with regard to `a^n`, will give the required root to a considerable degree of accuracy. Example: required the approximate cube root of 128. Here `∛128=∛(5^3+3)=5∛(1+3/125)=5(1+(1/3)(3/125)-(1/3)(1/3)(3/125)^2+(1/3^2)(5/9)(3/125)^3-...)=5+1/5^2-1/5^5+(1/3)(1/5^7)-...=5+0.04-0.00032+0.0000042-...=5.0396842`.
q: Required the approximate cube root of 128, to 7 decimal places. {5.0396842|5.0396841}
art: 323 | Limit of the error | In the preceding example, we obtain only an approximate value. To determine the limit in the error occasioned by neglecting the remaining terms of the series, let R be the true root, and as the terms are alternately positive and negative, put R = `a-b+c-d+e-f+g-h+k-...`, and let R' = `a-b+c-d+e-f`, R'' = `a-b+c-d+e-f+g`. Then, since the terms continually decrease, `a-b`, `c-d`, `e-f`, `g-h`, etc., are all positive, and therefore R', which contains three only of those differences, will be less than R. For the same reason, all the pairs of terms after `g`, as `-h+k`, `-l+m`, etc., will be all negative, and R'' will be greater than R; therefore the true value of the series lies between R' and R''. Hence, the error committed by the omission of any number of the terms of a converging series whose signs are alternately positive and negative, is less than the first omitted term. Thus, in the preceding example, had we stopped at the 3d term, the error would have been less than .0000042.
tf: When the terms of a converging series are alternately positive and negative, the error of stopping is less than the first omitted term. {T}
q: Find the 5th root of 35, true to 5 decimal places. Here `N=35=32+3=2^5(1+3/2^5)`. (The book prints 2.036172+, the sum of the first four terms; the true root is 2.036168.) {2.03617|2.03616}
q: Find `√10=√(9+1)`, true to 0.00001. {3.16228|3.16227}
q: Find `∛24=∛(27-3)`, true to 0.00001. {2.8845|2.88449}
q: Find the 7th root of 108, `(128-20)^(1/7)`, true to 0.00001. {1.95204}
art: 323 | Remark | The nth root may be extracted by the formula in Art. 321, the number whose root is to be extracted being divided into any two parts whatever. The advantage of the formula in Art. 322 consists in the rapid convergence of its terms.
== 67 | Indeterminate Coefficients and Series | Differential method: orders of differences; nth term; sum of n terms
art: 324 | The Differential Method | The Differential Method is used, 1st, to find the successive differences of the terms of a series; 2d, to find any particular term of the series; or, 3d, to find the sum of a finite number of its terms. If, in any series, we take the first term from the second, the second from the third, the third from the fourth, and so on, the new series thus formed is called the first order of differences. If we proceed with this new series in the same manner, we shall obtain another series, termed the second order of differences. In a similar manner we find the third, fourth, etc., orders of differences. If we have the series 1, 8, 27, 64, 125, 216, ..., the 1st order of differences is 7, 19, 37, 61, 91, ...; the 2d, 12, 18, 24, 30, ...; the 3d, 6, 6, 6, ...
q: The series 1, 8, 27, 64, 125, 216: type its first order of differences. {list: 7, 19, 37, 61, 91}
q: Its second order of differences. {list: 12, 18, 24, 30}
art: 325 | Problem I | To find the first term of any order of differences. Let the series be `a`, `b`, `c`, `d`, `e`, ...; then the respective orders of differences are: 1st order, `b-a`, `c-b`, `d-c`, `e-d`, ...; 2d order, `c-2b+a`, `d-2c+b`, `e-2d+c`, ...; 3d order, `d-3c+3b-a`, `e-3d+3c-b`, ...; 4th order, `e-4d+6c-4b+a`. Here, each difference pointed off by commas, though a compound quantity, is called a term. If we denote the first terms in the 1st, 2d, 3d, 4th, etc., orders of differences by D1, D2, D3, D4, etc., and invert the order of the letters, we have D1 = `-a+b`; D2 = `a-2b+c`; D3 = `-a+3b-3c+d`; D4 = `a-4b+6c-4d+e`, etc. Here, the coefficients of `a`, `b`, `c`, `d`, etc., in the nth order of differences, are evidently those of the terms of a binomial raised to the nth power; and their signs are alternately positive and negative. Hence, the first term of the nth order of differences is `a-nb+(n(n-1))/(1*2)c-(n(n-1)(n-2))/(1*2*3)d+...` when `n` is even, and `-a+nb-(n(n-1))/(1*2)c+(n(n-1)(n-2))/(1*2*3)d-...` when `n` is odd. Corollary: it is evident from the coefficients that when `n=1`, the value of Dn has only two terms, for then `n-1=0`; when `n=2`, this value has only three terms, for then `n-2=0`; and so on.
q: Find the first term of the fourth order of differences of the series `1^3`, `2^3`, `3^3`, `4^3`, `5^3`, ..., or 1, 8, 27, 64, etc. (Here `n=4`; take five terms of the first value of Dn, with `a=1`, `b=8`, `c=27`, `d=64`, `e=125`.) {0 @= 1-4*8+6*27-4*64+125}
q: Find the first term of the second order of differences of the series `1^2`, `2^2`, `3^2`, `4^2`, ..., or 1, 4, 9, 16, 25. {2 @= 1-2*4+9}
q: What is the first term of the third order of differences of the series 1, 3, 6, 10, 15, etc.? {0 @= -1+3*3-3*6+10}
q: Required the first term of the fifth order of differences of the series 1, 3, `3^2`, `3^3`, `3^4`, etc. {32 @= -1+5*3-10*9+10*27-5*81+243}
q: Find the first term of the fifth order of differences of the series 1, `1/2`, `1/4`, `1/8`, `1/16`, etc. {$ -1/32 @ -1+5/2-10/4+10/8-5/16+1/32}
art: 326 | Problem II | To find the nth term of the series `a`, `b`, `c`, `d`, `e`, etc. From the preceding article, D1 = `-a+b`, whence `b=a+D1`; D2 = `a-2b+c`, whence `c=a+2D1+D2`; D3 = `-a+3b-3c+d`, whence `d=a+3D1+3D2+D3`; D4 = `a-4b+6c-4d+e`, whence `e=a+4D1+6D2+4D3+D4`. It is evident from inspection that the coefficients of the nth term of the series are the coefficients of the (n-1) power of a binomial. Hence, writing `n-1` instead of `n` in the coefficients of the nth power of `a+b` (Art. 319), the nth term of the series is `a+(n-1)D1+((n-1)(n-2))/(1*2)D2+((n-1)(n-2)(n-3))/(1*2*3)D3+...`
art: 326 | Examples | 1. Find the 12th term of the series 1, 3, 6, 10, 15, 21, ... The orders of differences are 2, 3, 4, 5, ...; 1, 1, 1, ...; 0, 0, ...; hence D1 = 2, D2 = 1, D3 = 0, and the succeeding orders are also 0; hence the 12th term is `a+(n-1)D1+((n-1)(n-2))/(1*2)D2=1+11*2+(11*10)/2*1=1+22+55=78`. 2. Find the nth term of the series 2, 6, 12, 20, 30, ... Here D1 = 4, D2 = 2, and D3 = 0; hence the nth term `=2+(n-1)4+((n-1)(n-2))/(1*2)*2=n^2+n`. From the formula `n^2+n`, or `n(n+1)`, any term of this series is readily found; thus, the 20th term `=20(20+1)=420`. It is also evident that the nth term of a series can be found exactly, only when some order of differences is zero.
q: Find the 12th term of the series 1, 3, 6, 10, 15, 21, ... {78 @= 1+11*2+55}
q: Find the nth term of the series 2, 6, 12, 20, 30, ... {$ n^2+n | n(n+1) @ 2+(n-1)4+(n-1)(n-2)}
q: Find the 15th term {225} and the nth term {$ n^2 @ 1+(n-1)3+(n-1)(n-2)} of the series `1^2`, `2^2`, `3^2`, `4^2`, ..., or 1, 4, 9, 16, ...
q: Find the 12th term of the series 1, 5, 15, 35, 70, 126, etc. {1365 @= 1+11*4+55*6+165*4+330}
q: Find the nth term of the series 1, 3, 6, 10, etc. {$ n(n+1)/2 | (n^2+n)/2 @ 1+2(n-1)+(n-1)(n-2)/2}
q: Find the 9th term of the series `2*5*7`, `4*7*9`, `6*9*11`, `8*11*13`, etc. {8694 @= 18*21*23}
q: What is the nth term of the series `1*2`, `3*4`, `5*6`, etc.? {$ 4n^2-2n @ (2n-1)(2n)}
art: 327 | Problem III | To find the sum of `n` terms of the series `a`, `b`, `c`, `d`, `e`, etc. Assume the series 0, `a`, `a+b`, `a+b+c`, `a+b+c+d`, ... Subtracting each term from the next succeeding, we have `a`, `b`, `c`, `d`, `e`, etc., which is the series whose sum it is proposed to find. Hence, the sum of `n` terms of the proposed series is the (n+1)th term of the assumed series. It is evident the nth order of differences in the given series is equal to the (n+1)th order in the assumed series. Hence, if we compare the quantities in the assumed series with those of the formula for finding the nth term of a series (Art. 326), we have 0 for `a`, `n+1` for `n`, `a` for D1, D1 for D2, etc. Substituting these values in the formula, we have `0+(n+1-1)a+((n+1-1)(n+1-2))/(1*2)D1+...`; or `na+(n(n-1))/(1*2)D1+(n(n-1)(n-2))/(1*2*3)D2+...`, which is the sum of `n` terms of the proposed series.
q: Find the sum of `n` terms of the odd numbers 1, 3, 5, 7, 9, ... (Here `a=1`, D1 = 2, D2 = 0.) {$ n^2 @ n+n(n-1)}
q: Find the sum of `n` terms of the series `1^2`, `2^2`, `3^2`, `4^2`, `5^2`, ... (Here `a=1`, D1 = 3, D2 = 2, D3 = 0.) {$ n(n+1)(2n+1)/6 @ n+3n(n-1)/2+n(n-1)(n-2)/3}
q: Find the sum of `n` terms of the series `1+3+6+10+15`, etc. {$ n(n+1)(n+2)/6 @ n+n(n-1)+n(n-1)(n-2)/6}
q: Find the sum of 20 terms of the series `3+11+31+69+131`, etc. {44330 @= 20*3+190*8+1140*12+4845*6}
q: Find the sum of 20 terms of the series `1*2*3+2*3*4+3*4*5+`, etc. {53130 @= 20*21*22*23/4}
q: Find the sum of `n` terms of the series of cube numbers `1^3+2^3+3^3+`, etc. {$ (n(n+1)/2)^2 | n^2(n+1)^2/4 @ n+7n(n-1)/2+2n(n-1)(n-2)+n(n-1)(n-2)(n-3)/4}
q: Find the sum of 25 terms of the series whose nth term is `n^2(3n-2)`. {305825 @= 3*325^2-2*5525}
== 68 | Indeterminate Coefficients and Series | Piling of cannon balls and shells
art: 328 | Piling of balls | Balls and shells are usually piled by horizontal courses, either in the form of a pyramid or a wedge; the base being either an equilateral triangle, or a square, or a rectangle. In the triangle and square, the pile terminates in a single ball, but in the rectangle it finishes in a ridge, or single row of balls.
art: 329 | Triangular pile | To find the number of balls in a triangular pile. A triangular pile is formed of successive horizontal courses of the form of an equilateral triangle, the number on each side decreasing continually by unity from the bottom to the single ball at the top. If we commence at the top, the number of balls in the respective courses is 1, `1+2`, `1+2+3`, `1+2+3+4`, `1+2+3+4+5`, and so on; or 1, 3, 6, 10, 15. Hence, to find the number of balls in a triangular pile, is to find the sum of the series 1, 3, 6, 10, 15, etc., to as many terms (`n`) as there are balls in one side of the lowest course. By applying the formula (Art. 327) to finding the sum of `n` terms of the series 1, 3, 6, 10, etc., we have `a=1`, D1 = 2, D2 = 1, and D3 = 0. Hence the formula `na+(n(n-1))/(1*2)D1+(n(n-1)(n-2))/(1*2*3)D2` gives `n+n^2-n+(n^3-3n^2+2n)/6=n(n+1)(n+2)/6` (A).
q: How many balls are in the 4th course from the top of a triangular pile? {10}
art: 330 | Square pile | To find the number of balls in a square pile. A square pile is formed of successive square horizontal courses, such that the number of balls in the sides of these courses decreases continually by unity, from the bottom to the single ball at the top. If we commence at the top, the number of balls in the respective courses is `1^2`, `2^2`, `3^2`, `4^2`, `5^2`, etc., or 1, 4, 9, 16, 25, and so on. Therefore, to find the number of balls in a square pile, is to find the sum of the squares of 1, 2, 3, etc., to as many terms (`n`) as there are balls in one side of the lowest course. But this sum (Ex. 2, Art. 327) is `n(n+1)(2n+1)/6` (B).
art: 331 | Rectangular pile | To find the number of balls in a rectangular pile. A rectangular pile is formed of successive rectangular courses, the number of balls in each of the sides decreasing by unity from the bottom to the single row at the top. If we commence at the top, the number of balls in the breadth of the successive rows is 1, 2, 3, and so on. Also, if `m+1` denotes the number of balls in the top row, the number in the length of the second row will be `m+2`, in the third `m+3`, and so on. Hence the number in the respective courses, commencing with the top, will be `1(m+1)`, `2(m+2)`, `3(m+3)`, and in the nth course `n(m+n)`. Or, `S=m(1+2+3+...+n)+(1^2+2^2+3^2+...+n^2)`; but the sums of `n` terms of the series in the two parentheses (Arts. 327, 330) are `n(n+1)/2` and `n(n+1)(2n+1)/6`. Hence `S=mn(n+1)/2+n(n+1)(2n+1)/6=(n(n+1))/6(3m+2n+1)` (C). Here, `m+n` represents the number of balls in the length of the lowest course. If we put `m+n=l`, we have `3m+2n=3l-n`; substituting this for `3m+2n` in (C), `S=(n(n+1))/6(3l-n+1)`. It is evident that the number of courses in a triangular or square pile is equal to the number of balls in one side of the base course, and in the rectangular pile to the number of balls in the breadth of the base course.
art: 332 | The three formulas | Collecting together the results of the three preceding articles, we have for the number of balls in a triangular pile `(1/6)n(n+1)(n+2)` (A); a square pile `(1/6)n(n+1)(2n+1)` (B); a rectangular pile `(1/6)n(n+1)(3l-n+1)` (C). In (A) and (B), `n` denotes the number of courses, or number of balls in the base course; in (C), `n` denotes the number in the breadth, and `l` the number in the length, of the base course. The number of balls in an incomplete pile is evidently found by subtracting the number in the pile which is wanting at the top, from the whole pile considered as complete. Example 1: find the number of balls in a triangular pile of 15 courses. Here `n=15`; substituting this value in (A), we find `(15(15+1)(15+2))/(2*3)=(15*16*17)/6=680`. Example 2: find the number of balls in an incomplete triangular pile of 15 courses, having 21 balls in the upper course. From Art. 329, the number of balls in one side of the upper course is 6; therefore 5 courses have been removed from the pile. From formula (A), the pile, considered as complete, would contain 1540 balls, and the removed pile contains 35. Hence `1540-35=1505`, the number left.
q: Find the number of balls in a triangular pile of 15 courses. {680 @= 15*16*17/6}
q: Find the number of balls in an incomplete triangular pile of 15 courses, having 21 balls in the upper course. {1505 @= 20*21*22/6-5*6*7/6}
q: Find the number of balls in a square pile of 15 courses. {1240 @= 15*16*31/6}
q: Find the number of balls in a rectangular pile, the length and breadth of the base containing 52 and 34 balls respectively. {24395 @= 34*35*(3*52-34+1)/6}
q: Find the number of balls in an incomplete triangular pile, a side of the base course having 25 balls, and a side of the top 13. {2561 @= 25*26*27/6-12*13*14/6}
q: How many balls in an incomplete triangular pile of 15 courses, having 38 balls in a side of the base? {7580 @= 38*39*40/6-23*24*25/6}
q: Find the number of balls in an incomplete square pile, a side of the base course having 44 balls, and a side of the top 22. {26059 @= 44*45*89/6-21*22*43/6}
q: The whole number of balls in the base and top courses of a square pile are 1521 and 169 respectively; how many are in the incomplete pile? {19890 @= 39*40*79/6-12*13*25/6}
q: The number of balls in a complete rectangular pile of 20 courses is 6440; how many balls are in its base? {740 @x: (20*21/6)(3x/20-20+1)=6440}
q: The number of balls in a triangular pile is to the number in a square pile having the same number of balls in the side of the base as 6 to 11; required the number in each pile. Triangular {816 @= 16*17*18/6}, square {1496 @= 16*17*33/6}
chk: x=16 | 11(x+2)=6(2x+1)
q: How many balls are in an incomplete rectangular pile of 8 courses, having 36 balls in the longer side, and 17 in the shorter side of the upper course? {6520 @= 24*25*(3*43-24+1)/6-16*17*(3*35-16+1)/6}
== 69 | Indeterminate Coefficients and Series | Interpolation; infinite series; summation of series
art: 333 | Interpolation | Interpolation is the process of finding intermediate numbers in mathematical, astronomical, or other tables. Its object is to furnish a shorter method of completing such tables when portions of them have been calculated by formulae. Thus, if the logarithms of 5, 6, and 8 are respectively 0.6989, 0.7782, and 0.9031, it may be required from these data to find the logarithm of 7. The latter numbers are sometimes called functions of the former, and the former arguments of the functions. As the functions constitute a series, the principle upon which interpolation is founded is explained in Art. 326; that is, certain terms of a series being known, it is required to find the nth term. Three cases may arise.
art: 333 | Case I | When the differences of the functions are proportional, or nearly proportional, to the differences of the arguments, or the functions are in arithmetical progression. Example: given the Dip of the Sea Horizon at the heights of 86, 89, 92, 95, and 98 feet, viz., 9'08", 9'17", 9'26", 9'36", and 9'45"; required that of 101 feet. Here, the first differences being 9", or nearly so, we add 9" to 9'45" for the Dip at 101 feet: 9'54". In all practical examples, there is no common first difference, and it becomes necessary to employ the second, third, etc., differences. If in the series composing the functions, we can obtain an order of differences equal to zero, the interpolation will be exact. In most cases, however, D2, D3, etc., do not vanish, but become so small after D2 or D3 that they may be omitted without sensible error.
q: Given the Dip of the Sea Horizon at the heights of 86, 89, 92, 95, and 98 feet: 9'08", 9'17", 9'26", 9'36", and 9'45"; required that of 101 feet. 9 minutes and {54} seconds
art: 334 | Case II | When the differences of the functions are not proportional to the differences of the arguments, and the term to be interpolated is one of the equidistant functions. In such examples, when three quantities are given, we may suppose D3 to vanish or become very small. We then have (Art. 326) the equation `-a+3b-3c+d=0`, and any of the quantities `a`, `b`, `c`, or `d` may be found, when the other three are given. Similarly, if the fourth differences vanish, then `a-4b+6c-4d+e=0`. Example: given `∛25=2.92401`, `∛26=2.96249`, `∛27=3`, `∛29=3.07231`, to find the cube root of 28. Here four quantities are given to find a fifth; therefore we have `a-4b+6c-4d+e=0`, where `d` is the term to be interpolated; hence `4d=a+6c+e-4b=2.92401+18+3.07231-11.84996=12.14636`, whence `d`, or `∛28`, `=3.03659`, which is true to .00001.
q: Given `∛25=2.92401`, `∛26=2.96249`, `∛27=3`, `∛29=3.07231`, find the cube root of 28. {3.03659}
art: 335 | Case III | When the differences are as in Case 2d, and the term to be interpolated is intermediate to any two of the functions. Example: having given the logarithms of 102, 103, 104, and 105, let it be required to find the logarithm of 103.55. Taking the formula, Art. 326, put `p` to represent the distance, in intervals, of the required term (`t`) from `a`, the first term of the series, in which case `p=n-1`, since the number of intervals is one less than the number of terms. Then `t=a+pD1+(p(p-1))/(1*2)D2+(p(p-1)(p-2))/(1*2*3)D3+...` The intervals between the given numbers is always to be considered as unity, and `p` is to be reckoned in parts of this interval; hence `p` will be fractional. Sufficient accuracy is generally obtained by making use of D1 and D2 only. In practice, however, the following is generally adopted: take the two functions of the series which precede, and the two which follow the term required, and find from them the three first differences, and the two second differences. Call the second of the three first differences `d`, the mean of the two second differences `d'`, the fractional part of the interval `p'`, and second term `b`. We then have from the above formula `t=b+p'(d+((p'-1)/2)d')`.
art: 335 | The example worked | The logarithms of 102, 103, 104, 105 are 2.0086002, 2.0128372, 2.0170333, 2.0211893. The first differences (in units of the 7th decimal place) are 42370, 41961, 41560; the second differences -409 and -401, whose mean is -405. Here `p'=.55`, `d=41961`, `d'=-405`, and `b=2.0128372`. So `t=2.0128372+.55(41961+(.45/2)*405)`, in units of the 7th place, `=2.0128372+.0023129=2.0151501`.
q: Find the logarithm of 103.55 from those of 102, 103, 104, and 105, to 7 decimal places. {2.0151501}
q: Find the 2d term of the series of which the 4th differences vanish, the 1st, 3d, 4th, and 5th terms being 3, 15, 30, 55. {7 @x: 3-4x+6*15-4*30+55=0}
q: And find the 6th, 7th, and 8th terms. {list: 93, 147, 220}
chk: a=3, b=7, c=15, d=30, f=55, g=93 | a-4b+6c-4d+f=0 | b-4c+6d-4f+g=0
chk: c=15, d=30, f=55, g=93, h=147, k=220 | c-4d+6f-4g+h=0 | d-4f+6g-4h+k=0
q: Find the 5th term of the series of which the 6th differences vanish, and the 1st, 2d, 3d, 4th, 6th, and 7th terms are 11, 18, 30, 50, 132, 209. {82 @x: 11-6*18+15*30-20*50+15x-6*132+209=0}
q: Given the logarithms of 101, 102, 104, and 105; viz., 2.0043214, 2.0086002, 2.0170333, and 2.0211893, find the logarithm of 103. {2.0128372}
q: Given the cube roots of 60, 62, 64, and 66; viz., 3.91487, 3.95789, 4, and 4.04124, find the cube root of 63. {3.97905|3.97906}
art: 335 | Squares by addition | Having given the squares of any two consecutive whole numbers, the squares of the succeeding whole numbers may be obtained by addition: the second differences of the squares are always 2, so each new first difference is 2 more than the last. Thus from 25 and 36 (difference 11), the next difference is 13, and `36+13=49`; then 15, and `49+15=64`.
q: The squares of 10 and 11 are 100 and 121. Add on to find the square of 12. {144 @= 121+23}
art: 336 | Infinite Series | An Infinite Series is a series consisting of an unlimited number of terms. The Sum of an infinite series is the limit to which we approach by adding together more terms, but which can not be exceeded by adding together any number of terms whatever. A Convergent Series is one which has a sum or limit. Thus, `1+1/2+1/4+1/8+1/16+1/32+1/64+`, etc., is a convergent series, whose limit is 2, since the sum of any number of its terms can not exceed 2. A Divergent Series is one which has no sum or limit; as `1+2+4+8+16+32+`, etc. An Ascending Series is one in which the powers of the leading quantity continually increase; as `a+bx+cx^2+dx^3+`. A Descending Series is one in which the powers of the leading quantity continually diminish; as `a+bx^(-1)+cx^(-2)+dx^(-3)+`, or `a+b/x+c/x^2+d/x^3+`.
tf: `1+2+4+8+16+`, etc., is a convergent series. {F}
art: 337 | Four methods | There are four general methods of converting an algebraic expression into an infinite series of equivalent value, each of which has been already exemplified; viz., 1st, by Division, Art. 134; 2d, by Extraction of Roots, Art. 183; 3d, by Indeterminate Coefficients, Arts. 315-317; and, 4th, by the Binomial Theorem, Art. 321.
art: 338 | Summation of Series | The Summation of a Series is the finding a finite expression equivalent to the series. The General Term of a Series is an expression from which the several terms of the series may be derived according to some determinate law. Thus, in the series `a/1+a/2+a/3+a/4+...` the general term is `a/x`, because by making `x=1`, 2, 3, etc., each term of the series is found. Again, in the series `2*2+2*3+2*4+2*5+...` the general term is `2(x+1)`. As different series are in general governed by different laws, the methods of finding the sum, which are applicable to one class, will not apply universally. We present two methods of most general application. First Method: in a regular decreasing geometrical series, whose first term is `a`, and ratio `r`, the sum is `a/(1-r)` (Art. 299).
art: 338 | Second Method: by subtraction | Example 1: find the sum of the infinite series `1/(2*3)+1/(3*4)+1/(4*5)+1/(5*6)+`, etc. Put `1/2+1/3+1/4+1/5+...=S`; then `1/3+1/4+1/5+1/6+...=S-1/2`. Subtracting, `1/(2*3)+1/(3*4)+1/(4*5)+1/(5*6)+...=1/2`. Example 2: find the sum of `1/(1*3)+1/(3*5)+1/(5*7)+1/(7*9)+`, etc. Put `1/1+1/3+1/5+1/7+...=S`; then `1/3+1/5+1/7+1/9+...=S-1`. Subtracting, `2/(1*3)+2/(3*5)+2/(5*7)+...=1`, and `1/(1*3)+1/(3*5)+1/(5*7)+...=1/2`. In such series, the first factor in the successive denominators is variable, while the second factor exceeds the first by a constant quantity. The general term is therefore `q/(n(n+p))`, where `n` is variable and `p` constant. Since `q/n-q/(n+p)=pq/(n(n+p))`, `q/(n(n+p))=(1/p)(q/n-q/(n+p))`. From which we derive the Rule: having found the values of `q`, `n`, and `p`, in the given series, express the series whose general formulas are `q/n` and `q/(n+p)`; subtract the latter from the former, and divide the result by `p` for the sum of the series.
q: Find the sum of the infinite series `1/(2*3)+1/(3*4)+1/(4*5)+1/(5*6)+`, etc. {1/2}
art: 338 | The rule applied | Required the sum of the series `1/(1*3)+1/(3*5)+1/(5*7)+`, etc., ad infinitum, that is, to infinity. Here `q=1`, `p=2`, and `n=1`, 3, 5, 7, etc. Then `q/n=1+1/3+1/5+1/7+...`, and `q/(n+p)=1/3+1/5+1/7+...`; subtracting, `q/n-q/(n+p)=pq/(n(n+p))=1`, so `q/(n(n+p))=1/2`, the sum of the given series. The sum of `n` terms of the same series is found in a manner nearly similar: `q/n=1+1/3+1/5+1/7+...+1/(2n-1)` and `q/(n+p)=1/3+1/5+1/7+...+1/(2n-1)+1/(2n+1)`; so `pq/(n(n+p))=1-1/(2n+1)=2n/(2n+1)`, and the sum is `n/(2n+1)`.
q: Required the sum of the series `1/(1*3)+1/(3*5)+1/(5*7)+`, etc., ad infinitum. {1/2}
q: And the sum of `n` terms of the same series. {$ n/(2n+1) @ (1/2)(1-1/(2n+1))}
q: Find the sum of the series `1/(1*2)+1/(2*3)+1/(3*4)+`, etc., ad infinitum. (Here `q=1`, `p=1`, and `n=1`, 2, 3, etc.) {1}
q: Find the sum of the above series to `n` terms. {$ n/(n+1) @ 1-1/(n+1)}
q: Find the sum of the series `1/(1*4)+1/(2*5)+1/(3*6)+1/(4*7)+`, etc., ad infinitum. (Here `q=1`, `p=3`, and `n=1`, 2, 3, etc.) {11/18 @= (1+1/2+1/3)/3}
q: Find the sum of the series `1/(1*3)+1/(2*4)+1/(3*5)+`, etc., ad infinitum. (Here `q=1`, `p=2`, and `n=1`, 2, 3, etc.) {3/4 @= (1+1/2)/2}
q: Find the series whose general term is `1/(n(n+4))`: its first 4 terms {list: 1/5, 1/12, 1/21, 1/32} and its sum continued to infinity {25/48 @= (1+1/2+1/3+1/4)/4}
art: 338 | Reducing to known forms | The sums of series may often be found by reducing them, by multiplication or division, to the forms already known.
q: Find the sum of the series `1+1/3+1/6+1/10+`, etc., ad infinitum. (Divide by 2 and compare with the series `1/(1*2)+1/(2*3)+`, etc.) {2}
q: Find the sum of the series `1/(3*8)+1/(6*12)+1/(9*16)+`, etc., ad infinitum. (Multiply by `3*4`.) {1/12}
art: 338 | Remark | There are other methods for the summation of certain classes of series, but they are too complex and extensive for an elementary work.
== 70 | Indeterminate Coefficients and Series | Recurring series; reversion of series
art: 339 | Recurring Series | A Recurring Series is a series so constituted that every term is connected with one or more of the terms which precede it by an invariable law, usually dependent on the operations of addition, subtraction, etc. Thus, in the series `1+2x+3x^2+5x^3+8x^4+13x^5+21x^6+`, etc., the sum of the coefficients of any two consecutive terms is equal to the coefficient of the next following term; and, by means of this relation between the coefficients, the series may be extended to any desired number of terms.
q: Extend the series `1+2x+3x^2+5x^3+8x^4+13x^5+21x^6+`: its next term. {$ 34x^7}
art: 340 | Scale of the coefficients | The particular relation, by means of which the coefficient of any term of the series may be found when the preceding coefficients are known, is called the scale of the coefficients. It is easily seen that it is sufficient to find the successive coefficients in order to determine the series, inasmuch as the desired powers of the variable may be supplied as wanted. Recurring series are of the first order, second order, etc., according to the number of terms in the scale. Thus, in the series `1-(b/a)x+(b^2/a^2)x^2-(b^3/a^3)x^3`, etc., the coefficient of each term after the first is equal to the preceding coefficient multiplied by `-b/a`, and the series is said to be of the first order. This, the simplest form of a recurring series, is obviously a series in Geometrical Progression.
art: 341 | Finding the scale | When the series is of the first order, the scale is easily determined, being the ratio of any two consecutive coefficients (Art. 295). When the series is of the second order, the law of the series depends on two terms, and the scale consists of two parts. Let `p` and `q` represent the two terms of the scale of the coefficients of the recurring series `A+Bx+Cx^2+Dx^3+Ex^4+Fx^5`, etc. Then, by the assumed law of the series, C = `Bp+Aq` (1); D = `Cp+Bq` (2); E = `Dp+Cq` (3); etc. The values of `p` and `q` may be found by eliminating between any two of these equations. Taking the first two (Art. 158), `p=(BC-AD)/(B^2-AC)` and `q=(BD-C^2)/(B^2-AC)`. Example: find the scale of the series `1+2x+3x^2+4x^3+5x^4`, etc. Here A = 1, B = 2, C = 3, D = 4, etc.; so `p=(2*3-1*4)/(2^2-1*3)=2` and `q=(2*4-3^2)/(2^2-1*3)=-1`. Now, by the use of the scale, we may extend the series as far as we please: the 5th coefficient = `p` times the 4th + `q` times the 3d = `2*4-3=5`; the 6th coefficient = `2*5-4=6`; the 7th = `2*6-5=7`; and as the ascending powers of `x` are wanted, we have `6x^5` for the 6th term, `7x^6` for the 7th, etc.
q: Find the scale of the series `1+2x+3x^2+4x^3+5x^4`, etc.: `p` {2 @= (2*3-1*4)/(2^2-1*3)} and `q` {$ -1 @ (2*4-3^2)/(2^2-1*3)}
art: 342 | Third order | In a recurring series of the third order, the law of the series involves three terms, which we will represent by `p`, `q`, and `r`, the series being `A+Bx+Cx^2+Dx^3+Ex^4+Fx^5+Gx^6`, etc. Then, by the law of the series, D = `Cp+Bq+Ar`; E = `Dp+Cq+Br`; F = `Ep+Dq+Cr`; etc. And, by combining these equations, the values of `p`, `q`, and `r` are readily found (Art. 158). In a similar manner the scale may be determined in series of the higher orders. In finding the scale of a series, we must first ascertain by inspection whether the series is in G. P.; if not, then make trial of a scale containing two terms, then one of three, four, and so on, until a correct result is obtained. We must be careful not to assume too many terms; for in that case every term of the scale will take the form `0/0`.
art: 343 | Sum of a recurring series | To find the sum of an infinite recurring series whose scale of relation is known. Let `A+Bx+Cx^2+Dx^3+Ex^4`, etc., be a recurring series of the second order, `p` and `q` being the terms of the scale. Then A = A; `Bx=Bx`; `Cx^2=Bpx^2+Aqx^2`; `Dx^3=Cpx^3+Bqx^3`; etc., ad infinitum. Represent by S the required sum, and add together the corresponding members of the preceding equations, observing that `Bx+Cx^2+Dx^3+...=S-A`; then `S=A+Bx+(S-A)px+Sqx^2`; so `S-Spx-Sqx^2=A+Bx-Apx`; or `S=(A+Bx-Apx)/(1-px-qx^2)`. If we make `q=0` (remembering that `B=Ap`), the formula becomes `S=A/(1-px)`, which is, as it ought to be, identical with the formula of Art. 299. Remark: every recurring series may be supposed to arise from the development of a rational fraction, and the summation of such a series may be regarded as a return to the generating fraction. There are several methods of accomplishing this return: of these the preceding is regarded as the most suitable for an elementary work. Example: find the sum of `1+3x+5x^2+7x^3+9x^4`, etc. Here A = 1, B = 3, C = 5, D = 7, etc.; and hence (Art. 341) `p=2`, `q=-1`. Then `S=(A+Bx-Apx)/(1-px-qx^2)=(1+3x-2x)/(1-2x+x^2)=(1+x)/(1-x)^2`.
q: Find the sum of `1+3x+5x^2+7x^3+9x^4`, etc. {$ (1+x)/(1-x)^2 | (1+x)/(1-2x+x^2) @ (1+3x-2x)/(1-2x+x^2)}
art: 343 | Exercises | In each of the following series, find the scale of relation, and the sum (S) of an infinite number of terms.
q: `1+6x+12x^2+48x^3+120x^4+`, etc.: `p` {1}, `q` {6}, and S {$ (1+5x)/(1-x-6x^2) @ (1+6x-x)/(1-x-6x^2)}
chk: p=1, q=6 | 12=6p+q | 48=12p+6q | 120=48p+12q
q: `1+2x+3x^2+4x^3+5x^4+6x^5+`, etc.: `p` {2}, `q` {$ -1}, and S {$ 1/(1-x)^2 | 1/(1-2x+x^2) @ (1+2x-2x)/(1-2x+x^2)}
q: `a/c-abx/c^2+ab^2x^2/c^3-ab^3x^3/c^4+`, etc. The series is in G. P.: `p` {$ -b/c} and S {$ a/(c+bx) @ (a/c)/(1+bx/c)}
q: `x+x^2+x^3+`, etc. The series is in G. P.: `p` {1} and S {$ x/(1-x)}
q: `x-x^2+x^3-x^4+`, etc. The series is in G. P.: `p` {$ -1} and S {$ x/(1+x)}
q: `1+3x+5x^2+7x^3+9x^4+`, etc.: `p` {2}, `q` {$ -1}, and S {$ (1+x)/(1-2x+x^2) | (1+x)/(1-x)^2 @ (1+3x-2x)/(1-2x+x^2)}
q: `1^2+2^2x+3^2x^2+4^2x^3+5^2x^4+6^2x^5+`, etc.: `p` {3}, `q` {$ -3}, `r` {1}, and S {$ (1+x)/(1-x)^3 @ (1+4x+9x^2-3x-12x^2+3x^2)/(1-3x+3x^2-x^3)}
chk: p=3, q=-3, r=1 | 16=9p+4q+r | 25=16p+9q+4r | 36=25p+16q+9r
art: 344 | Reversion of Series | To Revert a Series is to express the value of the unknown quantity in it by means of another series involving the powers of some other quantity. Let `x` and `y` represent two undetermined quantities, and express the value of `y` by a series involving the powers of `x`; thus, `y=ax+bx^2+cx^3+dx^4+...` (1), in which `a`, `b`, `c`, `d`, etc., are known quantities; then, to revert this series is to express the value of `x` in a series containing the known quantities `a`, `b`, `c`, `d`, etc., and the powers of `y`. To revert this series, assume `x=Ay+By^2+Cy^3+Dy^4+...` (2), in which the coefficients A, B, C, ... are undetermined. Find the values of `y^2`, `y^3`, `y^4`, ... from (1): `y^2=a^2x^2+2abx^3+(b^2+2ac)x^4+...`; `y^3=a^3x^3+3a^2bx^4+...`; `y^4=a^4x^4+...`. Substituting these values in (2), and arranging, `0=(Aa-1)x+(Ab+Ba^2)x^2+(Ac+2Bab+Ca^3)x^3+(Ad+Bb^2+2Bac+3Ca^2b+Da^4)x^4+...`. Since this is true whatever be the value of `x`, the coefficients of `x`, `x^2`, `x^3`, etc., will each `=0` (Art. 314, Cor.): `Aa-1=0`, so A = `1/a`; `Ab+Ba^2=0`, so B = `-b/a^3`; `Ac+2Bab+Ca^3=0`, so C = `(2b^2-ac)/a^5`; and D = `-(a^2d-5abc+5b^3)/a^7`. Hence `x=(1/a)y-(b/a^3)y^2+((2b^2-ac)/a^5)y^3-((a^2d-5abc+5b^3)/a^7)y^4+...` (3).
q: Reverting `y=ax+bx^2+cx^3+...`, the coefficient of `y^3` is C = {$ (2b^2-ac)/a^5 @x: (1/a)c+2(-b/a^3)ab+x*a^3=0}
art: 345 | A constant term | If the given series has a constant term prefixed, thus, `y=a'+ax+bx^2+cx^3+dx^4+...`, assume `y-a'=z`, and we have `z=ax+bx^2+cx^3+dx^4+...`. But this is the same as (1) in the preceding article, except that `z` stands in the place of `y`; hence, if `z` be substituted for `y` in (3), the result will be the required development of `x`; and then, `y-a'` being substituted for `z`, the result is `x=(1/a)(y-a')-(b/a^3)(y-a')^2+((2b^2-ac)/a^5)(y-a')^3-...`
art: 346 | Odd powers | When the given series contains the odd powers of `x`, assume for `x` another series containing the odd powers of `y`. Thus, if `y=ax+bx^3+cx^5+dx^7+...`, to develop `x` in terms of `y`, assume `x=Ay+By^3+Cy^5+Dy^7+...`. Then, by substituting the values of `y`, `y^3`, etc., derived from the former equation, in the latter, and equating the coefficients to zero, we find `x=(1/a)y-(b/a^4)y^3+((3b^2-ac)/a^7)y^5-((a^2d-8abc+12b^3)/a^10)y^7+...` If both sides of the equation be expressed in a series, as `ay+by^2+cy^3+...=a'x+b'x^2+c'x^3+...`, and it be required to find `y` in terms of `x`, we must assume, as before, `y=Ax+Bx^2+Cx^3+Dx^4+...`, and substitute the values of `y`, `y^2`, `y^3`, etc., derived from this last equation, in the proposed equation; we shall then, by equating the coefficients of the like powers of `x`, determine the values of A, B, C, etc., as before.
art: 346 | Exercises | The following exercises may be solved either by substituting the values of `a`, `b`, `c`, etc., in the equations obtained in the preceding articles, or by proceeding according to the methods by which those equations were obtained. Type the terms one at a time.
q: Given the series `y=x-x^2+x^3-x^4+...`, find the value of `x` in terms of `y`: its first 4 terms. {list: y, y^2, y^3, y^4}
q: Find the value of `x`, in an infinite series in terms of `y`, when `y=x+x^2+x^3+`, etc.: its first 5 terms. {list: y, -y^2, y^3, -y^4, y^5}
q: When `y=2x+3x^3+4x^5+5x^7+`, etc.: its first 3 terms. {list: y/2, -3y^3/16, 19y^5/128}
q: When `y=1-2x+3x^2`: its first 3 terms, in powers of `y-1`. {list: -(1/2)(y-1), (3/8)(y-1)^2, -(9/16)(y-1)^3}
q: When `y=x+(1/2)x^2+(1/6)x^3+(1/24)x^4+`, etc.: its first 4 terms. {list: y, -y^2/2, y^3/3, -y^4/4}
art: 346 | One more | When `y+ay^2+by^3+cy^4+...=gx+hx^2+kx^3+lx^4+...`, the book's answer is `x=y/g+((ag^2-h)y^2)/g^3+([bg^4-kg-2h(ag^2-h)]y^3)/g^5+...`
== 71 | Continued Fractions, Logarithms, and Interest | Continued fractions
art: 347 | Continued Fractions | A Continued Fraction is one whose denominator is continued by being itself a mixed number, and the denominator of the fractional part again continued as before, and so on; thus, `1/(a+1/b)`, `1/(a+1/(b+1/c))`, `1/(a+1/(b+1/(c+1/d)))`, in which `a`, `b`, `c`, `d`, etc., are positive whole numbers. Continued fractions are useful in approximating to the values of ratios expressed by large numbers, in resolving exponential equations, indeterminate equations of the first degree, etc.
art: 348 | A fraction as a continued fraction | To express a rational fraction in the form of a continued fraction. Let it be required to reduce `30/157` to a continued fraction. If we divide both terms of the fraction by the numerator, we find `30/157=1/(5+7/30)`. If we omit `7/30`, the denominator will be too small, and `1/5`, the value of the fraction, will be too large. Again, if we divide both terms of the fraction `7/30` by the numerator, we find `30/157=1/(5+1/(4+2/7))`. If we omit `2/7`, the value will be expressed by `1/(5+1/4)=4/21`, which is less than the true value of the fraction. Hence, generally, by stopping at an odd reduction, and neglecting the fractional part, the result is too great; but by stopping at an even reduction, and neglecting the fractional part, the result is too small. Since `2/7=1/(3+1/2)`, we find `30/157=1/(5+1/(4+1/(3+1/2)))`: the 1st reduction too great; the 2d too small; the 3d too great; the 4th the true value. By this process we find `13/30=1/(2+1/(3+1/4))` and `49/204=1/(4+1/(6+1/8))`.
q: Reduce `30/157` to a continued fraction: type the denominators 5, 4, ... of the integral fractions. {list: 5, 4, 3, 2}
q: `1/(5+1/4)` as a common fraction. {4/21}
mc: Compared with the true value `30/157`, the 2d reduction `4/21` is... | greater | *less | equal
q: Reduce `49/204` to a continued fraction: the denominators of its integral fractions. {list: 4, 6, 8}
art: 349 | Converging fractions | The different quantities `1/a`, `1/(a+1/b)`, `1/(a+1/(b+1/c))`, etc., are called converging fractions, because each one in succession gives a nearer value of the given expression. The fractions `1/a`, `1/b`, `1/c`, etc., are called integral fractions.
art: 350 | Forming the converging fractions | To explain the manner in which the converging fractions are found from the integral fractions. 1. `1/a` is the 1st converging fraction. 2. `1/(a+1/b)=b/(ab+1)`, the 2d. 3. `1/(a+1/(b+1/c))=(bc+1)/(c(ab+1)+a)`, the 3d. By examining the third converging fraction, we find it is formed from the 1st and 2d, and from the 3d integral fraction, as follows: numerator = 3d quotient times the numerator of the 2d converging fraction + the numerator of the 1st; denominator = 3d quotient times the denominator of the 2d converging fraction + the denominator of the 1st. To prove the general law of formation, let `P/P'`, `Q/Q'`, `R/R'` be the three converging fractions corresponding to the three integral fractions `1/a`, `1/b`, and `1/c`; as has already been shown, `R/R'=(Qc+P)/(Q'c+P')`. Let us now take the next integral fraction `1/d`, and let `S/S'` express the 4th converging fraction. Then it is obvious that `R/R'` will become `S/S'` by substituting `c+1/d` instead of `c`; hence `S/S'=(Q(c+1/d)+P)/(Q'(c+1/d)+P')=((Qc+P)d+Q)/((Q'c+P')d+Q')=(Rd+Q)/(R'd+Q')`. The same rule applies to the 4th converging fraction, and so on. Hence, for the nth converging fraction: multiply the denominator of the nth integral fraction by the numerator of the (n-1)th converging fraction, and add to the product the numerator of the (n-2)th converging fraction; this will give the numerator of the nth converging fraction. Multiply the denominator of the nth integral fraction by the denominator of the (n-1)th converging fraction, and add to the product the denominator of the (n-2)th; this will give the denominator of the nth converging fraction.
q: Find a series of converging fractions for `84/227`. The integral fractions are `1/2`, `1/1`, `1/2`, `1/2`, `1/1`, `1/3`, `1/2`; type the converging fractions. {list: 1/2, 1/3, 3/8, 7/19, 10/27, 37/100, 84/227}
art: 351 | Their differences | If the 2d converging fraction (Art. 350) be subtracted from the 1st, the remainder will be found to be a fraction having for its numerator +1, and for its denominator the product of the two denominators; and if the 3d be subtracted from the 2d, the resulting fraction will have -1 for its numerator, and the product of the denominators for its denominator. By a process of reasoning similar to that employed in Art. 350, it may be shown, in a general manner, that the difference between any two consecutive converging fractions is always a fraction having +1, or -1, for its numerator, and the product of the two denominators for its denominator, according as the fraction subtracted is in an even or odd place.
q: Subtract the 3d converging fraction of `84/227`, `3/8`, from the 2d, `1/3`. {$ -1/24}
art: 352 | Lowest terms | To show that every converging fraction is in its lowest terms; and to find the approximate value of the fraction `a/b`. If `A/B` and `C/D` be any two consecutive converging fractions, by Art. 351, `A/B-C/D=+1/(BD)` or `-1/(BD)`; that is, `AD-BC=±1`. Now, if A and B have a common divisor greater than 1, it will divide their multiples AD and BC, and their difference ±1 (Art. 100); or, a quantity greater than 1 is a divisor of 1, which is impossible; hence `A/B` is in its lowest terms. Since the denominators of the convergents continually increase, and their values continually diminish, and since the true value of `a/b` lies between any two consecutive convergents, it is evident that by continuing the series, any degree of approximation to the true value may be obtained.
art: 353 | Square root of a^2+1 | To express `√N`, when `N=a^2+1`, in the form of a continued fraction. `√(a^2+1)=a+(√(a^2+1)-a)=a+1/(√(a^2+1)+a)` (Art. 206) `=a+1/(a+a+(√(a^2+1)-a))=a+1/(2a+1/(2a+1/(2a+...)))`. Example: `√17=√(4^2+1)=4+1/(8+1/(8+1/(8+...)))`; the converging fractions to be added to 4 are `1/8`, `8/65`, `65/528`, etc.
q: The converging fractions to be added to 4 for `√17`: type the first three. {list: 1/8, 8/65, 65/528}
art: 354 | Square root of a^2+b | To convert `√N`, where `N=a^2+b`, into a continued fraction. Example: convert `√19`, or `√(16+3)`, into a continued fraction. `√19=4+1/a`. Hence `a=1/(√19-4)=(√19+4)/3=2+1/b`; `b=3/(√19-2)=3(√19+2)/15=(√19+2)/5=1+1/c`; `c=5/(√19-3)=5(√19+3)/10=(√19+3)/2=3+1/d`. Hence `√19=4+1/(2+1/(1+1/(3+...)))`. Proceeding in the same manner, the successive values of `a`, `b`, `c`, `d`, `e`, and `f` will be found 2, 1, 3, 1, 2, 8. The value of `g` is the same as that of `a`; consequently, the succeeding values will recur in the same order as before. The converging fractions are `4/1`, `9/2`, `13/3`, `48/11`, `61/14`, etc.
q: The converging fractions for `√19`: type the first five. {list: 4, 9/2, 13/3, 48/11, 61/14}
art: 355 | Recurring denominators | To find the value of a continued fraction, when the denominators `q`, `r`, `s`, etc., of the integral fractions recur ad infinitum in a certain order. Example: let `1/(q+1/(r+1/(q+1/(r+...))))=x`, ad infinitum. Then `1/(q+1/(r+x))=x`, or `(r+x)/(qr+qx+1)=x`. From this equation, the value of `x` is easily found.
art: 356 | Exponential equations | To find in the form of a continued fraction the value of `x` which satisfies the equation `a^x=b`. Example: required the value of `x` in the equation `10^x=2`. By substituting 0 and 1 for `x`, it appears that `x>0` and `<1`. Let `x=1/y`; then `10^(1/y)=2`, or `2^y=10`. Since `2^3=8` and `2^4=16`, one of which is less and the other greater than 10, `y>3` and `<4`; let `y=3+1/z`. Then `2^(3+1/z)=10`; or `2^3*2^(1/z)=10`, or `2^(1/z)=10/8=1.25`; therefore `(1.25)^z=2`. Again, it appears that `z>3` and `<4`; let `z=3+1/u`; then `(1.25)^(3+1/u)=(1.25)^3(1.25)^(1/u)=2`, so `(1.25)^(1/u)=2/(1.25)^3=1.024`; therefore `(1.024)^u=1.25`, and by trial `u>9` and `<10`. Hence `x=1/(3+1/(3+1/(9+...)))`. This gives `x=1/3`, too great; `3/10`, too small; `28/93=.30107` nearly, etc.
q: The converging fractions for `x` in `10^x=2`: type the first three. {list: 1/3, 3/10, 28/93}
art: 356 | Exercises | Reduce each of the following to a continued fraction, and find the successive integral and converging fractions. Type the denominators of the integral fractions, then the converging fractions.
q: `130/421`: the denominators of the integral fractions. {list: 3, 4, 5, 6}
q: `130/421`: the converging fractions. {list: 1/3, 4/13, 21/68, 130/421}
q: `130/291`: the denominators of the integral fractions. {list: 2, 4, 5, 6}
q: `130/291`: the converging fractions. {list: 1/2, 4/9, 21/47, 130/291}
q: `157/972`: the denominators of the integral fractions. {list: 6, 5, 4, 3, 2}
q: `157/972`: the converging fractions. {list: 1/6, 5/31, 21/130, 68/421, 157/972}
q: The height of Mt. Etna is 10963 feet, of Vesuvius 3900 feet; required the approximate ratio of the height of the latter to that of the former: the converging fractions to `3900/10963`. {list: 1/2, 1/3, 5/14, 16/45, 37/104, 90/253, 127/357, 3900/10963}
q: The height of Mt. Perdu, the highest of the Pyrenees, is 11283 feet; that of Mt. Hecla is 4900 feet; required the approximate ratio of the height of Hecla to that of Mt. Perdu: the first five converging fractions to `4900/11283`. {list: 1/2, 3/7, 10/23, 33/76, 76/175}
q: When the diameter of a circle is 1, the circumference is found to be greater than 3.1415926, and less than 3.1415927; required the series of fractions converging to the ratio of the diameter to the circumference (the same in both series). {list: 1/3, 7/22, 106/333, 113/355}
art: 356 | Suggestion | In examples of this kind the integral fractions, corresponding to both fractions, should be found, and then the converging fractions calculated from those integral fractions that are the same in both series. The last ratio, `113/355` (or 355 to 113), is true to within less than three ten-millionths of the circumference.
q: Express approximately the ratio of 24 hr. to 5 hr., 48 min., 49 sec., the excess of the solar year above 365 days: the converging fractions to `20929/86400`. {list: 1/4, 7/29, 8/33, 31/128, 39/161, 655/2704, 694/2865, 1349/5569, 20929/86400}
art: 356 | Leap years | Hence, after every 4 years, we must have had 1 intercalary day, as in leap year; after every 29 years, we ought to have had 7 intercalary days; after every 33 years we ought to have had 8 intercalary days. This last was the correction used by the Persian astronomers, who had 7 regular leap years, and then deferred the eighth until the fifth year, instead of having it on the fourth.
q: Find the least fraction with only two figures in each term, approximating to `1947/3359`. (The book's answer is `11/19`; `40/69`, the next converging fraction, also has two figures and is nearer.) {11/19|40/69}
q: The lunar month, calculated on an average of 100 years, is 27.321661 days. Find a series of common fractions approximating nearer and nearer to this quantity: the first four. {list: 27, 82/3, 765/28, 3907/143}
q: Find a series of fractions converging to `√2`: the first five. {list: 1, 3/2, 7/5, 17/12, 41/29}
tf: `√5` is greater than `682/305`, and less than `2889/1292`. {T}
q: If `8^x=32`, find `x`. {5/3 @x: 3x=5}
q: If `3^x=15`, find `x`, to 3 decimal places. {2.465}
== 72 | Continued Fractions, Logarithms, and Interest | Logarithms: definitions, characteristic, products, quotients, powers, roots
art: 357 | Logarithms | This method of computation was invented by Lord Napier, but subsequently much improved by Mr. Henry Briggs, whose system is now universally adopted in numerical computations. The advantage secured in the use of logarithms arises from the application of the law of exponents, by which multiplication, division, involution, and evolution are performed by addition, subtraction, multiplication, and division. Thus, `a^5*a^2=a^7`, `a^7/a^3=a^4`, `(a^3)^5=a^15`, `(a^20)^(1/5)=a^4`. If some number, arbitrarily assumed, be taken as a base, then the Logarithm of any number is the exponent of that power of the base which is equal to that number. Thus, if `a` is the base of a system of logarithms, N, N', N'', etc., any numbers, and `a^2=N`, `a^3=N'`, `a^x=N''`, then 2, 3, and `x` are called the logarithms of N, N', and N'', in the system whose base is `a`.
q: In the system whose base is 3, what is the logarithm of 81? {4 @x: 3^x=81}
art: 357 | Briggs' logarithms | The base of "Briggs' Logarithms," or the common system, is the number 10. Assuming this, we shall have `10^0=1`, hence 0 is the log. of 1; `10^1=10`, so 1 is the log. of 10; `10^2=100`, so 2 is the log. of 100; `10^3=1000`, so 3 is the log. of 1000; `10^4=10000`, so 4 is the log. of 10000; etc. The logarithm of every number between 1 and 10 is, evidently, some number between 0 and 1; that is, a proper fraction. The logarithm of every number between 10 and 100 is some number between 1 and 2: that is, 1 plus a fraction. The logarithm of every number between 100 and 1000 is 2 plus a fraction; and so on.
q: What is the common logarithm of 10000? {4}
art: 358 | The characteristic | The integral part of a logarithm is called the index or characteristic of the logarithm. Since the logarithm of 1 is 0, of 10 is 1, of 100 is 2, of 1000 is 3, and so on; therefore, for any number greater than unity, the Characteristic of the logarithm is one less than the number of integral figures in the given number. Thus, the logarithm of 123 is 2 plus a fraction; the logarithm of 1234 is 3 plus a fraction, and so on.
q: What is the characteristic of the logarithm of 1234? {3}
q: What is the characteristic of the logarithm of 56789.2? {4}
art: 359 | Computing logarithms | The computation of logarithms, in the common system, consists in finding the values of `x` in the equation `10^x=N`, when N is successively 1, 2, 3, etc. One method of finding an approximate value of `x` has been explained in Art. 356, but other methods more expeditious will be given hereafter. The following table contains the logarithms of numbers from 1 to 100 in the common system: 1, 0.000000; 2, 0.301030; 3, 0.477121; 4, 0.602060; 5, 0.698970; 6, 0.778151; 7, 0.845098; 8, 0.903090; 9, 0.954243; 10, 1.000000; 11, 1.041393; 12, 1.079181; 13, 1.113943; 14, 1.146128; 15, 1.176091; 16, 1.204120; 17, 1.230449; 18, 1.255273; 19, 1.278754; 20, 1.301030; 21, 1.322219; 22, 1.342423; 23, 1.361728; 24, 1.380211; 25, 1.397940; 26, 1.414973; 27, 1.431364; 28, 1.447158; 29, 1.462398; 30, 1.477121; 31, 1.491362; 32, 1.505150; 33, 1.518514; 34, 1.531479; 35, 1.544068; 36, 1.556303; 37, 1.568202; 38, 1.579784; 39, 1.591065; 40, 1.602060; 41, 1.612784; 42, 1.623249; 43, 1.633468; 44, 1.643453; 45, 1.653213; 46, 1.662758; 47, 1.672098; 48, 1.681241; 49, 1.690196; 50, 1.698970; 51, 1.707570; 52, 1.716003; 53, 1.724276; 54, 1.732394; 55, 1.740363; 56, 1.748188; 57, 1.755875; 58, 1.763428; 59, 1.770852; 60, 1.778151; 61, 1.785330; 62, 1.792392; 63, 1.799341; 64, 1.806180; 65, 1.812913; 66, 1.819544; 67, 1.826075; 68, 1.832509; 69, 1.838849; 70, 1.845098; 71, 1.851258; 72, 1.857333; 73, 1.863323; 74, 1.869232; 75, 1.875061; 76, 1.880814; 77, 1.886491; 78, 1.892095; 79, 1.897627; 80, 1.903090; 81, 1.908485; 82, 1.913814; 83, 1.919078; 84, 1.924279; 85, 1.929419; 86, 1.934498; 87, 1.939519; 88, 1.944483; 89, 1.949390; 90, 1.954243; 91, 1.959041; 92, 1.963788; 93, 1.968483; 94, 1.973128; 95, 1.977724; 96, 1.982271; 97, 1.986772; 98, 1.991226; 99, 1.995635; 100, 2.000000. In works on Trigonometry, Surveying, etc., where a set of logarithmic tables is given, the characteristic is usually omitted, and must be supplied by the rule given in Art. 358.
q: From the table, what is the logarithm of 9? {0.954243}
art: 360 | Products | General Properties of Logarithms. Let N and N' be any two numbers, `x` and `x'` their respective logarithms, and `a` the base of the system; or, take any two numbers in the common system. Then (Art. 357), `10^5=100000` and `a^x=N` (1); `10^2=100` and `a^(x')=N'` (2). Multiplying equations (1) and (2) together, we find `10^7=10000000` and `a^(x+x')=NN'`. But, by the definition of logarithms, 7 and `x+x'` are the logarithms of 10000000 and of NN' respectively. Hence, the sum of the logarithms of two numbers is equal to the logarithm of their product. Similarly, the sum of the logarithms of three or more factors is equal to the logarithm of their product. Hence, to multiply two or more numbers by means of logarithms, the Rule: add together the logarithms of the numbers for the logarithm of the product.
art: 361 | Quotients | Taking the same equations (Art. 360), and dividing equation (1) by equation (2), we find `10^3=1000` and `a^(x-x')=N/N'`. But, by the definition of logarithms, 3 and `x-x'` are the logarithms of 1000 and of N/N'. Hence, to divide by means of logarithms, the Rule: from the logarithm of the dividend subtract the logarithm of the divisor for the logarithm of the quotient. Example 1: find the product of 9 and 6 by means of logarithms. By the table, the log. of 9 is 0.954243, the log. of 6 is 0.778151; the sum of these logarithms is 1.732394, and the number corresponding in the table is 54. Example 2: find the quotient of 63 divided by 9. The log. of 63 is 1.799341, the log. of 9 is 0.954243; the difference is 0.845098, and the number corresponding to this log. is 7.
q: Find the product of 9 and 6 by means of logarithms: the sum of the logarithms {1.732394 @= 0.954243+0.778151} and the product {54}
q: Find the quotient of 63 divided by 9: the difference of the logarithms {0.845098 @= 1.799341-0.954243} and the quotient {7}
art: 361 | Exercises | By means of logarithms, using the table above:
q: Find the product of 7 and 8: the logarithm of the product {1.748188 @= 0.845098+0.903090} and the product {56}
q: Find the continued product of 2, 3, and 7: the logarithm {1.623249 @= 0.301030+0.477121+0.845098} and the product {42}
q: Find the quotient of 85 divided by 17: the logarithm {0.69897 @= 1.929419-1.230449} and the quotient {5}
q: Find the quotient of 91 divided by 13: the logarithm {0.845098 @= 1.959041-1.113943} and the quotient {7}
art: 362 | Powers | Resuming equation (1) (Art. 360), `10^2=100` and `a^x=N`. Raising both sides to the 3d and to the mth power, we find `10^6=1000000` and `a^(mx)=N^m`. But (Art. 357), 6 and `mx` are the logarithms of 1000000 and of `N^m` respectively. Hence, to raise a number to any power by means of logarithms, the Rule: multiply the logarithm of the given number by the exponent of the required power for the logarithm of the power of the number.
art: 363 | Roots | Take the same equation `10^6=1000000` and `a^x=N`. Extracting the 3d and nth root of both sides, we have `10^2=100` and `a^(x/n)=N^(1/n)`. But (Art. 357), 2 and `x/n` are the logarithms of 100 and of `N^(1/n)` respectively. Hence, to extract any root of a number, the Rule: divide the logarithm of the given number by the index of the required root for the logarithm of the root of the number. Example 1: find the third power of 4 by means of logarithms. The logarithm of 4 is 0.602060; multiply by the exponent 3: the product is 1.806180, which is the logarithm of 64. Example 2: extract the fifth root of 32. The logarithm of 32 is 1.505150; dividing by the index 5, the quotient is 0.301030, which is the logarithm of 2, the required root.
q: Find the third power of 4 by means of logarithms: the logarithm {1.80618 @= 3*0.602060} and the power {64}
q: Extract the fifth root of 32 by means of logarithms: the logarithm {0.30103 @= 1.505150/5} and the root {2}
art: 363 | Exercises | Solve the following examples by means of logarithms. Other examples may be taken from arithmetic. It is, however, the province of algebra to explain the principles of logarithms, and the methods of computing the tables, rather than their use in actual calculations.
q: Find the square of 7: the logarithm {1.690196 @= 2*0.845098} and the square {49}
q: Find the fourth power of 3: the logarithm {1.908484 @= 4*0.477121} and the power {81}
q: Extract the cube root of 27: the logarithm (to 6 places) {0.477121} and the root {3}
q: Extract the sixth root of 64: the logarithm {0.30103 @= 1.806180/6} and the root {2}
== 73 | Continued Fractions, Logarithms, and Interest | Logarithms of decimals; properties; computing logarithms; the logarithmic series
art: 364 | Logarithms of fractions | By means of negative exponents, we can also express the logarithms of fractions less than 1. Thus, in the common system, since `10^(-1)=1/10=.1`, therefore -1 is the log. of .1; `10^(-2)=1/100=.01`, so -2 is the log. of .01; `10^(-3)=1/1000=.001`, so -3 is the log. of .001; `10^(-4)=1/10000=.0001`, so -4 is the log. of .0001; etc. The logarithm of any fraction between one and one-tenth, between one-tenth and one-hundredth, etc., may be expressed thus: log. `7/10` = log. `(1/10*7)` = log. `1/10` + log. 7 = -1 + log. 7; log. `3/100` = log. `(1/100*3)` = -2 + log. 3. It is customary not to perform the subtraction indicated, but to unite the logarithm of the numerator to the negative characteristic. Thus, log. 0.7 = -1 + log. 7 = -1.845098, written with the bar over the 1 to show that only the 1 is negative; log. 0.03 = -2 + log. 3 = -2.477121 (bar over the 2); log. 0.004 = -3 + log. 4 = -3.602060 (bar over the 3). Hence, the characteristic of the logarithm of a decimal fraction is a negative number, and is numerically equal to the distance of the first significant figure from the decimal point.
q: What is the logarithm of .001? {$ -3}
q: What is the characteristic of the logarithm of 0.03? {$ -2}
q: Log. 0.7 = -1 + log. 7. Performing the subtraction, what is its value? {$ -0.154902 @ -1+0.845098}
art: 365 | General Rule | On the principle above explained, we may deduce the following General Rule for finding from the Tables the Logarithms of any Decimal Fraction. 1. Find the logarithm of the figures composing the decimal as if the fraction were a whole number. 2. Prefix the negative characteristic according to the rule given in Art. 364.
q: What is the characteristic of the logarithm of .0004? {$ -4}
art: 366 | Exercises on the properties | The following examples, illustrative of the principles already explained, will afford a useful exercise: 1. Log. `(a*b*c*d)` = log. `a` + log. `b` + log. `c` + log. `d`. 2. Log. `((abc)/(de))` = log. `a` + log. `b` + log. `c` - log. `d` - log. `e`. 3. Log. `(a^m*b^n*c^p)` = `m` log. `a` + `n` log. `b` + `p` log. `c`. 4. Log. `((a^m*b^n)/c^p)` = `m` log. `a` + `n` log. `b` - `p` log. `c`. 5. Log. `(a^2-x^2)` = log. `[(a+x)(a-x)]` = log. `(a+x)` + log. `(a-x)`. 6. Log. `√(a^2-x^2)` = `1/2` log. `(a+x)` + `1/2` log. `(a-x)`. 7. Log. `(a^3*∜(a^3))` = `3 3/4` log. `a`. 8. Log. `(√(a^2-x^2)/(a+x)^2)` = `1/2`[log. `(a-x)` - 3 log. `(a+x)`].
q: Log. `(a^3*∜(a^3))` = how many times log. `a`? {3 3/4}
tf: Log. `(a^2-x^2)` = log. `(a+x)` + log. `(a-x)`. {T}
tf: Log. `((abc)/(de))` = log. `a` + log. `b` + log. `c` + log. `d` + log. `e`. {F}
art: 367 | Log of the base, and of 1 | Let us resume the equation `a^x=N`. 1st. If we make `x=1`, we have `a^1=N=a`; hence, log. `a=1`; that is, whatever be the base of the system, its logarithm in that system is 1. 2d. If we make `x=0`, in the equation `a^x=N`, we have `a^0=N=1`; hence, log. 1 = 0; that is, in any system the logarithm of 1 is 0.
q: In the system whose base is 7, what is the logarithm of 7? {1}
art: 368 | Log of 0 | In the equation `a^x=N`, consider `a>1`, as in the common and the Naperian systems, and `x` negative; we then have `a^(-x)=1/a^x=N`, and `1/a^∞=a^(-∞)=0`, or log. 0 = minus infinity. Hence, the logarithm of 0, in a system whose base is greater than 1, is an infinite number and negative. In a similar manner, it may be shown that in a system whose base is less than 1, the logarithm of 0 is infinite and positive.
art: 369 | Negative numbers | As the positive and negative characteristics are taken to designate whole numbers and fractions, there remains no method of designating negative quantities by logarithms; or, as N, in each of the equations `a^x=N` and `a^(-x)=N`, is positive, negative numbers have no real logarithms.
tf: Negative numbers have no real logarithms. {T}
art: 370 | Only the primes | Computation of Logarithms. Before proceeding to explain the methods of computing logarithms, we may observe that it is only necessary to compute the logarithms of the prime numbers. For, the logarithm of every composite number is equal to the sum of the logarithms of its factors. Hence, the logarithms of 1, 2, 3, 5, 7, etc., being known, we can find those of 4, 6, 8, etc. Thus, `4=2^2`, hence log. 4 = 2 log. 2 (Art. 362); `6=2*3`, so log. 6 = log. 2 + log. 3; `8=2^3`, so log. 8 = 3 log. 2; `9=3^2`, so log. 9 = 2 log. 3; `10=2*5`, so log. 10 = log. 2 + log. 5.
q: Suppose the logarithms of the numbers 2, 3, 5, and 7 to be known: log. 2 = 0.301030 and log. 3 = 0.477121. Find log. 12 = 2 log. 2 + log. 3. {1.079181 @= 2*0.301030+0.477121}
q: Of what numbers between 30 and 100 may the logarithms be found from those of 2, 3, 5, and 7? Of how many different numbers? {23} (from 32 to 98: those with no prime factor but 2, 3, 5, and 7)
art: 371 | Briggs' system | In the common system, the equation `a^x=N` (Art. 357) becomes `10^x=N`. If we multiply both sides by 10, we have `10^x*10=10^(x+1)=10N`; also `10^x*100=10^x*10^2=10^(x+2)=100N`. Hence, in the common system, the logarithm of any number will become the logarithm of 10 times, 100 times, etc., that number, by increasing the characteristic by 1, 2, etc. From this results the advantage of Briggs' system. Thus, the log. of 3 is 0.477121, of 30 is 1.477121, of 300 is 2.477121. Also, the log. of .2583 is -1.412124 (bar over the 1), of 2.583 is 0.412124, of 25.83 is 1.412124.
q: The log. of 2.583 is 0.412124. What is the log. of 25.83? {1.412124}
q: The log. of 3 is 0.477121. What is the log. of 300? {2.477121}
art: 372 | Means | If we compare the different powers of 10 with their logarithms in the common system, we have the numbers 1, 10, 100, 1000, 10000, and the logarithms 0, 1, 2, 3, 4, and so on. Hence, while the numbers are in geometrical progression, their logarithms are in arithmetical progression. Therefore, if we take a geometrical mean between two numbers, and an arithmetical mean between their logarithms, the latter number will be the logarithm of the former. Thus, the geometrical mean between 10 and 1000 is `√(10*1000)=100`, and the arithmetical mean between their logarithms, 1 and 3, is `(1+3)/2=2`. In general, if `a^x=N` and `a^(x')=N'`, then log. of `√(NN')` is `(x+x')/2`. By means of this principle, the common, or Briggean, system of logarithms was originally calculated.
art: 372 | The log of 5 | Let it be required to calculate the logarithm of 5. First: the proposed number lies between 1 and 10; hence its logarithm will lie between 0 and 1. The geometrical mean is `√(1*10)=3.162277`; the arithmetical mean is `(0+1)/2=0.5`. Hence, the log. of 3.162277 is 0.5. Secondly: take the numbers 3.162277 and 10, and their logarithms .5 and 1; we find the log. of 5.623413 is 0.75. Thirdly: take the numbers 3.162277 and 5.623413, and their logarithms 0.5 and 0.75; we find the log. of 4.216964 is 0.625. Fourthly: take the numbers 4.216964 and 5.623413, and their logarithms 0.625 and 0.75; we find the log. of 4.869674 is 0.6875. By continuing this process, always taking the two numbers nearest to 5, one of which is less and the other greater, after twenty-two operations, we obtain the number 5.000000+, and its corresponding logarithm 0.698970+. Having the log. of 5 we readily find that of 2, or `10/5` (Art. 361). To find the log. of 3, take the numbers 2 and 3.162277, and their logarithms, and proceed as in finding the log. of 5.
q: The log. of 3.162277 is 0.5 and of 10 is 1. Of what number is 0.75 the logarithm? {5.623413}
q: Having the log. of 5, 0.698970, find the log. of 2, or `10/5`. {0.30103 @= 1-0.698970}
art: 373 | Logarithmic Series | The most convenient method of computing logarithms is by means of Series. Let `x` be a number whose logarithm is to be expressed in a series, and let us apply the method of Indeterminate Coefficients (Art. 314). If we assume log. `x` = `A+Bx+Cx^2+Dx^3+...`, and make `x=0`, we have log. 0 = A = minus infinity (Art. 368), which is absurd. If we assume log. `x` = `Ax+Bx^2+Cx^3+...`, and make `x=0`, we have log. 0 = 0; that is, minus infinity = 0, which is also absurd. Hence, it is impossible to develop the logarithm of a number in powers of that number. But if we assume log. `(1+x)` = `Ax+Bx^2+Cx^3+Dx^4+...` (1), and make `x=0`, we have log. 1 = 0, which is correct (Art. 367). In like manner, assume log. `(1+z)` = `Az+Bz^2+Cz^3+Dz^4+...` (2). Subtracting, log. `(1+x)` - log. `(1+z)` = `A(x-z)+B(x^2-z^2)+C(x^3-z^3)+...` (3).
art: 373 | Finding the coefficients | The second member of this equation is divisible by `x-z` (Art. 83); let us reduce the first member to a form in which it shall also be divisible by the same factor. By Art. 361, log. `(1+x)` - log. `(1+z)` = log. `((1+x)/(1+z))` = log. `(1+(x-z)/(1+z))`. Now, regarding `(x-z)/(1+z)` as a single quantity, we may assume this log. = `A(x-z)/(1+z)+B((x-z)/(1+z))^2+C((x-z)/(1+z))^3+...`. Substituting this in equation (3), and dividing both sides by `x-z`, we obtain `A/(1+z)+B(x-z)/(1+z)^2+C(x-z)^2/(1+z)^3+...=A+B(x+z)+C(x^2+xz+z^2)+...`. Since this equation is true for all values of `x` and `z`, it must be true when `x=z`. Making this supposition, `A/(1+x)=A+2Bx+3Cx^2+4Dx^3+5Ex^4+...`; or, performing the division of 1 by `1+x`, `A(1-x+x^2-x^3+x^4-...)=A+2Bx+3Cx^2+4Dx^3+...`. Equating the coefficients of the like powers of `x` (Art. 314), A = A, B = `-A/2`, C = `A/3`, D = `-A/4`. The law of this series is obvious, the coefficient of the nth term being `A/n`, plus or minus according as `n` is odd or even. Hence log. `(1+x)` = `Ax-(A/2)x^2+(A/3)x^3-(A/4)x^4+...` `=A(x-x^2/2+x^3/3-x^4/4+x^5/5-x^6/6+...)` (4).
q: In log. `(1+x)=Ax+Bx^2+Cx^3+Dx^4+...`, D is how many times A? {$ -1/4}
art: 373 | The modulus | There still remains one quantity, A, undetermined. This is as it should be, for the logarithm of a given number is indeterminate unless the base of the system be given. The value of A depends on the base of the system, so that when A is given, the base may be determined; or, when the base is known, A may be determined. If we denote the series in the parenthesis in equation (4) by `x'`, we may write log. `(1+x)` = `Ax'`. Hence, the logarithm of a number consists of two factors, one of which depends on the number itself, and the other on the base of the system in which the logarithm is taken. That factor which depends on the base is called the Modulus of the system of logarithms. Lord Napier, the inventor of logarithms, assumed the modulus equal to unity, and the system resulting from such a modulus is called the Naperian, or Hyperbolic system. Designating the logarithms in this system by log', we have log'. `(1+x)` = `x/1-x^2/2+x^3/3-x^4/4+...` (5). For all values of `x` above `x=1` the series (5) diverges, and is therefore inapplicable. Thus, if `x=0`, we find log'. 1 = 0, as in Art. 367. If we make `x=1`, we have log'. 2 = `1-1/2+1/3-1/4+1/5-...`
q: The Naperian log'. `(1+x)` as a series: its first 4 terms. {list: x, -x^2/2, x^3/3, -x^4/4}
tf: Lord Napier assumed the modulus of his system of logarithms equal to unity. {T}
== 74 | Continued Fractions, Logarithms, and Interest | Naperian and common logarithms by series; the modulus; the base e
art: 374 | A faster series | The preceding series converges so slowly that it would be necessary to take a great number of terms to obtain a near approximation. But we may obtain a more converging series in the following manner. Resuming equation (5), log'. `(1+x)=x/1-x^2/2+x^3/3-x^4/4+x^5/5-...` (5). Substituting `-x` for `x` in this equation, we obtain log'. `(1-x)=-x/1-x^2/2-x^3/3-x^4/4-x^5/5-...` (6). Subtracting equation (6) from (5), and observing that log'. `(1+x)` - log'. `(1-x)` = log'. `((1+x)/(1-x))`, we have log'. `((1+x)/(1-x))=2(x/1+x^3/3+x^5/5+x^7/7+x^9/9+...)`. Since `(1+x)/(1-x)=1+(2x)/(1-x)`, let `(1+x)/(1-x)=1+1/z`, so `x=1/(2z+1)`, and log'. `((1+x)/(1-x))` = log'. `(1+1/z)` = log'. `((z+1)/z)` = log'. `(z+1)` - log'. `z`. By substitution, the preceding series becomes log'. `(z+1)` = log'. `z+2(1/(2z+1)+1/(3(2z+1)^3)+1/(5(2z+1)^5)+...)` (7).
q: In series (7), when `z=1`, what is `2z+1`? {3}
art: 375 | Naperian logarithms | By means of this series, the Naperian logarithm of any number may be computed, when the logarithm of the preceding number is known. But the log'. of 1 is 0 (Art. 367); therefore, making `z=1`, 2, 4, 6, etc., we obtain the following Naperian, or Hyperbolic Logarithms. Log'. 2 = log'. 1 + `2(1/3+1/(3*3^3)+1/(5*3^5)+1/(7*3^7)+...)` = 0.693147. Log'. 3 = log'. 2 + `2(1/5+1/(3*5^3)+1/(5*5^5)+1/(7*5^7)+...)` = 1.098612. Log'. 4 = 2 log'. 2 = 1.386294. Log'. 5 = log'. 4 + `2(1/9+1/(3*9^3)+1/(5*9^5)+1/(7*9^7)+...)` = 1.609438. Log'. 6 = log'. 2 + log'. 3 = 1.791759. Log'. 7 = log'. 6 + `2(1/13+1/(3*13^3)+1/(5*13^5)+...)` = 1.945910. Log'. 8 = 3 log'. 2, or log'. 2 + log'. 4, = 2.079442. Log'. 9 = 2 log'. 3 = 2.197225. Log'. 10 = log'. 2 + log'. 5 = 2.302585. In this manner the Naperian logarithms of all numbers may be computed. When the numbers are large, their logarithms are computed more easily than in the case of small numbers. Thus, in calculating the logarithm of 101, the first term of the series gives the result true to seven places of decimals.
q: Log'. 2 = 0.693147. Find log'. 4 = 2 log'. 2. {1.386294 @= 2*0.693147}
q: Log'. 2 = 0.693147 and log'. 3 = 1.098612. Find log'. 6. {1.791759 @= 0.693147+1.098612}
q: Log'. 2 = 0.693147 and log'. 5 = 1.609438. Find log'. 10. {2.302585 @= 0.693147+1.609438}
q: Log'. 3 = 1.098612. Find log'. 9. {2.197224|2.197225}
art: 376 | Common from Naperian | To explain the method of computing common logarithms from Naperian logarithms. We have already found (Art. 373, Equation 4) log. `(1+x)=A(x/1-x^2/2+x^3/3-x^4/4+x^5/5-x^6/6+...)`. Denoting the Naperian logarithm by an accent, we have log'. `(1+x)=A'(x/1-x^2/2+x^3/3-...)`. Since the series in the second members are the same, we have log. `(1+x)` : log'. `(1+x)` :: A : A'. Therefore, the logarithms of the same number, in two different systems, are to each other as the moduli of those systems. But in Napier's system the modulus A' = 1. Therefore log. `(1+x)` = A log'. `(1+x)`. Hence, to find the common logarithm of any number, multiply the Naperian logarithm of the number by the modulus of the common system. It now remains to find the modulus of the common system. From the equation log. `(1+x)` = A log'. `(1+x)`, we find A = log. `(1+x)` divided by log'. `(1+x)`. Hence, the modulus of the common system is equal to the common log. of any number divided by the Naperian log. of the same number. But the common logarithm of 10 is 1, and we have calculated the Naperian logarithm of 10 (Art. 375); therefore A = `1/2.302585` = .4342944, which is the modulus of the common system. Hence, if N is any number, we have Com. log. N = .4342944 times Nap. log. N. On account of the importance of the number A, its value has been calculated with great exactness. It is A = .43429448190325182765.
q: The modulus of the common system, `1/2.302585`, to 7 decimal places. {0.4342944|0.4342945}
q: Log'. 2 = 0.693147. Find the common log. of 2 = .4342944 times log'. 2, to 6 decimal places. {0.30103}
art: 377 | Common logarithms directly | To calculate the common logarithms of numbers directly. Having found the modulus of the common system, if we multiply both members of equation (7), Art. 374, by A, and recollect that A times Nap. log. N = com. log. N, the series becomes log. `(z+1)` = log. `z+2A(1/(2z+1)+1/(3(2z+1)^3)+1/(5(2z+1)^5)+...)`. Or, by changing `z` into P, for the sake of distinction, and putting B, C, D, etc., to represent the terms immediately preceding those in which they are used, log. (P+1) = log. P + 2A/(2P+1) + B/(3(2P+1)^2) + 3C/(5(2P+1)^2) + 5D/(7(2P+1)^2) + 7E/(9(2P+1)^2) + 9F/(11(2P+1)^2) + etc. We shall now exemplify its use in finding the logarithm of 2. Here P = 1, and 2P+1 = 3. Log. P = log. 1 = .00000000; 2A/(2P+1) = .86858896/3 = .28952965 (B); B/(3(2P+1)^2) = .28952965/(3*9) = .01072332 (C); 3C/(5*9) = .00071489 (D); 5D/(7*9) = .00005674 (E); 7E/(9*9) = .00000490 (F); 9F/(11*9) = .00000045 (G); 11G/(13*9) = .00000004 (H). Therefore, the common logarithm of 2 = .30102999.
q: In finding the common log. of 2, the first term 2A/3 = .86858896/3, to 8 places. {0.28952965}
art: 377 | Exercise | In a similar manner let the pupil calculate the common logarithms of 3, 5, 7, and 11. For the results to 6 places of decimals, see the Table, Art. 359.
q: The common logarithm of 3, to 6 places. {0.477121}
q: The common logarithm of 5, to 6 places. {0.69897}
q: The common logarithm of 7, to 6 places. {0.845098}
q: The common logarithm of 11, to 6 places. {1.041393}
art: 378 | The base e | To find the base of the Naperian system of logarithms. If we designate the base by `e`, we have (Art. 376) log. `e` : log'. `e` :: A : A'. But A = .4342944, A' = 1, and log'. `e` = 1 (Art. 367); hence log. `e` : 1 :: .4342944 : 1; whence log. `e` = .4342944. Taking the number of which the logarithm is .4342944, from the table of common logarithms, we find `e` = 2.71828182. We thus see that in both the common and the Naperian systems of logarithms, the base is greater than unity. Napier's logarithms are used in the Calculus, but not in the common operations of multiplication, division, etc.
q: The base `e` of the Naperian system, to 5 decimal places. {2.71828}
tf: In both the common and the Naperian systems of logarithms, the base is greater than unity. {T}
== 75 | Continued Fractions, Logarithms, and Interest | Single and double position; exponential equations
art: 379 | Theorems | The student may prove the following theorems: 1. No system of logarithms can have a negative base, or have unity for its base. 2. The logarithms of the same numbers in two different systems have the same ratio to each other. 3. The difference of the logarithms of two consecutive numbers is less as the numbers themselves are greater.
tf: A system of logarithms can have 1 for its base. {F}
tf: The difference of the logarithms of two consecutive numbers is less as the numbers themselves are greater. {T}
art: 380 | Single Position | This subject is introduced in connection with that of logarithms, because the rule for Double Position is applied to the solution of exponential equations. The Rule of Single Position is applied to the solution of questions which give rise to an equation of the form `ax=m` (1). If we assume `x'` to be the value of `x`, and denote by `m'` the result of the substitution of `x'` for `x`, we have `ax'=m'` (2). Comparing equations (1) and (2), we have `m':m::ax':ax::x':x`; that is, as the result of the supposition is to the result in the question, so is the supposed number to the number required.
q: What is the number, whose third, fourth, and sixth part being added, the sum will be 45? {60 @x: x/3+x/4+x/6=45}
art: 381 | Double Position | In Double Position, the result, although it is dependent on the unknown quantity, does not increase or diminish in the same ratio with it. The class of questions to which it is particularly applicable gives rise to an equation of the form `ax+b=m` (1). If we suppose `x'` and `x''` to be near values of `x`, and `e'` and `e''` to be the errors, or the differences between the true result and the results obtained by substituting `x'` and `x''` for `x`, we have `ax'+b=m+e'` (2) and `ax''+b=m+e''` (3). If we subtract equation (1) from (2), and (3) from (2), we have `a(x'-x)=e'` (4) and `a(x'-x'')=e'-e''` (5). From these equations, we easily obtain `(x'-x'')/(e'-e'')=(x'-x)/e'` (6). By subtracting equation (1) from (3), we also find `a(x''-x)=e''`, and thence `(x'-x'')/(e'-e'')=(x''-x)/e''` (7). Hence (Art. 263), the difference of the errors is to the difference of the two assumed numbers, as the error of either result is to the difference between the true result and the corresponding assumed number. When the question gives rise to an equation of the form `ax+b=m`, this rule gives a result absolutely correct; but when the equation is of a less simple form, as in exponential equations (Art. 383), the result obtained is only approximately true. Corollary: the common arithmetical rule is deduced from the following value of `x`, found either from equation (6) or (7): `x=(e'x''-e''x')/(e'-e'')`.
q: For `3x+4=25`: with `x'=5`, `3x'+4` is 19, so `e'=-6`; with `x''=9`, `3x''+4` is 31, so `e''=6`. Find `x=(e'x''-e''x')/(e'-e'')`. {7 @x: 3x+4=25}
art: 382 | Exponential Equations | An Exponential Equation is an equation in which the unknown quantity appears in the form of an exponent or index; as `a^x=b`, `x^x=a`, `a^(bx)=c`, etc. Such equations are most easily solved by means of logarithms. Thus, in the equation `a^x=b`, we have (Art. 362) `x` log. `a` = log. `b`; or `x` = log. `b` divided by log. `a`. Example 1: what is the value of `x` in the equation `2^x=64`? Here, `x` log. 2 = log. 64; whence `x` = log. 64 / log. 2 = 1.806180/.301030 = 6.
q: What is the value of `x` in the equation `2^x=64`? {6 @x: 2^x=64}
art: 383 | x to the x power | If the equation is of the form `x^x=a`, the value of `x` may be found by Double Position, as follows. Find by trial two numbers nearly equal to the value of `x`; substitute them for `x` in the given equation, and note the results. Then, from (7), we have (Art. 263) the proportion: as the difference of the errors is to the difference of the two assumed numbers, so is the error of either result to the correction to be applied to the corresponding assumed number. Example: given `x^x=100`, to find the value of `x`. The value of `x` is evidently between 3 and 4, since `3^3=27` and `4^4=256`; hence, taking the logarithms of both sides, `x` log. `x` = log. 100 = 2. By trial, we readily find that `x` is greater than 3.5, and less than 3.6; then let us assume 3.5 and 3.6 for the two numbers. First supposition: `x=3.5`; log. `x` = .544068; multiplying by 3.5, `x` log. `x` = 1.904238; true no. 2.000000; error -.095762. Second supposition: `x=3.6`; log. `x` = .556303; multiplying by 3.6, `x` log. `x` = 2.002690; true no. 2.000000; error +.002690. Diff. results : diff. assumed nos. :: error 2d result : its correction; that is, .098452 : 0.1 :: .002690 : .00273. Hence `3.6-.00273=3.59727` nearly. By trial we find that 3.5972 is less, and 3.5973 greater than the true value; and by repeating the operation with these numbers, we would find `x=3.5972849` nearly.
q: Given `x^x=100`, find `x` to 4 decimal places. {3.5973|3.5972}
art: 383 | Exercises | Solve by logarithms and by Double Position.
q: Given `20^x=100`, find `x` to 5 decimal places. {1.53724}
q: Given `x^x=5`, find `x` to 6 decimal places. {2.129372}
q: How many places of figures will there be in the number expressing the 64th power of 2? {20}
chk: x=19.26592 | x=64*0.301030
art: 383 | Letter exercises | 5. Given `a^(bx+d)=c`, to find `x`. Answer: `x` = (log. `c` - `d` log. `a`) divided by (`b` log. `a`). 6. Given `a^(mx)b^(nx)=c`, to find `x`. Answer: `x` = log. `c` divided by (`m` log. `a` + `n` log. `b`). 7. Given `x+y=a`, and `m^(x-y)=n`, to find `x` and `y`. Answer: `x` = `1/2`(`a` + log. `n` / log. `m`), `y` = `1/2`(`a` - log. `n` / log. `m`). 8. Given `2^x*3^z=2000`, and `3z=5x`, to find the values of `x` and `z`. Answer: `x` = 3(3 + log. 2) divided by (3 log. 2 + 5 log. 3), `z` = 5(3 + log. 2) divided by (3 log. 2 + 5 log. 3).
tf: If `a^(bx+d)=c`, then `x` = (log. `c` - `d` log. `a`) divided by (`b` log. `a`). {T}
q: Given `a^(2x)-2a^x=8`, to find `x`. This is a quadratic form, therefore complete the square: `a^x` is {4 @x: x^2-2x=8} (the other root, -2, gives no real `x`), so `x` = 2 log. 2 divided by log. `a`.
q: Given `2^(2x)+2^x=12`, find `x` to 5 decimal places. First `2^x` is {3 @x: x^2+x=12}; then `x` = log. 3 / log. 2 = {1.58496}
art: 383 | More letter exercises | 11. Given `a^x+1/a^x=b`, to find `x`. Answer: `x` = log. `(1/2)(b±√(b^2-4))` divided by log. `a`. 13. Given `(a^2-b^2)^(2(x-1))=(a-b)^(2x)`, to find `x`. Answer: `x` = 1 + log. `(a-b)` / log. `(a+b)`. 14. Given `(a^4-2a^2b^2+b^4)^(x-1)=(a-b)^(2x)(a+b)^(-2)`, to find `x`. Answer: `x` = log. `(a-b)` / log. `(a+b)`. 15. Given `x^y=y^x`, and `x^p=y^q`, to find `x` and `y`. Answer: `x=(p/q)^(q/(p-q))`, `y=(p/q)^(p/(p-q))`.
q: Given `x^y=y^x`, and `x^3=y^2`, to find `x` {2 1/4} and `y` {3 3/8}.
chk: x=9/4, y=27/8 | x^3=y^2 | x^(1/2)=3/2
q: Given `3^(x^2-4x+5)=1200`, to find `x` to 2 decimal places. The positive root: {4.33|4.34}
q: And the other root is minus what number? {0.33|0.34}
== 76 | Continued Fractions, Logarithms, and Interest | Interest, population, discount, and annuities
art: 384 | Interest and Annuities | The solution of all questions in Interest and Annuities may be simplified, and also generalized, by means of algebraical formulae; but certain problems in Compound Interest and Annuities may be very much abridged by the use of logarithms. Let P = the principal, or sum at interest in dollars; `r` = the interest of 1 dollar for one year; `t` = the time in years that P draws interest; A = the amount, at the end of `t` years. (The book writes these with capitals P, A, R; the questions below use numbers.)
art: 385 | Simple Interest | Since `tr` represents the interest of 1 dollar for `t` years, and P`tr` the interest of P dollars for `t` years, therefore A = P + P`tr` = P`(1+tr)` (1). From this equation, any three of the quantities P, `r`, `t`, A, being given, the fourth may be found. Thus, P = A/`(1+tr)`, `t` = (A-P)/(P`r`), `r` = (A-P)/(P`t`). Examples may be given from any treatise on arithmetic.
q: What is the amount of $200 for 3 years at 6 per cent. simple interest? $ {236 @= 200(1+3*0.06)}
art: 386 | Compound Interest | Let R = `1+r`, the amount of 1 dollar for one year; then R will be the principal for the second year; and since the amount, in each case, is proportional to the principal for the same time, therefore 1 : R :: R : the amount of 1 dollar in 2 years = R squared; and in like manner, R to the `t` power is the amount of 1 dollar in `t` years. The amount of P dollars will be P times the amount of 1 dollar. Hence A = P`(1+r)^t`; whence log. A = log. P + `t` log. `(1+r)` (1); log. P = log. A - `t` log. `(1+r)` (2); `t` = (log. A - log. P) / log. `(1+r)` (3); log. `(1+r)` = (log. A - log. P) / `t` (4). Corollary 1: the interest = A - P = P(R to the `t` power - 1). Corollary 2: if the interest is paid half-yearly, `t` becomes `2t`, and `r` becomes `r/2`; hence A = P`(1+r/2)^(2t)` (5). If paid quarterly, A = P`(1+r/4)^(4t)` (6). Corollary 3: from the equation A = P times R to the `t` power, we can readily find the time in which any sum, at compound interest, will amount to twice, thrice, or `m` times itself. Thus, if A = 2P, then R to the `t` power = 2, and `t` = log. 2 / log. R; if A = 3P, `t` = log. 3 / log. R; if A = `m`P, `t` = log. `m` / log. R.
q: Find the time in which any sum will double itself at 10 per cent. compound interest. (Here `r=.10`, R = 1.10, and `t` = log. 2 / log. R = .301030/.041393.) Years, to 3 decimal places: {7.272|7.273}
q: What is the amount of $1 for 100 years at 6 per cent. per annum, compound interest? (The book, working with 6-place logarithms, gets $339.28; the exact amount is $339.30.) $ {339.30|339.28|339.3}
q: How many figures will express the amount of $1 for 1000 years, at 6 per cent. per annum, compound interest? {26}
chk: x=25.3059 | x=1000*0.0253059
q: In how many years will any sum double itself at compound interest at 5 per cent. per annum? Years, to 4 decimal places: {14.2066|14.2067}
q: At 6 per cent.? {11.8956|11.8957}
q: At 7 per cent.? {10.2447|10.2448}
q: At 8 per cent.? {9.0064|9.0065}
q: In what time, at compound interest, reckoning 5 per cent. per annum, will $10 amount to $100? Years, to 2 decimal places: {47.19}
art: 386 | A letter exercise | If P dollars, at compound interest, amount to M dollars in `t` years, what sum will amount to P dollars at the end of `t` years? Since the amount is proportional to the principal, the sum is P times P divided by M, or P squared over M.
q: If $100, at compound interest, amounts to $200 in `t` years, what sum will amount to $100 at the end of `t` years? $ {50}
art: 387 | Population | The increase of the population of a country may be computed on the same principles as compound interest. Example: the population of the United States in 1790 was 3900000, and in 1840, 17000000. Required the average rate of increase for each 10 years. Here, there are 5 periods of 10 years each. Hence, by comparing the quantities given with those in equation (4), Art. 386, we have A = 17000000, P = 3900000, and `t=5`. Log. A = 7.230449; log. P = 6.591065; the difference is 0.639384; divide by 5: log. `(1+r)` = 0.127877, so `1+r` = 1.342. Hence `r=1.342-1=.342`, or `34 1/5` per cent.
q: The population of the United States in 1790 was 3900000, and in 1840, 17000000. Required the average rate of increase for each 10 years, per cent., to 1 decimal place. {34.2}
q: The population of England in 1820 was 11000000, and in 1830 about 13000000. What was the annual rate of increase? (The book writes it .016.) As a decimal, to 3 places: {0.017|0.016}
q: In what time would the population be doubled, at that rate? Years, to 2 decimal places: {41.49|41.5}
art: 388 | Compound Discount | The present value of a sum P, due `t` years hence, reckoning compound interest, is easily obtained from Art. 386. Let P' = the present worth; then in `t` years P' at compound interest will amount to P; therefore P = P'`(1+r)^t`, and P' = P / `(1+r)^t` (1). Let D = the compound discount; then D = P - P' = P - P / `(1+r)^t` (2). From equation (1), log. P' = log. P - `t` log. `(1+r)` (3).
q: What is the compound discount on $1000, due in 20 years, at 5 per cent.? $ {623.11}
art: 389 | Annuities Certain | An Annuity is a sum of money which is payable at equal intervals of time. An annuity already commenced is said to be in possession; one commencing after a certain number of years has elapsed is called a deferred annuity, or an annuity in reversion. An annuity certain is one limited to a certain number of years. A life annuity is one which terminates with the life of any person. A perpetuity, or perpetual annuity, is one which is unlimited in its duration. All the computations relating to annuities are made according to compound interest.
art: 390 | Amount of an annuity | To find the amount of an annuity in any number of years, at compound interest. Let `a` denote the annuity, `p` the present value, `m` the amount; and `r`, R, `t`, the same as in the preceding articles. The first annuity `a` becomes due at the end of the year, and thus, in `t-1` years, will amount to `a` times R to the power `t-1` (Art. 386). The second and third annuities, due in 2 and 3 years, amount to `a` times R to the powers `t-2` and `t-3`, and so on to the last, which is `a`. Hence, the entire amount is the sum of a geometrical series, whose first term is `a`, common ratio R, and number of terms `t`; therefore (Art. 297), `m=a((1+r)^t-1)/r`. If the annuity is to be received in half-yearly installments, `m=a((1+r/2)^(2t)-1)/r`; if quarterly, `m=a((1+r/4)^(4t)-1)/r`. Corollary: similarly, the amount of `a` dollars placed out annually for `t` successive years, at compound interest, would be `m=a(1+r)((1+r)^t-1)/r`.
q: To what sum will an annuity of $120 for 20 years amount at 6 per cent. per annum? $ {4414.27}
q: What would $100, put out annually at compound interest, amount to in 10 years at 6 per cent.? $ {1397.16}
art: 390 | Three children | Three children, A, B, C, who come of age at the end of `a`, `b`, `c` years, are to have P dollars divided among them, so that their shares being placed at compound interest, each shall receive, at coming of age, the same sum. The share of A, the youngest, is P divided by (1 + R to the power `a-b` + R to the power `a-c`).
art: 391 | Present value of an annuity | To find the present value of an annuity to be paid `t` years, at compound interest. Let `p` denote the present value of the annuity `a`; then the amount of `p` dollars in `t` years is `p(1+r)^t` (Art. 386), and the amount of the annuity `a` in the same time is `a((1+r)^t-1)/r` (Art. 390); but these two amounts must be equal to each other; hence `p=(a/r)(1-1/(1+r)^t)`. Corollary: if the annuity is to continue forever, `t` becomes infinite, `1/(1+r)^t` vanishes, and we have `p=a/r`.
q: What is the present worth of an annuity of $250, payable yearly for 30 years at 5 per cent.? (The book gets $3843.1135.) $ {3843.11}
q: What is the present worth of a perpetual annuity of $600 at 6 per cent. per annum? $ {10000 @= 600/0.06}
art: 392 | Annuity in reversion | To find the present value of an annuity in reversion; that is, an annuity which is to commence at the end of `n` years, and to continue `t` years. By Art. 391, the present value of the annuity for `n+t` years is `(a/r)(1-1/(1+r)^(n+t))`, and for `n` years, `(a/r)(1-1/(1+r)^n)`. The difference of these two sums is the value in reversion; therefore `p=(a/(r(1+r)^n))(1-1/(1+r)^t)`. If the annuity is payable forever after `n` years, we have `p=a/(r(1+r)^n)`.
q: What is the present value of an annuity of $112.50, to commence at the end of 10 years, and to continue 20 years, at 4 per cent.? (The book gets $1032.877.) $ {1032.88|1032.87}
q: What is the present value of an annuity of $1000, to commence at the end of 15 years and continue forever, at 6 per cent. per annum? (The book gets $6954.40; the exact value is $6954.42.) $ {6954.42|6954.40|6954.4}
art: 392 | Paying off a debt | A debt of `a` dollars, accumulating at compound interest, is discharged in `n` years, by equal annual payments of `b` dollars; the value of `n` is (log. `b` - log. `(b-ra)`) / log. `(1+r)`.
q: A debt of $8000, at 6 per cent. compound interest, is discharged by eight equal annual payments. Required the annual payment. (The book gets $1288.286.) $ {1288.29|1288.28}
== 77 | General Theory of Equations | Definitions; a root a means divisible by x-a; n roots
art: 393 | Equations of the nth degree | From Art. 113, it is obvious that, as `ax+b=0` is an equation of the 1st degree, `x^2+bx+c=0` of the 2d degree, `x^3+bx^2+cx+d=0` of the 3d degree; so `x^n+Ax^(n-1)+Bx^(n-2)+Cx^(n-3)+...+Tx+V=0` is, in general, an equation of the nth degree. The coefficients A, B, C, etc., may be positive or negative, integral or fractional; and any of them may be equal to zero. If the coefficient of the highest power of `x` is not unity, it may be made so by division.
q: Of what degree is the equation `x^3+bx^2+cx+d=0`? {3}
art: 394 | Root; function; permanence and variation | A Root of an equation is a number, or quantity, such that being substituted for the unknown quantity, the equation will be verified. Thus, 3 is a root in the equation `x^3+2x^2-14x-3=0`. A Function of a quantity is any expression dependent on that quantity. Thus, `2x+3` is a function of `x`; `5x^2` is a function of `x`; `7x-3y^2` is a function of `x` and `y`. In a series, when the signs of two successive terms are alike, they constitute a permanence; when they are unlike, a variation. Thus, in the polynomial `-r-s+t+u`, the signs of the first and second terms constitute a permanence, of the second and third a variation, and of the third and fourth a permanence.
mc: In the polynomial `-r-s+t+u`, the signs of the second and third terms constitute a... | permanence | *variation | root
art: 395 | Proposition I | If `a` is a root of any equation `x^n+Ax^(n-1)+Bx^(n-2)+Cx^(n-3)+...+Tx+V=0` (n), then will the equation be divisible by `x-a`. For if `a` is one value of `x`, the equation will be verified when `a` is substituted for `x`. This gives `a^n+Aa^(n-1)+Ba^(n-2)+Ca^(n-3)+...+Ta+V=0`; or, V = `-a^n-Aa^(n-1)-Ba^(n-2)-Ca^(n-3)-...-Ta`. Substituting this value of V in the given equation, and arranging the terms according to the same powers of `x` and `a`, we have `(x^n-a^n)+A(x^(n-1)-a^(n-1))+B(x^(n-2)-a^(n-2))+...+T(x-a)=0`. As (Art. 83) each of the expressions `x^n-a^n`, `x^(n-1)-a^(n-1)`, etc., is divisible by `x-a`, the given equation is divisible by `x-a`. Corollary: conversely, if the equation (n) is divisible by `x-a`, then `a` is a root of the equation. For if we call the quotient Q, we have `(x-a)Q=0`, which may be satisfied by making `x-a=0`, whence `x=a`. D'Alembert's proof of Prop. I: if said division leave a remainder, call it R, and the quotient Q; then equation (n) becomes `(x-a)Q+R=0`. But `x-a=0`, therefore R = 0; that is, there is no remainder on dividing equation (n) by `x-a`. Illustration: in the equation `x^3+x^2-14x-24=0`, the roots are -2, -3, and 4; and the equation is divisible by `x+2`, `x+3`, and `x-4`.
q: The roots of `x^3+x^2-14x-24=0` are -2, -3, and 4. Divide `x^3+x^2-14x-24` by `x-4`. {$ x^2+5x+6 @ (x^3+x^2-14x-24)/(x-4)}
art: 396 | Proposition II | An equation of the nth degree has `n` roots. Let `a` be a root of the equation (n). By Art. 395 this equation is divisible by `x-a`. If we perform the division, equation (n) becomes `(x-a)(x^(n-1)+...)=0`, where the second factor is of the degree `n-1`. Now, this equation must also have a root, which may be denoted by `b`, and is (Art. 395) divisible by `x-b`. Placing the second factor equal to zero, taking `c` a third root, and dividing by `x-c`, we shall have an equation of a degree still lower by a unit. It is evident that if this operation be continued, the exponent `n` will be exhausted, and the last quotient will be unity; hence, calling the last root `l`, we shall have `(x-a)(x-b)(x-c)(x-d)...(x-l)=0`, which is satisfied by making `x=a`, `b`, `c`, `d`, ... or `l`; that is, the equation has `n` roots, `a`, `b`, `c`, `d`, etc.
art: 396 | Corollaries | Corollary I: if we know one root of an equation, by dividing (Art. 395) we may find the equation containing the remaining roots. Thus, one root of the equation `x^3-12x^2+47x-60=0` is 5, and by dividing it by `x-5`, the quotient is `x^2-7x+12=0`, the roots of which may be found, viz., +3 and +4. Corollary II: when any equation, whose right hand member is zero, can be separated into factors, the roots of the equation may be found by placing each of the factors equal to zero. Thus, if `x^2+4x=0`, we have `x(x+4)=0`, whence `x=0` and `x=-4` (See Art. 253). Remark: two or more of the `n` roots may be equal to each other. Thus, the equation `x^3-6x^2+12x-8=0` is the same as `(x-2)(x-2)(x-2)=0`, or `(x-2)^3=0`. Hence the three roots are `x=2`, `x=2`, and `x=2`.
q: How many roots has an equation of the 5th degree? {5}
q: One root of `x^3-12x^2+47x-60=0` is 5; the others: `x` = {3 @x: x^2-7x+12=0} or {4 @x: x^2-7x+12=0}
q: One root of the equation `x^3-11x^2+23x+35=0` is -1; find the equation containing the remaining roots. {$ x^2-12x+35=0 @ (x^3-11x^2+23x+35)/(x+1)=0}
q: One root of the equation `x^3-9x^2+26x-24=0` is 3; find the remaining roots. `x` = {2 @x: x^3-9x^2+26x-24=0} or {4 @x: x^3-9x^2+26x-24=0}
q: Two roots of the equation `x^4+2x^3-41x^2-42x+360=0` are 3 and -4; required the remaining roots. `x` = {5 @x: x^4+2x^3-41x^2-42x+360=0} or {$ -6 @x: x^4+2x^3-41x^2-42x+360=0}
art: 397 | Proposition III | No equation of the nth degree can have more than `n` roots. If it be possible, let the equation (n), besides the `n` roots `a`, `b`, `c`, `d`, etc., have another root, `r`, not identical with either of the roots `a`, `b`, `c`, `d`, etc.; then the equation must be divisible by `x-r` (Art. 395); this gives `(x-a)(x-b)(x-c)...(x-l)=(x-r)(x^(n-1)+...)`. But since `r` is a value of `x`, we have, by substitution, `(r-a)(r-b)(r-c)...(r-l)=(r-r)(r^(n-1)+...)`. Now, the second member of this equation is 0, because `r-r=0`; but the other side can not be 0, since `r` is not equal to any of the quantities `a`, `b`, `c`, etc.; hence, the supposition is absurd that `x` can have any value other than `a`, `b`, `c`, `d`, ... `l`.
tf: An equation of the 3d degree may have four different roots. {F}
== 78 | General Theory of Equations | Relations of roots and coefficients; no fractional roots
art: 398 | Proposition IV | To discover the relations between the coefficients of an equation and its roots. Let `x=a`, `x=b`, `x=c`, `x=d`, etc. Then `x-a=0`, `x-b=0`, `x-c=0`, `x-d=0`, etc. By multiplying together the corresponding terms of the last set of equations, we have `(x-a)(x-b)(x-c)(x-d)=0`. If we perform the actual multiplication of the factors, we find `x^4-(a+b+c+d)x^3+(ab+ac+ad+bc+bd+cd)x^2-(abc+abd+acd+bcd)x+abcd=0`. Similarly, in the equation of the nth degree, `x^n+Ax^(n-1)+Bx^(n-2)+...=(x-a)(x-b)(x-c)...(x-l)=0`. If we perform the multiplication of the `n` factors, we shall have `-a-b-c-...`=A; `ab+ac+ad+...`=B; `-abc-abd-acd-...`=C; and so on. For the last term, plus or minus `abcd...kl`=V. The ± is prefixed to the last, or absolute term, because the product `-a*-b*-c...*-l` will be plus or minus, according as the degree of the equation is even or odd.
art: 398 | The relations | Hence: 1. The coefficient of the second term of any equation is equal to the sum of all the roots, with their signs changed. 2. The coefficient of the third term is equal to the sum of the products of all the roots taken two and two. 3. The coefficient of the fourth term is equal to the sum of the products of all the roots taken three and three, with their signs changed. And so on; and 4. The last term is the product of all the roots, with the sign changed if the degree of the equation is odd. Corollary I: if any term is wanting, its coefficient is 0. II: if the 2d term is wanting, the sum of the roots is 0. III: if the 3d term is wanting, the sum of the products of the roots, taken two and two in a product, is 0. IV: if the absolute term is wanting, the product of the roots must be 0, and hence one of the roots must be 0. V: since the last term is the product of all the roots, therefore it must be divisible by each of them; that is, every rational root of an equation is a divisor of the last term.
art: 398 | Example | Form the equation whose roots are 3, 4, and -5. The equations `x=3`, `x=4`, and `x=-5` give `x-3=0`, `x-4=0`, and `x+5=0`; hence `(x-3)(x-4)(x+5)=x^3-2x^2-23x+60=0`. Here, `3+4-5=+2`, the coefficient of the 2d term with contrary sign; `3*4+3*-5+4*-5=-23`, the coefficient of the 3d term; `3*4*-5=-60`, the sign of which must be changed, for the last term, because the degree of the equation is odd.
q: Form the equation whose roots are 3, 4, and -5. {$ x^3-2x^2-23x+60=0 @ (x-3)(x-4)(x+5)=0}
q: What is the equation whose roots are 2, 3, and -5? (See Cor. II.) {$ x^3-19x+30=0 @ (x-2)(x-3)(x+5)=0}
q: Form the equation with roots 0, -1, 2, and -5. {$ x^4+4x^3-7x^2-10x=0 @ x(x+1)(x-2)(x+5)=0}
q: Find the equation whose roots are `1±√2` and `2±√3`. {$ x^4-6x^3+8x^2+2x-1=0 @ (x^2-2x-1)(x^2-4x+1)=0}
q: What is the 4th term of the equation whose roots are -2, -1, 1, 3, 4? {$ 29x^2}
q: The sum of the roots of `x^3-12x^2+47x-60=0`. {12}
tf: Every rational root of an equation is a divisor of the last term. {T}
art: 399 | Proposition V | No equation having unity for the coefficient of the first term, and all the other coefficients integers, can have a root equal to a rational fraction. Assume that all the coefficients are integers in the general equation `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0`. If possible, let `a/b`, a fraction in its lowest terms, be a root of this equation; then, by substituting it for `x`, reducing the terms to a common denominator, transposing, etc., we shall have `a^n/b=-Aa^(n-1)-Ba^(n-2)b-...-Tab^(n-2)-Vb^(n-1)`. But, by hypothesis, `a` and `b`, and consequently `a^n` and `b`, contain no common factor; therefore an irreducible fraction is equal to a series of integers, which is absurd. Hence, the supposition is absurd, and the equation has no fractional root.
tf: The equation `x^3+2x^2-5x+7=0` can have the root `1/2`. {F}
== 79 | General Theory of Equations | Changing the signs of the roots; imaginary roots in pairs; Descartes' rule; a root between two numbers
art: 400 | Proposition VI | If the signs of the alternate terms of an equation be changed, the signs of all the roots will be changed. Let `a` be a root of the equation `x^n+Ax^(n-1)+Bx^(n-2)+Cx^(n-3)+...+V=0` (1). Then `a^n+Aa^(n-1)+Ba^(n-2)+Ca^(n-3)+...+V=0` (2). Changing the signs of the alternate terms of equation (1), `x^n-Ax^(n-1)+Bx^(n-2)-Cx^(n-3)+...±V=0` (3). Substituting `-a` for `x` in this equation, we have `(-a)^n-A(-a)^(n-1)+B(-a)^(n-2)-C(-a)^(n-3)+...±V=0` (4). Now, if `n` be even, the 2d, 4th, etc., terms will contain odd powers of `-a`, which will (Art. 193) render those terms positive. Hence, the whole result will be the same as that produced by the substitution of `a` for `x` in equation (1). But if `n` be odd, the 1st, 3d, etc., terms will be negative, which will render all the terms of (4) negative. Changing the signs of all the terms, (4) becomes the same as (2). Hence, if `a` is a root of equation (1), `-a` is a root of (3), whether `n` be odd or even.
q: The roots of the equation `x^3-3x^2-10x+24=0` are 2, -3, and 4; what are the roots of the equation `x^3+3x^2-10x-24=0`? `x` = {$ -2 @x: x^3+3x^2-10x-24=0} or {3 @x: x^3+3x^2-10x-24=0} or {$ -4 @x: x^3+3x^2-10x-24=0}
art: 401 | Proposition VII | When the coefficients of an equation are real, if it contains imaginary roots, the number of these roots must be even. If `a+b√-1` be a root of the equation `x^n-Ax^(n-1)+Bx^(n-2)-...=0`, then `a-b√-1` is also a root. In the equation, substitute `a+b√-1` for `x`, and the result will consist of two parts: 1st, possible quantities which involve the odd and even powers of `a`, and the even powers of `b√-1`; 2d, impossible quantities which involve the odd powers of `b√-1`. Call the sum of the possible quantities P, and of the impossible Q`√-1`; then P + Q`√-1` is the whole result; hence P + Q`√-1` = 0. But the first quantity being real, and the second imaginary, in order to satisfy the equation, each of the quantities must be 0; this gives P = 0, and Q`√-1` = 0. Again, let `a-b√-1` be substituted for `x`, and the 1st part of the result will be the same as before, and the 2d part, which arises from the odd powers of `b√-1`, will differ from the former imaginary part only in its sign; therefore the result will be P - Q`√-1`; but since P = 0 and Q`√-1` = 0, we must have P - Q`√-1` = 0. Hence `a-b√-1` is a root of the equation, since its substitution for `x` gives a result equal to 0.
art: 401 | Corollaries | Corollary I: in a similar manner, it may be shown that surd roots of the form `a±√b`, `±b√-1`, or `±√b`, enter an equation by pairs. Corollary II: since irrational and imaginary roots always occur in pairs where the coefficients are real, it follows that every equation of an odd degree must have at least one real root. Corollary III: corresponding to any pair of imaginary roots `a±b√-1`, we have in the equation the quadratic factor `(x-(a+b√-1))(x-(a-b√-1))=(x-a)^2+b^2`; hence, every equation of an even order, with real coefficients, is composed of real factors of the second degree.
tf: Every equation of an odd degree, with real coefficients, has at least one real root. {T}
q: One root of the equation `x^3-26x+60=0` is -6; required the other roots. {$ 3±√-1 @x: x^2-6x+10=0}
q: One root of `x^3-7x^2+13x-3=0` is `2-√3`; find the other roots. `x` = {$ 2+√3 @x: x^3-7x^2+13x-3=0} or {3 @x: x^3-7x^2+13x-3=0}
q: One root of `x^4-3x^2-42x-40=0` is `-(1/2)(3+√-31)`; find the other roots. `x` = {$ -3/2+(1/2)√-31 @x: x^2+3x+10=0} or {4 @x: x^4-3x^2-42x-40=0} or {$ -1 @x: x^4-3x^2-42x-40=0}
q: Two roots of `x^5-10x^4+29x^3-10x^2-62x+60=0` are 3 and `√2`; find the other roots. `x` = {$ -√2 @x: x^5-10x^4+29x^3-10x^2-62x+60=0} or {2 @x: x^5-10x^4+29x^3-10x^2-62x+60=0} or {5 @x: x^5-10x^4+29x^3-10x^2-62x+60=0}
art: 402 | Descartes' Rule of the Signs | Proposition VIII: no equation can have a greater number of positive roots than there are variations of sign; nor a greater number of negative roots than there are permanences of sign. In the equation `x-a=0`, where the value of `x` is `+a`, there is one variation, and one positive root. In the equation `x+a=0`, where the value of `x` is `-a`, there is one permanence, and one negative root. In `x^2-(a+b)x+ab=0`, where the values of `x` are `+a` and `+b`, there are two variations and two positive roots. In `x^2+(a+b)x+ab=0`, where the values of `x` are `-a` and `-b`, there are two permanences, and two negative roots. In `x^2-x-12=0`, where `x=+4` and -3, there is one variation, and one positive root; one permanence, and one negative root. If we form an equation of the third degree whose roots are +2, +3, +4, we shall have `x^3-9x^2+26x-24=0`, where there are three variations, and three positive roots. But if we form an equation whose roots are -2, -3, +4, we shall have `x^3+x^2-14x-24=0`, where there is one variation, and one positive root, and two permanences, and two negative roots.
art: 402 | The proof | To prove the proposition generally, let the signs of the terms in their order, in any complete equation, be + + - + - + + +, and let a new factor `x-a=0`, corresponding to a new positive root, be introduced. In the product, each permanence is changed into an ambiguity; hence, the permanences, take the ambiguous sign as you will, are not increased in the final product; but the number of signs is increased by one, and therefore the number of variations must be increased by one. Hence, the introduction of any positive root introduces at least one additional variation of sign. Let us now begin with the equation `x-a=0`, which contains one positive root, and has one variation of sign. Then, since every additional positive root introduces at least one additional variation of sign, the number of positive roots can never exceed the number of variations of sign. Again, if we change the signs of the alternate terms, the roots will be changed from positive to negative, and, conversely (Art. 400), the permanences and variations in the proposed equation will be interchanged. But since the changed equation can not have a greater number of positive roots than there are variations of sign, the proposed equation can not have a greater number of negative roots than there are permanences of sign.
q: How many variations of sign are there in `x^3+x^2-14x-24=0`? {1}
q: And how many permanences? {2}
art: 402 | Corollaries | Corollary I: in an equation of the mth degree, since the sum of the variations and permanences is equal to `m`, the number of real roots in any equation can not be greater than its degree. Corollary II: if the number of real roots be less than the degree of the equation, the remaining roots are imaginary. Take, for example, the equation `x^2+16=0`, or `x^2±0x+16=0`. Taking the upper sign, there are no variations; hence, there is no positive root: taking the lower sign, there are no permanences; hence, there is no negative root. But the equation has two roots (Art. 396); they must, therefore, both be imaginary. Take, again, the cubic equation `x^3+Bx+C=0`, or `x^3±0x^2+Bx+C=0`. Reasoning as before, we find that there can be but one real root, which is negative. Therefore, the other two roots must be imaginary.
q: How many imaginary roots has `x^2+16=0`? {2}
art: 403 | Proposition IX | If two numbers, when substituted for the unknown quantity in an equation, give results affected with different signs, one root, at least, of this equation lies between these numbers. Let the equation, for example, be `x^3-x^2+x-8=0`. If we substitute 2 for `x` in this equation, the result is -2; and if we substitute 3 for `x`, the result is +13. It is required to show that there must be one real root, at least, between 2 and 3. The equation may evidently be written thus, `(x^3+x)-(x^2+8)=0`. Now, in substituting 2 for `x`, `x^3+x=10`, and `x^2+8=12`; therefore `x^3+x<x^2+8`. Also, in substituting 3 for `x`, `x^3+x=30`, and `x^2+8=17`; therefore `x^3+x>x^2+8`. Now, both members of the inequality increase while `x` increases, but the first increases more rapidly than the second, since when `x=2` it is less than the second, but when `x=3` it is greater. Consequently, for some value of `x` between 2 and 3, we must have `x^3+x=x^2+8`, and this value of `x` is, therefore, a real root. In general, suppose X = 0 to be a polynomial equation involving `x`, and that `p` and `q`, when substituted for `x`, give results with contrary signs. Let P be the sum of the positive, and N the sum of the negative terms. When `x=p`, let P - N be negative, or P < N; and when `x=q`, let P - N be positive, or P > N. Now, there must be some value of `x` between `p` and `q`, which renders P = N, or satisfies the equation X = 0. This value of `x` is, therefore, a real root of the equation. Corollary: if the difference between `p` and `q` is equal to unity, it is evident that we have found the integral part of one of the roots.
q: In `x^3-x^2+x-8=0`, what is the result of substituting 3 for `x`? {13 @= 27-9+3-8}
q: Find the integral part of one value of `x` in the equation `x^4-4x^3+3x^2+x-5=0`. (If `x=3`, the value of the expression is -2; but if `x=4`, the value is 47.) {3}
chk: x=3 | x^4-4x^3+3x^2+x-5=-2
chk: x=4 | x^4-4x^3+3x^2+x-5=47
q: Required the first figure of one of the roots of the equation `x^3-5x^2-x+1=0`. {5}
chk: x=5 | x^3-5x^2-x+1=-4
chk: x=6 | x^3-5x^2-x+1=31
== 80 | General Theory of Equations | Transformation of equations
art: 404 | Transformation | The Transformation of an Equation is the changing of it into another of the same degree, whose roots shall have a specified relation to the roots of the given equation. Thus, in `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0` (1), if `-y` be substituted for `x`, the equation will be transformed into another whose roots are the same as those in (1), but with contrary signs, for `y=-x`. If `1/y` be substituted for `x`, then `y=1/x`, and the roots of the new equation in `y` will be the reciprocals of those of equation (1).
art: 405 | Proposition I | To transform an equation into one whose roots are the roots of the given equation multiplied or divided by any given quantity. Let `a`, `b`, `c`, etc., be the roots of the equation (1). Assume `y=kx`, or `x=y/k`. Substituting this value for `x` in (1), `y^n/k^n+Ay^(n-1)/k^(n-1)+By^(n-2)/k^(n-2)+...+Ty/k+V=0`; hence `y^n+Aky^(n-1)+Bk^2y^(n-2)+...+Tk^(n-1)y+k^nV=0`. Since `y=kx`, the roots of this equation are `ka`, `kb`, `kc`, etc. It is evident that this equation may be derived from (1); or that the transformation of (1) is effected by multiplying the successive terms by 1, `k`, `k^2`, `k^3`, etc., and changing `x` into `y`. In the case of division, assume `y=x/k`, or `x=ky`, and substitute. Corollary: by this transformation an equation may be cleared of fractions, or the coefficient of the first term may be made unity. Example: transform the equation `x^3+(1/2)px^2+(1/3)qx+r=0` into one which is clear of fractions, and which has unity for the coefficient of the term containing the highest power of `x`. Multiplying by 6, `6x^3+3px^2+2qx+6r=0`. Putting `y=6x`, or `x=(1/6)y`, `6y^3/6^3+3py^2/6^2+2qy/6+6r=0`; multiplying by `6^2`, `y^3+3py^2+12qy+216r=0`.
q: Find the equation whose roots are each 3 times those of the equation `x^4+7x^2-4x+3=0`. {$ y^4+63y^2-108y+243=0 @ (y/3)^4+7(y/3)^2-4(y/3)+3=0}
q: Find the equation whose roots are each 5 times those of the equation `x^4+2x^3-7x-1=0`. {$ y^4+10y^3-875y-625=0 @ (y/5)^4+2(y/5)^3-7(y/5)-1=0}
q: What is the equation whose roots are each `1/2` of those of `x^3-3x^2+4x+10=0`? {$ 4y^3-6y^2+4y+5=0 @ (2y)^3-3(2y)^2+4(2y)+10=0}
q: Transform the equation `x^3-2x^2+(1/3)x-10=0` into one having integral coefficients. (Put `y=3x`.) {$ y^3-6y^2+3y-270=0 @ (y/3)^3-2(y/3)^2+(1/3)(y/3)-10=0}
art: 406 | Proposition II | To transform an equation into one whose roots are greater or less by any given quantity than the corresponding roots of the proposed equation. Let `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0` be an equation whose roots are `a`, `b`, `c`, etc. The relation between `x` and `y` will be expressed by the equation `y=x±r`. As the principle is the same in both cases, let `y=x-r`, or `x=y+r`. Substituting `y+r` for `x`, we have `(y+r)^n+A(y+r)^(n-1)+B(y+r)^(n-2)+...+T(y+r)+V=0`. Developing the different powers of `y+r` by the Binomial Theorem, and arranging the terms, we have `y^n+(nr+A)y^(n-1)+((n(n-1))/(1*2)r^2+(n-1)Ar+B)y^(n-2)+...+(r^n+Ar^(n-1)+Br^(n-2)+...+Tr+V)=0`. Now, since `y=x-r`, the values of `y` in this equation are `a-r`, `b-r`, `c-r`, etc.
art: 407 | Removing a term | Corollary: by means of the preceding transformation, we may remove any intermediate term of an equation. Thus, to transform an equation into one which shall want the second term, `r` must be assumed so that `nr+A=0`. To take away the third term, put `(1/2)n(n-1)r^2+(n-1)Ar+B=0`.
q: Transform the equation `x^3-7x+7=0` into another whose roots shall be less by one than the corresponding roots of this equation. {$ y^3+3y^2-4y+1=0 @ (y+1)^3-7(y+1)+7=0}
q: Find the equation whose roots are less by 3 than those of the equation `x^4-3x^3-15x^2+49x-12=0`. {$ y^4+9y^3+12y^2-14y=0 @ (y+3)^4-3(y+3)^3-15(y+3)^2+49(y+3)-12=0}
q: To transform `x^3-6x^2+8x-2=0` into another whose second term shall be absent, `r` must make `3r-6=0`; so `r` = {2} and the new equation is {$ y^3-4y-2=0 @ (y+2)^3-6(y+2)^2+8(y+2)-2=0}
art: 408 | An easier method | There is an easier and more elegant method of transformation. Let the proposed equation be `Ax^4+Bx^3+Cx^2+Dx+E=0` (1), and let it be required to transform it into another whose roots shall be less by `r`; then `y=x-r` and `x=y+r`. By substituting `y+r` instead of `x`, and developing the powers of `y+r`, the transformed equation will take the form A`y^4`+B1`y^3`+C1`y^2`+D1`y`+E1 = 0 (2), where A is evidently the same as in (1), while the other four coefficients are unknown quantities to be determined. For `y`, substitute its value `x-r`, and equation (2) becomes A`(x-r)^4`+B1`(x-r)^3`+C1`(x-r)^2`+D1`(x-r)`+E1 = 0 (3). Now, since the values of `x` are the same in (1) and (3), these equations are identical. Hence, let (3) or (1) be divided by `x-r`, and the quotient will be A`(x-r)^3`+B1`(x-r)^2`+C1`(x-r)`+D1, with the remainder E1; hence the last coefficient is determined. Divide this quotient by `x-r`, and the next remainder is D1. Continuing the division by `x-r`, we obtain all the coefficients of equation (2). Example: transform `x^3-7x+7=0` into another whose roots shall be less by 1. Here `y=x-1`, and we divide the proposed equation and the successive quotients by `x-1`. The successive remainders, +1, -4, and +3, will be the coefficients of `y` in the transformed equation, taken from the last, except that of the highest power, which has the same coefficient as the highest power of `x` in the proposed equation: `y^3+3y^2-4y+1=0`. This method may be greatly shortened by Horner's Synthetic Method of Division.
q: Divide `x^3-7x+7` by `x-1`: the quotient {$ x^2+x-6 @ (x^3-7x+7-1)/(x-1)} and the remainder {1}
== 81 | General Theory of Equations | Synthetic division; derived polynomials
art: 409 | Synthetic Division | This may be considered as an abridgment of the method of division by Detached Coefficients (Art. 77). To explain the process, we shall first divide `5x^4-12x^3+3x^2+4x-5` by `x-2`, by detached coefficients: the divisor 1-2 into 5-12+3+4-5 gives the quotient 5-2-1+2, or `5x^3-2x^2-x+2`, with remainder -1. By changing the sign of the second term of the divisor, and adding each partial product, except the first term, which, being always the same as the first term of each dividend, may be omitted, the operation may be shortened. It is unnecessary to bring down the several terms of the dividend. Hence the operation may be represented as follows: write +2 as the divisor, and the coefficients 5, -12, +3, +4, -5. Bring down 5, the first term of the quotient; +10 is the product of +2, the divisor, by 5; the sum of +10 and -12 gives -2, the second term of the quotient; +2 times -2 = -4, and -4 and +3 gives -1, the third term of the quotient, and so on. The last term, -1, is the remainder. Supplying the powers of `x`, the quotient is `5x^3-2x^2-x+2`, with a remainder -1. A similar method may be used when the divisor contains three terms, but the process is more complicated. If the coefficient of the first term of the divisor is not unity, it may be made unity by dividing both dividend and divisor by the coefficient of the first term of the divisor. If any term is wanting, its place must be supplied with a zero.
q: Divide `5x^4-12x^3+3x^2+4x-5` by `x-2` by synthetic division: the quotient {$ 5x^3-2x^2-x+2 @ (5x^4-12x^3+3x^2+4x-5+1)/(x-2)} and the remainder {$ -1}
art: 410 | Transforming by synthetic division | In application of these principles, let it be required to find the equation whose roots are less by 1 than those of the equation `x^3-7x+7=0`. Since the second term is wanting, its place must be supplied with 0. The divisor is `x-1`; hence we divide by +1: the coefficients 1, 0, -7, +7 give the 1st remainder +1; dividing the quotient 1, +1, -6 again, the 2d remainder -4; and again, the 3d remainder +3. Hence the required coefficients are 1, +3, -4, and +1, and `y^3+3y^2-4y+1=0` is the transformed equation required. Example 2: transform the equation `5x^4+28x^3+51x^2+32x-1=0` into another having its roots greater by 2 than those of the given equation. Here `y=x+2`; hence we divide by -2. The successive remainders are -5, +4, +3, -12; hence the transformed equation is `5y^4-12y^3+3y^2+4y-5=0`. Example 3: find the equation whose roots are less by 1.7 than those of the equation `x^3-2x^2+3x-4=0`. If we transform this equation into another whose roots are less by 1, the resulting equation is `y^3+y^2+2y-2=0`. We may then transform this into another whose roots are less by .7, or the whole operation may be performed at once by dividing by +1.7: the remainders are .233, 4.87, and 3.1. Hence the equation is `y^3+3.1y^2+4.87y+.233=0`.
q: Transform `5x^4+28x^3+51x^2+32x-1=0` into another having its roots greater by 2. {$ 5y^4-12y^3+3y^2+4y-5=0 @ 5(y-2)^4+28(y-2)^3+51(y-2)^2+32(y-2)-1=0}
q: Find the equation whose roots are less by 1.7 than those of `x^3-2x^2+3x-4=0`: the coefficient of `y^2` {3.1}, of `y` {4.87}, and the last term {0.233}
chk: x=1.7 | x^3-2x^2+3x-4=0.233
chk: x=1.7 | 3x^2-4x+3=4.87
q: Find the equation whose roots are each less by 3 than the roots of `x^3-27x-36=0`. {$ y^3+9y^2-90=0 @ (y+3)^3-27(y+3)-36=0}
q: Required the equation whose roots are less by 5 than those of the equation `x^4-18x^3-32x^2+17x+9=0`. {$ y^4+2y^3-152y^2-1153y-2331=0 @ (y+5)^4-18(y+5)^3-32(y+5)^2+17(y+5)+9=0}
q: Required the equation whose roots are less by 1.2 than those of the equation `x^5-6x^4+7.4x^3+7.92x^2-17.872x-.79232=0`. {$ y^5-7y^3+2y-8=0}
chk: x=1.2 | x^5-6x^4+7.4x^3+7.92x^2-17.872x-0.79232=-8
chk: x=1.2 | 5x^4-24x^3+22.2x^2+15.84x-17.872=2
art: 410 | Removing terms | Transform the following equations into others wanting the 2d term (see Art. 407).
q: Transform `x^3-6x^2+7x-2=0` into one wanting the 2d term. {$ y^3-5y-4=0 @ (y+2)^3-6(y+2)^2+7(y+2)-2=0}
q: Transform `x^3-6x^2+12x+19=0` into one wanting the 2d term. {$ y^3+27=0 @ (y+2)^3-6(y+2)^2+12(y+2)+19=0}
art: 410 | Wanting the 3d term | Transform the following equations into others wanting the 3d term. Here `r` must make `3r^2+2Ar+B=0`, which has two roots, so there are two answers.
q: Transform `x^3-6x^2+9x-20=0` into one wanting the 3d term (`3r^2-12r+9=0`, so `r=3` or `r=1`). With `r=3`: {$ y^3+3y^2-20=0 @ (y+3)^3-6(y+3)^2+9(y+3)-20=0}
q: And with `r=1`: {$ y^3-3y^2-16=0 @ (y+1)^3-6(y+1)^2+9(y+1)-20=0}
q: Transform `x^3-4x^2+5x-2=0` into one wanting the 3d term (`3r^2-8r+5=0`, so `r=1` or `r=5/3`). With `r=1`: {$ y^3-y^2=0 @ (y+1)^3-4(y+1)^2+5(y+1)-2=0}
q: And with `r=5/3`: {$ y^3+y^2-4/27=0 @ (y+5/3)^3-4(y+5/3)^2+5(y+5/3)-2=0}
art: 411 | Derived Polynomials | Proposition III: to determine the law of Derived Polynomials. Let X represent the general equation of the nth degree; that is, X = `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0`. If we substitute `x+h` for `x`, and put X1 to represent the new value of X, we have X1 = `(x+h)^n+A(x+h)^(n-1)+B(x+h)^(n-2)+...`, and if we expand the different powers of `x+h` by the binomial theorem, and collect the terms by the powers of `h`, the first column is the same as the original equation, and if we put X', X'', X''', etc., to represent the succeeding columns, we have X = `x^n+Ax^(n-1)+Bx^(n-2)+...`, X' = `nx^(n-1)+(n-1)Ax^(n-2)+(n-2)Bx^(n-3)+...`, X'' = `n(n-1)x^(n-2)+(n-1)(n-2)Ax^(n-3)+...`, etc. By substituting these in the development of X1, we have X1 = X + X'`h` + X''`h^2/(1*2)` + X'''`h^3/(1*2*3)` + etc. The expressions X', X'', X''', etc., are called derived polynomials of X, or derived functions of X. X' is called the first derived polynomial of X, or first derived function of X; X'' is called the second, X''' the third, and so on. It is easily seen that X' may be derived from X, X'' from X', etc., by multiplying each term by the exponent of `x` in that term, and diminishing the exponent by unity.
q: The first derived polynomial of `x^3-7x+7`. {$ 3x^2-7}
q: The second derived polynomial of `x^3-7x+7`. {$ 6x}
art: 412 | Corollary | If we transpose X, we have X1 - X = X'`h` + X''`h^2/(1*2)` + etc. Now, it is evident that `h` may be taken so small that the sign of the sum X'`h` + X''`h^2/(1*2)` + etc. will be the same as the sign of the first term X'`h`. For, since X'`h` + `(1/2)`X''`h^2` + etc. = `h`(X' + `(1/2)`X''`h` + etc.), if `h` be taken so small that `(1/2)`X''`h` + `(1/6)`X'''`h^2` + etc. becomes less than X' (their magnitudes alone being considered), the sign of the sum of these two expressions must be the same as the sign of the greater X'.
art: 413 | Transforming by derived polynomials | By comparing the transformed equation in Art. 406 with the development of X1 in Art. 411, it is easily seen that X1 may be considered the transformed equation, `y` corresponding to `x`, and `r` to `h`. Hence, the transformed equation may be obtained by substituting the values of X, X', etc., in the development of X1. As an example, let it be required to find the equation whose roots are less by 1 than those of the equation `x^3-7x+7=0`. Here X = `x^3-7x+7`, X' = `3x^2-7`, X'' = `6x`, X''' = 6, and the fourth derived polynomial is 0. Observing that `h=1`, and substituting these values in the equation X1 = X + X'`h` + X''`h^2/(1*2)` + X'''`h^3/(1*2*3)` + etc., we have X1 = `(x^3-7x+7)+(3x^2-7)1+(6x)(1/(1*2))+6/(1*2*3)=x^3+3x^2-4x+1`, in which the value of `x` is equal to that of `x` in the given equation diminished by 1. By this method, solve the examples in Art. 410.
== 82 | General Theory of Equations | Equal roots; limits of the roots
art: 414 | Equal Roots | To determine the equal roots of an equation. We have already seen (Art. 396, Rem.) that an equation may have two or more of its roots equal to each other. We now propose to determine when an equation has equal roots, and how to find them. If we take the equation `(x-2)^3=0` (1), its first derived polynomial is `3(x-2)^2=0`. Hence, we see that if any equation contains the same factor taken three times, its first derived polynomial will contain the same factor taken twice; this last factor is, therefore, a common divisor of the given equation, and its first derived polynomial. In general, if we have an equation X = 0, containing the factors `(x-a)^m(x-b)^n`, its first derived polynomial will contain the factors `m(x-a)^(m-1)n(x-b)^(n-1)`; that is, the greatest common divisor of the given equation and its first derived polynomial will be `(x-a)^(m-1)(x-b)^(n-1)`, and the given equation will have `m` roots, each equal to `a`, and `n` roots, each equal to `b`. Therefore, to determine whether an equation has equal roots: find the greatest common divisor between the equation and its first derived polynomial. If there is no common divisor, the equation has no equal roots. If the G.C.D. contains a factor of the form `x-a`, then it has two roots equal to `a`; if it contains a factor of the form `(x-a)^2` it has three roots equal to `a`, and so on. If it has a factor of the form `(x-a)(x-b)` it has two roots equal to `a`, and two equal to `b`, and so on.
art: 414 | Example | Given the equation `x^3-x^2-8x+12=0`, to determine whether it has equal roots, and if so, to find them. We have for the first derived polynomial (Art. 411) `3x^2-2x-8`. The G.C.D. of this and the given equation (Art. 108) is `x-2`. Hence `x-2=0`, and `x=+2`. Therefore, the equation has two roots equal to 2. Now, since the equation has two roots equal to 2, it must be divisible by `(x-2)(x-2)`, or `(x-2)^2` (Art. 395). Whence `x^3-x^2-8x+12=(x-2)^2(x+3)=0`, and `x+3=0`, or `x=-3`. Hence, when an equation contains other roots besides the equal roots, the degree of the equation may be depressed by division, and the unequal roots found by other methods.
q: The first derived polynomial of `x^3-x^2-8x+12`. {$ 3x^2-2x-8}
q: The G.C.D. of `x^3-x^2-8x+12` and `3x^2-2x-8`. {$ x-2 @gcd: x^3-x^2-8x+12; 3x^2-2x-8}
q: Its other root. {$ -3 @x: x^3-x^2-8x+12=0}
art: 414 | Exercises | The following equations have equal roots; find all the roots. Type each root, the equal ones as many times as they occur, in any order.
q: `x^3-2x^2-15x+36=0`. `x` = {3 @x: x^3-2x^2-15x+36=0} or {3 @x: x^3-2x^2-15x+36=0} or {$ -4 @x: x^3-2x^2-15x+36=0}
chk: x=3 | 3x^2-4x-15=0
q: `x^4-9x^2+4x+12=0`. `x` = {2 @x: x^4-9x^2+4x+12=0} or {2 @x: x^4-9x^2+4x+12=0} or {$ -1 @x: x^4-9x^2+4x+12=0} or {$ -3 @x: x^4-9x^2+4x+12=0}
chk: x=2 | 4x^3-18x+4=0
q: `x^4-6x^3+12x^2-10x+3=0`. `x` = {1 @x: x^4-6x^3+12x^2-10x+3=0} or {1 @x: x^4-6x^3+12x^2-10x+3=0} or {1 @x: x^4-6x^3+12x^2-10x+3=0} or {3 @x: x^4-6x^3+12x^2-10x+3=0}
chk: x=1 | 4x^3-18x^2+24x-10=0 | 12x^2-36x+24=0
q: `x^4-7x^3+9x^2+27x-54=0`. `x` = {3 @x: x^4-7x^3+9x^2+27x-54=0} or {3 @x: x^4-7x^3+9x^2+27x-54=0} or {3 @x: x^4-7x^3+9x^2+27x-54=0} or {$ -2 @x: x^4-7x^3+9x^2+27x-54=0}
chk: x=3 | 4x^3-21x^2+18x+27=0 | 12x^2-42x+18=0
q: `x^4+2x^3-3x^2-4x+4=0`. `x` = {$ -2 @x: x^4+2x^3-3x^2-4x+4=0} or {$ -2 @x: x^4+2x^3-3x^2-4x+4=0} or {1 @x: x^4+2x^3-3x^2-4x+4=0} or {1 @x: x^4+2x^3-3x^2-4x+4=0}
chk: x=1 | 4x^3+6x^2-6x-4=0
chk: x=-2 | 4x^3+6x^2-6x-4=0
q: `x^4-12x^3+50x^2-84x+49=0`: it is `(x^2-6x+7)^2=0`, so each of the roots {$ 3±√2 @x: x^2-6x+7=0} is taken twice.
q: `x^5-2x^4+3x^3-7x^2+8x-3=0`: the root 1 is taken {3} times, and the other two roots are {$ -1/2±(1/2)√-11 @x: x^2+x+3=0}
chk: x=1 | x^5-2x^4+3x^3-7x^2+8x-3=0 | 5x^4-8x^3+9x^2-14x+8=0 | 20x^3-24x^2+18x-14=0
q: `x^6+3x^5-6x^4-6x^3+9x^2+3x-4=0`. `x` = {1} or {1} or {1} or {$ -1} or {$ -1} or {$ -4}
chk: x=1 | x^6+3x^5-6x^4-6x^3+9x^2+3x-4=0 | 6x^5+15x^4-24x^3-18x^2+18x+3=0
chk: x=-1 | x^6+3x^5-6x^4-6x^3+9x^2+3x-4=0 | 6x^5+15x^4-24x^3-18x^2+18x+3=0
chk: x=-4 | x^6+3x^5-6x^4-6x^3+9x^2+3x-4=0
art: 414 | Suggestion | In the solution of equations of high degree, the principles above explained may be extended. Thus, in the last example, the G.C.D. is `x^3-x^2-x+1`. Proceeding, we may, 1st, find the common measure of this and its first derived polynomial, and thus resolve into factors; or, 2d, find the G.C.D. of the first and second derived polynomials. If it is of the form `x-a`, one of the factors of the original equation will evidently be `(x-a)^3`, etc. By the 1st method, we find `x^3-x^2-x+1=(x-1)(x^2-1)=(x-1)^2(x+1)`; by the 2d, `(x-1)^3` is a factor of the original equation; hence `(x-1)^2` is a factor of `x^3-x^2-x+1`.
art: 415 | Limits of the roots | Limits to a Root of an Equation are any two numbers between which that root lies. A Superior Limit to the positive roots is a number numerically greater than the greatest positive root. Its characteristic is, that when it, or any number greater than it, is substituted for `x` in the equation, the result is positive. An Inferior Limit to the negative roots is a number numerically greater than the greatest negative root. The substitution of it, or any number greater than it, for `x`, produces a negative result. The object of ascertaining the limits of the roots is to diminish the labor necessary in finding them.
art: 416 | Proposition I | The greatest negative coefficient, increased by unity, is greater than the greatest root of the equation. Take the general equation `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0`, and suppose A to be the greatest negative coefficient. The reasoning will not be affected if we suppose all the coefficients to be negative, and each equal to A. It is required to find what number substituted for `x` will make `x^n` greater than A times `(x^(n-1)+x^(n-2)+x^(n-3)+...+x+1)`. By Art. 297, the sum in parenthesis is `(x^n-1)/(x-1)`; hence we must have `x^n` greater than A`(x^n-1)/(x-1)`. But if `x^n` = A`x^n/(x-1)`, we find `x` = A + 1; so A + 1 substituted for `x` will render `x^n` greater than A`x^n/(x-1)` minus A`/(x-1)`. By considering all the coefficients after the first negative, we have taken the most unfavorable case; if any of them were positive, the quantity in parenthesis would be less.
q: By Proposition I, a superior limit of the roots of `x^3-5x^2+2x-8=0`. {9}
art: 417 | Proposition II | If we take the greatest negative coefficient, extract a root of it whose index is equal to the number of terms preceding the first negative term, and increase it by unity, the result will be greater than the greatest positive root of the equation. Let C`x^(n-r)` be the first negative term, C being the greatest negative coefficient; then, any value of `x` which makes `x^n` greater than C`(x^(n-r)+x^(n-r-1)+...+x+1)` (1) will render the first of the proposed equation positive. By Art. 297, the series in parenthesis = `(x^(n-r+1)-1)/(x-1)`. This inequality will be true if `x^n` equals C`x^(n-r+1)/(x-1)`; or, by multiplying both members by `x-1`, and dividing by `x^(n-r+1)`, when `(x-1)x^(r-1)` = C, or greater (2). But `x-1` is less than `x`, so (2) will be true if we have `(x-1)(x-1)^(r-1)` = C, or greater; or `(x-1)^r` = C; or `x-1` = the rth root of C; or `x` = 1 + the rth root of C, or greater.
art: 417 | Examples | Find superior limits of the roots of the following equations. 1. `x^4-5x^3+37x^2-3x+39=0`. Here C = 5, and `r=1`; so the limit is `1+5=6`. 2. `x^5+7x^4-12x^3-49x^2+52x-13=0`. Here the limit is 1 + the square root of 49 = `1+7=8`. 3. `x^4+11x^2-25x-67=0`. By supposing the second term `+0x^3`, we have `r=3`; hence the limit is `1+∛67`, or 6. 4. `3x^3-2x^2-11x+4=0`. Dividing by 3, `x^3-(2/3)x^2-(11/3)x+4/3=0`. Here the limit is `1+11/3`, or 5.
q: Find a superior limit of the roots of `x^4-5x^3+37x^2-3x+39=0`. {6}
q: Of `x^5+7x^4-12x^3-49x^2+52x-13=0`. {8 @= 1+49^(1/2)}
q: Of `x^4+11x^2-25x-67=0`, the next whole number above `1+∛67`. {6}
q: Of `3x^3-2x^2-11x+4=0`, the next whole number above `1+11/3`. {5}
art: 418 | Inferior limit | To determine the inferior limit to the negative roots, change the signs of the alternate terms; this will change the signs of the roots (Art. 400); then, the superior limit of the roots of this equation, by changing its sign, will be the inferior limit of the roots of the proposed equation.
q: By changing the signs of the alternate terms of `x^3+5x^2+2x+8=0` it becomes `x^3-5x^2+2x-8=0`. Proposition I gives 9 as a superior limit of its roots; so what is an inferior limit of the roots of the first equation? {$ -9}
== 83 | General Theory of Equations | Signs between the roots; Sturm's theorem
art: 419 | Proposition III | If the real roots of an equation, taken in the order of their magnitudes, be `a`, `b`, `c`, `d`, etc., `a` being greater than `b`, `b` greater than `c`, and so on; then, if a series of numbers, `a'`, `b'`, `c'`, `d'`, etc., in which `a'` is greater than `a`, `b'` a number between `a` and `b`, `c'` a number between `b` and `c`, and so on, be substituted for `x` in the proposed equation, the results will be alternately positive and negative. The first member of the proposed equation is equivalent to `(x-a)(x-b)(x-c)(x-d)...=0`. Substituting for `x` the proposed series of numbers, `(a'-a)(a'-b)(a'-c)...` is a + product, since all the factors are +; `(b'-a)(b'-b)(b'-c)...` is a - product, since only one factor is -; `(c'-a)(c'-b)(c'-c)...` is a + product, since two factors are -, and the rest +; and so on.
art: 419 | Corollaries | Corollary 1: if two numbers be successively substituted for `x`, in any equation, and give results with contrary signs, there must be one, three, five, or some odd number of roots between these numbers. Corollary 2: if two numbers, substituted for `x`, give results with the same sign, then between these numbers there must be two, four, or some even number of real roots, or no roots at all. Corollary 3: if a quantity `q`, and every quantity greater than `q`, render the results continually positive, `q` is greater than the greatest root of the equation. Corollary 4: hence, if the signs of the alternate terms be changed, and if `p`, and every quantity greater than `p`, renders the result positive, then `-p` is less than the least root of the equation. Illustration: if we form the equation whose roots are 5, 2, and -3, the result is `x^3-4x^2-11x+30=0`. Now, if we substitute any number whatever for `x`, greater than 5, the result is positive. If we put `x=5`, the result is zero, as it should be. If we substitute for `x` any number less than 5 and greater than 2, the result is negative. Putting `x=2`, the result is zero. Substituting for `x` any number less than 2, and greater than -3, the result is positive. Substituting -3, it is zero. Substituting a number less than -3, the result is negative. From Cors. 3 and 4, it is easy to find when we have passed all the real roots, either in the ascending or descending scale.
q: In `x^3-4x^2-11x+30=0`, whose roots are 5, 2, and -3, what is the result of substituting 3 for `x`? {$ -12 @ 27-36-33+30}
mc: Two numbers substituted for `x` give results with contrary signs. Between them there must be... | *an odd number of roots | an even number of roots | no root
art: 420 | Sturm's Theorem | To find the number of real and imaginary roots of an equation. In 1834, M. Sturm gained the mathematical prize of the French Academy of Sciences, by the discovery of a beautiful theorem, by means of which the number and situation of all the real roots of an equation can, with certainty, be determined. Let X = `x^n+Ax^(n-1)+Bx^(n-2)+...+Tx+V=0` be any equation of the nth degree, containing no equal roots; for if the given equation contains equal roots, these may be found (Art. 414), and its degree diminished by division. Let the first derived function of X (Art. 411) be denoted by X1. Divide X by X1 until the remainder is of a lower degree with respect to `x` than the divisor, and call this remainder, with its sign changed, X2. Divide X1 by X2 in the same manner, and so on, denoting the successive remainders, with their signs changed, by X3, X4, etc., until we arrive at a remainder which does not contain `x`, which must always happen, since the equation having no equal roots, there can be no factor containing `x` common to the equation and its first derived function. Let this remainder, having its sign changed, be called the last function. In these divisions, we may, to avoid fractions, either multiply or divide the dividends and divisors by any positive number, as this will not affect the signs of the functions. By this operation, we obtain the series of quantities X, X1, X2, X3, ... (1). Each member of this series is of a lower degree with respect to `x` than the preceding, and the last does not contain `x`. Call X the primitive function, and X1, X2, etc., auxiliary functions.
art: 421 | Lemmas I and II | Lemma I: two consecutive functions, X1, X2, for example, can not both vanish for the same value of `x`. From the process by which the functions are obtained, X = X1 Q1 - X2, X1 = X2 Q2 - X3, X2 = X3 Q3 - X4, and so on. If possible, let X1 = 0 and X2 = 0; then by the second equation X3 = 0; by the third X4 = 0; and proceeding in the same way, we shall find every following function = 0, and finally the last. But this is impossible, since the last does not contain `x`, and therefore can not vanish for any value of `x`. Lemma II (Art. 422): if one of the auxiliary functions vanishes for any particular value of `x`, the two adjacent functions must have contrary signs for the same value of `x`. Let us suppose that X3 = 0 when `x=a`; then, because X2 = X3 Q3 - X4, and X3 = 0, therefore X2 = -X4; that is, X2 and X4 have contrary signs.
art: 423 | Lemma III | If any of the auxiliary functions vanishes when `x=a`, and `h` be taken so small that no root of any of the other functions in series (1) lies between `a-h` and `a+h`, then will the number of variations and permanences, when `a-h` and `a+h` are substituted for `x` in this series, be precisely the same. Suppose the substitution of `a` for `x` causes the function X3 to vanish; then, by Art. 421, neither X2 nor X4 can vanish for the same value of `x`; and since when X3 vanishes, X2 and X4 have contrary signs (Art. 422), the signs of X2, X3, X4 must be + 0 - or - 0 +. And since `h` is taken so small that no root of X2 = 0 or X4 = 0 lies between `a-h` and `a+h`, the signs of these functions will continue the same whether we substitute `a-h` or `a+h`. Hence, whether X3 is + or -, there will be one variation and one permanence. So that no alteration in the number of variations and permanences can be made in passing from `a-h` to `a+h`.
art: 424 | Lemma IV | If `a` is a root of the equation X = 0, then the series of functions X, X1, X2, etc., will lose one variation of signs in passing from `a-h` to `a+h`; `h` being taken so small that no root of the function X1 = 0 lies between `a-h` and `a+h`. For `x` substitute `a+h` in the equation X = 0, and denote the result by H. Also put A, A', A'' for the values of X and its derived functions when `a` is substituted for `x`; then (Art. 411) H = A + A'`h` + `(1/2)`A''`h^2` + etc. But, since `a` is a root, A = 0, while A' can not be 0, since the equation has no equal roots. Hence H = `h`(A' + `(1/2)`A''`h` + etc.). Now `h` may be taken so small that the quantity within the parenthesis shall have the same sign as its first term A' (Art. 412); therefore the sign of X, when `x=a+h`, will be the same as the sign of X1. If we substitute `a-h`, by changing `h` into `-h`, the result is `-h`(A' - `(1/2)`A''`h` + etc.); for very small values of `h` its sign will be contrary to that of A'. Hence, when `x=a-h`, there is a variation of signs in the first two terms of the series X, X1; and when `x=a+h`, there is a continuation of the same sign. Therefore, one variation is lost in passing from `x=a-h` to `x=a+h`. If any of the auxiliary functions should vanish at the same time by making `x=a`, the number of variations will not be affected on this account (Art. 423), and therefore one variation of signs will still be lost.
art: 425 | Sturm's Theorem | If any two numbers, `p` and `q` (`p` being less than `q`), be substituted for `x` in the series of functions X, X1, X2, etc., the substitution of `p` for `x` giving `k` variations, and that of `q` for `x` giving `k'` variations; then `k-k'` will be the exact number of real roots of the equation X = 0, which lie between `p` and `q`. Let us suppose that minus infinity is substituted for `x`, and suppose that `x` continually increases and passes through all degrees of magnitude till it becomes 0, and finally reaches plus infinity. Now, it is evident that so long as `x`, with its minus sign, is less than any of the roots of the functions, no alteration will take place in the signs of any of these functions (Art. 419); but when `x` becomes equal to the least root of any of the auxiliary functions, although a change may occur in the sign of this function, yet we have seen (Art. 423) that it is the order only, and not the number of variations which is affected. But when `x` becomes equal to any of the roots of the primitive function, then one variation of signs is always lost. Since, then, a variation is always lost whenever the value of `x` passes through a root of the primitive function X = 0, and since a variation can not be lost in any other way, nor can one be ever introduced, it follows that the excess of the number of variations given by `x=p` above that given by `x=q` is exactly equal to the number of real roots of X = 0 which lie between `p` and `q`. Corollary: if the equation is of the nth degree, and `m` represents the number of real roots, then (Art. 396) the number of imaginary roots will be `n-m`.
art: 426 | The number of real roots | To determine the number of real roots, substitute minus infinity and plus infinity for `x` in the several functions, since the roots must all be comprised between these limits. In this case, the sign of each function will be that of its first term. If we substitute 0 for `x`, the number of variations lost from minus infinity to 0 will be the number of negative roots; and from 0 to plus infinity, the number of positive roots.
art: 427 | The situation of the roots | To determine the situation of each real root; that is, the figures between which it lies. Substitute 0, -1, -2, -3, etc., for `x`, in series (1), till we find a number which produces as many variations as `x` = minus infinity produced. This will be the limit of the negative roots. Substitute 1, 2, 3, etc., till we find a positive number which gives the same number of variations that `x` = plus infinity does. This will be the superior limit of the positive roots. By observing where variations are lost, we find the situation of the roots. If two or more variations are lost between two of the substitutions, take smaller numbers, until only one is lost. This is termed the separation of the roots.
art: 427 | Example 1 | Find the number and situation of the real roots of the equation `4x^3-12x^2+11x-3=0`. Here X = `4x^3-12x^2+11x-3`, and (Art. 411) X1 = `12x^2-24x+11`. Multiplying X by 3, to render the first term divisible by the first term of X1, and proceeding as in the method of finding the G.C.D. (Art. 108), we have for a remainder `-2x+2`. Canceling the factor +2, and changing the signs (Art. 420), we have X2 = `x-1`. Dividing X1 by X2, we have for a remainder -1; therefore X3 = +1. Put minus infinity and plus infinity for `x`, and we have (Art. 426): for `x` = minus infinity, the signs - + - +, three variations, so `k=3`; for `x` = plus infinity, + + + +, no variation, so `k'=0`. Hence `k-k'=3-0=3`, the number of real roots. For `x=0`, - + - +, three variations, so `k=3`. Hence there is (Art. 426) no real root between 0 and minus infinity. This we might also have learned from Art. 402, since there is no permanence in the proposed equation. It is best to substitute integral numbers first, and afterward fractional, if two or more roots are found to lie between two whole numbers. Or, substitute fractions at once: for `x=1/4` the signs give 3 variations; `x=1/2` makes X = 0; for `x=3/4`, 2 variations; `x=1` makes X = 0; for `x=1 1/4`, 1 variation; `x=1 1/2` makes X = 0; for `x=1 3/4` and plus infinity, 0 variations. The roots are `1/2`, 1, and `1 1/2`. A careful study of this example will serve to illustrate the theorem. Thus, we see that there are three changes of sign of the primitive function, two of the first auxiliary function, and one of the second. Again, while no variation is lost by the change of sign of either of the auxiliary functions, each change of sign of the primitive function occasions a loss of one variation.
q: For `4x^3-12x^2+11x-3=0`, the first auxiliary function X1. {$ 12x^2-24x+11}
q: Its roots: `x` = {1/2 @x: 4x^3-12x^2+11x-3=0} or {1 @x: 4x^3-12x^2+11x-3=0} or {1 1/2 @x: 4x^3-12x^2+11x-3=0}
art: 427 | Example 2 | How many real roots has the equation `x^3-3x^2+x-3=0`? Here X = `x^3-3x^2+x-3`, X1 = `3x^2-6x+1`, X2 = `x+2`, X3 = -25. For `x` = minus infinity the signs are - + - -, 2 variations, so `k=2`; for `x` = plus infinity, + + + -, 1 variation, so `k'=1`. Hence `k-k'=2-1=1`, the number of real roots. One variation is lost in passing from 2 to 4, and X = 0 when `x=3`; therefore the root is +3.
q: How many real roots has the equation `x^3-3x^2+x-3=0`? {1}
q: And what is that root? {3 @x: x^3-3x^2+x-3=0}
art: 427 | Exercises | Find the number and situation of the real roots in each of the following equations.
q: `x^3-2x^2-x+2=0`: how many real roots? {3} They are `x` = {$ -1 @x: x^3-2x^2-x+2=0} or {1 @x: x^3-2x^2-x+2=0} or {2 @x: x^3-2x^2-x+2=0}
q: `8x^3-36x^2+46x-15=0`: how many real roots? {3} One lies between 0 and 1, one between 1 and {2}, and one between {2} and 3.
chk: x=0 | 8x^3-36x^2+46x-15=-15
chk: x=1 | 8x^3-36x^2+46x-15=3
chk: x=2 | 8x^3-36x^2+46x-15=-3
chk: x=3 | 8x^3-36x^2+46x-15=15
q: `x^3-3x^2-4x+11=0`: how many real roots? {3} One between -2 and {$ -1}, one between 1 and {2}, and one between {3} and 4.
chk: x=-2 | x^3-3x^2-4x+11=-1
chk: x=-1 | x^3-3x^2-4x+11=11
chk: x=2 | x^3-3x^2-4x+11=-1
chk: x=3 | x^3-3x^2-4x+11=-1
chk: x=4 | x^3-3x^2-4x+11=11
q: `x^3-2x-5=0`: how many real roots? {1} It lies between {2} and 3.
chk: x=2 | x^3-2x-5=-1
chk: x=3 | x^3-2x-5=16
q: `x^3-15x-22=0`: how many real roots? {3} One root is {$ -2 @x: x^3-15x-22=0}, one between `-2 1/4` and `-2 1/2`, and one between 4 and {5}.
chk: x=4 | x^3-15x-22=-18
chk: x=5 | x^3-15x-22=28
q: `x^4-4x^3-3x+23=0`: how many real roots? {2} One between 2 and {3}, and one between {3} and 4.
chk: x=2 | x^4-4x^3-3x+23=1
chk: x=3 | x^4-4x^3-3x+23=-13
chk: x=4 | x^4-4x^3-3x+23=11
q: `x^4-2x^3-7x^2+10x+10=0`: how many real roots? {4} (The limits are -3 and -2; 0 and -1; 2 and 3; 2 and 3.)
chk: x=-3 | x^4-2x^3-7x^2+10x+10=52
chk: x=-2 | x^4-2x^3-7x^2+10x+10=-6
chk: x=-1 | x^4-2x^3-7x^2+10x+10=-4
chk: x=0 | x^4-2x^3-7x^2+10x+10=10
chk: x=2.5 | x^4-2x^3-7x^2+10x+10=-0.9375
chk: x=2 | x^4-2x^3-7x^2+10x+10=2
chk: x=3 | x^4-2x^3-7x^2+10x+10=4
q: `x^5-10x^3+6x+1=0`: how many real roots? {5} (The limits are -4 and -3; -1 and 0; -1 and 0; 0 and 1; 3 and 4.)
chk: x=-4 | x^5-10x^3+6x+1=-407
chk: x=-3 | x^5-10x^3+6x+1=10
chk: x=-1 | x^5-10x^3+6x+1=4
chk: x=-0.5 | x^5-10x^3+6x+1=-0.78125
chk: x=0 | x^5-10x^3+6x+1=1
chk: x=1 | x^5-10x^3+6x+1=-2
chk: x=3 | x^5-10x^3+6x+1=-8
== 84 | Resolution of Numerical Equations | Rational roots
art: 428 | Numerical equations | In the preceding articles we have demonstrated the most important propositions in the theory of equations, and in some cases have shown how to find their roots. The general solution of an equation higher than the fourth degree has never yet been effected. In the practical application of Algebra, however, numerical equations most frequently occur; and when the roots of these are real, they can always be found, either exactly or approximately. The way for doing this has been prepared in the preceding articles, by finding the limits of the roots, and separating them from each other.
art: 429 | Integral roots | Proposition I: to determine the integral roots of an equation. If `a` be an integral root of the equation A`x^4`+B`x^3`+C`x^2`+D`x`+E = 0, we shall have A`a^4`+B`a^3`+C`a^2`+D`a`+E = 0; therefore E/`a` = -A`a^3`-B`a^2`-C`a`-D. Now, since the second member of the last equation is evidently a whole number, E is divisible by `a`. Put E/`a` = E'; transpose D to the first member, and divide by `a`; this gives (E'+D)/`a` = -A`a^2`-B`a`-C; so `a` is also a divisor of E'+D. Put (E'+D)/`a` = D', transpose C, and divide by `a`; this gives (D'+C)/`a` = -A`a`-B; so `a` is a divisor of D'+C. Again, put (D'+C)/`a` = C', transpose B, divide by `a`, and (C'+B)/`a` = -A. Lastly, making (C'+B)/`a` = B', and transposing A, we have B'+A = 0. If, then, all these conditions are satisfied, `a` is a root of the proposed equation; but if any one of them fails, `a` is not a root. Hence, the Rule for finding the Integral Roots of an Equation: divide the last term of the equation by any of its divisors `a`, and add to the quotient the coefficient of the term containing `x`. Divide this sum by `a`, and add to the quotient the coefficient of `x^2`. Proceed in this manner unto the first term, and if `a` be a root, all these quotients will be whole numbers, and the result will be 0.
art: 429 | Corollaries | Corollary 1: it will be easier to ascertain whether +1 and -1 are roots, by trial. Also, by ascertaining the limits to the positive and negative roots (Art. 417), we may reduce the number of divisors. Corollary 2: if the first coefficient be not unity, the equation may have a fractional root. To determine if this be the case, transform the equation into one having its first coefficient unity (Art. 405, Cor. 1), and its roots integers (Art. 399). Corollary 3: when all the roots except two are integral, divide the equation and find the others (Art. 396, Cor. 1).
art: 429 | Example | Find the rational roots of the equation `x^3+3x^2-4x-12=0`. Here, by Art. 417, no positive root can exceed 1 + the square root of 12, or 4, and the limit of the negative roots is `1+3=4`. It is also found, by trial, that +1 and -1 are not roots. We then proceed to arrange the divisors of -12, among which it is possible to find the roots: the divisors +2, +3, +4, -2, -3, -4 give the quotients -6, -4, -3, +6, +4, +3; adding -4 gives -10, -8, -7, +2, 0, -1; dividing again, -5, (not whole), (not whole), -1, 0, (not whole); adding +3 gives -2, +2, +3; the quotients -1, -1, -1; adding +1 gives 0, 0, 0. Since -8, -7, and -1 are not divisible by +3, +4, and -4, we proceed no further with these divisors, as it is evident that they are not roots of the equation. The roots are +2, -2, and -3.
q: Find the rational roots of the equation `x^3+3x^2-4x-12=0`. `x` = {2 @x: x^3+3x^2-4x-12=0} or {$ -2 @x: x^3+3x^2-4x-12=0} or {$ -3 @x: x^3+3x^2-4x-12=0}
art: 429 | Exercises | Find the roots of the following equations. When any term is wanting, its place must be supplied with 0. When there are equal roots, they may be found (Art. 414), or having found one, reduce the degree of the equation by division, and proceed as before. Type the roots in any order.
q: `x^3-7x^2+36=0`. `x` = {3 @x: x^3-7x^2+36=0} or {6 @x: x^3-7x^2+36=0} or {$ -2 @x: x^3-7x^2+36=0}
q: `x^3-6x^2+11x-6=0`. `x` = {1 @x: x^3-6x^2+11x-6=0} or {2 @x: x^3-6x^2+11x-6=0} or {3 @x: x^3-6x^2+11x-6=0}
q: `x^3+x^2-4x-4=0`. `x` = {2 @x: x^3+x^2-4x-4=0} or {$ -1 @x: x^3+x^2-4x-4=0} or {$ -2 @x: x^3+x^2-4x-4=0}
q: `x^3-3x^2-46x-72=0`. `x` = {9 @x: x^3-3x^2-46x-72=0} or {$ -2 @x: x^3-3x^2-46x-72=0} or {$ -4 @x: x^3-3x^2-46x-72=0}
q: `x^3-5x^2-18x+72=0`. `x` = {3 @x: x^3-5x^2-18x+72=0} or {6 @x: x^3-5x^2-18x+72=0} or {$ -4 @x: x^3-5x^2-18x+72=0}
q: `x^4-10x^3+35x^2-50x+24=0`. `x` = {1 @x: x^4-10x^3+35x^2-50x+24=0} or {2 @x: x^4-10x^3+35x^2-50x+24=0} or {3 @x: x^4-10x^3+35x^2-50x+24=0} or {4 @x: x^4-10x^3+35x^2-50x+24=0}
q: `x^4+4x^3-x^2-16x-12=0`. `x` = {2 @x: x^4+4x^3-x^2-16x-12=0} or {$ -1 @x: x^4+4x^3-x^2-16x-12=0} or {$ -2 @x: x^4+4x^3-x^2-16x-12=0} or {$ -3 @x: x^4+4x^3-x^2-16x-12=0}
q: `x^4-4x^3-19x^2+46x+120=0`. `x` = {4 @x: x^4-4x^3-19x^2+46x+120=0} or {5 @x: x^4-4x^3-19x^2+46x+120=0} or {$ -2 @x: x^4-4x^3-19x^2+46x+120=0} or {$ -3 @x: x^4-4x^3-19x^2+46x+120=0}
q: `x^4-27x^2+14x+120=0`. `x` = {3 @x: x^4-27x^2+14x+120=0} or {4 @x: x^4-27x^2+14x+120=0} or {$ -2 @x: x^4-27x^2+14x+120=0} or {$ -5 @x: x^4-27x^2+14x+120=0}
q: `x^4+x^3-29x^2-9x+180=0`. `x` = {3 @x: x^4+x^3-29x^2-9x+180=0} or {4 @x: x^4+x^3-29x^2-9x+180=0} or {$ -3 @x: x^4+x^3-29x^2-9x+180=0} or {$ -5 @x: x^4+x^3-29x^2-9x+180=0}
q: `x^3-2x^2-4x+8=0`. `x` = {2 @x: x^3-2x^2-4x+8=0} or {2 @x: x^3-2x^2-4x+8=0} or {$ -2 @x: x^3-2x^2-4x+8=0}
chk: x=2 | 3x^2-4x-4=0
q: `x^3+3x^2-8x+10=0`: the rational root {$ -5 @x: x^3+3x^2-8x+10=0} and the other two {$ 1±√-1 @x: x^2-2x+2=0}
q: `x^4-9x^3+17x^2+27x-60=0`: the rational roots `x` = {4 @x: x^4-9x^3+17x^2+27x-60=0} or {5 @x: x^4-9x^3+17x^2+27x-60=0}, and the other two {$ ±√3 @x: x^2-3=0}
q: `2x^3-3x^2+2x-3=0`: the rational root {3/2 @x: 2x^3-3x^2+2x-3=0} and the other two {$ ±√-1 @x: x^2+1=0}
q: `3x^3-2x^2-6x+4=0`: the rational root {2/3 @x: 3x^3-2x^2-6x+4=0} and the other two {$ ±√2 @x: x^2-2=0}
q: `8x^3-26x^2+11x+10=0`: the rational root {5/2 @x: 8x^3-26x^2+11x+10=0} and the other two {$ 3/8±(1/8)√41 @x: 8x^2-6x-4=0}
q: `6x^4-25x^3+26x^2+4x-8=0`. `x` = {2 @x: 6x^4-25x^3+26x^2+4x-8=0} or {2 @x: 6x^4-25x^3+26x^2+4x-8=0} or {2/3 @x: 6x^4-25x^3+26x^2+4x-8=0} or {$ -1/2 @x: 6x^4-25x^3+26x^2+4x-8=0}
chk: x=2 | 24x^3-75x^2+52x+4=0
q: `x^4-9x^3+(45/4)x^2+(27/2)x-81/4=0`: the root `3/2` is taken {2} times, and the other two are {$ 3±3√2 @x: x^2-6x-9=0}
chk: x=3/2 | x^4-9x^3+(45/4)x^2+(27/2)x-81/4=0 | 4x^3-27x^2+(45/2)x+27/2=0
== 85 | Resolution of Numerical Equations | Horner's method of approximation
art: 430 | Horner's Method | Irrational Roots: Methods of Approximation. Having found all the integral roots, we must have recourse to methods of approximation, the best of which is Horner's. The principle of this method depends on the successive transformations of the given equation, by Synthetic Division (Art. 410), so as to diminish its roots at each step of the operation. Let the equation, one of whose roots is to be found, be P`x^n`+Q`x^(n-1)`+...+T`x`+V = 0. Suppose `a` to be the integral part of the root required, and `r`, `s`, `t`, ... the decimal digits taken in order, so that `x=a+r+s+t...`. Find `a` by trial, or by Sturm's theorem, and transform the equation into one whose roots shall be diminished by `a` (Art. 410). Let P`y^n`+Q'`y^(n-1)`+...+T'`y`+V' = 0 be the transformed equation; then the value of `y` is the decimal `r+s+t+...`; and since this root is contained between 0 and 1, we may easily find its first digit `r`. Again, let the roots of this equation be diminished by `r`, and let the transformed equation be P`z^n`+Q''`z^(n-1)`+...+T''`z`+V'' = 0. Now, the value of `z` in this equation is `s+t+...`, and the value of `s` lies between .00 and .1; that is, it is either .00, .01, .02, or .09. But since the figure `s` is in the second place of decimals, `z^2`, `z^3`, ... will be small, and we may generally find `s` from the equation T''`s`+V'' = 0; or `s` = -V''/T'', nearly. Having found `s`, diminish the roots of the last equation by `s`, and then from the last two terms of the resulting equation find `t`, the next decimal figure, and so on.
art: 431 | The trial divisor | The absolute number, or last term, is sometimes called the dividend, and the coefficient of the first power of the unknown quantity (as T'' or T''') the incomplete or trial divisor. The correctness of the values of `s`, `t`, etc., obtained by means of the trial divisor, will always be verified in the next operation. If too great or too small, the quotient figure must be increased or diminished. The accuracy with which each succeeding decimal figure may be found increases as the value of the figure decreases. In general, after finding three or four decimal figures, the rest may be obtained with sufficient accuracy by dividing V'' by T''.
art: 432 | Negative roots | By changing the signs of the alternate terms (Art. 400), and finding the positive roots of the resulting equation, we may obtain the negative roots of the proposed equation. Remark: it is generally easier to find the first decimal figure of the root by trial than by Sturm's theorem.
art: 433 | Example 1 | To illustrate this method, let it be required to find the positive root of the equation `x^2-4x-10.768649=0`. We readily find that `x` must be greater than 5, and less than 6; therefore `a=5`. We then proceed to transform this equation into another whose roots shall be less by 5 (see Art. 410): the 1st transformed equation is `y^2+6y-5.768649=0`. Here we may find the value of `y` nearly, by dividing 5.7 by 6, which gives .9; but this is too great, because we neglected `y^2`. If we assume `y=.8`, and deduct `y^2=.64` from 5.7, and then divide by 6, we see that `y` must be .8. Let us now transform the equation into another whose roots shall be less by .8: 2d transformed equation, `z^2+7.6z-.328649=0`. The approximate value of `z` in this equation is the second decimal figure of the root. This is readily found by dividing the absolute term by the coefficient of `z`, the first term, `z^2`, being now so small that it may be neglected. Thus, `.328/7.6=.04=s`. We next diminish the roots of the last equation by .04: the 3d transformed equation is `z'^2+7.68z'-.023049=0`. Here `z'` is nearly `.023/7.68=.003=t`. By diminishing the roots of the last equation by .003, we have the remainder zero, which shows that we have obtained the exact root, which is 5.843. By changing the sign of the second term of the proposed equation, we have `x^2+4x-10.768649=0`. The root of this equation may be found in a similar manner; it is 1.843. Hence, the two roots are +5.843 and -1.843.
q: Find the positive root of `x^2-4x-10.768649=0`. {5.843 @x: x^2-4x-10.768649=0}
q: The 1st transformed equation, roots less by 5. {$ y^2+6y-5.768649=0 @ (y+5)^2-4(y+5)-10.768649=0}
art: 433 | Example 2 | To illustrate this method further, let us form the equation whose roots are 3, `+√2`, `-√2`, which gives `x^3-3x^2-2x+6=0`. Let it now be required to find, by Horner's method, the root which lies between 1 and 2; that is, `√2`. One root lies between 1 and 2; hence `a=1`, and the first step is to transform the equation so as to diminish its roots by 1. Hence `y^3±0y^2-5y+2=0` is the first transformed equation. By dividing the absolute term 2 by 5, the trial divisor or coefficient of `y`, we find `r=.4`, and proceed to transform the equation so as to diminish its roots by .4. This gives `z^3+1.2z^2-4.52z+.064=0` for the 2d transformed equation; and for `s`, the next figure of the root, `.064/4.52=.01`. Transforming so as to diminish its roots by .01 gives `z'^3+1.23z'^2-4.4957z'+.018921=0`; and for the next figure of the root `t=.0189/4.495=.004`. Transforming so as to diminish its roots by .004, the last term becomes .000957944 and the coefficient of the first power -4.485812. We may obtain several of the succeeding figures accurately by division; thus, `.000957944/4.485812=.0002135`, which is true to the last decimal place, as will be found by extracting the square root of 2. Hence `x=1.4142135`.
q: The first transformed equation of `x^3-3x^2-2x+6=0`, roots less by 1. {$ y^3-5y+2=0 @ (y+1)^3-3(y+1)^2-2(y+1)+6=0}
q: The root of `x^3-3x^2-2x+6=0` between 1 and 2, to 7 decimal places. {1.4142135|1.4142136}
art: 433 | Example 3 | In practice it is customary to make some abridgments. Thus, mark with a star the coefficients of the unknown quantity in each transformed equation instead of rewriting it. Also, when the root is required only to five or six places of decimals, use about this number in the operation. Given `x^4-8x^3+14x^2+4x-8=0`, to find a value of `x`. The book's operation, carried out in columns, gives the root 5.236068. As the root is found only to six decimal places, carry the true divisor for the third figure (6) to five decimal places: this divisor is 66.50915, which multiplied by .006 gives eight decimal places; and the dividend ought to be carried thus far, to make the figure in the sixth decimal place of the root correct. The divisor 66.825, for the fifth figure of the root, requires to be carried only to three decimal places, for the product of this number by .00006 gives eight decimal places, as it ought to do. So the divisor for the last figure (8) of the root would require to be carried only to two decimal places. The numbers in the preceding columns require to be carried to still fewer places. The last three figures of the root may be obtained merely by division; thus, `.00454269/66.82571=.000068`, nearly. Observe that where decimals are omitted, we always take the figure next to the omitted places, to the nearest unit. Thus, .07752 is nearer .08 than .07; therefore, the former is taken.
q: Given `x^4-8x^3+14x^2+4x-8=0`, find the value of `x` between 5 and 6, to 6 decimal places. {5.236068}
art: 434 | The Rule | Horner's method may be applied to equations of any degree, and is the most elegant method of approximation yet discovered. It may be expressed by the following Rule: 1. Find, by trial, or by Sturm's theorem, the integral part of the required root. 2. Transform the equation (Art. 410) into another whose roots shall be those of the proposed equation, diminished by the part of the root already found. 3. With the absolute term in the first transformed equation for a dividend, and the coefficient of `x` for a divisor, find the first decimal figure of the root. 4. Transform the last equation into another whose roots shall be diminished by the part of the root already found, and from the first two terms of this equation, find the second figure of the root. 5. Continue this process till the root is found to the required degree of accuracy. 6. To find the negative roots, change the signs of the alternate terms, and proceed as for a positive root. Remarks: 1. If any figure, found by trial, is too great or too small, it will be made manifest in the next transformation (See Art. 431). 2. After finding three figures of the root, the next three may generally be obtained by dividing the absolute term by the coefficient of `x`.
art: 434 | Exercises | Find at least one value of `x` in each of the following.
q: `x^2+5x-12.24=0`. {1.8 @x: x^2+5x-12.24=0}
q: `x^2+12x-35.4025=0`. {2.45 @x: x^2+12x-35.4025=0}
q: `4x^2-28x-61.25=0`. {8.75 @x: 4x^2-28x-61.25=0}
q: `8x^2-120x+394.875=0`. {10.125 @x: 8x^2-120x+394.875=0}
q: `5x^2-7.4x-16.08=0`. {2.68 @x: 5x^2-7.4x-16.08=0}
q: `x^2-6x+6=0`, to 5 decimal places. {4.73205}
q: `x^3+4x^2-9x-57.623625=0`. {3.45 @x: x^3+4x^2-9x-57.623625=0}
q: `2x^3-50x+32.994306=0`. {4.63 @x: 2x^3-50x+32.994306=0}
q: `x^3+4x^2-5x-20=0`, to 5 decimal places. (The root is √5 = 2.2360680; the book prints 2.23608.) {2.23607|2.23608|2.23606}
q: `x^3-2x-5=0`, to 7 decimal places. {2.0945515}
q: `x^3+10x^2-24x-240=0`, to 7 decimal places. {4.8989795}
q: `x^4-8x^3+20x^2-15x+.5=0`, to 6 decimal places. {1.284724}
q: `x^4-59x^2+840=0`, to 7 decimal places. {4.8989795}
q: `2x^4+5x^3+4x^2+3x=8002`, to 6 decimal places. {7.335554}
q: `x^5+2x^4+3x^3+4x^2+5x=54321`, to 6 decimal places. {8.414455}
art: 435 | Roots of numbers | To extract the roots of numbers by Horner's Method. This is only a particular case of the solution of the equation `x^n=N`, or `x^n-N=0`; an equation of the nth degree, in which all the terms are wanting except the first and last. In performing the operation, observe that the successive integral figures have the same relation to each other that the successive decimal places have in the previous examples. In extracting any root, point off the given number into periods, as in the operation by the common rule. For an example, let it be required to find the cube root of 12977875; that is, one root of the equation `x^3-12977875=0`. The operation gives the figures 2, 3, and 5, so the root is 235. The reason for placing the figures as they are in the successive columns will be readily understood by using the numbers 200 and 30, instead of 2 and 3.
q: Find the cube root of 12977875. {235 @= 12977875^(1/3)}
q: By the same method find the cube root of 34012224. {324 @= 34012224^(1/3)}
q: The cube root of 9, to 6 decimal places. {2.080084}
q: The cube root of 30, to 6 decimal places. {3.107233|3.107232}
q: The fifth root of 68641485507. {147 @= 68641485507^(1/5)}
== 86 | Resolution of Numerical Equations | Approximation by double position; Newton's method
art: 436 | Double Position | Approximation by Double Position. Double Position furnishes one of the most useful methods of approximating to the roots of equations. It has the advantage of being applicable, whether the equation is fractional, radical, or exponential, or to any other form of function. Let X = 0 represent any equation; and suppose that `a` and `b`, substituted for `x`, give results, the one too small, and the other too great, so that one root lies between `a` and `b` (Art. 403). Let A and B be the results arising from the substitution of `a` and `b` for `x`, in the equation X = 0. Let `x=a+h`, and `b=a+k`; then, if we substitute `a+h` and `a+k` for `x`, in the equation X = 0, we shall have X = A + A'`h` + `(1/2)`A''`h^2` + etc., and B = A + A'`k` + `(1/2)`A''`k^2` + etc. Here, A', A'', etc., are the derived functions of A (Art. 411). Now, if `h` and `k` be so small that their second and higher powers may be neglected without much error, we shall have X - A = A'`h` nearly, and B - A = A'`k` nearly. Whence B - A : X - A :: A'`k` : A'`h` :: `k` : `h`; or B - A : `k` :: X - A : `h` (Art. 270); or B - A : `b-a` :: X - A : `h`, since `k=b-a`. Hence, we have the following Rule: find, by trial, two numbers which, substituted for `x`, give one a result too small, and the other too great. Then say, as the difference of the results is to the difference of the suppositions, so is the difference between the true and the first result, to the correction to be added to the first supposition. Substitute this approximate value for the unknown quantity, and find whether it is too small or too great; then, take two less numbers, such that the true root may lie between them, and proceed as before, and so on. It is generally best to begin with two integers which differ from each other by unity, and to carry the first approximation only to one place of decimals. In the next operation make the difference of the suppositions 0.1, and carry the 2d quotient to two places, and so on.
art: 436 | Example | Given `x^3+x^2+x=100`, to find `x`. Here, `x` lies between 4 and 5. Substitute these two numbers for `x` in the given equation: for 4, `x^3=64`, `x^2=16`, `x=4`, and the result is 84; for 5, `x^3=125`, `x^2=25`, `x=5`, and the result is 155. Then 155 - 84 = 71 : 5 - 4 = 1 :: 100 - 84 = 16 : 0.22; therefore `x=4.2`, the first approximation. Substituting 4.2 and 4.3 for `x`, and proceeding as before, we get for a second approximation `x=4.264`. Assuming `x=4.264` and 4.265, and continuing, we obtain `x=4.2644299`, nearly.
q: Given `x^3+x^2+x=100`: the result of substituting 4 for `x` {84 @= 64+16+4} and of substituting 5 {155 @= 125+25+5}
q: The first correction, `16/71`, to 2 decimal places. {0.23|0.22}
q: Given `x^3+x^2+x=100`, find `x` to 7 decimal places. {4.26443|4.2644299|4.2644300}
art: 436 | Exercises | Find one root of each of the following equations.
q: `x^3+30x=420`, to 7 decimal places. {6.1701032|6.170103}
q: `144x^3-973x=319`. {2.75 @x: 144x^3-973x=319}
q: `x^3+10x^2+5x=2600`, to 5 decimal places. {11.00679|11.0068}
q: `2x^3+3x^2-4x=10`, to 5 decimal places. {1.62482|1.62481}
q: `x^4-x^3+2x^2+x=4`, to 5 decimal places. {1.14699}
q: `∛(7x^3+4x^2)+√(10x(2x-1))=28`, to 5 decimal places. {4.51066}
art: 437 | Newton's Method | Newton's Method of Approximation. This method, now but little used, is briefly as follows. Find, by trial, a quantity `a` within less than 0.1 of the value of the root. Substitute `a+y` for `x` in the given equation, and it will be of this form: A + A'`y` + `(1/2)`A''`y^2` + `(1/6)`A'''`y^3` + etc. = 0 (Art. 411), where A, A', A'', etc., are what the proposed equation, the first derived polynomial, etc., become when `x=a`. From this equation, by transposing and dividing, we find `y` = -A/A' - `(1/2)`(A''/A')`y^2` - `(1/6)`(A'''/A')`y^3` - etc.; and since `y` is less than 0.1, `y^2` will be less than 0.01, `y^3` less than 0.001, and so on. Therefore, if the sum of the terms containing `y^2`, `y^3`, etc., be less than .01, we shall, in neglecting them, obtain a value of `y` within .01 of the truth. Putting `y` = -A/A', we have `x` = `a` - A/A'. This will differ from the true value of `x` by less than .01. Now, put `b` for this approximate value of `x`, and let `x=b+z`; we have then as before B + B'`z` + `(1/2)`B''`z^2` + `(1/6)`B'''`z^3` + etc. = 0; and as `z` is supposed to be less than .01, `z^2` will be less than .0001. If, then, we neglect the terms containing `z^2`, `z^3`, etc., we shall obtain a probable value of `z` within .0001; and so on. Applying the successive corrections, we obtain the value of `x`.
q: For `x^3-2x-5=0`, take `a=2`. Then A = -1 and A' = 10. The first correction `y` = -A/A' is {0.1 @= 1/10}, so `x` is about 2.1.
art: 437 | Newton's example | Newton gave but a single example, viz.: required to find the value of `x` in the equation `x^3-2x-5=0`. Answer: `x=2.09455149`.
q: Required to find the value of `x` in the equation `x^3-2x-5=0`, to 8 decimal places. {2.09455148|2.09455149}
== 87 | Resolution of Numerical Equations | Cardan's rule for cubic equations
art: 438 | Cardan's Rule | Cardan's Rule for solving Cubic Equations. In its most general form, a cubic equation may be represented by `x^3+px^2+qx+r=0`; but as we can always take away the second term (Art. 407), we will suppose, to avoid fractions, that it is reduced to the form `x^3+3qx+2r=0`. Assume `x=y+z`, and the equation becomes `y^3+z^3+3yz(y+z)+3q(y+z)+2r=0`. Now, since we have two unknown quantities in this equation, and have made only one supposition respecting them, we are at liberty to make another. Let, therefore, `yz=-q`. Substituting, we have `y^3+z^3+2r=0`; but since `yz=-q`, `z^3=-q^3/y^3`; hence `y^3-q^3/y^3+2r=0`. Whence `y^3=-r+√(r^2+q^3)`; and similarly `z^3=-r-√(r^2+q^3)`; the radical being positive in one, and negative in the other, by reason of the relation `yz=-q`. And since `x=y+z`, we have `x=∛(-r+√(r^2+q^3))+∛(-r-√(r^2+q^3))`. This formula will give one of the roots. The others may be found by reducing the equation (Art. 396, Cor. 1).
q: In Cardan's rule, `x=y+z` and `yz=-q`; then `y^3+z^3` equals what? {$ -2r}
art: 439 | The irreducible case | If `r^2+q^3` be negative, that is, if `r^2+q^3<0`, the values of `x` become apparently imaginary when they are actually real, and we shall now show that Cardan's Method of Solution does not extend to those cases in which the equation has three real and unequal roots. Suppose the one real root (Art. 401, Cor. 3) to be `a`; and the other two arising from the solution of a quadratic to be `b+√(3c)` and `b-√(3c)`, in which, if `3c` be positive, the roots are real, and if `3c` be negative, they are imaginary; and because the second term of the equation is 0, we have (Art. 398) `0=a+(b+√(3c))+(b-√(3c))=a+2b`; `3q=a*2b+b^2-3c=-3b^2-3c`; `2r=-a(b^2-3c)=2b^3-6bc`. Hence we have `r^2+q^3=(b^3-3bc)^2-(b^2+c)^3=-9b^4c+6b^2c^2-c^3=-c(3b^2-c)^2`; so `√(r^2+q^3)=(3b^2-c)√-c`. Now, this expression is real when `c` is negative, and imaginary when `c` is positive, or when the equation has three real roots. If `c=0`, the roots are `a`, `b`, and `b`; hence, Cardan's Rule is applicable to equations containing two equal roots.
tf: Cardan's rule gives the roots in real form when the cubic has three real and unequal roots. {F}
art: 440 | Example | In illustration of the apparent paradox that when the roots of the quadratic equation, Art. 438, are imaginary, the roots of the cubic equation are all real, take the following example: to find the three roots of the equation `x^3-15x-4=0`. By substituting `y+z` for `x`, we have `y^3+z^3+3yz(y+z)-15(y+z)-4=0`. And, since `3yz=15`, `y^3+z^3-4=0`. From the solution of these equations, we obtain `y^3=2+11√-1`. By actual multiplication, we find that `y=2+√-1`; likewise, `z^3=2-11√-1`, and `z=2-√-1`. Hence `x=y+z=(2+√-1)+(2-√-1)=4`. By dividing the given equation by `x-4`, we find the other two roots are `x=-2+√3`, and `-2-√3`. As no means have yet been discovered for reducing the imaginary forms to real values, Cardan's rule fails when all the roots are real. This is the Irreducible Case of cubic equations.
q: Find the three roots of the equation `x^3-15x-4=0`. `x` = {4 @x: x^3-15x-4=0} or {$ -2+√3 @x: x^3-15x-4=0} or {$ -2-√3 @x: x^3-15x-4=0}
art: 441 | Examples | The following examples, containing one real and two imaginary roots, may be solved by Cardan's rule. When the equation contains the second term, remove it (Art. 407), and reduce the equation to the form `x^3+3qx+2r=0`. Then `x=∛(-r+√(r^2+q^3))+∛(-r-√(r^2+q^3))` will be the real root of the proposed equation. Having the real root, the imaginary roots may be found by reducing the equation to a quadratic (Art. 396, Cor. 1). Example 1: solve the equation `v^3+3v^2+9v-13=0`. Substituting `x-1` for `v` (Art. 407), we have `x^3+6x-20=0`. Comparing this with the equation `x^3+3qx+2r=0`, we find `q=2`, `r=-10`; hence `x=∛(10+√108)+∛(10-√108)=2.732-.732=2`. Whence `v=x-1=2-1=1`. The other two roots are easily found to be `-1±3√-1`.
q: Solve the equation `v^3+3v^2+9v-13=0`: the real root {1 @x: x^3+3x^2+9x-13=0} and the other two {$ -1±3√-1 @x: x^2+2x+10=0}
q: `x^3-9x+28=0`: the real root {$ -4 @x: x^3-9x+28=0} and the other two {$ 2±√-3 @x: x^2-4x+7=0}
q: `x^3+6x-2=0`: the real root, `∛4-∛2`, to 5 decimal places. {0.32748}
q: `x^3-6x^2+13x-10=0`: the real root {2 @x: x^3-6x^2+13x-10=0} and the other two {$ 2±√-1 @x: x^2-4x+5=0}
q: `x^3-9x^2+6x-2=0`: the real root, to 6 decimal places. {8.306674}
art: 441 | Remark | Cardan's Rule, together with those of Ferrari, Euler, Descartes, and others, are regarded, since the discovery of Horner's method, and Sturm's theorem, as little more than analytical curiosities.
== 88 | Resolution of Numerical Equations | Reciprocal or recurring equations; binomial equations
art: 442 | Recurring Equations | A Recurring or Reciprocal Equation is one such that if `a` be one of its roots, the reciprocal of `a` will be another. Proposition I: in a recurring equation the coefficients, when taken in a direct and in an inverse order, are the same. Let `x^n+Ax^(n-1)+Bx^(n-2)+...+Sx^2+Tx+V=0` be a recurring equation; that is, one that is satisfied by the substitution of the reciprocal of `x` for `x`. This gives `1/x^n+A/x^(n-1)+B/x^(n-2)+...+S/x^2+T/x+V=0`; and multiplying by `x^n`, `1+Ax+Bx^2+...+Sx^(n-2)+Tx^(n-1)+Vx^n=0`, which proves the proposition. Such equations are called Recurring Equations, from the forms of their coefficients; and Reciprocal Equations, from the forms of their roots.
tf: If `a` is a root of a recurring equation, then `1/a` is also a root. {T}
art: 442 | Propositions II and III | Proposition II: a recurring equation of an odd degree has one of its roots equal to +1, when the signs of the like coefficients are different, but equal to -1, when their signs are alike. Since every power of +1 is positive, when the signs of the like coefficients are different, if we substitute +1 for `x` the corresponding terms will destroy each other. When the signs of the like coefficients are the same, since one will belong to an odd, and the other to an even power, if we substitute -1 for `x`, the corresponding terms will destroy each other. Such equations may, therefore, be reduced one degree lower by dividing by `x-1`, or `x+1`. Proposition III: a recurring equation of an even degree, whose like coefficients have opposite signs, is divisible by `x^2-1`, and therefore two of its roots are +1 and -1. Let `x^(2n)+Ax^(2n-1)+Bx^(2n-2)+...-Bx^2-Ax-1=0` be an equation of the kind specified. It may evidently be arranged thus, and be divisible by `x^2-1` (Art. 83): `(x^(2n)-1)+Ax(x^(2n-2)-1)+Bx^2(x^(2n-4)-1)+...=0`. Corollary: an equation of this form may therefore be reduced two degrees lower by either common or synthetic division.
q: The recurring equation `x^3+5x^2+5x+1=0` is of an odd degree, and the signs of its like coefficients are alike. Which number is one of its roots? {$ -1 @x: x^3+5x^2+5x+1=0}
art: 442 | Proposition IV | Every recurring equation of an even degree above the second, may be reduced to an equation of half that degree, when the signs of the corresponding terms are alike. For `x^(2n)-Ax^(2n-1)+Bx^(2n-2)-...+Bx^2-Ax+1=0`, by dividing by `x^n`, and collecting the pairs of terms equi-distant from the extremes, becomes of the form `(x^n+1/x^n)-A(x^(n-1)+1/x^(n-1))+B(x^(n-2)+1/x^(n-2))-...=0`. Let `x+1/x=z`; then `x^2+1/x^2=z^2-2`, by squaring; also `x^3+1/x^3=(x^2+1/x^2)z-(x+1/x)=(z^2-2)z-z`; and generally `x^n+1/x^n=(x^(n-1)+1/x^(n-1))z-(x^(n-2)+1/x^(n-2))`. Hence, each of the binomials may be expressed in terms of `z`, and the resulting equation will be of the nth degree.
q: If `x+1/x=z`, then `x^2+1/x^2` = {$ z^2-2} (square both sides: `x^2+2+1/x^2=z^2`)
art: 442 | Example | Given `x^4-5x^3+6x^2-5x+1=0`, to find `x`. Here, dividing by `x^2`, `x^2-5x+6-5/x+1/x^2=0`, or `(x^2+1/x^2)-5(x+1/x)+6=0`. Let `x+1/x=z`; then `z^2-5z+4=0`, and `z=4`, or 1. Putting `x+1/x` equal to each of these values of `z`, we obtain for the four values of `x`, `2±√3` and `(1/2)(1±√-3)`. The second of these values is the reciprocal of the first, and the fourth of the third, as may be shown, thus: `1/(2+√3)=(2-√3)/((2+√3)(2-√3))=(2-√3)/(4-3)=2-√3`.
q: Given `x^4-5x^3+6x^2-5x+1=0`: the values of `z` are {4 @x: x^2-5x+4=0} and {1 @x: x^2-5x+4=0}
q: And the four values of `x`: {$ 2±√3 @x: x^2-4x+1=0} and {$ 1/2±(1/2)√-3 @x: x^2-x+1=0}
art: 442 | Exercises | Examples in Recurring Equations. Type the roots in any order; a pair written with ± is one answer.
q: `x^4-10x^3+26x^2-10x+1=0`. `x` = {$ 3±2√2 @x: x^2-6x+1=0} or {$ 2±√3 @x: x^2-4x+1=0}
q: `x^4-(5/2)x^3+2x^2-(5/2)x+1=0`. `x` = {2 @x: x^4-(5/2)x^3+2x^2-(5/2)x+1=0} or {1/2 @x: x^4-(5/2)x^3+2x^2-(5/2)x+1=0} or {$ ±√-1 @x: x^2+1=0}
q: `x^4-3x^3+3x-1=0`. `x` = {$ ±1 @x: x^2-1=0} or {$ 3/2±(1/2)√5 @x: x^2-3x+1=0}
q: `x^5-11x^4+17x^3+17x^2-11x+1=0`. `x` = {$ -1 @x: x^5-11x^4+17x^3+17x^2-11x+1=0} or {$ 9/2±(1/2)√77 @x: x^2-9x+1=0} or {$ 3/2±(1/2)√5 @x: x^2-3x+1=0}
q: `4x^6-24x^5+57x^4-73x^3+57x^2-24x+4=0`. `x` = {2 @x: 4x^6-24x^5+57x^4-73x^3+57x^2-24x+4=0} or {1/2 @x: 4x^6-24x^5+57x^4-73x^3+57x^2-24x+4=0} or {$ 1/2±(1/2)√-3 @x: x^2-x+1=0}
chk: x=2 | 24x^5-120x^4+228x^3-219x^2+114x-24=0
art: 442 | The double roots | In the last example, 2 and `1/2` are each double roots (the book lists `2, 1/2, 2, 1/2`): the equation is `(2x^2-5x+2)^2(x^2-x+1)=0`.
art: 443 | Binomial Equations | Binomial equations are those of the form `y^n±A=0`. Let the nth root of A be `a`; that is, A = `a^n`. Then `y^n±a^n=0`. Let `y=ax`; then `a^nx^n±a^n=0`, or `x^n±1=0`, which is a recurring equation.
art: 444 | Properties | I. The roots of the equation `x^n±1=0` are all unequal; for the first derived polynomial `nx^(n-1)` evidently has no divisor in common with `x^n±1`, and therefore there are no equal roots (Art. 414). II. If `n` be even, the equation `x^n-1=0`, or `x^n=1`, has two real roots, +1 and -1, and no more, because no other real number can, by its involution, produce 1. By dividing `x^n-1=0` by `(x+1)(x-1)=x^2-1`, we have `x^(n-2)+x^(n-4)+...+x^4+x^2+1=0`, a recurring equation, having `n-2` imaginary roots. For example, the equation `x^6=1`, or `x^6-1=0`, divided by `x^2-1`, gives `x^4+x^2+1=0`; whence `x=±√((-1±√-3)/2)`. This gives for the six roots of 1: +1, -1, and the four square roots, plus and minus, of `(-1+√-3)/2` and of `(-1-√-3)/2`.
q: How many real roots has `x^6-1=0`? {2}
art: 444 | Odd n | III. If `n` be odd, the equation `x^n-1=0` has only one real root, viz.: +1; for +1 is the only real number of which the odd powers are +1. Dividing `x^n-1=0` by `x-1`, we have `x^(n-1)+x^(n-2)+x^(n-3)+...+x^2+x+1=0`, a recurring equation, having `n-1` imaginary roots. For example, the equation `x^3=1`, or `x^3-1=0`, divided by `x-1`, gives `x^2+x+1=0`; whence `x=(-1±√-3)/2`. Hence, the three third roots of 1 are 1, `(-1+√-3)/2`, `(-1-√-3)/2`.
q: The three cube roots of 1: `x` = {1 @x: x^3-1=0} or {$ -1/2±(1/2)√-3 @x: x^2+x+1=0}
art: 444 | x^n = -1 | IV. If `n` be even, the equation `x^n+1=0`, or `x^n=-1`, has no real root, since the nth root of -1 is then impossible. Hence, all the roots of this equation are imaginary. For example, the four roots of the recurring equation `x^4+1=0` (Art. 442) are `(-1+√-1)/√2`, `(-1-√-1)/√2`, `(1+√-1)/√2`, `(1-√-1)/√2`. V. If `n` be odd, the equation `x^n+1=0`, or `x^n=-1`, has one real root, viz.: -1, and no more, because this is the only real number of which an odd power is -1. For example, `x^3+1=0`, divided by `x+1`, gives `x^2-x+1=0`; whence `x=(1±√-3)/2`. Therefore, the three third roots of -1 are -1, `(1+√-3)/2`, and `(1-√-3)/2`. Binomial equations have other properties, but some of them can not be discussed without a knowledge of Analytical Trigonometry.
q: How many real roots has `x^4+1=0`? {0}
q: The three cube roots of -1: `x` = {$ -1 @x: x^3+1=0} or {$ 1/2±(1/2)√-3 @x: x^2-x+1=0}
q: Find the four fourth roots of unity. `x` = {$ ±1 @x: x^2-1=0} or {$ ±√-1 @x: x^2+1=0}
art: 444 | The fifth roots | Find the five fifth roots of unity. Answer: 1, and the four roots `(1/4)(√5-1±√(-10-2√5))` and `-(1/4)(√5+1∓√(-10+2√5))`. THE END.
q: One of the five fifth roots of unity is real. Which? {1}
EOF
make-book.ps1: builds any book: -Book algebra2 writes public\books\algebra2.json.
cat > /root/rays-rebuild/make-book.ps1 <<'EOF'
# Builds public/books/<id>.json from a hand-corrected book in source/<Book>.txt (format at the top of source/primary.txt).
# Generates every table exactly, works out {?} answers, and checks typed answers wherever the question is plain
# arithmetic ("How many are 3 and 5?", "One from 9?", "Nine and how many make 17?", "How many twos in 8?").
# Usage: powershell -ExecutionPolicy Bypass -File RaysArithmetic\tools\make-book.ps1 [-Book primary|intellectual|...]
param([string]$Book = 'primary')
$root = Split-Path -Parent (Split-Path -Parent $MyInvocation.MyCommand.Path)
$src = Get-Content "$root\source\$Book.txt" -Encoding UTF8
# the book's id, title, shelf line and color: "@book: primary1877 | Ray's New Primary Arithmetic | 1877 - Book One | #2f6f8f"
$head = $src | Where-Object { $_ -match '^@book: ' } | Select-Object -First 1
if (-not $head) { throw "source\$Book.txt has no @book: line" }
$bk = ($head -replace '^@book: ', '') -split '\s*\|\s*'
$script:errors = New-Object System.Collections.ArrayList
# ---------- numbers ----------
$ones = @{ naught = 0; zero = 0; one = 1; two = 2; three = 3; four = 4; five = 5; six = 6; seven = 7; eight = 8; nine = 9; ten = 10; eleven = 11; twelve = 12; thirteen = 13; fourteen = 14; fifteen = 15; sixteen = 16; seventeen = 17; eighteen = 18; nineteen = 19 }
$tens = @{ twenty = 20; thirty = 30; forty = 40; fifty = 50; sixty = 60; seventy = 70; eighty = 80; ninety = 90 }
$plural = @{ ones = 1; twos = 2; threes = 3; fours = 4; fives = 5; sixes = 6; sevens = 7; eights = 8; nines = 9; tens = 10 }
function WordNum([string]$w) {
$w = $w.ToLower()
if ($w -match '^\d+$') { return [long]$w }
if ($w -eq 'one hundred' -or $w -eq 'hundred') { return 100 }
if ($ones.ContainsKey($w)) { return $ones[$w] }
if ($tens.ContainsKey($w)) { return $tens[$w] }
if ($w -match '^(\w+)-(\w+)$' -and $tens.ContainsKey($Matches[1]) -and $ones.ContainsKey($Matches[2])) { return $tens[$Matches[1]] + $ones[$Matches[2]] }
return $null
}
$numRx = '\b(?:\d+|one hundred|(?:twenty|thirty|forty|fifty|sixty|seventy|eighty|ninety)(?:-(?:one|two|three|four|five|six|seven|eight|nine))?|naught|zero|eleven|twelve|thirteen|fourteen|fifteen|sixteen|seventeen|eighteen|nineteen|one|two|three|four|five|six|seven|eight|nine|ten)\b'
# Plain arithmetic in a question part -> its value, or $null when the part isn't plain arithmetic.
# Reads left to right, the way the book works them ("2 and 5 are 7; 7 less 3 are 4"); every x comes first in the book.
function Calc([string]$t) {
$s = ' ' + $t.ToLower() + ' '
$s = $s -replace '[?:]', ' ' -replace '\s*=\s*', ' ' -replace ',', ' '
# "Twelve are how many times 3?" -> 12 / 3
# "What are 2/3 of 9?" -> 6
if ($s -match '^\s*(?:what (?:are|is)\s+)?(\d+)/(\d+) of (\d+)\s*$') { $v = [int]$Matches[3] * [int]$Matches[1]; if ($v % [int]$Matches[2]) { return $null }; return [int]($v / [int]$Matches[2]) }
if ($s -match "^\s*($numRx)\s+(?:are|is) how many times\s+($numRx)\s*$") { $a = WordNum $Matches[1]; $b = WordNum $Matches[2]; if ($a % $b) { return $null }; return [int]($a / $b) }
$s = $s -replace '\bare how many\b', ' ' -replace '\bhow many (are|is)\b', ' ' -replace '\bhow many\b', ' '
# "N from M leaves how many" / "N from M" / "N taken away from M"
if ($s -match "^\s*($numRx)\s+(?:taken\s+)?(?:away\s+)?from\s+($numRx)\s*(?:leaves)?\s*$") { return (WordNum $Matches[2]) - (WordNum $Matches[1]) }
# "N and how many make M"
if ($s -match "^\s*($numRx)\s+and\s+make\s+($numRx)\s*$") { return (WordNum $Matches[2]) - (WordNum $Matches[1]) }
# "how many twos in 8"
if ($s -match "^\s*(ones|twos|threes|fours|fives|sixes|sevens|eights|nines|tens)\s+in\s+($numRx)\s*$") { return [int]((WordNum $Matches[2]) / $plural[$Matches[1]]) }
# "times is 2 contained in 4" / "2 in 4"
if ($s -match "^\s*(?:times is\s+)?($numRx)\s+(?:contained\s+)?in\s+($numRx)\s*$") { return [int]((WordNum $Matches[2]) / (WordNum $Matches[1])) }
$s = $s -replace '\bmultiplied by\b', ' x ' -replace '\bdivided by\b', ' / ' -replace '\btimes\b', ' x ' -replace '\btime\b', ' x ' -replace '\bplus\b', ' + ' -replace '\bminus\b', ' - ' -replace '\bless\b', ' - ' -replace '\band\b', ' + '
$tok = @([regex]::Matches($s, "$numRx|[-+x/]") | ForEach-Object { $_.Value })
$rest = ([regex]::Replace($s, "$numRx|[-+x/]", ' ')).Trim()
if ($rest -or $tok.Count -lt 3 -or $tok.Count % 2 -eq 0) { return $null }
$v = WordNum $tok[0]; if ($null -eq $v) { return $null }
for ($i = 1; $i -lt $tok.Count; $i += 2) {
$b = WordNum $tok[$i + 1]; if ($null -eq $b) { return $null }
switch ($tok[$i]) { '+' { $v += $b } '-' { $v -= $b } 'x' { $v *= $b } '/' { if ($v % $b) { return $null }; $v = $v / $b } default { return $null } }
}
return [long]$v
}
# ---------- exact fractions ----------
# {~ 1/2 + 1/4} works the answer out exactly: whole numbers, a/b, mixed numbers written 1_3/4, + - * / and ( ).
# A fraction is written without spaces (3/4); division between numbers needs spaces (12 / 3).
# The answer is written the book's way: 3/4, 2 1/3, 5.
function Gcd([long]$a, [long]$b) { $a = [Math]::Abs($a); $b = [Math]::Abs($b); while ($b) { $t = $a % $b; $a = $b; $b = $t }; [long][Math]::Max($a, 1) }
function Rat([long]$n, [long]$d) { if ($d -lt 0) { $n = -$n; $d = -$d }; $g = Gcd $n $d; ,@([long]($n / $g), [long]($d / $g)) }
function RatStr($r) {
$n = $r[0]; $d = $r[1]
if ($d -eq 1) { return "$n" }
$w = [long][Math]::Truncate($n / $d); $f = $n - $w * $d
if ($w) { "$w $([Math]::Abs($f))/$d" } else { "$n/$d" }
}
function EvalFrac([string]$e) {
$script:tk = @([regex]::Matches(($e -replace '(?<=\d),(?=\d{3})', ''), '\d*\.\d*\(\d+\)|\d+_\d+/\d+|\d+/\d+|\d*\.\d+|\d+|[-+*/()]') | ForEach-Object { $_.Value }); $script:ti = 0
function Atom {
$x = $script:tk[$script:ti]; $script:ti++
if ($x -eq '(') { $v = Sum; $script:ti++; return ,$v }
# a circulate: .45(3) = .4533..., 104.(14) = 104.1414...; the figures in ( ) repeat
if ($x -match '^(\d*)\.(\d*)\((\d+)\)$') {
$w = [long]('0' + $Matches[1]); $a = $Matches[2]; $rp = $Matches[3]
$num = [long]('0' + $a + $rp) - [long]('0' + $a); $den = [long](('9' * $rp.Length) + ('0' * $a.Length))
return ,(Rat ($w * $den + $num) $den)
}
if ($x -match '^(\d+)_(\d+)/(\d+)$') { return ,(Rat ([long]$Matches[1] * [long]$Matches[3] + [long]$Matches[2]) ([long]$Matches[3])) }
if ($x -match '^(\d+)/(\d+)$') { return ,(Rat ([long]$Matches[1]) ([long]$Matches[2])) }
if ($x -match '^\d+$') { return ,(Rat ([long]$x) 1) }
if ($x -match '^(\d*)\.(\d+)$') { return ,(Rat ([long]($Matches[1] + $Matches[2])) ([long][Math]::Pow(10, $Matches[2].Length))) }
throw "bad token '$x' in $e"
}
function Prod {
$v = Atom
while ($script:ti -lt $script:tk.Count -and $script:tk[$script:ti] -match '^[*/]$') {
$op = $script:tk[$script:ti]; $script:ti++; $b = Atom
if ($op -eq '*') { $v = Rat ($v[0] * $b[0]) ($v[1] * $b[1]) } else { $v = Rat ($v[0] * $b[1]) ($v[1] * $b[0]) }
}
,$v
}
function Sum {
$v = Prod
while ($script:ti -lt $script:tk.Count -and $script:tk[$script:ti] -match '^[-+]$') {
$op = $script:tk[$script:ti]; $script:ti++; $b = Prod
$n = $(if ($op -eq '+') { $v[0] * $b[1] + $b[0] * $v[1] } else { $v[0] * $b[1] - $b[0] * $v[1] })
$v = Rat $n ($v[1] * $b[1])
}
,$v
}
$r = Sum
if ($script:ti -ne $script:tk.Count) { throw "couldn't read all of: $e" }
$script:lastRat = $r
RatStr $r
}
# a value as a circulate, the repeating figures in ( ): 77/111 -> ".(693)", 5/36 -> ".13(8)"
function AsRep($r) {
$n = [long]$r[0]; $d = [long]$r[1]; $w = [long][Math]::Floor($n / $d); $rem = $n - $w * $d
$digits = New-Object Text.StringBuilder; $seen = @{}
while ($rem -and -not $seen.ContainsKey($rem)) { $seen[$rem] = $digits.Length; $rem *= 10; [void]$digits.Append([long][Math]::Floor($rem / $d)); $rem = $rem % $d }
$s = $digits.ToString(); $lead = $(if ($w) { "$w" } else { '' })
if (-not $rem) { if ($s) { return "$lead.$s" } else { return "$w" } }
$k = $seen[$rem]; "$lead.$($s.Substring(0, $k))($($s.Substring($k)))"
}
# a value as the book's complex decimal, carried to $p places: 41 1391/1875 -> "41.7422 2/3"; exact decimals stay pure
function AsCplx($r, [int]$p) {
$n = [long]$r[0]; $d = [long]$r[1]; $scale = [long][Math]::Pow(10, $p)
$N = $n * $scale; $q = [long][Math]::Floor($N / $d); $rem = $N - $q * $d
$ip = [long][Math]::Floor($q / $scale); $dec = ($q % $scale).ToString().PadLeft($p, '0')
if (-not $rem) { $dec = $dec.TrimEnd('0'); if (-not $dec) { return "$ip" } }
$s = $(if ($ip) { "$ip" } else { '' }) + '.' + $dec
if ($rem) { $g = Gcd $rem $d; $s += " $($rem / $g)/$($d / $g)" }
$s
}
# the same value written as a decimal when it ends (denominator only 2s and 5s): "2 39/50" -> "2.78"; else unchanged
function AsDec([string]$v) {
if ($v -notmatch '^(-?\d+)( (\d+)/(\d+)|/(\d+))?$') { return $v }
if (-not $Matches[2]) { return $v }
if ($Matches[3]) { $w = [long]$Matches[1]; $n = [long]$Matches[3]; $d = [long]$Matches[4] } else { $w = 0; $n = [long]$Matches[1]; $d = [long]$Matches[5] }
$t = $d; while ($t % 2 -eq 0) { $t /= 2 }; while ($t % 5 -eq 0) { $t /= 5 }; if ($t -ne 1) { return $v }
$s = ([decimal]$w + [decimal]$n / [decimal]$d).ToString('0.##########################')
if ($s.StartsWith('0.')) { $s.Substring(1) } else { $s }
}
# ---------- the book's tables ----------
function Table([string]$op, [int]$n) {
$f = New-Object System.Collections.ArrayList
# t = the book's line, q = the same fact asked as a question (the app's drill and the voice use both)
function F($t, $a, $b, $r) {
$q = switch ($op) { 'add' { "How many are $a and $b?" } 'sub' { "$a from $b leaves how many?" } 'mul' { if ($a -eq 1) { "How many is 1 time $b?" } else { "How many are $a times $b?" } } 'div' { "How many times is $a contained in $b?" } }
[void]$f.Add([ordered]@{ t = $t; q = $q; a = $a; b = $b; r = $r })
}
switch ($op) {
'add' { foreach ($k in 1..10) { F "$n and $k are $($n + $k)" $n $k ($n + $k); if ($k -ne $n) { F "$k and $n are $($n + $k)" $k $n ($n + $k) } } }
'sub' { F "$n from $n leaves 0" $n $n 0
foreach ($k in 1..9) { $m = $n + $k; F "$n from $m leaves $k" $n $m $k; if ($k -ne $n) { F "$k from $m leaves $n" $k $m $n } } }
'mul' { if ($n -eq 1) { foreach ($k in 2..10) { F "1 time $k is $k" 1 $k $k; F "$k times 1 are $k" $k 1 $k } }
else { F "$n times 1 are $n" $n 1 $n; foreach ($k in 2..10) { F "$k times $n are $($k * $n)" $k $n ($k * $n); if ($k -ne $n) { F "$n times $k are $($k * $n)" $n $k ($k * $n) } } } }
'div' { F "$n in $n, 1 time" $n $n 1
foreach ($k in 2..10) { $m = $n * $k; F "$n in $m, $k times" $n $m $k; if ($k -ne $n) { F "$k in $m, $n times" $k $m $n } } }
}
return ,$f.ToArray()
}
# ---------- algebra (Book 6) ----------
# Math in a text is written between backticks in plain ASCII: `3a^2b - 4(x+y)/2`. It is shown the book's way
# (3a²b − 4(x+y)/2) and said for the voice ("3 A squared B minus 4 times the quantity X plus Y, over 2").
# An answer {$ expr} is typed on the algebra pad; {$ expr @ same} checks it has the value of `same`, {$~ (a+b)(c+d)} multiplies it out itself,
# {$ 12 @x: 6x+2x = 3x+60} checks it solves the equation for x, {15 @= 5^2-2*5} checks a plain number.
# chk: x=5, y=4 | x+y=9 | x-y=1 checks a pair of answers against the equations.
Add-Type -Path "$root\tools\alg.cs"
function MathSplit([string]$t, [scriptblock]$plain, [scriptblock]$math) {
$bits = $t -split '`'; $o = ''
for ($i = 0; $i -lt $bits.Count; $i++) { $o += $(if ($i % 2) { & $math $bits[$i] } elseif ($bits[$i]) { & $plain $bits[$i] } else { '' }) }
$o
}
$SUPS = @{ '0' = [char]0x2070; '1' = [char]0x00B9; '2' = [char]0x00B2; '3' = [char]0x00B3; '4' = [char]0x2074; '5' = [char]0x2075; '6' = [char]0x2076; '7' = [char]0x2077; '8' = [char]0x2078; '9' = [char]0x2079; '-' = [char]0x207B }
# superscript letters and signs for a^m, a^(m+n), a^(2/3) (q has none: such an exponent is left as ^(...))
$SUPL = 'a1D43 b1D47 c1D9C d1D48 e1D49 f1DA0 g1D4D h2B0 i2071 j2B2 k1D4F l2E1 m1D50 n207F o1D52 p1D56 r2B3 s2E2 t1D57 u1D58 v1D5B w2B7 x2E3 y2B8 z1DBB +207A /141F'
foreach ($kv in $SUPL -split ' ') { $SUPS[$kv.Substring(0, 1)] = [string][char][Convert]::ToInt32($kv.Substring(1), 16) }
function AlgPretty([string]$m) {
$m = [regex]::Replace($m, '\^(-?\d+|[a-z]|\(([^()]*)\))', { param($x)
$d = $(if ($x.Groups[2].Success) { $x.Groups[2].Value } else { $x.Groups[1].Value })
if (@($d.ToCharArray() | Where-Object { -not $SUPS.ContainsKey([string]$_) }).Count) { $x.Value } else { -join ($d.ToCharArray() | ForEach-Object { $SUPS[[string]$_] }) } })
$m.Replace('-', [string][char]0x2212).Replace('*', [string][char]0x00D7)
}
function AlgSay([string]$m) {
$tk = @([regex]::Matches(($m -replace [char]0x2212, '-'), '\d+\.?\d*|\.\d+|[A-Za-z]|\^-?\d+|\^[a-z]|\^\([^()]*\)|[-+*/()=<>,;:.]|\S') | ForEach-Object { $_.Value })
$w = New-Object System.Collections.ArrayList; $prev = ''
for ($i = 0; $i -lt $tk.Count; $i++) {
$t = $tk[$i]; $nx = $(if ($i + 1 -lt $tk.Count) { $tk[$i + 1] } else { '' })
if ($t -match '^\^(-?\d+)$') { $n = [int]$Matches[1]; [void]$w.Add($(switch ($n) { 0 { 'to the zero power' } 2 { 'squared' } 3 { 'cubed' } default { "to the $(if ($n -lt 0) { 'minus ' })$(OrdWord ([Math]::Abs($n))) power" } })) }
# a^(2/3) "to the 2 thirds power", a^(-1/2) "to the minus 1 half power", a^m "to the M power", a^(m+n) "to the M plus N power"
elseif ($t -match '^\^\((-?)(\d+)/(\d+)\)$') { [void]$w.Add("to the $(if ($Matches[1]) { 'minus ' })$(FracWords $Matches[2] $Matches[3]) power") }
elseif ($t -match '^\^\(?(.+?)\)?$') { [void]$w.Add("to the $(AlgSay $Matches[1]) power") }
elseif ($t -match '^[a-z]$') { [void]$w.Add($t.ToUpper()) }
elseif ($t -match '^[\d.]+$') {
# a plain number fraction 3/4 (not 3/4x) is said "3 fourths"
if ($nx -eq '/' -and $i + 2 -lt $tk.Count -and $tk[$i + 2] -match '^\d+$' -and [int]$tk[$i + 2] -gt 1 -and ($i + 3 -ge $tk.Count -or $tk[$i + 3] -notmatch '^([a-z(]|\^)') -and $prev -notmatch '^[a-z)]$') { [void]$w.Add((FracWords $t $tk[$i + 2])); $i += 2; $t = 'frac' }
else { if ($prev -match '^[a-z)]$') { [void]$w.Add('times') }; [void]$w.Add($t) }
}
elseif ($t -eq '(') { [void]$w.Add($(if ($prev -match '^([\d.]+|[a-z)]|\^-?\d+)$') { 'times the quantity' } else { 'the quantity' })) }
elseif ($t -eq ')') { [void]$w.Add(',') }
else { [void]$w.Add($(switch ($t) { '+' { 'plus' } '-' { 'minus' } '*' { 'times' } '/' { 'over' } '=' { 'equals' } '^' { 'to the power' } '<' { 'is less than' } '>' { 'is greater than' } ([string][char]0x221A) { $(if ($prev -match '^([\d.]+|[a-z)]|\^-?\d+)$') { 'times the square root of' } else { 'the square root of' }) } ([string][char]0x221B) { $(if ($prev -match '^([\d.]+|[a-z)]|\^-?\d+)$') { 'times the cube root of' } else { 'the cube root of' }) } ([string][char]0x221C) { $(if ($prev -match '^([\d.]+|[a-z)]|\^-?\d+)$') { 'times the fourth root of' } else { 'the fourth root of' }) } ([string][char]0x00B1) { 'plus or minus' } ([string][char]0x2213) { 'minus or plus' } ([string][char]0x00F7) { 'divided by' } default { $t } })) }
$prev = $t
}
(($w -join ' ') -replace ' ,', ',' -replace ',(\s*,)+', ',' -replace ',\s*$', '').Trim()
}
# the pad's extra keys: the letters used, and a root sign when there is one
# (and the cube root, fourth root and plus-or-minus signs of Book 7 when they are used)
function AlgLetters([string]$s) { (-join (@([regex]::Matches(($s -replace '\^-?\d+', ''), '[a-z]') | ForEach-Object { $_.Value }) | Sort-Object -Unique)) + (-join (@(0x221A, 0x221B, 0x221C, 0x00B1) | ForEach-Object { [string][char]$_ } | Where-Object { $s.Contains($_) })) }
# ---------- questions ----------
# display: the book's x and / become real signs; spoken: signs become words for the voice
$TIMES = " $([char]0x00D7) "; $DIV = " $([char]0x00F7) "; $MINUS = " $([char]0x2212) " # plain-ASCII script: no BOM needed
function Display([string]$t) { if ($t.Contains('`')) { return MathSplit $t { param($x) Display $x } { param($x) AlgPretty $x } }; ($t -replace '(?<=[\d)]) x (?=[\d.(])', $TIMES -replace '(?<=[\d)]) / (?=[\d.(])', $DIV -replace '(?<=[\d)]) - (?=[\d.(])', $MINUS) }
# fractions said the book's way: "3/4" -> "3 fourths", "2 1/2" -> "2 and 1 half"
$FRN = @{ 2 = 'half'; 3 = 'third'; 4 = 'fourth'; 5 = 'fifth'; 6 = 'sixth'; 7 = 'seventh'; 8 = 'eighth'; 9 = 'ninth'; 10 = 'tenth'; 11 = 'eleventh'; 12 = 'twelfth'; 13 = 'thirteenth'; 14 = 'fourteenth'; 15 = 'fifteenth'; 16 = 'sixteenth'; 17 = 'seventeenth'; 18 = 'eighteenth'; 19 = 'nineteenth'; 20 = 'twentieth'; 100 = 'hundredth' }
# any other denominator as an ordinal word: 23 -> twenty-third, 115 -> one hundred and fifteenth
function OrdWord([int]$d) {
$o = 'zero one two three four five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen eighteen nineteen' -split ' '
$t = ',,twenty,thirty,forty,fifty,sixty,seventy,eighty,ninety' -split ','
$oo = @{ one = 'first'; two = 'second'; three = 'third'; five = 'fifth'; eight = 'eighth'; nine = 'ninth'; twelve = 'twelfth' }
function Card([int]$n) { if ($n -lt 20) { return $o[$n] }; $w = $t[[Math]::Floor($n / 10)]; if ($n % 10) { $w += '-' + $o[$n % 10] }; $w }
$words = @()
if ($d -ge 1000) { $words += (Card ([Math]::Floor($d / 1000))) + ' thousand'; $d = $d % 1000 }
if ($d -ge 100) { $words += (Card ([Math]::Floor($d / 100))) + ' hundred'; $d = $d % 100 }
if ($d) { if ($words.Count) { $words += 'and' }; $words += (Card $d) }
$s = $words -join ' '
if ($s -match '^(.*?)(\w+)$') { $head = $Matches[1]; $last = $Matches[2] }
$last = $(if ($oo[$last]) { $oo[$last] } elseif ($last -match 'y$') { $last -replace 'y$', 'ieth' } else { $last + 'th' })
$head + $last
}
function FracWords([int]$n, [int]$d) {
$name = $FRN[$d]; if (-not $name) { $name = OrdWord $d }
if ($n -gt 1) { $name = $(if ($name -eq 'half') { 'halves' } else { $name + 's' }) }
"$n $name"
}
function SayFractions([string]$t) {
$t = [regex]::Replace($t, '(?<![\d/])(\d+) (\d+)/(\d+)(?![\d/])', { param($m) "$($m.Groups[1].Value) and $(FracWords $m.Groups[2].Value $m.Groups[3].Value)" })
[regex]::Replace($t, '(?<![\d/])(\d+)/(\d+)(?![\d/])', { param($m) FracWords $m.Groups[1].Value $m.Groups[2].Value })
}
function SayRep([string]$t) { [regex]::Replace($t, '(\d*)\.(\d*)\((\d+)\)', { param($m) $w = $m.Groups[1].Value; $a = ($m.Groups[2].Value.ToCharArray() -join ' '); $r = ($m.Groups[3].Value.ToCharArray() -join ' '); (($(if ($w) { "$w " } else { '' }) + 'point ' + $(if ($a) { "$a, " } else { '' }) + "$r repeating")) }) }
function Spoken([string]$t) { if ($t.Contains('`')) { return MathSplit $t { param($x) Spoken $x } { param($x) AlgSay $x } }; $t =($t -replace '(?<=[\d)]) x (?=[\d.])', ' times ' -replace '(?<=[\d)]) / (?=[\d.])', ' divided by ' -replace '(?<=[\d)]) - (?=[\d.])', ' minus ' -replace '(?<=[\d)]) \+ (?=[\d.])', ' plus ' -replace '= \?', 'equals what?' -replace "\s*$([char]0x00B1)\s*", ' plus or minus ' -replace "\s*$([char]0x2213)\s*", ' minus or plus '); SayFractions (SayRep $t) }
function Question([string]$q, [string]$where) {
$parts = New-Object System.Collections.ArrayList; $script:reps = New-Object System.Collections.ArrayList
$pos = 0
foreach ($m in [regex]::Matches($q, '\{([^}]*)\}')) {
$seg = $q.Substring($pos, $m.Index - $pos).Trim(); $pos = $m.Index + $m.Length
$ans = $m.Groups[1].Value.Trim(); if ($ans -notmatch '^~p\s') { $ans = $ans -replace '(?<=\d),(?=\d{3})', '' } # 1,234 -> 1234 (not in a compound chain: 9,144)
$algE = $null; if ($ans -match '^\$\s*(.+)$') { $algE = $Matches[1].Trim(); $ans = '$' } # algebra answer, below
# {15 @= 5^2-2*5}: a plain number checked with the algebra reader (powers, letters' values written in)
# {12 @x: 6x+2x = 3x+60}: a plain number that must solve the equation(s) for x (several split by ;)
if ($ans -match '^([^@]+?)\s*@([a-z]):\s*(.+)$') { $ans = $Matches[1].Trim(); $r = [RaysAlgCheck]::Holds("$($Matches[2])=" + ($ans -replace '^(\d+) (\d+)/(\d+)$', '($1+$2/$3)'), @($Matches[3] -split '\s*;\s*')); if ($r) { [void]$script:errors.Add("$where : $r") } }
if ($ans -match '^([^@]+?)\s*@=\s*(.+)$') { $ans = $Matches[1].Trim(); $r = [RaysAlgCheck]::Same(($ans -replace '^(\d+) (\d+)/(\d+)$', '($1+$2/$3)'), $Matches[2]); if ($r) { [void]$script:errors.Add("$where : $r") } }
# {1234 @ 567 + 667}: the book's printed answer, checked against the sum worked out from the question (catches misread digits)
if ($ans -match '^([^@]+?)\s*@\s*(.+)$') {
$ans = $Matches[1].Trim(); $chk = $Matches[2]
try { $want = EvalFrac $chk; $got = EvalFrac (($ans -replace '^(\d+) (\d+/\d+)$', '$1_$2') -replace '\|.*$', '')
if ($want -ne $got) { [void]$script:errors.Add("$where : printed answer $ans, but $chk = $want") } } catch { [void]$script:errors.Add("$where : $_") }
}
# [[+ 184 216 135]] / [[- 5000 1234]] / [[x 345 27]]: a sum written in a column, the book's way; its result checks the answer
$cv = $null; $colSay = $null
if ($seg -match '\[\[([-+x])\s+([\d,. ]+)\]\]') {
$op = $Matches[1]; $ns = @($Matches[2].Trim() -split '\s+'); $seg = $seg.Replace($Matches[0], '').Trim()
$expr = ($ns | ForEach-Object { $_ -replace ',', '' }) -join $(switch ($op) { '+' { ' + ' } '-' { ' - ' } 'x' { ' * ' } })
try { $cv = EvalFrac $expr } catch { [void]$script:errors.Add("$where : $_") }
$colSay = switch ($op) { '+' { 'Add ' + (($ns | Select-Object -SkipLast 1) -join ', ') + ', and ' + $ns[-1] + '.' } '-' { "From $($ns[0]) take $($ns[1])." } 'x' { "Multiply $($ns[0]) by $($ns[1])." } }
if ($ans -eq '?') { $ans = "$cv" } elseif ($ans -match '^[\d.]+( \d+/\d+)?$' -and $ans -ne $cv -and (EvalFrac ($ans -replace ' ', '_')) -ne $cv) { [void]$script:errors.Add("$where : the column comes to $cv, not $ans") }
}
$p = [ordered]@{ t = (Display $seg) }
if ($null -ne $cv) { $p.col = [ordered]@{ op = $op; n = $ns } }
if ($ans -match '^(-?\d+)\.\.(-?\d+) by (-?\d+)$') {
$a = [int]$Matches[1]; $b = [int]$Matches[2]; $st = [int]$Matches[3]
$seq = @(); for ($v = $a; ($st -gt 0 -and $v -le $b) -or ($st -lt 0 -and $v -ge $b); $v += $st) { $seq += $v }
if ($seq[-1] -ne $b) { [void]$script:errors.Add("$where : count by $st from $a never lands on $b") }
$p.seq = $seq
} elseif ($ans -match '^\d+(\|\d+)+$') { # more than one right answer, e.g. {100|1} = 100 cents or 1 dollar
$all = @($ans -split '\|' | ForEach-Object { [int]$_ }); $p.a = $all[0]; $p.alt = @($all | Select-Object -Skip 1)
} elseif ($ans -match '^[\d./ ]+(\|[\d./ ]+)+$') { # either form, e.g. money to mills or exact: {23.062|23.0625}
$all = @($ans -split '\|' | ForEach-Object { $_.Trim() }); $p.f = $all[0]; $p.falt = @($all | Select-Object -Skip 1)
} elseif ($ans -match '^~\s*(.+)$') { # worked out exactly: {~ 1/2 + 1/4} -> 3/4
# {~d expr} or an expression with a decimal in it: show a decimal answer when it ends (2.78, not 2 39/50)
# {~c4 expr}: the answer as a complex decimal carried to 4 places (.0154 1/4), the book's way with complex decimals
# {~r3 expr}: rounded to 3 decimal places ("preserving three places"); the cut-off value is taken too
$ex = $Matches[1]
# {~m expr}: money to the cent; the book works interest by aliquot parts carried to mills, so a cent either way is right too
if ($ex -match '^m\s+(.+)$') {
try { [void](EvalFrac $Matches[1]); $r = $script:lastRat; $x = [decimal]$r[0] / [decimal]$r[1]
$c = [Math]::Round($x * 100, [MidpointRounding]::AwayFromZero)
$p.f = ($c / 100).ToString('0.00'); $p.falt = @((($c - 1) / 100).ToString('0.00'), (($c + 1) / 100).ToString('0.00')) } catch { [void]$script:errors.Add("$where : $_") }
$ex = $null
}
elseif ($ex -match '^r(\d+)\s+(.+)$') {
$rp = [int]$Matches[1]; $rex = $Matches[2]
try { [void](EvalFrac $rex); $r = $script:lastRat; $sc = [decimal][Math]::Pow(10, $rp); $x = [decimal]$r[0] / [decimal]$r[1]
$rnd = [Math]::Round($x * $sc, [MidpointRounding]::AwayFromZero) / $sc; $cut = [Math]::Truncate($x * $sc) / $sc
$fmt = { param($v) $s = $v.ToString('0.' + ('0' * $rp)); if ($rp -eq 0) { $s = $v.ToString('0') }; if ($s.StartsWith('0.')) { $s.Substring(1) } else { $s } }
$p.f = & $fmt $rnd; if ($cut -ne $rnd) { $p.falt = @(& $fmt $cut) } } catch { [void]$script:errors.Add("$where : $_") }
$ex = $null
}
# {~p 320,16_1/2,12 # 2 # expr}: a compound number. expr is the whole quantity in the lowest unit (inches);
# the chain gives how many of each unit make one of the unit above (mi.>rd.>ft.>in.); # 2 asks for the 3rd unit (ft.).
# Every unit but the last is a whole number; the last takes the remainder (decimal when it ends, else a fraction).
if ($null -ne $ex -and $ex -match '^p\s+([^#]*)#\s*(\d+)\s*#\s*(.+)$') {
$chain = @($Matches[1].Trim() -split '\s*,\s*'); $idx = [int]$Matches[2]; $pex = $Matches[3].Trim()
if ($pex -eq '$') { $pex = $script:lastPex; $chain = $script:lastChain } else { $script:lastPex = $pex; $script:lastChain = $chain } # {~p # 1 # $}: same quantity, next unit
try {
[void](EvalFrac $pex); $rem = $script:lastRat
for ($k = 0; $k -le $chain.Count; $k++) {
$sz = $(if ($k -lt $chain.Count) { [void](EvalFrac (($chain[$k..($chain.Count - 1)]) -join ' * ')); $script:lastRat } else { ,@([long]1, [long]1) })
if ($k -eq $chain.Count) { $part = $rem } else {
$qq = [long][Math]::Floor(([decimal]$rem[0] * $sz[1]) / ([decimal]$rem[1] * $sz[0]))
$part = Rat $qq 1; $rem = Rat ($rem[0] * $sz[1] - $qq * $sz[0] * $rem[1]) ($rem[1] * $sz[1]) }
if ($k -eq $idx) { $ps = RatStr $part; if ($ps -match '^\d+$') { $p.a = [long]$ps } else { $p.f = $(if ($pex -match '\d\.\d') { AsDec $ps } else { $ps })
# the book often gives the last unit "nearly": accept it rounded or cut to 0-4 places too
$x = ([decimal]($part[0])) / ([decimal]($part[1])); $alts = @()
foreach ($dp in 0..4) { $sc = [decimal][Math]::Pow(10, $dp); foreach ($v in @(([Math]::Round($x * $sc, [MidpointRounding]::AwayFromZero) / $sc), ([Math]::Truncate($x * $sc) / $sc))) { $vs = $v.ToString('0.####'); if ($vs.StartsWith('0.')) { $vs = $vs.Substring(1) }; if ($alts -notcontains $vs) { $alts += $vs } } }
if ($pex -match '\d\.\d' -or $part[1] -gt 100) { $p.falt = $alts } }; break }
}
} catch { [void]$script:errors.Add("$where : $_") }
$ex = $null
}
if ($null -ne $ex) {
# {~q expr}: as a common fraction, with the circulate shown after the question (.45(3))
$wantRep = $ex -match '^q\s'; $ex = $ex -replace '^q\s+', ''
$cp = $(if ($ex -match '^c(\d+)\s') { [int]$Matches[1] } else { -1 }); $ex = $ex -replace '^c\d+\s+', ''
$wantDec = $ex -match '^d\s' -or $ex -match '\d*\.\d'; $ex = $ex -replace '^d\s+', ''
try { $v = EvalFrac $ex; if ($wantRep) { [void]$script:reps.Add((AsRep $script:lastRat)) }
if ($cp -ge 0) { $c = AsCplx $script:lastRat $cp; if ($c -match '^\d+$') { $p.a = [long]$c } else { $p.f = $c } }
elseif ($v -match '^\d+$') { $p.a = [long]$v } else { $p.f = $(if ($wantDec) { AsDec $v } else { $v }) } } catch { [void]$script:errors.Add("$where : $_") }
}
} elseif ($ans -match '^list:\s*(.+)$') { # {list: 1, 3, 5/2}: typed one item at a time, in order (continued fraction quotients, series terms)
$items = @($Matches[1] -split '\s*,\s*' | ForEach-Object { $_.Trim() }); $p.seq = $items; $p.lst = 1
# items with letters, minus signs or roots are typed on the algebra pad and checked like {$ }
if (@($items | Where-Object { $_ -match "[a-z\-$([char]0x221A)$([char]0x221B)$([char]0x221C)]" }).Count) {
$p.la = 1; $p.v = AlgLetters (($items -join ' ') + ' ' + (@([regex]::Matches($seg, '`([^`]*)`') | ForEach-Object { $_.Groups[1].Value }) -join ' '))
$p.ss = @($items | ForEach-Object { AlgSay $_ })
}
foreach ($it in $items) { $r = [RaysAlgCheck]::Same(($it -replace '^(\d+) (\d+)/(\d+)$', '($1+$2/$3)'), ($it -replace '^(\d+) (\d+)/(\d+)$', '($1+$2/$3)')); if ($r) { [void]$script:errors.Add("$where : list item: $r") } }
} elseif ($ans -match '^=(.+)$') { # exact written form, e.g. {=1/2} for "reduce to lowest terms"; {=3/6|1/2} more than one
$ex = @($Matches[1] -split '\|' | ForEach-Object { $_.Trim() }); $p.f = $ex[0]; $p.ex = $ex
} elseif ($ans -eq '$') { # algebra: typed on the algebra pad, checked by alg.js (same value, written as simply)
$e = $algE; $chk = $null
# {$~ (a+b)(c+d)}: multiplied out exactly, written the book's way
$expand = { param($x) try { [RaysAlgCheck]::Expand($x) } catch { [void]$script:errors.Add("$where : $($_.Exception.InnerException.Message) in $x"); '0' } }
if ($e -match '^~\s*(.+)$') { $e = & $expand $Matches[1] }
else {
if ($e -match '^(.+?)\s+@\s*(.+)$') { $e = $Matches[1].Trim(); $chk = $Matches[2].Trim() }
# {$ x^2(x+a) | ~x^2(x+a)}: other ways that count too (~ = multiplied out)
$alts = @($e -split '\s*\|\s*'); $e = $alts[0]
if ($alts.Count -gt 1) { $p.ealt = @($alts[1..($alts.Count - 1)] | ForEach-Object { if ($_ -match '^~\s*(.+)$') { & $expand $Matches[1] } else { $_ } }) }
}
# @gcd: A; B = the answer divides each evenly; @lcm: A; B = each divides the answer evenly
if ($chk -match '^(gcd|lcm):\s*(.+)$') {
$mode = $Matches[1]
foreach ($qq in @($Matches[2] -split '\s*;\s*')) {
try { [void][RaysAlgCheck]::Expand($(if ($mode -eq 'gcd') { "($qq)/($e)" } else { "($e)/($qq)" })) } catch { [void]$script:errors.Add("$where : $e is not a $(if ($mode -eq 'gcd') { 'divisor' } else { 'multiple' }) of $qq") }
}
$chk = $null
}
foreach ($x in @($p.ealt)) { if ($x) { $r = [RaysAlgCheck]::Same($x, $e); if ($r) { [void]$script:errors.Add("$where : alternative $r") } } }
$p.e = $e; $p.es = AlgSay $e
# pad letters: the answer's and the question's (so they don't give the answer away); none for a plain number
$p.v = $(if ($e -match "[a-z$([char]0x221A)$([char]0x221B)$([char]0x221C)$([char]0x00B1)]") { AlgLetters ($e + ' ' + (@([regex]::Matches($seg, '`([^`]*)`') | ForEach-Object { $_.Groups[1].Value }) -join ' ')) } else { '' }) + $(if ($e.Contains('*')) { [string][char]0x00D7 } else { '' }) + $(if ($e -match '\d\.|\.\d') { '.' } else { '' }) # a times sign or a decimal point in the answer gets its key
# an equation or inequality answer (Book 7): the pad gets = or < > too
if ($e -match '[=<>]') { $p.v += -join (@('=', '<', '>') | Where-Object { $e.Contains($_) -or ($_ -ne '=' -and $e -match '[<>]') }) }
# "3±√5" is two roots: each is checked (a ± in the check expression goes the same way)
$PM = [string][char]0x00B1
foreach ($sg in @(if ($e.Contains($PM)) { '+'; '-' } else { '' })) {
$ee = $(if ($sg) { $e.Replace($PM, $sg) } else { $e }); $cc = $(if ($sg -and $chk) { $chk.Replace($PM, $sg) } else { $chk })
if ($cc) {
# @sq: radicand = the answer squared gives it (a square root); @pow3: Q = the answer cubed gives Q (any nth root: @powN:)
$r = $(if ($cc -match '^sq:\s*(.+)$') { [RaysAlgCheck]::Same("($ee)^2", $Matches[1]) } elseif ($cc -match '^pow(\d+):\s*(.+)$') { [RaysAlgCheck]::Same("($ee)^$($Matches[1])", $Matches[2]) } elseif ($cc -match '^([a-z]):\s*(.+)$') { [RaysAlgCheck]::Holds("$($Matches[1])=$ee", @($Matches[2] -split '\s*;\s*')) } else { [RaysAlgCheck]::Same($ee, $cc) })
if ($r) { [void]$script:errors.Add("$where : $r") }
} else { $r = [RaysAlgCheck]::Same($ee, $ee); if ($r) { [void]$script:errors.Add("$where : can't read answer: $r") } }
}
} elseif ($ans -eq 'open') { # answered out loud to a grown-up (e.g. "Give two numbers which make 10")
$p.open = $true
} elseif ($ans -match '^(\d+ )?\d+/\d+$' -or $ans -match '^\d*\.\d+$' -or $ans -match '^\d*\.\d+ \d+/\d+$') { # fraction, mixed number, decimal, or complex decimal (.0154 1/4)
$p.f = $ans
} elseif ($ans -eq '?') {
$v = Calc $seg
if ($null -eq $v) { [void]$script:errors.Add("$where : can't work out {?} for '$seg'") } else { $p.a = $v }
} elseif ($ans -match '^\d+$') {
$p.a = [long]$ans
$v = Calc $seg
if ($null -ne $v -and $v -ne $p.a) { [void]$script:errors.Add("$where : '$seg' is $v, not $ans") }
} else { [void]$script:errors.Add("$where : bad answer {$ans}") }
if ($colSay) { $p.s = ((Spoken $seg) + ' ' + $colSay).Trim() } elseif ((Spoken $seg) -ne $seg) { $p.s = Spoken $seg }
[void]$parts.Add($p)
}
# "x = {A} or {B}": either order (the two roots of a quadratic); app.js swaps them when B comes first
for ($k = 1; $k -lt $parts.Count; $k++) { if ($parts[$k].t -match '^or\b') { $parts[$k - 1].pr = 1 } }
# "x = {A}, y = {B}; or x = {C}, y = {D}" (the solution sets of simultaneous equations): the sets in any order. Each
# part gets its set (sn) and its place in the set (sk); app.js swaps whole sets when a later set is typed first
$starts = @(0) + @(for ($k = 1; $k -lt $parts.Count; $k++) { if ($parts[$k].t -match '^;\s*or\b') { $k } })
if ($starts.Count -gt 1) {
$n = $starts[1]
if ($starts.Count * $n -ne $parts.Count -or @($starts | Where-Object { $_ % $n }).Count) { [void]$script:errors.Add("$where : solution sets (; or x = ...) must all have the same number of answers") }
else { for ($k = 0; $k -lt $parts.Count; $k++) { $parts[$k].sn = [int][Math]::Floor($k / $n); $parts[$k].sk = [int]($k % $n) } }
}
$tail = $q.Substring($pos).Trim()
# text after the last {answer} joins the last part, shown and said like the rest (its `math` too)
if ($tail) { if ($parts.Count) { $lp = $parts[$parts.Count - 1]; $s0 = $(if ($lp.s) { $lp.s } else { $lp.t })
$lp.t += ' ' + (Display $tail); if ($lp.s -or (Spoken $tail) -ne $tail) { $lp.s = "$s0 $(Spoken $tail)" } } else { [void]$script:errors.Add("$where : question has no {answer}") } }
$res = [ordered]@{ parts = $parts.ToArray() }
if ($script:reps.Count) { $res.sol = 'As a circulate: ' + ($script:reps -join '; ') + '.' }
return $res
}
# ---------- lessons ----------
$lessons = New-Object System.Collections.ArrayList
$L = $null; $lastQ = $null; $qn = 0
foreach ($line in $src) {
if ($line -match '^\s*(#|$)' -or $line -match '^@book: ') { continue }
if ($line -match '^== (\d+) \| ([^|]+) \| (.+)$') {
$L = [ordered]@{ n = [int]$Matches[1]; part = $Matches[2].Trim(); title = $Matches[3].Trim(); kind = 'problems' }
$L.review = $L.part -eq 'Review'
[void]$lessons.Add($L); $lastQ = $null; $lastArt = $null; $qn = 0; continue
}
if (-not $L) { continue }
$where = "Lesson $($L.n)"
if ($line -match '^kind: (count|numbers) (\d+) (\d+)$') { $L.kind = $Matches[1]; $L.from = [int]$Matches[2]; $L.to = [int]$Matches[3] }
elseif ($line -match '^kind: (read|write)$') { $L.kind = $Matches[1] }
elseif ($line -match '^list: (.+)$') { $L.list = @($Matches[1] -split '\s+' | ForEach-Object { [int]$_ }) }
elseif ($line -match '^note: (.+)$') { $L.note = $Matches[1] }
elseif ($line -match '^table: (add|sub|mul|div) (\d+)$') { $L.op = $Matches[1]; $L.table = Table $Matches[1] ([int]$Matches[2]) }
elseif ($line -match '^table: \+(add|sub|mul|div) (\d+) (\d+)( from 0)?$') { # Book Two style "2 + 1 = 3" ... "2 + 12 = 14"; several add up
$L.op = $Matches[1]; $op = $Matches[1]; $n = [int]$Matches[2]; $max = [int]$Matches[3]; $k0 = $(if ($Matches[4]) { 0 } else { 1 }) # Book Three: "2 + 0 = 2"
$rows = New-Object System.Collections.ArrayList; if ($L.table) { [void]$rows.AddRange(@($L.table)) }
foreach ($k in $k0..$max) {
switch ($op) {
'add' { $r = $n + $k; [void]$rows.Add([ordered]@{ t = "$n + $k = $r"; q = "How many are $n and $k?"; a = $n; b = $k; r = $r }) }
'sub' { $m = $n + $k - 1; $r = $k - 1; [void]$rows.Add([ordered]@{ t = "$m - $n = $r"; q = "$n from $m leaves how many?"; a = $n; b = $m; r = $r }) }
'mul' { $r = $n * $k; [void]$rows.Add([ordered]@{ t = "$k x $n = $r"; q = "How many are $k times $n?"; a = $k; b = $n; r = $r }) } # the book's columns: 1 x 4, 2 x 4 ... 12 x 4
'div' { $m = $n * $k; [void]$rows.Add([ordered]@{ t = "$m / $n = $k"; q = "How many times is $n contained in $m?"; a = $n; b = $m; r = $k }) }
}
}
foreach ($f in $rows) { $f.t = Display $f.t }
$L.table = $rows.ToArray()
}
elseif ($line -match '^rule: (\d+) (.+) make 1 (.+)$') {
if (-not $L.rules) { $L.rules = New-Object System.Collections.ArrayList }
$r = [ordered]@{ t = "$($Matches[1]) $($Matches[2]) make 1 $($Matches[3])"; q = "How many $($Matches[2]) make 1 $($Matches[3])?"; n = [int]$Matches[1]; a = $Matches[2]; b = $Matches[3] }
if ($r.a -match '\d|^and ') { $r.quiz = $false } # "365 days and 6 hours": show it, don't quiz it
[void]$L.rules.Add($r)
}
elseif ($line -match '^q: (.+)$') {
$qn++; if (-not $L.qs) { $L.qs = New-Object System.Collections.ArrayList }
$lastQ = Question $Matches[1] "$where q$qn"; [void]$L.qs.Add($lastQ)
}
elseif ($line -match '^sol: (.+)$') { if ($lastQ) { $lastQ.sol = $Matches[1] } else { [void]$script:errors.Add("$where : sol without a question") } }
# Book Five (Geometry): the book's articles to study, each with its figure cut from the scan, then a quiz
elseif ($line -match '^art: (\d+) \| ([^|]*) \| (.+)$') {
if (-not $L.arts) { $L.arts = New-Object System.Collections.ArrayList }
$lastArt = [ordered]@{ n = [int]$Matches[1]; h = $Matches[2].Trim(); t = $Matches[3].Trim() }; [void]$L.arts.Add($lastArt)
if ("$($lastArt.h)$($lastArt.t)".Contains('`')) { $lastArt.s = "$($lastArt.n). $(if ($lastArt.h) { "$(Spoken $lastArt.h). " })$(Spoken $lastArt.t)"; $lastArt.h = Display $lastArt.h; $lastArt.t = Display $lastArt.t }
}
elseif ($line -match '^chk: ([^|]+)\|(.+)$') { # chk: x=5, y=4 | x+y=9 | x-y=1
$r = [RaysAlgCheck]::Holds($Matches[1].Trim(), @($Matches[2] -split '\s*\|\s*' | ForEach-Object { $_.Trim() }))
if ($r) { [void]$script:errors.Add("$where : $r") }
}
elseif ($line -match '^fig: (\d+) ([\d.]+) ([\d.]+)( [\d.]+ [\d.]+)?$') { # page top bottom [left right], fractions of the page
if (-not $lastArt) { [void]$script:errors.Add("$where : fig without an art"); continue }
$fk = "p$($Matches[1])-" + [int]([double]$Matches[2] * 1000)
$lastArt.figs = @($lastArt.figs | Where-Object { $_ }) + "fig/$($bk[0])/$fk.png" # an article may have several
}
elseif ($line -match '^mc: (.+)$') {
$parts = @($Matches[1] -split '\s*\|\s*'); $ch = @($parts[1..($parts.Count - 1)])
$right = @(for ($i = 0; $i -lt $ch.Count; $i++) { if ($ch[$i] -like '[*]*') { $i } })
if ($ch.Count -lt 2 -or $right.Count -ne 1) { [void]$script:errors.Add("$where : mc needs 2+ choices and one *right one: '$line'"); continue }
if (-not $L.quiz) { $L.quiz = New-Object System.Collections.ArrayList }
$cs = @($ch | ForEach-Object { $_ -replace '^\*', '' }); $item = [ordered]@{ q = $parts[0]; c = $cs; a = $right[0] }
if ($line.Contains('`')) { $item.q = Display $parts[0]; $item.c = @($cs | ForEach-Object { Display $_ }); $item.qs = Spoken $parts[0]; $item.cs = @($cs | ForEach-Object { Spoken $_ }) } # algebra: shown the book's way, and what the voice says
[void]$L.quiz.Add($item)
}
elseif ($line -match '^tf: (.+) \{([TF])\}$') {
if (-not $L.quiz) { $L.quiz = New-Object System.Collections.ArrayList }
$tq = $Matches[1]; $item = [ordered]@{ q = $tq; c = @('True', 'False'); a = $(if ($Matches[2] -eq 'T') { 0 } else { 1 }); tf = $true }
if ($tq.Contains('`')) { $item.q = Display $tq; $item.qs = Spoken $tq }
[void]$L.quiz.Add($item)
}
else { [void]$script:errors.Add("$where : can't read line '$line'") }
}
foreach ($L in $lessons) {
if ($L.rules) { $L.rules = $L.rules.ToArray() }
if ($L.qs) { $L.qs = $L.qs.ToArray() }
if ($L.arts) { $L.arts = $L.arts.ToArray() }
if ($L.quiz) { $L.quiz = $L.quiz.ToArray() }
if ($L.kind -eq 'problems' -and -not $L.qs -and -not $L.rules -and -not $L.table -and -not $L.arts) { [void]$script:errors.Add("Lesson $($L.n) : no questions") }
}
$nums = @($lessons | ForEach-Object { $_.n })
for ($i = 0; $i -lt $nums.Count; $i++) { if ($nums[$i] -ne $i + 1) { [void]$script:errors.Add("lesson numbers out of order at $($nums[$i])"); break } }
if ($script:errors.Count) { "PROBLEMS:"; $script:errors; exit 1 }
$out = [ordered]@{ id = $bk[0]; title = $bk[1]; sub = $bk[2]; color = $bk[3]; lessons = $lessons.ToArray() }
New-Item -ItemType Directory -Force "$root\public\books" | Out-Null
[IO.File]::WriteAllText("$root\public\books\$($bk[0]).json", ($out | ConvertTo-Json -Depth 10 -Compress), (New-Object Text.UTF8Encoding $false))
$q = ($lessons | ForEach-Object { @($_.qs).Count } | Measure-Object -Sum).Sum
$a = ($lessons | ForEach-Object { foreach ($x in @($_.qs)) { if ($x) { $x.parts.Count } } } | Measure-Object -Sum).Sum
"$($lessons.Count) lessons, $q questions, $a answers -> public\books\$($bk[0]).json"
EOF
alg.cs: the algebra checker make-book.ps1 loads (complex values, roots, exponents, equations, solution sets).
cat > /root/rays-rebuild/alg.cs <<'EOF'
// Algebra checks for make-book.ps1 (Books 6-7): reads expressions the way public/alg.js does (2ab = 2*a*b, a/bc = a/(bc),
// x^2, a^(2/3), a^m, ∛x, ∜x, √-1) and tests that two expressions have the same value, or that values make an equation
// true, at random numbers. Values are complex numbers, so √-1 works the book's way (√-a·√-b = −√ab).
using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;
using F = System.Func<System.Collections.Generic.Dictionary<string, RaysAlgCheck.Cx>, RaysAlgCheck.Cx>;
public static class RaysAlgCheck {
public struct Cx {
public double Re, Im; public Cx(double r, double i) { Re = r; Im = i; }
public static Cx operator +(Cx a, Cx b) { return new Cx(a.Re + b.Re, a.Im + b.Im); }
public static Cx operator -(Cx a, Cx b) { return new Cx(a.Re - b.Re, a.Im - b.Im); }
public static Cx operator -(Cx a) { return new Cx(-a.Re, -a.Im); }
public static Cx operator *(Cx a, Cx b) { return new Cx(a.Re * b.Re - a.Im * b.Im, a.Re * b.Im + a.Im * b.Re); }
public static Cx operator /(Cx a, Cx b) { double d = b.Re * b.Re + b.Im * b.Im; return new Cx((a.Re * b.Re + a.Im * b.Im) / d, (a.Im * b.Re - a.Re * b.Im) / d); }
public double Abs { get { return Math.Sqrt(Re * Re + Im * Im); } }
public bool Bad { get { return double.IsNaN(Re) || double.IsInfinity(Re) || double.IsNaN(Im) || double.IsInfinity(Im); } }
public override string ToString() { return Math.Abs(Im) < 1e-12 ? Re.ToString() : Re + (Im < 0 ? "-" : "+") + Math.Abs(Im) + "i"; }
}
// whole powers by multiplying, the rest by the principal value
static Cx CPow(Cx z, Cx e) {
if (Math.Abs(e.Im) < 1e-12 && e.Re == Math.Floor(e.Re) && Math.Abs(e.Re) <= 64) {
Cx r = new Cx(1, 0); for (int k = 0; k < (int)Math.Abs(e.Re); k++) r = r * z; return e.Re < 0 ? new Cx(1, 0) / r : r;
}
if (Math.Abs(z.Im) < 1e-15 && z.Re > 0 && Math.Abs(e.Im) < 1e-12) return new Cx(Math.Pow(z.Re, e.Re), 0);
double m0 = z.Abs; if (m0 == 0) return new Cx(0, 0);
double lr = Math.Log(m0), th = Math.Atan2(z.Im, z.Re), m = Math.Exp(e.Re * lr - e.Im * th), an = e.Im * lr + e.Re * th;
return new Cx(m * Math.Cos(an), m * Math.Sin(an));
}
// √ = principal square root; ∛ of a real number = the real cube root (∛-8 = -2)
static Cx CRoot(Cx z, int n) {
if (Math.Abs(z.Im) < 1e-15) { if (z.Re >= 0) return new Cx(Math.Pow(z.Re, 1.0 / n), 0); if (n % 2 == 1) return new Cx(-Math.Pow(-z.Re, 1.0 / n), 0); }
if (n == 2) { double r = z.Abs; return new Cx(Math.Sqrt((r + z.Re) / 2), (z.Im < 0 ? -1 : 1) * Math.Sqrt((r - z.Re) / 2)); }
return CPow(z, new Cx(1.0 / n, 0));
}
class P {
List<string> tk; int i;
public P(string s) {
tk = new List<string>();
foreach (Match m in Regex.Matches(s.Replace("−", "-"), @"log|ln|\d+\.?\d*|\.\d+|[a-z]|[-+*/^()]|\S")) tk.Add(m.Value);
}
string Peek() { return i < tk.Count ? tk[i] : null; }
string Take() { if (i >= tk.Count) throw new Exception("unexpected end"); return tk[i++]; }
static int RootN(string t) { return t == "√" ? 2 : t == "∛" ? 3 : t == "∜" ? 4 : 0; }
bool StartsAtom(string t) { return t != null && (char.IsDigit(t[0]) || t[0] == '.' || (t[0] >= 'a' && t[0] <= 'z') || t == "(" || RootN(t) > 0); }
public F All() { var f = Sum(); if (i != tk.Count) throw new Exception("couldn't read '" + tk[i] + "'"); return f; }
F Atom() {
string t = Take();
if (t == "(") { var a = Sum(); if (Take() != ")") throw new Exception("missing )"); return a; }
int rn = RootN(t);
if (rn > 0) { bool neg = false; if (Peek() == "-") { Take(); neg = true; } var r = Pow(); return e => CRoot(neg ? -r(e) : r(e), rn); } // √a, ∛(2a), √-1
// number checks of Book 7 (logarithms, permutations): log(x) common log, ln(x), C(n,r) combinations, P(n,r) permutations
if (t == "log" || t == "ln") { var r = Pow(); bool ten = t == "log"; return e => new Cx(ten ? Math.Log10(r(e).Re) : Math.Log(r(e).Re), 0); }
if ((t == "C" || t == "P") && Peek() == "(") {
Take(); var n = Sum(); if (Take() != ",") throw new Exception("C(n,r) needs a comma"); var k = Sum(); if (Take() != ")") throw new Exception("missing )");
bool comb = t == "C"; return e => { double nn = n(e).Re, kk = k(e).Re, v = 1; for (int j = 0; j < kk; j++) v = v * (nn - j) / (comb ? j + 1 : 1); return new Cx(v, 0); };
}
if (t.Length == 1 && t[0] >= 'a' && t[0] <= 'z') { string n = t; return e => { Cx v; if (!e.TryGetValue(n, out v)) throw new Exception("no value for " + n); return v; }; }
double num; if (double.TryParse(t, System.Globalization.NumberStyles.Float, System.Globalization.CultureInfo.InvariantCulture, out num)) return e => new Cx(num, 0);
throw new Exception("bad token '" + t + "'");
}
// pow := atom [^ ([-]int | letter | ( sum ))]
F Pow() {
var b = Atom();
if (Peek() == "!") { Take(); var a = b; b = e => { double v = 1; for (int j = 2; j <= (int)Math.Round(a(e).Re); j++) v *= j; return new Cx(v, 0); }; } // n!
if (Peek() != "^") return b;
Take();
if (Peek() == "(") { Take(); var x = Sum(); if (Take() != ")") throw new Exception("missing ) in exponent"); return e => CPow(b(e), x(e)); }
string p = Peek();
if (p != null && p.Length == 1 && p[0] >= 'a' && p[0] <= 'z') { Take(); string n = p; return e => { Cx v; if (!e.TryGetValue(n, out v)) throw new Exception("no value for " + n); return CPow(b(e), v); }; }
int sg = 1; if (Peek() == "-") { Take(); sg = -1; } int ex = int.Parse(Take()) * sg; return e => CPow(b(e), new Cx(ex, 0));
}
F Imp() {
var f = Pow();
while (StartsAtom(Peek())) { var a = f; var b = Pow(); f = e => a(e) * b(e); }
return f;
}
F Term() {
var f = Imp();
while (Peek() == "*" || Peek() == "/") { string op = Take(); var a = f; var b = Imp(); if (op == "*") f = e => a(e) * b(e); else f = e => a(e) / b(e); }
return f;
}
F Sum() {
F f;
if (Peek() == "-") { Take(); var t = Term(); f = e => -t(e); } else { if (Peek() == "+") Take(); f = Term(); }
while (Peek() == "+" || Peek() == "-") { string op = Take(); var a = f; var b = Term(); if (op == "+") f = e => a(e) + b(e); else f = e => a(e) - b(e); }
return f;
}
}
// ---------- exact polynomials: {$~ (a+b)(c+d)} -> "ac+ad+bc+bd" ----------
// A term's key is its letters with exponents in alphabet order ("a2b1"); coefficients are exact fractions.
class Q { public long n, d; public Q(long n, long d) { if (d < 0) { n = -n; d = -d; } long g = G(Math.Abs(n), d); this.n = n / g; this.d = d / g; }
static long G(long a, long b) { while (b != 0) { long t = a % b; a = b; b = t; } return a == 0 ? 1 : a; }
public static Q operator +(Q a, Q b) { return new Q(a.n * b.d + b.n * a.d, a.d * b.d); }
public static Q operator *(Q a, Q b) { return new Q(a.n * b.n, a.d * b.d); } }
class Poly : Dictionary<string, Q> {
public static Poly C(Q q) { var p = new Poly(); if (q.n != 0) p[""] = q; return p; }
public static Poly V(string v) { var p = new Poly(); p[v + "1"] = new Q(1, 1); return p; }
static SortedDictionary<string, int> Split(string k) { var m = new SortedDictionary<string, int>(StringComparer.Ordinal); foreach (Match x in Regex.Matches(k, "([a-z])(\\d+)")) m[x.Groups[1].Value] = int.Parse(x.Groups[2].Value); return m; }
static string Join(SortedDictionary<string, int> m) { var s = ""; foreach (var kv in m) if (kv.Value != 0) s += kv.Key + kv.Value; return s; }
public Poly Add(Poly o, int sg) { var r = new Poly(); foreach (var kv in this) r[kv.Key] = kv.Value; foreach (var kv in o) { Q c = kv.Value * new Q(sg, 1); Q old; r[kv.Key] = r.TryGetValue(kv.Key, out old) ? old + c : c; if (r[kv.Key].n == 0) r.Remove(kv.Key); } return r; }
public Poly Mul(Poly o) { var r = new Poly(); foreach (var a in this) foreach (var b in o) { var m = Split(a.Key); foreach (var kv in Split(b.Key)) { int e; m[kv.Key] = (m.TryGetValue(kv.Key, out e) ? e : 0) + kv.Value; } var k = Join(m); Q c = a.Value * b.Value; Q old; r[k] = r.TryGetValue(k, out old) ? old + c : c; if (r[k].n == 0) r.Remove(k); } return r; }
// exact division: by a number or a monomial term by term, else long division (must come out even)
public Poly Div(Poly b) {
if (b.Count == 0) throw new Exception("division by 0");
var lead = b.Lead(); var r = new Poly(); var rem = this; int guard = 0;
while (rem.Count > 0) {
if (++guard > 500) throw new Exception("division doesn't end");
var t = rem.Lead(); var qk = DivKey(t, lead);
if (qk == null) throw new Exception("doesn't divide evenly");
Q c = rem[t] * new Q(b[lead].d, b[lead].n); var term = new Poly(); term[qk] = c;
r = r.Add(term, 1); rem = rem.Add(term.Mul(b), -1);
}
return r;
}
static string DivKey(string a, string b) { var m = Split(a); foreach (var kv in Split(b)) { int e; if (!m.TryGetValue(kv.Key, out e) || e < kv.Value) return null; m[kv.Key] = e - kv.Value; } return Join(m); }
static string LexKey(string k) { var s = ""; foreach (char c in "abcdefghijklmnopqrstuvwxyz") { int e; s += (char)('z' - (Split(k).TryGetValue(c.ToString(), out e) ? e : 0)); } return s; }
public string Lead() { string best = null; foreach (var k in Keys) if (best == null || string.CompareOrdinal(LexKey(k), LexKey(best)) < 0) best = k; return best; }
public Poly Pow(int e) { if (e < 0) throw new Exception("negative power"); var r = C(new Q(1, 1)); for (int i = 0; i < e; i++) r = r.Mul(this); return r; }
// the book's order: alphabetical, higher powers first (a^3b^2+a^2bcd^2+abcd+c^2d^3), numbers last
public string Str() {
var keys = new List<string>(Keys);
Func<string, string> lex = k => { var s = ""; foreach (char c in "abcdefghijklmnopqrstuvwxyz") { int e; s += (char)('z' - (Split(k).TryGetValue(c.ToString(), out e) ? e : 0)); } return s; };
keys.Sort((x, y) => string.CompareOrdinal(lex(x), lex(y)));
var o = "";
foreach (var k in keys) {
Q q = this[k]; long n = Math.Abs(q.n); var lets = "";
foreach (var kv in Split(k)) lets += kv.Key + (kv.Value > 1 ? "^" + kv.Value : "");
string t = (n == 1 && lets != "" ? "" : n.ToString()) + lets + (q.d != 1 ? "/" + q.d : "");
o += (q.n < 0 ? "-" : (o == "" ? "" : "+")) + t;
}
return o == "" ? "0" : o;
}
}
class PP {
List<string> tk; int i;
public PP(string s) { tk = new List<string>(); foreach (Match m in Regex.Matches(s.Replace("−", "-"), @"\d+|[a-z]|[-+*/^()]|\S")) tk.Add(m.Value); }
string Peek() { return i < tk.Count ? tk[i] : null; }
string Take() { if (i >= tk.Count) throw new Exception("unexpected end"); return tk[i++]; }
bool StartsAtom(string t) { return t != null && (char.IsDigit(t[0]) || (t[0] >= 'a' && t[0] <= 'z') || t == "("); }
public Poly All() { var p = Sum(); if (i != tk.Count) throw new Exception("couldn't read '" + tk[i] + "'"); return p; }
Poly Atom() { string t = Take(); if (t == "(") { var a = Sum(); if (Take() != ")") throw new Exception("missing )"); return a; }
if (t.Length == 1 && t[0] >= 'a' && t[0] <= 'z') return Poly.V(t);
long n; if (long.TryParse(t, out n)) return Poly.C(new Q(n, 1)); throw new Exception("can't expand '" + t + "'"); }
Poly Pow() { var b = Atom(); if (Peek() == "^") { Take(); return b.Pow(int.Parse(Take())); } return b; }
Poly Imp() { var f = Pow(); while (StartsAtom(Peek())) f = f.Mul(Pow()); return f; }
Poly Term() { var f = Imp(); while (Peek() == "*" || Peek() == "/") { string op = Take(); var b = Imp(); if (op == "*") f = f.Mul(b); else f = f.Div(b); } return f; }
Poly Sum() { Poly f; if (Peek() == "-") { Take(); f = Poly.C(new Q(0, 1)).Add(Term(), -1); } else { if (Peek() == "+") Take(); f = Term(); }
while (Peek() == "+" || Peek() == "-") { int sg = Take() == "+" ? 1 : -1; f = f.Add(Term(), sg); } return f; }
}
public static string Expand(string e) { return new PP(e).All().Str(); }
static Random rnd = new Random(7);
static List<string> Letters(string s) { var l = new List<string>(); foreach (Match m in Regex.Matches(s, "[a-z]")) if (!l.Contains(m.Value)) l.Add(m.Value); return l; }
// letters used in an exponent (a^m, a^(m+n)) get whole numbers 1-4, the way the book means them
static HashSet<string> ExpLetters(string s) { var h = new HashSet<string>(); foreach (Match m in Regex.Matches(s, @"\^(\(([^()]*)\)|[a-z])")) foreach (Match x in Regex.Matches(m.Groups[1].Value, "[a-z]")) h.Add(x.Value); return h; }
// with roots or letter/fraction exponents, letters stand for positive numbers (√(a^2) = a)
static bool Positive(string s) { return Regex.IsMatch(s, @"[√∛∜]|\^\(|\^[a-z]"); }
static Cx Rand(string v, HashSet<string> expL, bool pos) { return expL.Contains(v) ? new Cx(1 + rnd.Next(4), 0) : new Cx((0.6 + rnd.NextDouble() * 2.7) * (!pos && rnd.NextDouble() < 0.3 ? -1 : 1), 0); }
static bool Close(Cx x, Cx y) { return (x - y).Abs <= 1e-7 * Math.Max(1, y.Abs); }
// "" when a and b have the same value, else why not
// an inequality "x>5" (or "5<x") as letter, sign, bound; null when s is not one
static string[] Ineq(string s) {
var m = Regex.Match(s.Replace(" ", ""), @"^([^<>]+)([<>])([^<>]+)$"); if (!m.Success) return null;
if (Regex.IsMatch(m.Groups[1].Value, "^[a-z]$")) return new[] { m.Groups[1].Value, m.Groups[2].Value, m.Groups[3].Value };
if (Regex.IsMatch(m.Groups[3].Value, "^[a-z]$")) return new[] { m.Groups[3].Value, m.Groups[2].Value == "<" ? ">" : "<", m.Groups[1].Value };
return null;
}
// two equations are the same one when left minus right of a is that of b times a number, not 0, which may depend on
// the other letters but not on x (same as alg.js sameEq)
static string SameEq(string a, string b) {
var pa = a.Split('='); var pb = b.Split('=');
if (pa.Length != 2 || pb.Length != 2) return "not one equation: " + (pa.Length != 2 ? a : b);
try {
var fa = new P("(" + pa[0] + ")-(" + pa[1] + ")").All(); var fb = new P("(" + pb[0] + ")-(" + pb[1] + ")").All();
var vs = Letters(a + " " + b); bool u = vs.Contains("x"); int ok = 0; bool pos = Positive(a + b); var expL = ExpLetters(a + " " + b);
Cx k = new Cx(0, 0); bool haveK = false;
for (int j = 0; j < 40 && ok < 6; j++) {
var env = new Dictionary<string, Cx>(); foreach (var v in vs) env[v] = Rand(v, expL, pos); if (u) haveK = false;
int good = 0;
for (int m = 0; m < 12 && good < (u ? 4 : 1); m++) {
if (u) env["x"] = Rand("x", expL, pos);
Cx x = fa(env), y = fb(env); if (x.Bad || y.Bad) continue;
if (!haveK) { if (y.Abs < 1e-9) continue; k = x / y; haveK = true; if (k.Abs < 1e-9) return a + " is not " + b; }
if ((x - k * y).Abs > 1e-7 * Math.Max(1, x.Abs)) return a + " is not the same equation as " + b;
good++;
}
if (good >= (u ? 3 : 1)) ok++;
}
return ok >= 3 ? "" : "couldn't try " + a + " = " + b;
} catch (Exception e) { return e.Message + " in " + a + " / " + b; }
}
public static string Same(string a, string b) {
if (a.Contains("=") || b.Contains("=")) return SameEq(a, b);
var ia = Ineq(a); var ib = Ineq(b);
if (ia != null || ib != null) { if (ia == null || ib == null || ia[0] != ib[0] || ia[1] != ib[1]) return a + " is not " + b; return Same(ia[2], ib[2]); }
try {
var fa = new P(a).All(); var fb = new P(b).All(); var vs = Letters(a + " " + b); int ok = 0;
bool pos = Positive(a + b); var expL = ExpLetters(a + " " + b);
for (int k = 0; k < 60 && ok < 8; k++) {
var env = new Dictionary<string, Cx>(); foreach (var v in vs) env[v] = Rand(v, expL, pos);
Cx x = fa(env), y = fb(env); if (x.Bad || y.Bad) continue;
if (!Close(x, y)) return a + " is not " + b;
ok++;
}
return ok >= 3 ? "" : "couldn't try " + a + " = " + b;
} catch (Exception e) { return e.Message + " in " + a + " / " + b; }
}
// "x=5, y=4" makes every "lhs = rhs" in eqs true (other letters random; a value may use them: "x=(b-d)/2")
public static string Holds(string assigns, string[] eqs) {
try {
var vals = new List<KeyValuePair<string, F>>();
string all = "";
foreach (var part in assigns.Split(',')) { var kv = part.Split('='); vals.Add(new KeyValuePair<string, F>(kv[0].Trim(), new P(kv[1]).All())); all += kv[1] + " "; }
var sides = new List<F[]>();
foreach (var q in eqs) { var lr = q.Split('='); if (lr.Length != 2) return "not an equation: " + q; sides.Add(new[] { new P(lr[0]).All(), new P(lr[1]).All() }); all += q + " "; }
var free = Letters(all); foreach (var kv in vals) free.Remove(kv.Key);
int ok = 0; bool pos = Positive(all); var expL = ExpLetters(all);
for (int k = 0; k < 60 && ok < 8; k++) {
var env = new Dictionary<string, Cx>(); foreach (var v in free) env[v] = Rand(v, expL, pos);
foreach (var kv in vals) env[kv.Key] = kv.Value(env);
bool skip = false;
for (int j = 0; j < sides.Count; j++) {
Cx x = sides[j][0](env), y = sides[j][1](env);
if (x.Bad || y.Bad) { skip = true; break; }
if (!Close(x, y)) return assigns + " doesn't make " + eqs[j] + " true (" + x + " vs " + y + ")";
}
if (!skip) ok++;
}
return ok >= 3 ? "" : "couldn't try " + assigns;
} catch (Exception e) { return e.Message + " in " + assigns; }
}
}
EOF
make-audio.ps1: records every line of a book with Eloquence: -Id algebra2.
cat > /root/rays-rebuild/make-audio.ps1 <<'EOF'
# Records everything Ray's Arithmetic says with the PC's ETI-Eloquence (Reed, the same voice as ABC Books) at each
# speed, then writes public/audio/<id>.json (what the app asks for -> clip id). WAVs land in tools/out/s<speed>/,
# shared by every book (a line two books both say is recorded once).
# Usage: powershell -ExecutionPolicy Bypass -File RaysArithmetic\tools\make-audio.ps1 [-Id primary1877|intellectual|...]
# The keys must match app.js: prompts, "lesson:N", "n:N", "find:N", "ans:N", and the book's own texts.
# -List FILE writes "key<TAB>spoken text" for every clip to FILE and records nothing (to check the spoken forms).
param([string]$Id = 'primary1877', [int[]]$Speeds = @(60, 75), [string]$List)
$root = Split-Path -Parent (Split-Path -Parent $MyInvocation.MyCommand.Path)
$book = Get-Content "$root\public\books\$Id.json" -Raw -Encoding UTF8 | ConvertFrom-Json
$P = Get-Content "$root\public\prompts.json" -Raw -Encoding UTF8 | ConvertFrom-Json
$kids = 'Layla', 'Lavon', 'Lilly'
$say = New-Object System.Collections.Specialized.OrderedDictionary ([StringComparer]::Ordinal)
function Add($key, $spoken) { if ($key -and -not $say.Contains([string]$key)) { $say[[string]$key] = $(if ($spoken) { $spoken } else { [string]$key }) } }
foreach ($pr in $P.PSObject.Properties) { if ($pr.Value -like '*{kid}*') { foreach ($k in $kids) { Add ($pr.Value -replace '\{kid\}', $k) } } else { Add $pr.Value } }
foreach ($k in $kids) { Add "Great job, $k!" }
foreach ($n in 0..100) { Add "n:$n" "$n."; Add "find:$n" "Find $n." }
# "2 1/2" -> "2 and 1 half", "3/4" -> "3 fourths": how the book says fractions
# any denominator as an ordinal word: 23 -> twenty-third, 115 -> one hundred and fifteenth
function OrdWord([int]$d) {
$o = 'zero one two three four five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen eighteen nineteen' -split ' '
$t = ',,twenty,thirty,forty,fifty,sixty,seventy,eighty,ninety' -split ','
$oo = @{ one = 'first'; two = 'second'; three = 'third'; five = 'fifth'; eight = 'eighth'; nine = 'ninth'; twelve = 'twelfth' }
function Card([int]$n) { if ($n -lt 20) { return $o[$n] }; $w = $t[[Math]::Floor($n / 10)]; if ($n % 10) { $w += '-' + $o[$n % 10] }; $w }
$words = @()
if ($d -ge 1000) { $words += (Card ([Math]::Floor($d / 1000))) + ' thousand'; $d = $d % 1000 }
if ($d -ge 100) { $words += (Card ([Math]::Floor($d / 100))) + ' hundred'; $d = $d % 100 }
if ($d) { if ($words.Count) { $words += 'and' }; $words += (Card $d) }
$s = $words -join ' '
if ($s -match '^(.*?)(\w+)$') { $head = $Matches[1]; $last = $Matches[2] }
$last = $(if ($oo[$last]) { $oo[$last] } elseif ($last -match 'y$') { $last -replace 'y$', 'ieth' } else { $last + 'th' })
$head + $last
}
function Frac([string]$f) {
$den = @{ 2 = 'half'; 3 = 'third'; 4 = 'fourth'; 5 = 'fifth'; 6 = 'sixth'; 7 = 'seventh'; 8 = 'eighth'; 9 = 'ninth'; 10 = 'tenth'; 11 = 'eleventh'; 12 = 'twelfth'; 20 = 'twentieth'; 100 = 'hundredth' }
if ($f -match '^\d*\.\d+$' -or $f -match '^\d+$') { return $f } # decimals, and whole numbers too long for a number ({=digits})
if ($f -match '^(\d*\.\d+) (\d+/\d+)$') { return "$($Matches[1]) and $(Frac $Matches[2])" } # complex decimal: .0154 1/4
$w = ''; if ($f -match '^(\d+) (.+)$') { $w = "$($Matches[1]) and "; $f = $Matches[2] }
$n, $d = $f -split '/'; $name = $den[[int]$d]; if (-not $name) { $name = OrdWord ([int]$d) }
if ($name -eq 'half' -and [int]$n -gt 1) { $name = 'halve' }
return "$w$n $name$(if ([int]$n -gt 1) { 's' })"
}
function GeoSay([string]$s) {
$s = $s -replace '\s*\(\d+(, ?\d+)*\)', ''
[regex]::Replace($s, '\b[A-Z]{2,6}\b', { param($m) ($m.Value.ToCharArray() -join ' ') })
}
# must match artKey() in app.js
function ArtKey($a) { "$($a.n). $(if ($a.h) { "$($a.h). " })$($a.t)" }
$answers = New-Object 'System.Collections.Generic.SortedSet[long]'
foreach ($L in $book.lessons) {
Add "lesson:$($L.n)" "Lesson $($L.n). $($L.title)."
foreach ($v in @($L.list)) { if ($null -ne $v) { [void]$answers.Add([long]$v); if ([long]$v -gt 100) { Add "n:$v" "$v." } } }
foreach ($f in @($L.table)) { if ($f) { Add $f.t; Add $f.q; [void]$answers.Add([long]$f.r) } }
foreach ($r in @($L.rules)) { if ($r) { Add $r.t; Add $r.q } }
foreach ($q in @($L.qs)) {
if (-not $q) { continue }
foreach ($p in $q.parts) {
$s = if ($p.s) { $p.s } else { $p.t }; Add $s
if ($null -ne $p.a) { [void]$answers.Add([long]$p.a) }
if ($p.f) { Add "ans:$($p.f)" "The answer is $(Frac $p.f)." }
if ($null -ne $p.e) { Add "ans:$($p.e)" "The answer is $($p.es)." } # algebra: es = the answer in words
# {list: } items: whole numbers share the n:/ans: clips; fractions, decimals and algebra (ss = the item in words) get their own
$sq = @($p.seq); for ($k = 0; $k -lt $sq.Count; $k++) { $v = $sq[$k]; if ($null -eq $v) { continue }
if ($p.la) { $w = @($p.ss)[$k]; Add "n:$v" "$w."; Add "ans:$v" "The answer is $w." }
elseif ("$v" -match '^\d+$') { [void]$answers.Add([long]$v); if ([long]$v -gt 100) { Add "n:$v" "$v." } }
else { $w = Frac "$v"; Add "n:$v" "$w."; Add "ans:$v" "The answer is $w." } }
}
if ($q.sol) { Add $q.sol }
}
# Geometry: figure letters are said one by one ("AOE" -> "A O E"), article references "(103)" are not read
# Algebra: arts and quiz with math carry what to say (s, qs, cs) since "3a²" can't be read off the screen text
foreach ($a in @($L.arts)) { if ($a) { $k = ArtKey $a; Add $k $(if ($a.s) { $a.s } else { GeoSay $k }) } }
foreach ($x in @($L.quiz)) {
if (-not $x) { continue }
$qs = $(if ($x.qs) { $x.qs } else { GeoSay $x.q })
if ($x.tf) { Add $x.q "True or false? $qs" } else { Add $x.q $qs }
for ($i = 0; $i -lt @($x.c).Count; $i++) { $c = @($x.c)[$i]; Add "ansc:$c" $(if ($x.cs) { "The answer is: $(@($x.cs)[$i])." } else { GeoSay "The answer is: $c." }) }
}
}
foreach ($a in $answers) { Add "ans:$a" "The answer is $a." }
Add "Answer out loud, then tap Next."
"$($say.Count) clips per speed"
if ($List) { [IO.File]::WriteAllLines($List, [string[]]@(foreach ($k in $say.Keys) { "$k`t$($say[$k])" })); return }
$sha = [Security.Cryptography.SHA1]::Create()
function Id($s) { (($sha.ComputeHash([Text.Encoding]::UTF8.GetBytes($s)) | Select-Object -First 6 | ForEach-Object { $_.ToString('x2') }) -join '') }
$items = New-Object System.Collections.Specialized.OrderedDictionary ([StringComparer]::Ordinal)
foreach ($k in $say.Keys) { $items[$k] = Id $say[$k] }
$ps32 = 'C:\Windows\SysWOW64\WindowsPowerShell\v1.0\powershell.exe'
foreach ($sp in $Speeds) {
$dir = "$root\tools\out\s$sp"; New-Item -ItemType Directory -Force $dir | Out-Null
$jobs = @(); $seen = @{}
foreach ($k in $say.Keys) { $cid = $items[$k]; if (-not $seen[$cid] -and -not (Test-Path "$dir\$cid.wav")) { $seen[$cid] = 1; $jobs += [ordered]@{ text = $say[$k]; out = "$dir\$cid.wav" } } }
"speed $sp : $($jobs.Count) to record"
for ($i = 0; $i -lt $jobs.Count; $i += 400) { # batches, so a long run shows progress
$jf = "$dir\jobs.json"; ConvertTo-Json @($jobs[$i..([Math]::Min($i + 399, $jobs.Count - 1))]) | Set-Content -Encoding utf8 $jf
& $ps32 -NoProfile -ExecutionPolicy Bypass -File "$root\tools\eloq-render.ps1" -Jobs $jf -Speed $sp | Out-Null
" $([Math]::Min($i + 400, $jobs.Count)) / $($jobs.Count)"
}
Remove-Item "$dir\*.wav.json" -ErrorAction SilentlyContinue # word times aren't used here
}
$out = [ordered]@{ speeds = $Speeds; items = $items }
New-Item -ItemType Directory -Force "$root\public\audio" | Out-Null
[IO.File]::WriteAllText("$root\public\audio\$Id.json", ($out | ConvertTo-Json -Depth 4 -Compress), (New-Object Text.UTF8Encoding $false))
"manifest: $root\public\audio\$Id.json"
EOF
selftest-alg.ps1: checks that the app’s algebra reader accepts every typed answer of a book (-Book algebra2), in headless Edge, plus unit tests.
cat > /root/rays-rebuild/selftest-alg.ps1 <<'EOF'
# Self-test of the algebra answers without a dev server: RaysAlg.ok(p.e, p.e) (and each p.ealt) over a built book,
# run in headless Edge. Prints "checked N fails M" and each failure.
# Usage: powershell -ExecutionPolicy Bypass -File RaysArithmetic\tools\selftest-alg.ps1 [-Book algebra2]
param([string]$Book = 'algebra2')
$root = Split-Path -Parent (Split-Path -Parent $MyInvocation.MyCommand.Path)
$tmp = Join-Path $env:TEMP 'rays-selftest'; New-Item -ItemType Directory -Force $tmp | Out-Null
$js = @'
var out=[],n=0;
function walk(x,path){ if(Array.isArray(x)) x.forEach(function(y,i){walk(y,path+'/'+i)}); else if(x&&typeof x==='object'){
if(typeof x.e==='string'){ n++; var r; try{r=RaysAlg.ok(x.e,x.e)}catch(err){r='ERR '+err} if(r!==true) out.push(path+' '+x.e+' -> '+r);
[].concat(x.ealt||[]).forEach(function(a){var r2; try{r2=RaysAlg.ok(a,a)}catch(e){r2='ERR'} if(r2!==true) out.push(path+' alt '+a+' -> '+r2)}); }
if(x.la&&x.seq) x.seq.forEach(function(it){ n++; var r3; try{r3=RaysAlg.ok(it,it)}catch(e){r3='ERR'} if(r3!==true) out.push(path+' list item '+it+' -> '+r3)});
for(var k in x) if(k!=='e') walk(x[k],path+'.'+k);} }
walk(B,'');
// the answer forms Book 7 added: [typed, book's answer, should it be right]
var T=[['a^(2/3)','a^(2/3)',1],['a^(-1/2)','1/√a',1],['x^(1/2)x^(1/2)','x',0],['a^m','a^m',1],['a^(m+n)','a^(m+n)',1],['a^ma^n','a^(m+n)',0],
['27a^(m+n)x^(m+n)','27a^(m+n)x^(m+n)',1],['x^(m-2n)','x^(m-2n)',1],['x^(m+2n)','x^(m-2n)',0],['a^(m-1)b^2+a^mb+a^(n-3)','a^(m-1)b^2+a^mb+a^(n-3)',1],
['∛(2a)','∛(2a)',1],['2∛3','∛24',1],['2∛3','2∛3',1],['∛-8','-2',0],['-2','∛-8',1],['2a∛(3a)','2a∛(3a)',1],['∛(24a^4)','2a∛(3a)',0],['∜a','∜a',1],
['√-1','√-1',1],['2√-3','2√-3',1],['√-12','2√-3',0],['a+b√-1','a+b√-1',1],['b√-1+a','a+b√-1',1],['a-b√-1','a+b√-1',0],['-√6','-√6',1],['3√-1','√-9',1],['√-9','3√-1',0],
['3±√5','3±√5',1],['3+√5','3±√5',0],['3∓√5','3±√5',0],['-√5+3','3±√5',0],['±√5+3','3±√5',1],['3±√-1','3±√-1',1],['3±2','5',0],
['3a+2b','3a+2b',1],['(a+3)(a+4)','(a+3)(a+4)',1],['a^2+7a+12','(a+3)(a+4)',0],['x^-3','x^-3',1],['2a√2','2a√2',1],['√(8a^2)','2a√2',0],
// chunk 8: equations (the same equation in any form) and inequalities (letter, sign, bound)
['x^2-9x=-20','x^2-9x=-20',1],['x^2-9x+20=0','x^2-9x=-20',1],['2x^2-18x+40=0','x^2-9x=-20',1],['(x-4)(x-5)=0','x^2-9x=-20',1],['20-9x+x^2=0','x^2-9x=-20',1],
['x^2-9x=20','x^2-9x=-20',0],['x^2-9x','x^2-9x=-20',0],['x^2=9x=-20','x^2-9x=-20',0],['0=0','x^2-9x=-20',0],['x^2-2mx=n^2-m^2','x^2-2mx=n^2-m^2',1],['x^2-2mx+m^2-n^2=0','x^2-2mx=n^2-m^2',1],
['4x-3x=12','4x-3x=12',1],['x/3-x/4=1','4x-3x=12',0],['x-12=0','4x-3x=12',1],['(x-a)(a-b)-(x-a)(a+b)=2nb','ax-a^2-bx+ab-ax+a^2-bx+ab=2nb',1],['(x-a)(a-b)-(x-a)(a+b)=2b','ax-a^2-bx+ab-ax+a^2-bx+ab=2nb',0],
['x>5','x>5',1],['5<x','x>5',1],['x<5','x>5',0],['y>5','x>5',0],['x>6','x>5',0],['>5','x>5',0],['x<36','x<36',1],['x>-2','x>-2',1],
// chunk 13: number bases with letter exponents, and a fraction whose side is a sum of factored terms
['3^n/2^n','3^n/2^n',1],['3^(n-2)/2^(n-1)','3^(n-2)/2^(n-1)',1],['(1/3)(3/2)^(n-1)','3^(n-2)/2^(n-1)',0],['3^n/2^n','3^(n-1)/2^n',0],
['ab/((n-1)a-(n-2)b)','ab/((n-1)a-(n-2)b)',1],['ab/(na-a-nb+2b)','ab/((n-1)a-(n-2)b)',1],['ab/((n-1)a-(n-2)b)','ab/(na-a-nb+2b)',1],['ab/((n-1)a-(n-3)b)','ab/((n-1)a-(n-2)b)',0]];
var tf=0; T.forEach(function(t){var r; try{r=RaysAlg.ok(t[0],t[1])}catch(e){r='ERR '+e} if(!!r!==!!t[2]){tf++; out.push('unit: ok('+t[0]+', '+t[1]+') = '+r)}});
var P=[['a^(2/3)','a²ᐟ³'],['a^(m+n)','aᵐ⁺ⁿ'],['x^-3','x⁻³'],['a^m-b','aᵐ−b'],['3±√5','3±√5']];
P.forEach(function(t){var r=RaysAlg.pretty(t[0]); if(r!==t[1]){tf++; out.push('pretty: '+t[0]+' = '+r)}});
document.getElementById('o').textContent='checked '+n+' answers + '+(T.length+P.length)+' unit tests, fails '+out.length+'\n'+out.join('\n');
'@
$html = "<!doctype html><meta charset=utf-8><pre id=o></pre><script>" + (Get-Content "$root\public\alg.js" -Raw -Encoding UTF8) +
"`nvar B=" + (Get-Content "$root\public\books\$Book.json" -Raw -Encoding UTF8) + ";`n" + $js + "</script>"
[IO.File]::WriteAllText("$tmp\selftest.html", $html, (New-Object Text.UTF8Encoding $false))
$edge = 'C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe'
Start-Process -FilePath $edge -ArgumentList @('--headless', '--disable-gpu', "--user-data-dir=$tmp\prof", '--virtual-time-budget=5000',
'--dump-dom', "file:///$($tmp -replace '\\','/')/selftest.html") -RedirectStandardOutput "$tmp\out.html" -RedirectStandardError "$tmp\err.txt" -Wait | Out-Null
$t = Get-Content "$tmp\out.html" -Raw -Encoding UTF8
if ($t -match '(?s)<pre id="o">(.*?)</pre>') { [Net.WebUtility]::HtmlDecode($Matches[1]) } else { 'no result'; Get-Content "$tmp\err.txt" -TotalCount 5 }
EOF
playthrough.js: the key-by-key test (how to run it is at its top).
cat > /root/rays-rebuild/playthrough.js <<'EOF'
// UI play-through (testing, not loaded by the app): paste into the page's console at http://localhost:8129/?preview
// with a reader picked and a book open on its lesson map, then: await PT.run(0, 87). Every Problems answer is typed key
// by key on the on-screen pad buttons (digits, + − ( ) / xⁿ, the letter row, and, /, .) and must turn green on the
// first OK. PT.log lists answers refused or needing a key the pad lacks; PT.done = lessons finished.
window.PT = (() => {
const w = ms => new Promise(r => setTimeout(r, ms));
const vis = b => b.offsetParent !== null;
const log = [], done = [];
async function until(fn, ms = 9000) { const t = Date.now(); while (Date.now() - t < ms) { if (fn()) return true; await w(60); } return false; }
const padBtns = () => [...document.querySelectorAll('.qa button')].filter(vis);
const keyFor = c => ({ '-': '−', '^': 'xⁿ', ' ': 'and', '*': '×' })[c] || c;
async function type(s) {
for (const c of String(s)) {
const k = keyFor(c), b = padBtns().find(x => x.textContent.trim() === k);
if (!b) return 'no key "' + c + '"';
b.click(); await w(15);
}
padBtns().find(x => x.textContent.trim() === 'OK').click(); await w(120);
return null;
}
const entry = () => document.querySelector('.qa .entry');
async function lesson(i) {
const D = Rays.debug, book = D().S && D().L;
const sel = document.getElementById('jumpSel'); sel.value = String(i); document.getElementById('jumpGo').click();
await w(400); Rays.toStep('problems');
const L = D().L; if (!L.qs) { done.push(L.n); return; }
await until(() => document.querySelector('.qa .q .pt'));
for (let qi = 0; qi < L.qs.length; qi++) {
const q = L.qs[qi];
for (let pi = 0; pi < q.parts.length; pi++) {
const p = q.parts[pi], where = `L${L.n} q${qi + 1}.${pi + 1}`;
const hintOk = () => document.getElementById('hint').textContent === `Question ${qi + 1} of ${L.qs.length}`;
const curOk = () => { const c = document.querySelector('.qa .q .pt.cur'); return c && c.textContent.trim() === String(p.t).trim(); };
if (!(await until(() => hintOk() && curOk() && !entry().classList.contains('ok')))) { log.push(where + ': never reached'); return; }
if (p.open) {
const nb = [...document.querySelectorAll('.qa button')].find(b => vis(b) && /Next/.test(b.textContent));
nb.click(); if (pi === q.parts.length - 1 && q.sol) { await w(300); nb.click(); }
await w(400); continue;
}
const items = p.seq ? p.seq.slice(p.lst ? 0 : 1) : [p.e != null ? p.e : p.ex ? p.ex[0] : p.f || p.a];
for (const it of items) {
const err = await type(it);
if (err) { // two misses make the app show the answer and move on
log.push(`${where}: ${err} in ${it}`);
if (!entry().textContent.trim()) padBtns().find(x => x.textContent.trim() === '1').click();
const ok = padBtns().find(x => x.textContent.trim() === 'OK'); ok.click(); await w(200); ok.click();
}
else if (!entry().classList.contains('ok')) { log.push(`${where}: refused ${it}`); padBtns().find(x => x.textContent.trim() === 'OK').click(); }
await w(p.seq ? 420 : 60);
}
}
}
done.push(L.n);
}
async function run(a, b) { for (let i = a; i <= b; i++) { try { await lesson(i); } catch (e) { log.push(`lesson index ${i}: ${e.message}`); } await w(1200); } return { done: done.length, log: log.length }; }
return { run, lesson, log, done };
})();
EOF
alg.js: the algebra pad’s reader and checker in the app.
cat > /root/rays-rebuild/alg.js <<'EOF'
// Algebra answers (Books 6-7, Ray's Elementary and Higher Algebra): reads what the kid typed on the algebra pad (3a+2b,
// x^2-4, (a+3)(a+4), (b-d)/2, -5, a^(2/3), a^m, ∛(2a), 2√-3, 3±√5), shows it the book's way (x², −) and checks it
// against the book's answer.
// An answer is right when it has the same value (tried at several random numbers for the letters, in complex numbers so
// √-1 works the book's way: √-a·√-b = −√ab) AND is written as simply as the book's: a sum of unlike terms when the
// book's is one (copying the question back doesn't count), in factors when the book's answer is factored (any order), a
// fraction no bigger than the book's when it is a fraction. "3±√5" (two roots in one answer) must be typed with ± too.
// Book 7 also has equation answers (x^2-9x=-20: any form of the same equation) and inequalities (x>5).
window.RaysAlg = (() => {
const SUP = { 0: '⁰', 1: '¹', 2: '²', 3: '³', 4: '⁴', 5: '⁵', 6: '⁶', 7: '⁷', 8: '⁸', 9: '⁹', '-': '⁻', '+': '⁺', '/': 'ᐟ',
a: 'ᵃ', b: 'ᵇ', c: 'ᶜ', d: 'ᵈ', e: 'ᵉ', f: 'ᶠ', g: 'ᵍ', h: 'ʰ', i: 'ⁱ', j: 'ʲ', k: 'ᵏ', l: 'ˡ', m: 'ᵐ', n: 'ⁿ', o: 'ᵒ', p: 'ᵖ',
r: 'ʳ', s: 'ˢ', t: 'ᵗ', u: 'ᵘ', v: 'ᵛ', w: 'ʷ', x: 'ˣ', y: 'ʸ', z: 'ᶻ' };
// the book's way: x^2 -> x², a^(2/3) -> a²ᐟ³, a^(m+n) -> aᵐ⁺ⁿ, - -> −, * -> ×
const sup = d => [...d].every(c => SUP[c]) ? [...d].map(c => SUP[c]).join('') : null;
const pretty = s => String(s).replace(/\^(-?\d+|[a-z]|\(([^()]*)\))/g, (m, d, inner) => sup(inner != null ? inner : d) || m).replace(/-/g, '−').replace(/\*/g, '×');
function tokens(s) {
const out = [], rx = /\s*(\d+\.?\d*|\.\d+|[a-z]|[-+*/^()√∛∜±])/gy; let m, i = 0;
s = String(s).replace(/−/g, '-').replace(/[·×]/g, '*').trim();
while (i < s.length) { rx.lastIndex = i; m = rx.exec(s); if (!m) return null; out.push(m[1]); i = rx.lastIndex; while (s[i] === ' ') i++; }
return out;
}
// sum := [+-] term ([+-] term)* ; term := imp ([*/] imp)* ; imp := pow pow* (2ab: implicit times binds tighter than /,
// so a/bc = a/(bc) and 2x/3 = (2x)/3) ; pow := atom [^ ([-]int | letter | ( sum ))] ;
// atom := number | letter | ( sum ) | √ pow | ∛ pow | ∜ pow (√-3: a root may take a minus sign: √(-3))
function parse(s) {
const tk = tokens(s); if (!tk || !tk.length || tk.includes('±')) return null; let i = 0;
const peek = () => tk[i], take = () => tk[i++];
const startsAtom = t => t !== undefined && (/^[\d.a-z√∛∜]/.test(t) || t === '(');
const ROOT = { '√': 2, '∛': 3, '∜': 4 };
function atom() {
const t = take();
if (t === undefined) throw 0;
if (ROOT[t]) { // √a, √(a-x), 2√3, √-1
let a; if (peek() === '-') { take(); a = { t: 'add', terms: [{ sg: -1, a: pow() }] }; } else a = pow();
return ROOT[t] === 2 ? { t: 'sqrt', a } : { t: 'root', n: ROOT[t], a };
}
if (t === '(') { const a = sum(); if (take() !== ')') throw 0; return { t: 'par', a }; }
if (/^[a-z]$/.test(t)) return { t: 'var', n: t };
if (/^[\d.]/.test(t)) return { t: 'num', v: parseFloat(t), s: t };
throw 0;
}
function pow() {
const b = atom();
if (peek() !== '^') return b;
take();
if (peek() === '(') { take(); const x = sum(); if (take() !== ')') throw 0; const c = constInt(x); return c != null ? { t: 'pow', b, e: c } : { t: 'pow', b, x }; }
if (/^[a-z]$/.test(peek() || '')) return { t: 'pow', b, x: { t: 'var', n: take() } };
let neg = false; if (peek() === '-') { take(); neg = true; } const e = take(); if (!/^\d+$/.test(e || '')) throw 0;
return { t: 'pow', b, e: neg ? -e : +e };
}
function imp() { const f = [pow()]; while (startsAtom(peek())) f.push(pow()); return f.length === 1 ? f[0] : { t: 'mul', f }; }
function term() {
let a = imp();
while (peek() === '*' || peek() === '/') { const op = take(), b = imp(); a = op === '*' ? { t: 'mul', f: [a, b], x: 1 } : { t: 'div', a, b }; }
return a;
}
function sum() {
const terms = []; let sg = 1;
if (peek() === '-' || peek() === '+') sg = take() === '-' ? -1 : 1;
terms.push({ sg, a: term() });
while (peek() === '+' || peek() === '-') { const s2 = take() === '-' ? -1 : 1; terms.push({ sg: s2, a: term() }); }
return terms.length === 1 && terms[0].sg === 1 ? terms[0].a : { t: 'add', terms };
}
try { const r = sum(); return i === tk.length ? r : null; } catch (e) { return null; }
}
// an exponent in brackets that is a plain whole number: a^(2) = a^2, a^(-3) = a^-3
function constInt(x) {
if (x.t === 'num' && Number.isInteger(x.v)) return x.v;
if (x.t === 'add' && x.terms.length === 1 && x.terms[0].a.t === 'num' && Number.isInteger(x.terms[0].a.v)) return x.terms[0].sg * x.terms[0].a.v;
return null;
}
// ---------- complex numbers [re, im] ----------
const cx = { add: (a, b) => [a[0] + b[0], a[1] + b[1]], mul: (a, b) => [a[0] * b[0] - a[1] * b[1], a[0] * b[1] + a[1] * b[0]],
div: (a, b) => { const d = b[0] * b[0] + b[1] * b[1]; return [(a[0] * b[0] + a[1] * b[1]) / d, (a[1] * b[0] - a[0] * b[1]) / d]; } };
function cpow(z, e) { // e = [re, im]; whole powers by multiplying, the rest by the principal value
if (Math.abs(e[1]) < 1e-12 && Number.isInteger(e[0]) && Math.abs(e[0]) <= 64) {
let r = [1, 0]; for (let k = 0; k < Math.abs(e[0]); k++) r = cx.mul(r, z); return e[0] < 0 ? cx.div([1, 0], r) : r;
}
if (Math.abs(z[1]) < 1e-15 && z[0] > 0 && Math.abs(e[1]) < 1e-12) return [Math.pow(z[0], e[0]), 0];
const r = Math.hypot(z[0], z[1]); if (r === 0) return [0, 0];
const lr = Math.log(r), th = Math.atan2(z[1], z[0]), m = Math.exp(e[0] * lr - e[1] * th), an = e[1] * lr + e[0] * th;
return [m * Math.cos(an), m * Math.sin(an)];
}
function croot(z, n) { // √ = principal square root; ∛ of a real number = the real cube root (∛-8 = -2)
if (Math.abs(z[1]) < 1e-15) { if (z[0] >= 0) return [Math.pow(z[0], 1 / n), 0]; if (n % 2) return [-Math.pow(-z[0], 1 / n), 0]; }
if (n === 2) { const r = Math.hypot(z[0], z[1]); return [Math.sqrt((r + z[0]) / 2), (z[1] < 0 ? -1 : 1) * Math.sqrt((r - z[0]) / 2)]; }
return cpow(z, [1 / n, 0]);
}
function ev(n, env) {
switch (n.t) {
case 'num': return [n.v, 0];
case 'var': return [env[n.n], 0];
case 'par': return ev(n.a, env);
case 'sqrt': return croot(ev(n.a, env), 2);
case 'root': return croot(ev(n.a, env), n.n);
case 'pow': return cpow(ev(n.b, env), n.x ? ev(n.x, env) : [n.e, 0]);
case 'mul': return n.f.reduce((p, x) => cx.mul(p, ev(x, env)), [1, 0]);
case 'div': return cx.div(ev(n.a, env), ev(n.b, env));
case 'add': return n.terms.reduce((p, x) => { const v = ev(x.a, env); return [p[0] + x.sg * v[0], p[1] + x.sg * v[1]]; }, [0, 0]);
}
return [NaN, NaN];
}
// a node written out again (for telling radicals apart: √a and √b are unlike terms)
const RS = { 2: '√', 3: '∛', 4: '∜' };
const ser = n => n.t === 'num' ? n.s : n.t === 'var' ? n.n : n.t === 'par' ? `(${ser(n.a)})` : n.t === 'sqrt' ? `√${ser(n.a)}` : n.t === 'root' ? `${RS[n.n]}${ser(n.a)}` : n.t === 'pow' ? `${ser(n.b)}^${n.x ? `(${ser(n.x)})` : n.e}` : n.t === 'mul' ? n.f.map(ser).join('*') : n.t === 'div' ? `${ser(n.a)}/${ser(n.b)}` : n.terms.map(x => (x.sg < 0 ? '-' : '+') + ser(x.a)).join('');
const letters = n => { const s = new Set(); (function w(x) { if (!x) return; if (x.t === 'var') s.add(x.n); ['a', 'b', 'x'].forEach(k => x[k] && typeof x[k] === 'object' && w(x[k])); (x.f || []).forEach(w); (x.terms || []).forEach(y => w(y.a)); })(n); return s; };
// same value: tried at 8 sets of random numbers (points where either side blows up are skipped).
function same(a, b) {
const sa = ser(a) + ser(b), vs = [...new Set([...letters(a), ...letters(b)])]; let tried = 0;
// with roots or letter/fraction exponents, letters stand for positive numbers (√(a^2) = a); letters in an exponent
// get whole numbers 1-4, so x^(m+n) = x^m*x^n is tried as the book means it
const pos = /[√∛∜]|\^\(/.test(sa) || [a, b].some(hasLetterExp), expL = new Set();
(function w(x) { if (!x || typeof x !== 'object') return; if (x.t === 'pow' && x.x) letters(x.x).forEach(v => expL.add(v)); ['a', 'b', 'x'].forEach(k => w(x[k])); (x.f || []).forEach(w); (x.terms || []).forEach(y => w(y.a)); })({ t: 'mul', f: [a, b] });
for (let k = 0; k < 40 && tried < 8; k++) {
const env = {}; vs.forEach(v => { env[v] = expL.has(v) ? 1 + Math.floor(Math.random() * 4) : (0.6 + Math.random() * 2.7) * (!pos && Math.random() < 0.3 ? -1 : 1); });
const x = ev(a, env), y = ev(b, env), my = Math.hypot(y[0], y[1]);
if (![...x, ...y].every(isFinite) || my > 1e12) continue;
if (Math.hypot(x[0] - y[0], x[1] - y[1]) > 1e-7 * Math.max(1, my)) return false;
tried++;
}
return tried >= 3;
}
// two equations (given as left minus right) are the same one: a is b times a number that may depend on the other
// letters but not on x (x^2-9x+20=0 and 2x^2-18x+40=0; (x-a)(a-b)-(x-a)(a+b)=2nb and the same over a^2-b^2)
function sameEq(a, b) {
const vs = [...new Set([...letters(a), ...letters(b)])], u = vs.includes('x') ? 'x' : null, sa = ser(a) + ser(b);
const pos = /[√∛∜]|\^\(/.test(sa) || [a, b].some(hasLetterExp), rnd = () => (0.6 + Math.random() * 2.7) * (!pos && Math.random() < 0.3 ? -1 : 1);
let k = null, tried = 0;
for (let n = 0; n < 30 && tried < 5; n++) {
const env = {}; vs.forEach(v => { env[v] = rnd(); }); if (u) k = null;
let good = 0;
for (let m = 0; m < 12 && good < (u ? 4 : 1); m++) {
if (u) env[u] = rnd();
const x = ev(a, env), y = ev(b, env), my = Math.hypot(y[0], y[1]);
if (![...x, ...y].every(isFinite) || my > 1e12) continue;
if (!k) { if (my < 1e-9) continue; k = cx.div(x, y); if (Math.hypot(k[0], k[1]) < 1e-9) return false; }
const ky = cx.mul(k, y); if (Math.hypot(x[0] - ky[0], x[1] - ky[1]) > 1e-7 * Math.max(1, Math.hypot(x[0], x[1]))) return false;
good++;
}
if (good >= (u ? 3 : 1)) tried++;
}
return tried >= 3;
}
const hasLetterExp = n => /\^\(/.test(ser(n)) || /\^\(?[a-z]/.test(ser(n));
// what is under a root of index r is in simplest form: no r-th power factor left in its number, no letter to the r-th
// power or more, no fraction (√(8a^2) is not simplest; 2a√2 is). A sum under the root (√(a-x)) is left alone;
// √-12 is not simplest (2√-3 is).
function surd(r, idx = 2) {
if (r.t === 'par') r = r.a;
if (r.t === 'add' && r.terms.length === 1 && r.terms[0].sg < 0) r = r.terms[0].a;
if (r.t === 'add') return true;
let ok = true;
(function w(x) {
if (x.t === 'num') { const n = x.v; if (!Number.isInteger(n)) ok = false; else for (let d = 2; Math.pow(d, idx) <= n; d++) if (n % Math.pow(d, idx) === 0) ok = false; }
else if (x.t === 'pow') { if (x.x || x.b.t !== 'var' || x.e < 1 || x.e >= idx) ok = false; }
else if (x.t === 'mul') x.f.forEach(w);
else if (x.t !== 'var') ok = false;
})(r);
return ok;
}
// a single term written simply: number(s) and letters, each letter once (a²b, not aab), one number at most, divided
// only by a number (x/3). Returns its letter signature ("a2b1") or null.
function termSig(n) {
let nums = 0; const pw = {};
function f(x) {
if (x.t === 'num') { nums++; return true; }
if (x.t === 'par' && x.a.t === 'div' && x.a.a.t === 'num' && x.a.b.t === 'num') { nums++; return true; } // (2/5)√3
if (x.t === 'var') { if (pw[x.n]) return false; pw[x.n] = 1; return true; }
if (x.t === 'pow' && x.b.t === 'var') { if (pw[x.b.n]) return false; if (x.x) { pw[x.b.n] = '^' + ser(x.x); return true; } if (x.e < 1) return false; pw[x.b.n] = x.e; return true; }
if (x.t === 'pow' && x.b.t === 'num' && x.x) { const k = ser(x); if (pw[k]) return false; pw[k] = 1; return true; } // 3^n, 2^(n-1)
if (x.t === 'sqrt' || x.t === 'root') { if (!surd(x.a, x.n || 2)) return false; const k = ser(x); if (pw[k]) return false; pw[k] = 1; return true; }
if (x.t === 'mul' && !x.x) return x.f.every((y, i) => (y.t !== 'num' || i === 0) && f(y)); // the number comes first: 3a, not a3
if (x.t === 'div' && x.b.t === 'num') return f(x.a.t === 'par' && x.a.a.t !== 'add' ? x.a.a : x.a); // (3y^2z)/2 = 3y^2z/2
return false;
}
if (!f(n) || nums > 1) return null;
return Object.keys(pw).sort().map(k => k + pw[k]).join('') || '1';
}
// a sum of unlike terms (no brackets): the simplified form of a polynomial
function flat(n) {
const ts = n.t === 'add' ? n.terms.map(x => x.a) : [n], seen = new Set();
for (const t of ts) { const s = termSig(t); if (s === null || seen.has(s)) return false; seen.add(s); }
return true;
}
// a bracket with nothing left to take out: its whole numbers have no common divisor and no letter is in every term
// (so 2(2x^2+3xy) is not the factors of 4x^2+6xy; 2x(2x+3y) is)
function primitive(n) {
const ts = n.t === 'add' ? n.terms.map(x => x.a) : [n]; if (ts.length < 2) return true;
const gcd = (a, b) => b ? gcd(b, a % b) : a; let g = 0, common = null;
for (const t of ts) {
let c = 1; const ls = new Set();
(function w(x) { if (x.t === 'num') c *= x.v; else if (x.t === 'var') ls.add(x.n); else if (x.t === 'pow' && x.b.t === 'var') ls.add(x.b.n); else if (x.t === 'mul') x.f.forEach(w); else if (x.t === 'div') { w(x.a); c = NaN; } else c = NaN; })(t);
if (Number.isInteger(c)) g = gcd(g, Math.abs(c)); else g = 1;
common = common ? new Set([...common].filter(v => ls.has(v))) : ls;
}
return g <= 1 && common.size === 0;
}
const deg = n => { let d = 0; if (n.t === 'add') return Math.max(...n.terms.map(x => deg(x.a))); if (n.t === 'var') return 1; if (n.t === 'pow') return n.x ? deg(n.b) : deg(n.b) * Math.max(0, n.e); if (n.t === 'par') return deg(n.a); if (n.t === 'mul') { n.f.forEach(x => d += deg(x)); return d; } if (n.t === 'div') return deg(n.a); return 0; };
const unneg = n => (n.t === 'add' && n.terms.length === 1) ? n.terms[0].a : n; // -(a+b)(a-b) -> the product
// factors: (a+3)(a+4), 2(x-1)², a(b+c). Counts the bracketed factors (a square counts twice), each must be simplified.
function factors(n) {
n = unneg(n); const fs = []; (function fl(x) { if (x.t === 'mul') x.f.forEach(fl); else fs.push(x); })(n); let k = 0;
for (const f of fs) {
const g = f.t === 'pow' && f.b.t === 'par' ? f.b : f;
if (g.t === 'par') { if (!flat(g.a) || !primitive(g.a)) return -1; k += f.t === 'pow' ? (f.x ? 1 : f.e) : 1; }
else if (termSig(g) === null) return -1;
}
return k;
}
// the book's answer decides what "written simply" means
function kind(a) {
const u = unneg(a);
if (flat(a)) return { k: 'p' };
if (u.t === 'div' && letters(u.b).size) return { k: 'r', d: deg(u.a) + deg(u.b) };
const f = factors(a); if (f > 0) return { k: 'f', n: f };
return { k: 'a' };
}
function ok1(typed, answer) {
const a = parse(answer), t = parse(typed); if (!a || !t) return false;
if (!same(t, a)) return false;
const K = kind(a);
if (K.k === 'p') return flat(t);
if (K.k === 'f') return factors(t) >= K.n;
if (K.k === 'r') { const u = unneg(t); if (flat(t)) return true; if (u.t !== 'div') return false; const side = x => { const y = x.t === 'par' ? x.a : x; return flat(y) || factors(y) >= 0 || (y.t === 'add' && y.terms.every(z => factors(z.a) >= 0)); }; /* (n-1)a-(n-2)b */ return side(u.a) && side(u.b) && deg(u.a) + deg(u.b) <= K.d; }
return tokens(typed).length <= tokens(answer).length + 2;
}
// "3±√5" stands for 3+√5 and 3−√5: the typed answer needs a ± too, and its two values must be the book's two (either way)
const pm = (s, sg) => String(s).replace('±', sg);
// Book 7: an equation answer (x^2-9x=-20) is right when the typed one is the same equation (x^2-9x+20=0 counts), with
// no fraction when the book's has none (a cleared equation can't be the question copied back); an inequality (x>5)
// needs the same letter, sign and bound (5<x counts)
const eqDiff = s => { const p = String(s).split('='); return p.length === 2 && p[0].trim() && p[1].trim() ? parse(`(${p[0]})-(${p[1]})`) : null; };
const ineq = s => {
const m = String(s).replace(/\s+/g, '').match(/^([^<>]+)([<>])([^<>]+)$/); if (!m) return null;
if (/^[a-z]$/.test(m[1])) return { v: m[1], op: m[2], b: m[3] };
if (/^[a-z]$/.test(m[3])) return { v: m[3], op: m[2] === '<' ? '>' : '<', b: m[1] };
return null;
};
function ok(typed, answer) {
if (String(answer).includes('=')) { const a = eqDiff(answer), t = eqDiff(typed); return !!(a && t && (String(answer).includes('/') || !String(typed).includes('/')) && sameEq(t, a)); }
if (/[<>]/.test(answer)) { const a = ineq(answer), t = ineq(typed); return !!(a && t && a.v === t.v && a.op === t.op && ok1(t.b, a.b)); }
const ta = String(typed).includes('±'), aa = String(answer).includes('±');
if (!aa) return !ta && ok1(typed, answer);
if (!ta) return false;
return (ok1(pm(typed, '+'), pm(answer, '+')) && ok1(pm(typed, '-'), pm(answer, '-'))) || (ok1(pm(typed, '+'), pm(answer, '-')) && ok1(pm(typed, '-'), pm(answer, '+')));
}
return { parse, pretty, ok, same, kind, flat, factors };
})();
EOF
app.js: the game, for the whole shelf.
cat > /root/rays-rebuild/app.js <<'EOF'
// Ray's Arithmetic: gamified Ray's New Primary Arithmetic (1877). Progress is saved per kid in localStorage ('rays').
// Same look and voice as ABC Books; the kid picked in ABC Books (same site) is picked here too.
const Rays = (() => {
const $ = id => document.getElementById(id);
// Anonymous funnel counts (/account/stats.js, abcbooks.fyi only): never names, only book/lesson/step.
const track = (url, data) => { try { window.abcStats && window.abcStats.step(url, data); } catch (e) {} };
// Readers come from ABC Books on this site ('abcbooks'.readers: names a grown-up added there). Same rule as ABC
// Books: no 'abcbooks' (or no kid and no progress) = no readers yet; an old device without .readers = the three
// original kids plus any names in its progress.
const NAME_OK = n => typeof n === 'string' && /^\p{L}[\p{L}' .-]{0,15}$/u.test(n.trim());
function readers() {
let c = null; try { c = JSON.parse(localStorage.getItem('abcbooks')); } catch (e) {}
let r = [];
if (c && Array.isArray(c.readers)) r = c.readers.filter(NAME_OK);
else if (c && (c.kid || (c.progress && Object.keys(c.progress).length))) r = ['Layla', 'Lavon', 'Lilly'].concat(Object.keys(c.progress || {}).filter(n => NAME_OK(n) && !['Layla', 'Lavon', 'Lilly'].includes(n)));
if (S && S.kid && r.length && !r.includes(S.kid)) r = r.concat(S.kid);
return r;
}
// Ray's series in order (raysarithmetic.wordpress.com/rays-free-arithmetic). A book is playable once books/<id>.json exists.
const SHELF = [
{ id: 'primary1877', title: "Ray's New Primary Arithmetic", sub: 'Book 1 · Grades 1-2', color: '#2f6f8f' },
{ id: 'intellectual', title: "Ray's New Intellectual Arithmetic", sub: 'Book 2 · Grades 3-4', color: '#6a4c93' },
{ id: 'practical', title: "Ray's New Practical Arithmetic", sub: 'Book 3 · Grades 5-6', color: '#2e7d4f' },
{ id: 'higher', title: "Ray's New Higher Arithmetic", sub: 'Book 4 · Grades 7-8', color: '#a0522d' },
{ id: 'geometry', title: "Ray's Geometry and Trigonometry", sub: 'Book 5 · Grades 9-10', color: '#7a6a1f' },
{ id: 'algebra1', title: "Ray's New Elementary Algebra", sub: 'Book 6 · Grades 9-10', color: '#8f2f4f' },
{ id: 'algebra2', title: "Ray's New Higher Algebra", sub: 'Book 7 · Grade 11', color: '#3b4a8f' }
];
const BOOKS = {};
let P = {};
const STICKERS = ['🦊', '🐢', '🦉', '🐝', '🦋', '🐞', '🐸', '🐧', '🦄', '🐬', '🦁', '🐼', '🐨', '🐙', '🦀', '🐳', '🦒', '🦓', '🐘', '🦔', '🐿️', '🦜', '🐠', '🐤', '🐰', '🐻', '🐯', '🐮', '🐷', '🐵', '🌻', '🌈', '⭐', '🚂', '🚀', '⛵', '🎈', '🍎', '🍓', '🍩'];
const STEPS = {
count: { name: 'Count', icon: '●' }, numbers: { name: 'Numbers', icon: '#' }, find: { name: 'Find the number', icon: '👂' },
say: { name: 'Read the numbers', icon: '💬' }, write: { name: 'Write the numbers', icon: '✎' }, trace: { name: 'Trace the numbers', icon: '1' },
learn: { name: 'Learn the table', icon: '📖' }, rules: { name: 'Learn the table', icon: '📖' }, drill: { name: 'Practice', icon: '⚡' },
problems: { name: 'Story problems', icon: '?' }, study: { name: 'Study', icon: '📐' }, quiz: { name: 'Quiz', icon: '✔' }
};
// ---------- storage ----------
let S = load();
function load() {
let s = null; try { s = JSON.parse(localStorage.getItem('rays')); } catch (e) {}
s = s || {};
s.progress = s.progress || {}; s.pos = s.pos || {}; s.best = s.best || {}; s.stickers = s.stickers || {};
if (!s.speed) s.speed = 60;
if (!s.kid) { // the kid picked in ABC Books or BlockCraft on this site
for (const k of ['abcbooks', 'blockcraft_cfg']) { try { const c = JSON.parse(localStorage.getItem(k)); const n = c && (k === 'abcbooks' ? c.kid : c.name); if (NAME_OK(n)) { s.kid = n.trim(); break; } } catch (e) {} }
}
return s;
}
function save() { try { localStorage.setItem('rays', JSON.stringify(S)); } catch (e) {} }
const kidMap = obj => (obj[S.kid] = obj[S.kid] || {});
const prog = b => (kidMap(S.progress)[b] = kidMap(S.progress)[b] || {});
// ---------- sound + voice (recorded Eloquence clips, else the device voice) ----------
let AC;
function beep(good) {
try {
AC = AC || new (window.AudioContext || window.webkitAudioContext)();
const o = AC.createOscillator(), g = AC.createGain(), t = AC.currentTime;
o.type = 'triangle'; o.connect(g); g.connect(AC.destination);
const notes = good ? [523, 659, 784] : [220, 180];
notes.forEach((f, i) => o.frequency.setValueAtTime(f, t + i * 0.1));
g.gain.setValueAtTime(0.25, t); g.gain.exponentialRampToValueAtTime(0.001, t + notes.length * 0.1 + 0.2);
o.start(t); o.stop(t + notes.length * 0.1 + 0.25);
} catch (e) {}
}
const hasTTS = 'speechSynthesis' in window;
let voice = null;
function pickVoice() { if (!hasTTS) return; const v = speechSynthesis.getVoices().filter(v => /^en/i.test(v.lang)); voice = v.find(v => /female|samantha|zira|aria|jenny|google us/i.test(v.name)) || v[0] || null; }
if (hasTTS) { pickVoice(); speechSynthesis.onvoiceschanged = pickVoice; }
let AUDIO = null; // audio/primary1877.json: spoken text -> clip id (tools/make-audio.ps1)
const clip = new Audio(); clip.preload = 'auto';
let clipDone = null, tok = 0, unlocked = false;
const blobs = new Map();
function clipURL(url) { // fetched whole and played from memory: works offline and on Safari
if (!blobs.has(url)) blobs.set(url, fetch(url).then(r => { if (!r.ok) throw new Error(r.status); return r.blob(); }).then(b => URL.createObjectURL(b)));
const p = blobs.get(url); p.catch(() => blobs.delete(url)); return p;
}
const speedOf = () => AUDIO.speeds.includes(S.speed) ? S.speed : AUDIO.speeds[0];
const urlFor = key => { const c = AUDIO && AUDIO.items[key]; return c ? `audio/s${speedOf()}/${c}.mp3` : null; };
function stopAll() { tok++; clip.pause(); if (clipDone) { const d = clipDone; clipDone = null; d(); } if (hasTTS) speechSynthesis.cancel(); }
function playURL(u, my) {
return new Promise(res => {
clipURL(u).then(b => {
if (my !== tok) return res();
clipDone = res; clip.muted = false; clip.src = b;
clip.onended = clip.onerror = () => { if (clipDone) { const d = clipDone; clipDone = null; d(); } };
clip.play().catch(() => clip.onended());
}).catch(() => res());
});
}
// speak(...keys): one clip per key, played one after the other; a key with no clip uses the device voice
async function speak(...keys) {
stopAll(); const my = tok;
for (const k of keys) {
if (my !== tok || k == null || k === '') continue;
const u = urlFor(String(k));
if (u) await playURL(u, my); else await tts(String(k).replace(/^(n|find|ans|lesson):/, ''));
}
}
function tts(text) {
return new Promise(res => {
if (!hasTTS) return setTimeout(res, 300);
const u = new SpeechSynthesisUtterance(text); if (voice) u.voice = voice; u.rate = 0.85;
u.onend = u.onerror = res; speechSynthesis.speak(u);
});
}
const sayNum = n => speak('n:' + n);
window.addEventListener('pointerdown', () => { // iOS: unlock audio inside the first tap
if (AC && AC.state === 'suspended') AC.resume();
const u = urlFor(P.yes); if (unlocked || !u) return; unlocked = true;
clipURL(u).then(b => { if (!clip.src) { clip.muted = true; clip.src = b; clip.play().then(() => { clip.pause(); clip.muted = false; }).catch(() => { clip.muted = false; }); } }).catch(() => {});
}, { passive: true });
// ---------- helpers ----------
function toast(t, ms) { const e = $('toast'); e.textContent = t; e.style.display = 'block'; clearTimeout(toast.t); toast.t = setTimeout(() => e.style.display = 'none', ms || 1100); }
function el(tag, cls, html) { const e = document.createElement(tag); if (cls) e.className = cls; if (html != null) e.innerHTML = html; return e; }
function btn(label, fn, cls) { const b = el('button', cls, label); b.onclick = fn; return b; }
const shuffle = a => { a = a.slice(); for (let i = a.length - 1; i > 0; i--) { const j = Math.floor(Math.random() * (i + 1)); [a[i], a[j]] = [a[j], a[i]]; } return a; };
const range = (a, b) => Array.from({ length: b - a + 1 }, (_, i) => a + i);
const starStr = n => '★'.repeat(n) + '☆'.repeat(3 - n);
const starsFor = (miss, n) => miss === 0 ? 3 : miss <= Math.max(2, Math.round(n * 0.15)) ? 2 : 1;
const wait = ms => new Promise(r => setTimeout(r, ms));
function go(id) { document.querySelectorAll('.screen').forEach(s => s.classList.toggle('on', s.id === id)); if (id === 'home') home(); if (id === 'stickers') stickers(); }
const ONES = ['zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine', 'ten', 'eleven', 'twelve', 'thirteen', 'fourteen', 'fifteen', 'sixteen', 'seventeen', 'eighteen', 'nineteen'];
const TENS = ['', '', 'twenty', 'thirty', 'forty', 'fifty', 'sixty', 'seventy', 'eighty', 'ninety'];
const words = n => n < 20 ? ONES[n] : n === 100 ? 'one hundred' : TENS[Math.floor(n / 10)] + (n % 10 ? '-' + ONES[n % 10] : '');
// pictures: dots for a fact (a and b in two colors, crossed out when taken away, rows for times, groups for division)
function dotsFor(op, a, b) {
const box = el('div', 'dots');
const grp = (n, cls, boxed) => { const g = el('div', 'grp' + (boxed ? ' box' : '')); for (let i = 0; i < n; i++) g.appendChild(el('i', 'dot ' + (cls || ''))); return g; };
if (op === 'add') { box.append(grp(a), el('span', 'op', '+'), grp(b, 'b')); }
else if (op === 'sub') { const g = el('div', 'grp'); for (let i = 0; i < b; i++) g.appendChild(el('i', 'dot ' + (i >= b - a ? 'x' : ''))); box.appendChild(g); }
else if (op === 'mul') { if (a * b > 100) return box; for (let i = 0; i < a; i++) box.appendChild(grp(b, i % 2 ? 'b' : '', true)); }
else if (op === 'div') { if (b > 100) return box; for (let i = 0; i < b / a; i++) box.appendChild(grp(a, i % 2 ? 'b' : '', true)); }
return box;
}
const SIGN = { add: '+', sub: '−', mul: '×', div: '÷' };
const expr = (op, f) => op === 'sub' ? `${f.b} − ${f.a}` : op === 'div' ? `${f.b} ÷ ${f.a}` : `${f.a} ${SIGN[op]} ${f.b}`;
// a picture for a story problem, from the first thing it counts
const PICS = [['cent|dime|money', '💰'], ['dollar', '💵'], ['apple', '🍎'], ['pear', '🍐'], ['peach', '🍑'], ['orange', '🍊'], ['lemon', '🍋'], ['cherr', '🍒'], ['plum|raisin|fig', '🍇'], ['melon', '🍈'], ['pine-apple', '🍍'], ['strawberr|berr', '🍓'], ['nut|chestnut|pecan|walnut', '🌰'],
['marble', '🔵'], ['top', '🎯'], ['kite', '🎏'], ['ball', '⚽'], ['doll', '🧸'], ['bird|swallow|crow|pigeon', '🐦'], ['owl', '🦉'], ['bat', '🦇'], ['duck', '🦆'], ['geese|goose', '🦢'], ['chicken|hen', '🐔'], ['fish', '🐟'], ['horse', '🐴'], ['cow|calf|calves', '🐄'], ['sheep', '🐑'], ['pig|hog', '🐖'], ['rabbit', '🐇'], ['cat|kitten', '🐈'], ['mice|mouse', '🐭'],
['egg', '🥚'], ['cake|candy', '🍬'], ['milk', '🥛'], ['book|primer|reader|geograph', '📚'], ['pen|pencil|slate', '✏️'], ['ribbon|tape|cloth|calico|muslin|silk', '🎀'], ['tree|orchard', '🌳'], ['flower|rose', '🌹'], ['leaves|leaf', '🍃'], ['ship|boat', '⛵'], ['car', '🚃'], ['mile|travel', '🛤️'], ['hour|minute', '⏰'], ['day|week|month|year', '📅'], ['wood|cord', '🌲'], ['flour|wheat|corn|oats|seed', '🌾'],
['boy|girl|pupil|scholar|men|man|persons', '🧒'], ['window|pane', '🏠'], ['chair|bench', '💺'], ['foot|feet|inch|yard|rod', '📏'], ['pound|ounce|ton', '⚖️'], ['quart|pint|gallon|gill|peck|bushel', '🍶']];
function picFor(text) { const t = text.toLowerCase(); let best = null, at = 1e9; for (const [rx, e] of PICS) { const m = t.match(new RegExp('\\b(' + rx + ')')); if (m && m.index < at) { at = m.index; best = e; } } return best || '🧮'; }
// ---------- spoken answers ----------
// The kid can say the answer. First choice: our own Vosk server (CT 307, /api/recognize, shared with ABC Books),
// told to listen only for number words. Fallback: the browser's own recognizer. No mic at all: the button hides.
const NUM_WORDS = 'zero oh one two three four five six seven eight nine ten eleven twelve thirteen fourteen fifteen sixteen seventeen eighteen nineteen twenty thirty forty fifty sixty seventy eighty ninety hundred thousand and a';
const SR = window.SpeechRecognition || window.webkitSpeechRecognition;
const GUM = !!(window.isSecureContext && navigator.mediaDevices && navigator.mediaDevices.getUserMedia);
let micOK = GUM || !!SR, useServer = GUM;
const W1 = { zero: 0, oh: 0, one: 1, two: 2, three: 3, four: 4, for: 4, five: 5, six: 6, seven: 7, eight: 8, ate: 8, nine: 9, ten: 10, eleven: 11, twelve: 12, thirteen: 13, fourteen: 14, fifteen: 15, sixteen: 16, seventeen: 17, eighteen: 18, nineteen: 19 };
const W10 = { twenty: 20, thirty: 30, forty: 40, fifty: 50, sixty: 60, seventy: 70, eighty: 80, ninety: 90 };
// "nine thousand six hundred" -> 9600; "four two" (digits one at a time) -> 42; "7" -> 7
function wordsToNumber(words) {
// "a hundred" = one hundred; a stray "a" (Vosk often hears it for "one"/"and" in fast speech) alone is one
const w = words.join(' ').toLowerCase().replace(/-/g, ' ').split(/\s+/).filter(x => x && x !== 'and').map((x, i, all) => x === 'a' ? (all.length === 1 || /^(hundred|thousand)$/.test(all[i + 1] || '') ? 'one' : '') : x).filter(Boolean);
if (!w.length) return null;
if (w.every(x => /^\d+$/.test(x))) return parseInt(w.join(''), 10);
if (w.length > 1 && w.every(x => x in W1 && W1[x] < 10)) return parseInt(w.map(x => W1[x]).join(''), 10);
let total = 0, cur = 0, any = false;
for (const x of w) {
if (/^\d+$/.test(x)) { cur += parseInt(x, 10); any = true; }
else if (x in W1 || x in W10) { // "nineteen twenty" (said like a year) -> 1920; "twenty four" -> 24
const v = x in W1 ? W1[x] : W10[x];
cur = v >= 10 && cur % 100 ? cur * 100 + v : cur + v; any = true;
}
else if (x === 'hundred') { cur = (cur || 1) * 100; any = true; }
else if (x === 'thousand') { total += (cur || 1) * 1000; cur = 0; any = true; }
else return null; // a word that isn't a number: didn't understand
}
return any ? total + cur : null;
}
let stopListening = () => {};
async function hearNumber() {
if (useServer) {
try { const w = await listenServer(7000); return w ? wordsToNumber(w) : null; }
catch (e) { useServer = false; if (!SR) { micOK = false; return null; } }
}
const alts = await listenBrowser(7000);
for (const a of alts) { const n = wordsToNumber(a); if (n != null) return n; }
return null;
}
// records until the kid stops talking (1.2 s quiet) or the time runs out (same as ABC Books)
async function listenServer(timeoutMs) {
let stream;
try { stream = await navigator.mediaDevices.getUserMedia({ audio: { echoCancellation: true, noiseSuppression: true } }); }
catch (e) { micOK = false; return null; }
const ctx = new (window.AudioContext || window.webkitAudioContext)();
try { await ctx.resume(); } catch (e) {}
const src = ctx.createMediaStreamSource(stream), proc = ctx.createScriptProcessor(4096, 1, 1);
const chunks = []; let spoke = false, quiet = 0; const t0 = performance.now();
await new Promise(res => {
let done = false; const fin = () => { if (!done) { done = true; res(); } };
stopListening = fin;
proc.onaudioprocess = e => {
const d = e.inputBuffer.getChannelData(0); chunks.push(new Float32Array(d));
let s = 0; for (let i = 0; i < d.length; i++) s += d[i] * d[i];
if (Math.sqrt(s / d.length) > 0.015) { spoke = true; quiet = 0; } else if (spoke) quiet += d.length / ctx.sampleRate * 1000;
if ((spoke && quiet > 1200) || performance.now() - t0 > timeoutMs) fin();
};
src.connect(proc); proc.connect(ctx.destination);
});
stopListening = () => {};
proc.disconnect(); src.disconnect(); stream.getTracks().forEach(t => t.stop());
const rate = ctx.sampleRate; ctx.close();
if (!spoke) return null;
const r = await fetch('/api/recognize?near=0&words=' + encodeURIComponent(NUM_WORDS), { method: 'POST', headers: { 'Content-Type': 'application/octet-stream' }, body: to16k(chunks, rate) });
if (!r.ok) throw new Error('speech ' + r.status);
const j = await r.json();
return j.words || [];
}
function to16k(chunks, rate) { // Float32 at the device rate -> 16 kHz 16-bit PCM (what Vosk wants)
const n = chunks.reduce((a, c) => a + c.length, 0), all = new Float32Array(n); let o = 0;
for (const c of chunks) { all.set(c, o); o += c.length; }
const ratio = rate / 16000, m = Math.floor(n / ratio), out = new Int16Array(m);
for (let i = 0; i < m; i++) {
const a = Math.floor(i * ratio), b = Math.min(n, Math.max(a + 1, Math.floor((i + 1) * ratio))); let s = 0;
for (let k = a; k < b; k++) s += all[k];
out[i] = Math.max(-1, Math.min(1, s / (b - a))) * 32767;
}
return out.buffer;
}
function listenBrowser(timeoutMs) {
return new Promise(res => {
if (!SR) return res([]);
const r = new SR(); r.lang = 'en-US'; r.interimResults = false; r.maxAlternatives = 5;
let best = [], done = false;
const fin = () => { if (done) return; done = true; try { r.stop(); } catch (e) {} res(best); };
stopListening = fin;
r.onresult = e => { best = [...e.results[0]].map(a => a.transcript.split(/\s+/)); fin(); };
r.onerror = e => { if (/not-allowed|service-not-allowed/.test(e.error || '')) micOK = false; fin(); };
r.onend = fin;
try { r.start(); } catch (e) { micOK = false; return fin(); }
setTimeout(fin, timeoutMs);
});
}
// number pad (big buttons; a computer keyboard works too; 🎤 to say the answer)
function numPad(onOK) {
const wrap = el('div', 'col'); wrap.style.height = 'auto'; wrap.style.gap = '1vmin';
const entry = el('div', 'entry', ' '); let val = '';
// long whole numbers are shown with commas, the book's way (4,576,791)
const show = () => { entry.textContent = (algMode ? RaysAlg.pretty(val) : /^\d{5,}$/.test(val) ? val.replace(/\B(?=(\d{3})+$)/g, ',') : val) || ' '; entry.classList.toggle('long', val.length > 9); entry.classList.remove('no', 'ok'); };
const pad = el('div', 'pad');
let fracMode = false; // answers like 3/4 or 2 1/2: extra keys, and OK hands back the text
let algMode = false; // Algebra: + − ( ) / power and the question's letters; OK hands back the text (alg.js checks it)
const press = k => {
if (k === '⌫') val = val.slice(0, -1);
else if (k === 'OK') { if (val.trim()) onOK(fracMode || algMode ? val.trim() : parseInt(val, 10)); return; }
else if (algMode) { if (val.length < 200 && !(k === '^' && !/[\da-z)]$/.test(val))) val += k === '−' ? '-' : k; }
// "and" after a decimal makes a complex decimal (.0154 1/4); the fraction after it may then have a /
else if (k === 'and') { if (fracMode && val && !/[ /]/.test(val) && !val.endsWith('.')) val += ' '; }
else if (k === '/') { if (fracMode && val && !val.endsWith(' ') && !val.includes('/') && (!val.includes('.') || /\.\d+ \d+$/.test(val))) val += '/'; }
else if (k === '.') { if (fracMode && !/[ /.]/.test(val)) val += '.'; }
else if (val.length < 40) val += k; // the book's long numbers (up to 36 figures) are checked as written
show();
};
['1', '2', '3', '4', '5', '6', '7', '8', '9', '⌫', '0', 'OK'].forEach(k => pad.appendChild(btn(k, () => press(k), k === 'OK' ? 'okb' : '')));
const fracRow = el('div', 'pad'); fracRow.style.display = 'none';
fracRow.append(btn('/', () => press('/')), btn('and', () => press('and')), btn('.', () => press('.')));
const algRow = el('div', 'pad alg'), letRow = el('div', 'pad alg'); algRow.style.display = letRow.style.display = 'none';
['+', '−', '(', ')', '/', '^'].forEach(k => algRow.appendChild(btn(k === '^' ? 'xⁿ' : k, () => press(k))));
const onKey = e => { if (algMode && /^[a-z+\-()/^*=<>]$/.test(e.key)) press(e.key); else if (/^[0-9]$/.test(e.key)) press(e.key); else if (e.key === '/' || e.key === '.') press(e.key); else if (e.key === ' ' && fracMode) { e.preventDefault(); press('and'); } else if (e.key === 'Backspace') press('⌫'); else if (e.key === 'Enter') press('OK'); };
window.addEventListener('keydown', onKey);
const mic = btn('🎤 Say it', async () => {
if (mic.classList.contains('live')) return stopListening();
stopAll(); mic.classList.add('live'); mic.textContent = '🎤 Listening…';
const n = await hearNumber();
mic.classList.remove('live'); mic.textContent = '🎤 Say it';
if (!micOK) { mic.style.display = 'none'; return toast('This device cannot listen. Type the answer.', 2000); }
if (n == null) return toast('I did not catch that. Say it again!', 1500);
val = String(n); show(); onOK(n);
}, 'micb');
if (!micOK) mic.style.display = 'none';
wrap.append(entry, pad, fracRow, algRow, letRow, mic);
return { el: wrap, entry, frac(on) { fracMode = !!on; fracRow.style.display = on ? '' : 'none'; mic.style.display = on || !micOK ? 'none' : ''; },
alg(keys) { // keys = the question's letters ("abx"); null turns the algebra keys off
algMode = keys != null; wrap.classList.toggle('algmode', algMode); algRow.style.display = letRow.style.display = algMode ? '' : 'none'; letRow.innerHTML = '';
[...(keys || '')].forEach(c => letRow.appendChild(btn(c, () => press(c), 'let')));
letRow.style.display = algMode && keys ? '' : 'none';
if (algMode) { fracMode = false; fracRow.style.display = 'none'; mic.style.display = 'none'; }
}, show(on) { wrap.style.display = on ? '' : 'none'; }, clear() { val = ''; show(); }, set(v, cls) { val = String(v); show(); if (cls) entry.classList.add(cls); }, bad() { entry.classList.remove('no'); void entry.offsetWidth; entry.classList.add('no'); }, stop() { stopListening(); window.removeEventListener('keydown', onKey); } };
}
// fractions compare by value: 5/2 = 2 1/2 = 2.5
function fracVal(s) {
s = String(s).trim(); let m;
if ((m = s.match(/^(\d+) (\d+)\/(\d+)$/))) return +m[1] + m[2] / m[3];
if ((m = s.match(/^(\d+)\/(\d+)$/))) return m[1] / m[2];
if ((m = s.match(/^(\d*)\.(\d+) (\d+)\/(\d+)$/))) return parseFloat((m[1] || '0') + '.' + m[2]) + m[3] / m[4] / Math.pow(10, m[2].length); // complex decimal
return /^\d*\.?\d+$/.test(s) ? parseFloat(s) : NaN;
}
// relative check, so tiny decimals (.00000002) and large ones (2900.000029) both compare exactly
const sameVal = (a, b) => { const x = fracVal(a), y = fracVal(b); return Math.abs(x - y) <= 1e-13 + 1e-10 * Math.abs(y); };
// counters tray: tap beads to count with
function initTray() {
const f = $('frame'); f.innerHTML = '';
for (let i = 0; i < 30; i++) f.appendChild(btn('', e => { e.currentTarget.classList.toggle('on'); count(); }));
const count = () => { $('trayN').textContent = f.querySelectorAll('.on').length; };
$('trayClear').onclick = () => { f.querySelectorAll('.on').forEach(b => b.classList.remove('on')); count(); };
$('trayClose').onclick = () => $('tray').classList.remove('on');
}
// "Show your work": a pencil button that opens scratch paper beside the question (scratch.js). The paper comes
// back open on the next question and the next lesson if the kid left it open.
function workPad() {
const w = RaysWork.Pad($('stage'), S.kid, bookId, toast);
const b = btn('', () => { label(w.toggle()); });
const label = on => { b.textContent = on ? '✏️ Put paper away' : '✏️ Show work'; b.classList.toggle('on', on); };
label(w.start());
return { btn: b, page: w.page, result: w.result, stop: w.stop };
}
// grown-ups: every page of work one kid has in one book, newest first, grouped by lesson
// With a family account, the pages saved there from other devices are added (fetched after the first draw).
let workBack = 'map';
const gone = new Set(); // deleted in this visit: the account may not have heard yet
function showWork(from, fromAcct) {
workBack = from; const id = bookId || 'primary1877', B = BOOKS[id], kid = S.kid;
const pages = RaysWork.list(kid, id), box = $('workList'); box.innerHTML = '';
if (fromAcct) {
const at = new Map(pages.map((pg, i) => [pg.key, i]));
fromAcct.filter(pg => !gone.has(id + '|' + pg.key) && !gone.has(id + '|*')).forEach(pg => {
if (!at.has(pg.key)) pages.push(pg); else if ((pg.t || 0) > (pages[at.get(pg.key)].t || 0)) pages[at.get(pg.key)] = pg;
});
} else RaysWork.remote(kid, id).then(r => { if (r.length && $('work').classList.contains('on') && S.kid === kid && (bookId || 'primary1877') === id) showWork(from, r); });
// lessons with the newest work first; inside a lesson, the pages in question order
const newest = {}; pages.forEach(pg => { newest[pg.l] = Math.max(newest[pg.l] || 0, pg.t || 0); });
pages.sort((a, b) => newest[b.l] - newest[a.l] || a.key.localeCompare(b.key, undefined, { numeric: true }));
$('workTitle').textContent = `${S.kid}: work in ${B ? B.title : ''} (${pages.length} page${pages.length === 1 ? '' : 's'})`;
$('workDel').style.display = pages.length ? '' : 'none';
$('workDel').onclick = () => { if (confirm(`Delete all of ${S.kid}'s work in this book?`)) { RaysWork.remove(S.kid, id); gone.add(id + '|*'); showWork(from); } };
if (!pages.length) box.appendChild(el('p', 'note', 'No work saved yet. In Story problems and Practice, the ✏️ Show work button opens scratch paper; each page is kept here with its question.'));
const tw = Math.min(300, Math.floor((window.innerWidth - 60) / 2));
let shown = 0, lastL = null;
function more() {
pages.slice(shown, shown + 40).forEach(pg => {
if (pg.l !== lastL) { lastL = pg.l; const Ls = B && B.lessons.find(x => x.n === pg.l); box.appendChild(el('h3', 'wles', '')).textContent = `Lesson ${pg.l}${Ls ? ': ' + Ls.title : ''}`; }
const card = el('button', 'wpage'); card.appendChild(RaysWork.picture(pg, tw));
const cap = el('div', 'wcap'); cap.textContent = pg.q;
const res = el('div', 'wres' + (pg.r === 'miss' ? ' miss' : pg.r === 'ok' ? ' ok' : ''));
res.textContent = (pg.a != null ? `Answer: ${pg.a} ` + (pg.r === 'ok' ? '✓' : pg.r === 'miss' ? '(missed a try)' : '') : 'Not answered') + ' · ' + new Date(pg.t).toLocaleString([], { month: 'short', day: 'numeric', hour: 'numeric', minute: '2-digit' });
card.append(cap, res); card.onclick = () => bigPage(pg, id, from); box.appendChild(card);
});
shown += 40; const m = box.querySelector('.wmore'); if (m) m.remove();
if (shown < pages.length) box.appendChild(btn('Show more', more, 'wmore'));
}
more(); go('work');
}
function bigPage(pg, id, from) {
const v = $('workBig'); v.innerHTML = ''; v.classList.add('on');
const q = el('div', 'wcap'); q.textContent = `Lesson ${pg.l}: ${pg.q}`;
const w = Math.min(window.innerWidth - 40, 1000), h = window.innerHeight - 190;
v.append(q, RaysWork.picture(pg, Math.round(Math.min(w, h / (pg.h || 0.75)))),
el('div', 'row'));
v.lastChild.append(btn('Close', () => v.classList.remove('on'), 'big'),
btn('Delete this page', () => { if (confirm('Delete this page?')) { RaysWork.remove(S.kid, id, pg.key); gone.add(id + '|' + pg.key); v.classList.remove('on'); showWork(from); } }, 'ghost parent'));
}
$('mapWork').onclick = () => showWork('map');
$('stkWork').onclick = () => { if (S.kid) showWork('stickers'); };
$('workBack').onclick =() => { $('workBig').classList.remove('on'); go(workBack); };
// ---------- home, map, stickers ----------
let addingReader = false;
function home() {
const k = $('kids'); k.innerHTML = '';
// names go in as text (never innerHTML); a name with no recorded greeting gets the line without a name
const rs = readers();
const signed = window.ABCAccount && window.ABCAccount.signedIn;
if (!rs.length && S.kid) { S.kid = null; save(); }
$('whoHint').textContent = rs.length ? '' : 'Grown-ups: add each learner (a first name or nickname).';
rs.forEach(n => { const b = btn('', () => { S.kid = n; save(); track('/math/picked'); home(); const g = P.greet.replace('{kid}', n); speak(urlFor(g) ? g : P.hello); }, S.kid === n ? 'sel' : ''); b.textContent = n; k.appendChild(b); });
if (signed) { // a family account: names are added and removed on the account page
if (!rs.length) $('whoHint').innerHTML = 'Grown-ups: add your learners on the <a href="/account/">account page</a>.';
else { const a = el('a', 'parent'); a.href = '/account/'; a.textContent = 'Add or remove learners'; k.appendChild(a); }
} else if (addingReader || !rs.length) {
// the names live in 'abcbooks'.readers, shared with ABC Books, so a learner added here is in both
const inp = el('input'); inp.maxLength = 16; inp.placeholder = 'Name'; inp.autocomplete = 'off';
const add = () => {
const n = inp.value.trim().replace(/\s+/g, ' ');
if (!NAME_OK(n)) return toast('Letters only, please');
if (rs.some(x => x.toLowerCase() === n.toLowerCase())) return toast(`${n} is already here`);
let c = null; try { c = JSON.parse(localStorage.getItem('abcbooks')); } catch (e) {}
c = c || { kid: null, progress: {}, boards: {} };
c.readers = rs.concat(n); if (!c.kid) c.kid = n;
try { localStorage.setItem('abcbooks', JSON.stringify(c)); } catch (e) {}
S.kid = n; addingReader = false; save(); track('/math/added'); home();
};
inp.onkeydown = e => { if (e.key === 'Enter') add(); };
k.append(inp, btn('Add', add, 'big'));
if (rs.length) k.appendChild(btn('Cancel', () => { addingReader = false; home(); }, 'ghost parent'));
setTimeout(() => inp.focus(), 50);
} else if (rs.length < 8) k.appendChild(btn('+', () => { addingReader = true; home(); }, 'add'));
const sb = $('speedBtn'); sb.textContent = 'Voice: ' + (S.speed === 75 ? 'faster' : 'normal');
sb.onclick = () => { S.speed = S.speed === 75 ? 60 : 75; save(); home(); speak(P.yes); };
const sh = $('shelf'); sh.innerHTML = '';
// the kid's current book glows: the first open book they haven't finished
const doneIn = id => S.kid && BOOKS[id] ? Object.values(prog(id)).filter(x => x && x.stars).length : 0;
const cur = S.kid && SHELF.find(b => BOOKS[b.id] && doneIn(b.id) < BOOKS[b.id].lessons.length);
SHELF.forEach(b => {
const B = BOOKS[b.id], n = B ? B.lessons.length : 0, d = doneIn(b.id);
const pr = !B ? 'Coming soon' : S.kid ? (d >= n ? '★ Finished!' : d ? `Lesson ${d + 1} of ${n}` : `Lessons: ${n}`) : '';
const e = btn(`<b>${b.title}</b><span class="bp">${pr}</span><small>${b.sub}</small>`, () => {
if (!B) return toast('Coming soon!');
if (!S.kid) return toast('Pick your name first!');
openBook(b.id);
}, 'book' + (!B ? ' soon' : '') + (cur && cur.id === b.id ? ' cur' : ''));
e.style.background = b.color; sh.appendChild(e);
});
}
let book, bookId;
let skipArm = null; // a locked tile tapped once: a 2nd tap within 4 s skips ahead to it
function openBook(id) {
bookId = id; book = BOOKS[id]; $('mapTitle').textContent = `${S.kid}: ${book.title}`;
track('/math/book', { book: id });
const t = $('tiles'); t.innerHTML = ''; const p = prog(id);
// Lessons are open up to one past the furthest one finished, so after a skip the kid carries on from there.
let far = -1; book.lessons.forEach((L, i) => { if ((p[L.n] || {}).stars) far = i; });
const paidAt = i => window.ABCAccount && window.ABCAccount.locked('math', i);
book.lessons.forEach((L, i) => {
const st = (p[L.n] || {}).stars || 0, open = i <= far + 1, isNext = i === far + 1;
// past the free lessons without a subscription (/account/sync.js; only when the paywall is switched on)
const paid = paidAt(i);
const tile = btn(`${L.n}<small>${L.part}</small><span class="st">${st ? starStr(st) : paid ? '🔒' : ''}</span>`, () => {
if (paid) return window.ABCAccount.unlockScreen('math');
if (!open && !st && !(skipArm && skipArm.i === i && Date.now() - skipArm.at < 4000)) {
skipArm = { i, at: Date.now() };
return toast(`Lesson ${L.n} is ahead. Tap it again to skip to it.`, 3500);
}
skipArm = null; startLesson(L);
}, 'tile' + (isNext ? ' next' : '') + (!open && !st ? ' locked' : '') + (L.review ? ' rev' : ''));
tile.title = `Lesson ${L.n}: ${L.title}` + (st ? ', done' : !open ? ', ahead' : '');
tile.setAttribute('aria-label', tile.title); t.appendChild(tile);
});
// "Go to lesson": every lesson by title, grouped by part, starting on the next one; Go starts it.
const sel = $('jumpSel'); sel.innerHTML = ''; let grp = null;
book.lessons.forEach((L, i) => {
if (!grp || grp.label !== L.part) { grp = document.createElement('optgroup'); grp.label = L.part || ''; sel.appendChild(grp); }
const o = el('option'); o.textContent = `Lesson ${L.n}: ${L.title}` + ((p[L.n] || {}).stars ? ' ★' : '');
o.value = i; if (i === Math.min(far + 1, book.lessons.length - 1)) o.selected = true; grp.appendChild(o);
});
$('jumpGo').onclick = () => { const i = +sel.value; paidAt(i) ? window.ABCAccount.unlockScreen('math') : startLesson(book.lessons[i]); };
go('map'); speak(P.map);
const nx = t.querySelector('.next'); if (nx) nx.scrollIntoView({ block: 'center' });
}
const stkKey = (b, n) => b === 'primary1877' ? n : `${b}:${n}`; // Book One keeps its first keys
function stickers() { // the sticker book for the book the kid is in (Book One when none is open yet)
const g = $('stkList'); g.innerHTML = ''; const got = kidMap(S.stickers), id = bookId || 'primary1877', B = BOOKS[id];
const n = B ? B.lessons.filter(L => got[stkKey(id, L.n)]).length : 0;
$('stkTitle').textContent = `${S.kid || ''} sticker book: ${B ? B.title : ''}, ${n} of ${B ? B.lessons.length : 0}`;
(B ? B.lessons : []).forEach(L => { const v = got[stkKey(id, L.n)]; const s = el('span', v ? 'got' : '', v || ''); s.title = 'Lesson ' + L.n; g.appendChild(s); });
}
$('toStickers').onclick = () => { if (!S.kid) return toast('Pick your name first!'); go('stickers'); };
// ---------- lesson flow ----------
let L, steps, stepIdx, scores, cleanup = null, sayAgain = null, stepTok = 0;
function stepsFor(L) {
switch (L.kind) {
case 'count': return ['count', 'find', 'trace'];
case 'numbers': return ['numbers', 'find', 'trace'];
case 'read': return ['say', 'find'];
case 'write': return ['write', 'trace'];
}
const s = [];
if (L.arts) s.push('study'); if (L.quiz) s.push('quiz');
if (L.table) s.push('learn', 'drill');
if (L.rules) s.push('rules'); if (L.rules && L.rules.some(r => r.quiz !== false) && !L.table) s.push('drill');
if (L.qs) s.push('problems');
return s;
}
function startLesson(lesson) {
L = lesson; steps = stepsFor(L); scores = {}; stepIdx = 0;
track('/math/lesson', { book: bookId, lesson: L.n });
$('lesTitle').textContent = `Lesson ${L.n}: ${L.title}`;
go('lesson'); runStep(true);
}
function leave() { stopStep(); openBook(bookId); }
function stopStep() { stopAll(); $('tray').classList.remove('on'); if (cleanup) { cleanup(); cleanup = null; } }
function runStep(first) {
stopStep();
const id = steps[stepIdx];
const dots = $('steps'); dots.innerHTML = '';
steps.forEach((x, i) => dots.appendChild(el('i', i < stepIdx ? 'done' : i === stepIdx ? 'cur' : '', STEPS[x].icon)));
if (!id) return finish();
track('/math/step/' + id, { book: bookId, lesson: L.n });
$('stepTitle').textContent = STEPS[id].name; $('stage').innerHTML = ''; $('controls').innerHTML = ''; $('hint').textContent = P[id] || '';
sayAgain = null; const my = ++stepTok;
const intro = (first ? speak('lesson:' + L.n, P[id]) : speak(P[id]));
$('sayBtn').onclick = () => sayAgain ? sayAgain() : speak(P[id]);
({ count: stepCount, numbers: stepNumbers, find: stepFind, say: stepSay, write: stepWrite, trace: stepTrace, learn: stepLearn, rules: stepRules, drill: stepDrill, problems: stepProblems, study: stepStudy, quiz: stepQuiz })[id](intro.then(() => my === stepTok));
}
function next(stars) { scores[steps[stepIdx]] = stars; stepIdx++; runStep(); }
const afterIntro = (intro, fn) => intro.then(ok => { if (ok) fn(); });
// Lesson 1: count the balls, one tap per ball
function stepCount(intro) {
let n = L.from;
const st = $('stage'); const col = el('div', 'col'); st.appendChild(col);
function show() {
col.innerHTML = ''; let c = 0;
const balls = el('div', 'balls'); const big = el('div', 'big-n', ' '); const w = el('div', 'word', ' ');
for (let i = 0; i < n; i++) balls.appendChild(btn('', e => {
const b = e.currentTarget; if (b.classList.contains('on')) return;
b.classList.add('on'); b.textContent = ++c; sayNum(c);
if (c === n) { big.textContent = n; w.textContent = words(n); setTimeout(() => { beep(true); speak('n:' + n).then(() => wait(700)).then(() => { if (++n > L.to) next(3); else show(); }); }, 650); }
}, 'ball'));
col.append(balls, big, w);
$('hint').textContent = `Tap each ball and count. (${n - L.from + 1} of ${L.to - L.from + 1})`;
}
sayAgain = () => speak(P.count);
show();
}
// Lessons 2-4: each number with its tens and ones
function stepNumbers(intro) {
let n = L.from; const st = $('stage'); const col = el('div', 'col'); st.appendChild(col);
let auto = false;
function show() {
col.innerHTML = '';
col.append(el('div', 'big-n', n), el('div', 'word', words(n)));
const rods = el('div', 'rods');
for (let t = 0; t < Math.floor(n / 10); t++) { const r = el('div', 'rod'); for (let i = 0; i < 10; i++) r.appendChild(el('i')); rods.appendChild(r); }
const ones = el('div', 'grp'); for (let i = 0; i < n % 10; i++) ones.appendChild(el('i', 'dot')); rods.appendChild(ones);
col.appendChild(rods);
col.appendChild(el('div', 'note', `${Math.floor(n / 10)} tens and ${n % 10} ones`));
$('hint').textContent = `${n - L.from + 1} of ${L.to - L.from + 1}`;
return sayNum(n);
}
async function playAll() { auto = true; playB.disabled = true; while (auto && n <= L.to) { await show(); await wait(700); if (!auto) break; if (n < L.to) n++; else break; } auto = false; playB.disabled = false; nextB.disabled = false; }
const prevB = btn('◀', () => { auto = false; if (n > L.from) { n--; show(); } });
const fwdB = btn('▶', () => { auto = false; if (n < L.to) { n++; show(); } else nextB.disabled = false; });
const playB = btn('▶ Play all', playAll, 'big'), nextB = btn('Next step ▶', () => next(3));
nextB.disabled = true; $('controls').append(prevB, playB, fwdB, nextB);
sayAgain = show; cleanup = () => { auto = false; };
col.append(el('div', 'big-n', n), el('div', 'word', words(n)));
afterIntro(intro, playAll);
}
// hear a number, tap it
function stepFind(intro) {
const pool = L.list || range(L.from, L.to);
const rounds = shuffle(pool).slice(0, 8); let r = 0, miss = 0, busy = false, target;
const st = $('stage'); const col = el('div', 'col'); st.appendChild(col);
const grid = el('div', 'choices'); col.appendChild(grid);
function round() {
if (r >= rounds.length) { toast('Great job! ⭐'); return setTimeout(() => next(starsFor(miss, rounds.length)), 900); }
target = rounds[r++]; grid.innerHTML = '';
const opts = shuffle([target, ...shuffle(pool.filter(x => x !== target)).slice(0, 3)]);
opts.forEach(v => grid.appendChild(btn(v, e => {
if (busy) return; const b = e.currentTarget;
if (v === target) { busy = true; beep(true); b.classList.add('ok'); setTimeout(() => { busy = false; round(); }, 800); }
else { miss++; beep(false); b.classList.remove('no'); void b.offsetWidth; b.classList.add('no'); }
})));
$('hint').textContent = `Find the number you hear (${r} of ${rounds.length})`;
sayAgain = () => speak('find:' + target); sayAgain();
}
afterIntro(intro, round);
}
// Lesson 5: numbers to be read, out loud to a grown-up
function stepSay(intro) {
const g = el('div', 'grid'); $('stage').appendChild(g);
L.list.forEach(v => g.appendChild(btn(v, e => { e.currentTarget.classList.add('seen'); sayNum(v); })));
$('controls').appendChild(btn('Done ✓', () => next(3), 'big'));
}
// Lesson 6: numbers to be written: hear it, type it
function stepWrite(intro) {
const items = shuffle(L.list).slice(0, 12); let i = 0, miss = 0, tries = 0;
const col = el('div', 'col'); $('stage').appendChild(col);
const pad = numPad(v => {
if (v === items[i]) { beep(true); pad.set(v, 'ok'); tries = 0; setTimeout(() => { i++; ask(); }, 700); }
else if (++tries < 2) { miss++; beep(false); pad.bad(); speak(P.tryAgain, 'n:' + items[i]); }
else { miss++; pad.set(items[i], 'ok'); speak('ans:' + items[i]); tries = 0; setTimeout(() => { i++; ask(); }, 1800); }
});
col.appendChild(pad.el);
function ask() {
if (i >= items.length) return next(starsFor(miss, items.length));
pad.clear(); $('hint').textContent = `Write the number you hear (${i + 1} of ${items.length})`;
sayAgain = () => sayNum(items[i]); sayAgain();
}
cleanup = () => pad.stop();
afterIntro(intro, ask);
}
// trace the figures (same engine as ABC Books)
function stepTrace(intro) {
const nums = L.kind === 'count' ? ['1 2 3', '4 5 6', '7 8 9', '10'] : L.kind === 'write' ? ['0 1 2 3 4', '5 6 7 8 9', '10 20 30'] : (() => { const r = range(L.from, L.to), out = []; for (let i = 0; i < r.length && out.length < 4; i += 4) out.push(r.slice(i, i + 4).join(' ')); return out; })();
let i = 0, misses = 0, tracer;
const box = el('div', 'grow paper'); box.style.height = '100%'; $('stage').appendChild(box);
const cv = el('canvas'); box.appendChild(cv);
ABCTrace.Tracer.onMiss = why => { misses++; beep(false); $('hint').textContent = why === 'start' ? 'Start at the green dot!' : 'Follow the arrow all the way.'; };
function page() {
if (tracer) tracer.stop();
$('hint').textContent = `Page ${i + 1} of ${nums.length}: start at the green dot and follow the arrow.`;
tracer = ABCTrace.Tracer(cv, nums[i], 'print', () => { beep(true); toast('⭐', 700); setTimeout(() => { if (++i < nums.length) page(); else next(misses < 3 ? 3 : misses < 8 ? 2 : 1); }, 800); });
}
$('controls').appendChild(btn('Skip page', () => { if (++i < nums.length) page(); else next(1); }, 'ghost parent'));
setTimeout(page, 50);
const onRes = () => page(); window.addEventListener('resize', onRes);
cleanup = () => { tracer && tracer.stop(); window.removeEventListener('resize', onRes); };
}
// the book's table, one line at a time with its picture
function stepLearn(intro) { learnList(L.table.map(f => ({ t: f.t, pic: () => dotsFor(L.op, f.a, f.b), ex: `${expr(L.op, f)} = ${f.r}` })), intro); }
function stepRules(intro) { learnList(L.rules.map(r => ({ t: r.t, pic: () => el('div', 'pic', picFor(r.t)) })), intro); }
function learnList(items, intro) {
const col = el('div', 'col'); $('stage').appendChild(col);
const face = el('div', 'col'); face.style.height = 'auto'; const chips = el('div', 'chips'); col.append(face, chips);
let i = 0, auto = false; const seen = new Set();
const chipEls = items.map((it, k) => { const c = btn(it.t, () => { auto = false; i = k; show(); }, 'chip'); chips.appendChild(c); return c; });
function show() {
face.innerHTML = ''; const it = items[i];
const f = el('div', 'fact', it.t); if (it.ex) f.appendChild(el('span', 'sm', it.ex));
face.append(f, it.pic());
chipEls.forEach((c, k) => c.classList.toggle('cur', k === i)); chipEls[i].classList.add('seen'); seen.add(i);
chipEls[i].scrollIntoView({ block: 'nearest' });
if (seen.size === items.length) nextB.disabled = false;
return speak(it.t);
}
async function playAll() { auto = true; playB.disabled = true; for (i = 0; i < items.length && auto; i++) { await show(); await wait(600); } i = Math.min(i, items.length - 1); auto = false; playB.disabled = false; nextB.disabled = false; }
const playB = btn('▶ Read to me', playAll, 'big'), nextB = btn('Next ▶', () => next(3));
nextB.disabled = true; $('controls').append(playB, nextB);
sayAgain = show; cleanup = () => { auto = false; };
face.appendChild(el('div', 'fact', items[0].t));
$('hint').textContent = 'Tap ▶ Read to me, or tap each line.';
afterIntro(intro, playAll);
}
// practice: every fact in the table (or every rule), timed; a missed one comes back later
function stepDrill(intro) {
const items = L.table ? L.table.map(f => ({ q: f.q, ex: expr(L.op, f) + ' = ?', a: f.r, say: f.t, pic: () => dotsFor(L.op, f.a, f.b) }))
: L.rules.filter(r => r.quiz !== false).map(r => ({ q: r.q, ex: `? ${r.a} = 1 ${r.b}`, a: r.n, say: r.t, pic: () => el('div', 'pic', picFor(r.t)) }));
let queue = shuffle(items), done = 0, miss = 0, tries = 0, streak = 0, t0 = 0, cur;
const key = `${bookId}:${L.n}`, best = kidMap(S.best);
const col = el('div', 'qa'); $('stage').appendChild(col);
const top = el('div', 'row'); const timer = el('div', 'timer'); const fire = el('div', 'timer'); top.append(timer, fire);
const ex = el('div', 'expr'); const qd = el('div', 'note'); const picBox = el('div', 'picbox'); picBox.style.minHeight = '0';
const pad = numPad(check);
col.append(top, ex, qd, picBox, pad.el);
const showB = btn('👀 Show me', () => { picBox.innerHTML = ''; picBox.appendChild(cur.pic()); }, 'ghost');
const work = workPad();
$('controls').append(showB, work.btn);
const tick = setInterval(() => { if (t0) timer.textContent = `⏱ ${Math.round((Date.now() - t0) / 1000)}s` + (best[key] ? ` (best ${best[key]}s)` : ''); }, 500);
function ask() {
if (!queue.length) {
const secs = Math.round((Date.now() - t0) / 1000);
let msg = `${secs} seconds!`;
if (!best[key] || secs < best[key]) { if (best[key]) msg += ' New best time! 🏆'; best[key] = secs; save(); }
toast(msg, 1800); return setTimeout(() => next(starsFor(miss, items.length)), 1800);
}
cur = queue[0]; tries = 0; pad.clear(); picBox.innerHTML = '';
ex.textContent = cur.ex; ex.className = 'expr' + (cur.ex.length > 12 ? ' long' : ''); qd.textContent = cur.q;
work.page(`${L.n}:d:${cur.ex}`, { q: `${cur.ex} ${cur.q}`, l: L.n });
$('hint').textContent = `${done + 1} of ${items.length}`;
sayAgain = () => speak(cur.q); sayAgain();
if (!t0) t0 = Date.now();
}
function check(v) {
work.result(v, v === cur.a);
if (v === cur.a) {
beep(true); pad.set(v, 'ok'); streak++; fire.textContent = streak >= 3 ? `🔥 ${streak}` : '';
queue.shift(); done++; setTimeout(ask, 600);
} else if (++tries < 2) { beep(false); pad.bad(); miss++; streak = 0; fire.textContent = ''; speak(P.tryAgain); }
else { // show it, say the book's line, and ask it again later
pad.set(cur.a, 'ok'); picBox.innerHTML = ''; picBox.appendChild(cur.pic());
const it = queue.shift(); queue.splice(Math.min(3, queue.length), 0, it);
speak(cur.say).then(() => wait(600)).then(ask);
}
}
cleanup = () => { clearInterval(tick); pad.stop(); work.stop(); };
afterIntro(intro, ask);
}
// story problems: the book's questions, one answer at a time; two misses shows the answer and the book's solution
function stepProblems(intro) {
const qs = L.qs, posKey = `${bookId}:${L.n}`, pos = kidMap(S.pos);
let qi = pos[posKey] || 0, pi = 0, tries = 0, miss = 0, si = 0, busy = false;
if (qi >= qs.length) qi = 0;
const col = el('div', 'qa'); $('stage').appendChild(col);
const pic = el('div', 'pic'); const qd = el('div', 'q'); const seq = el('div', 'seq'); const sol = el('div', 'sol');
const pad = numPad(check);
col.append(pic, qd, seq, sol, pad.el);
initTray();
const work = workPad();
if (!/^algebra/.test(bookId)) $('controls').append(btn('🧮 Counters', () => $('tray').classList.toggle('on'))); // no counting beads in Algebra
$('controls').append(work.btn, btn('Finish later', () => { pos[posKey] = qi; save(); leave(); }, 'ghost parent'));
if (L.note) $('hint').textContent = L.note;
const Q = () => qs[qi], Pt = () => Q().parts[pi];
function render() {
const q = Q(); qd.innerHTML = ''; qd.classList.toggle('has-stack', q.parts.some(p => p.col));
q.parts.forEach((p, k) => {
qd.appendChild(el('span', 'pt' + (k === pi ? ' cur' : k < pi ? '' : ''), p.t + ' '));
if (p.col) { // a sum written in a column, the book's way: numbers right-aligned, the sign on the last line, a rule under
const st = el('div', 'stack'), sign = { '+': '+', '-': '−', x: '×' }[p.col.op];
p.col.n.forEach((v, j) => st.appendChild(el('div', '', (j === p.col.n.length - 1 ? `<b>${sign}</b>` : '') + v)));
if (k < pi) st.appendChild(el('div', 'sum', String(p.f || p.a))); qd.appendChild(st);
}
if (k < pi) qd.appendChild(el('span', 'got' + (p.missed ? ' miss' : ''), p.seq || p.open ? '✓' : p.e != null ? RaysAlg.pretty(p.e) : (p.f || p.a)));
if (k < q.parts.length - 1) qd.append(' ');
});
pic.textContent = picFor(q.parts[0].t);
seq.innerHTML = '';
const p = Pt(); if (p && p.seq) p.seq.forEach((v, k) => seq.appendChild(el('span', k < si ? 'got' : k === si ? 'cur' : '', k < si ? (p.la ? RaysAlg.pretty(v) : v) : '?')));
const cur = seq.querySelector('.cur'); if (cur) cur.scrollIntoView({ block: 'nearest' });
}
function ask(sayIt) {
if (qi >= qs.length) { pos[posKey] = 0; save(); return next(starsFor(miss, qs.reduce((n, q) => n + q.parts.length, 0))); }
tries = 0; pad.clear(); sol.textContent = ''; if (pi === 0) Q().shown = false;
const p = Pt(); if (p.seq && si === 0 && !p.lst) si = 1; // the first number of a count is given (not of a {list: })
pad.frac(p.f || (p.lst && !p.la && p.seq.some(x => /\//.test(x)))); pad.alg(p.e != null || p.la ? p.v || '' : null); pad.show(!p.open); openB.style.display = p.open ? '' : 'none';
render();
work.page(`${L.n}:${qi}`, { q: Q().parts.map(x => x.t).join(' '), l: L.n }); // one page for all the parts of a question
$('hint').textContent = `Question ${qi + 1} of ${qs.length}`;
sayAgain = () => speak(p.s || p.t, p.open ? 'Answer out loud, then tap Next.' : null);
if (sayIt !== false) sayAgain();
}
function advance() {
busy = false; const q = Q();
if (++pi < q.parts.length) { si = 0; return ask(); }
if (q.sol && !q.shown) { q.shown = true; sol.textContent = q.sol; }
qi++; pi = 0; si = 0; pos[posKey] = qi; save();
setTimeout(() => ask(), q.sol && sol.textContent ? 600 : 0);
}
function check(v) {
if (busy) return; const p = Pt();
const norm = s => String(s).trim().replace(/\s+/g, ' ');
const isRight = (p, v) => { const want = p.seq ? p.seq[si] : p.e != null ? p.e : p.f || p.a;
return p.e != null ? RaysAlg.ok(v, p.e) || (p.ealt || []).some(x => RaysAlg.ok(v, x)) : p.ex ? p.ex.includes(norm(v)) : p.f ? sameVal(v, p.f) || (p.falt || []).some(x => sameVal(v, x)) : p.lst ? (p.la ? RaysAlg.ok(v, want) : sameVal(String(v), String(want))) : v === want || (!p.seq && p.alt && p.alt.includes(v)); };
let right = isRight(p, v);
const swap = (a, b) => { for (const k of ['e', 'es', 'ealt', 'a', 'alt', 'f', 'falt', 'v']) { const t = a[k]; if (b[k] === undefined) delete a[k]; else a[k] = b[k]; if (t === undefined) delete b[k]; else b[k] = t; } };
// "x = {A} or {B} or {C}" (the roots of an equation): any root typed first counts; that box then wants this one's
for (let j = pi + 1, ps = Q().parts; !right && ps[j - 1] && ps[j - 1].pr && ps[j]; j++) {
const nx = ps[j]; if (!isRight(nx, v)) continue;
swap(p, nx); right = true;
}
// "x = {A}, y = {B}; or x = {C}, y = {D}" (solution sets): the first answer of a set may start any later set;
// the two whole sets then change places, so y wants that set's y
if (!right && p.sk === 0) for (let j = pi + 1, ps = Q().parts; j < ps.length; j++) {
if (ps[j].sk !== 0 || !isRight(ps[j], v)) continue;
for (let k = 0; ps[pi + k] && ps[pi + k].sn === p.sn; k++) swap(ps[pi + k], ps[j + k]);
right = true; break;
}
const want = p.seq ? p.seq[si] : p.e != null ? p.e : p.f || p.a;
if (!p.seq || !right) work.result(v, right);
if (right) {
beep(true); pad.set(v, 'ok'); tries = 0;
if (p.seq) { if (++si >= p.seq.length) { busy = true; render(); return setTimeout(() => { si = 0; advance(); }, 700); } setTimeout(() => { pad.clear(); render(); }, 350); return; }
busy = true; speak(P.yes); setTimeout(advance, 900); return;
}
miss++;
if (++tries < 2) { beep(false); pad.bad(); speak(P.tryAgain); return; }
// second miss: show the answer, say it, and the book's solution when there is one
busy = true; pad.set(want, 'ok'); tries = 0;
const q = Q(), last = !p.seq && pi === q.parts.length - 1;
if (last && q.sol) { sol.textContent = q.sol; q.shown = true; }
if (p.seq) { si++; if (si >= p.seq.length) { si = 0; p.missed = true; return speak('ans:' + want).then(() => advance()); } return speak('n:' + want).then(() => { busy = false; pad.clear(); render(); }); }
p.missed = true;
speak('ans:' + want, last && q.sol ? q.sol : null).then(() => wait(800)).then(advance);
}
// a question answered out loud to a grown-up: no typing, just Next. When the book gives the answer (sol:), the first
// Next shows and says it (e.g. "57 is written LVII."), the second moves on.
const openB = btn('Next ▶', () => {
if (busy) return; const q = Q();
if (pi === q.parts.length - 1 && q.sol && !q.shown) { q.shown = true; sol.textContent = q.sol; speak(q.sol); return; }
busy = true; beep(true); setTimeout(advance, 300);
}, 'big'); openB.style.display = 'none';
col.appendChild(openB);
cleanup = () => { pad.stop(); work.stop(); };
afterIntro(intro, () => ask());
}
// Book Five: the book's articles, each beside its figure cut from the scan (same key as make-audio.ps1 ArtKey)
const artKey = a => `${a.n}. ${a.h ? a.h + '. ' : ''}${a.t}`;
function stepStudy(intro) {
const arts = L.arts; let i = 0, run = 0; const seen = new Set();
const stop = () => { run++; playB.disabled = false; }; // a tap cancels reading-to-me
const col = el('div', 'col study'); $('stage').appendChild(col);
const face = el('div', 'art'); const chips = el('div', 'chips'); col.append(face, chips);
const chipEls = arts.map((a, k) => { const c = btn('§' + a.n, () => { stop(); i = k; show(); }, 'chip'); chips.appendChild(c); return c; });
function draw() {
const a = arts[i]; face.innerHTML = '';
if (a.figs) { const fb = el('div', 'figs'); a.figs.forEach(f => { const im = el('img', 'fig'); im.src = f; im.alt = 'Figure for article ' + a.n; fb.appendChild(im); }); face.appendChild(fb); }
face.appendChild(el('p', '', `<b>${a.n}.</b> ${a.h ? `<b>${a.h}.</b> ` : ''}${a.t}`));
chipEls.forEach((c, k) => c.classList.toggle('cur', k === i));
}
function show() {
const a = arts[i]; draw(); chipEls[i].classList.add('seen'); seen.add(i);
chipEls[i].scrollIntoView({ block: 'nearest' }); face.scrollTop = 0;
$('hint').textContent = `Part ${i + 1} of ${arts.length}`;
if (seen.size === arts.length) nextB.disabled = false;
return speak(artKey(a));
}
async function playAll() { // from the part on screen to the end
const my = ++run; playB.disabled = true;
for (; i < arts.length; i++) { await show(); if (my !== run) return; await wait(700); if (my !== run) return; }
i = arts.length - 1; playB.disabled = false; nextB.disabled = false;
}
const prevB = btn('◀', () => { stop(); if (i > 0) { i--; show(); } });
const fwdB = btn('▶', () => { stop(); if (i < arts.length - 1) { i++; show(); } else nextB.disabled = false; });
const playB = btn('▶ Read to me', playAll, 'big'), nextB = btn('Next step ▶', () => next(3));
nextB.disabled = true; $('controls').append(prevB, playB, fwdB, nextB);
sayAgain = show; cleanup = () => { run++; };
draw(); afterIntro(intro, () => { if (!seen.size) playAll(); });
}
// pick the answer (or True / False); a miss comes back at the end, two misses show the answer
function stepQuiz(intro) {
let queue = shuffle(L.quiz.map(x => ({ ...x }))), done = 0, miss = 0, tries = 0, busy = false, cur;
const total = queue.length;
const col = el('div', 'qa'); $('stage').appendChild(col);
const qd = el('div', 'q'); const grid = el('div', 'mc'); col.append(qd, grid);
function ask() {
if (!queue.length) { toast('Great job! ⭐'); return setTimeout(() => next(starsFor(miss, total)), 900); }
cur = queue[0]; tries = 0; busy = false; grid.innerHTML = '';
qd.textContent = (cur.tf ? 'True or false? ' : '') + cur.q;
const order = cur.tf ? [0, 1] : shuffle(cur.c.map((_, k) => k));
order.forEach(k => grid.appendChild(btn(cur.c[k], e => pick(k, e.currentTarget))));
$('hint').textContent = `${done + 1} of ${total}`;
sayAgain = () => speak(cur.q); sayAgain();
}
function pick(k, b) {
if (busy) return;
if (k === cur.a) { busy = true; beep(true); b.classList.add('ok'); queue.shift(); done++; speak(P.yes); return setTimeout(ask, 900); }
miss++; beep(false); b.classList.remove('no'); void b.offsetWidth; b.classList.add('no'); b.disabled = true;
if (++tries < 2 && !cur.tf) return speak(P.tryAgain);
busy = true; [...grid.children].forEach(x => { if (x.textContent === cur.c[cur.a]) x.classList.add('ok'); });
const it = queue.shift(); it.again = true; queue.push(it); // asked again at the end
speak('ansc:' + cur.c[cur.a]).then(() => wait(700)).then(ask);
}
afterIntro(intro, ask);
}
function finish() {
const vals = Object.values(scores), stars = Math.max(1, Math.round(vals.reduce((a, b) => a + b, 0) / Math.max(1, vals.length)));
const p = prog(bookId), old = (p[L.n] || {}).stars || 0;
p[L.n] = { stars: Math.max(old, stars), at: Date.now() };
track('/math/done', { book: bookId, lesson: L.n, stars });
const got = kidMap(S.stickers), sk = stkKey(bookId, L.n); const sticker = got[sk] || STICKERS[(L.n * 7 + SHELF.findIndex(b => b.id === bookId) * 3) % STICKERS.length]; got[sk] = sticker;
save();
$('stepTitle').textContent = `${S.kid}, you finished Lesson ${L.n}!`;
$('stage').innerHTML = `<div class="col"><div class="stars">${starStr(stars)}</div><div class="stk">${sticker}</div><div class="note">A new sticker for your sticker book!</div></div>`;
$('hint').textContent = ''; $('controls').innerHTML = '';
$('controls').append(btn('Lessons', () => openBook(bookId), 'big'), btn('Sticker book', () => go('stickers')));
const gj = `Great job, ${S.kid}!`; beep(true); speak(urlFor(gj) ? gj : P.greatJob, P.done);
}
// ?preview opens the "Coming soon" books that already have a book file (testing a book before it goes live)
const ready = b => !b.soon || /[?&]preview\b/.test(location.search);
Promise.all([
fetch('prompts.json').then(r => r.json()).then(j => { P = j; }),
...SHELF.filter(ready).map(b => fetch(`books/${b.id}.json`).then(r => r.ok ? r.json() : null).then(j => { if (j) BOOKS[b.id] = j; })),
...SHELF.filter(ready).map(b => fetch(`audio/${b.id}.json`).then(r => r.ok ? r.json() : null).then(j => {
if (!j) return; if (!AUDIO) AUDIO = { speeds: j.speeds, items: {} }; Object.assign(AUDIO.items, j.items);
}).catch(() => {}))
]).then(home, () => toast('Could not load the book. Check the internet.', 4000));
// the account answer can arrive after the first draw: redraw the home screen
if (window.ABCAccount) window.ABCAccount.ready.then(() => { if ($('home').classList.contains('on') && Object.keys(BOOKS).length) home(); });
return { go, leave, debug: () => ({ S, L, steps, stepIdx, scores }), toStep: id => { const i = steps.indexOf(id); if (i >= 0) { stepIdx = i; runStep(); } }, wordsToNumber };
})();
EOF
index.html: the page and its styles.
cat > /root/rays-rebuild/index.html <<'EOF'
<!doctype html>
<html lang="en"><head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no">
<meta name="theme-color" content="#121212">
<title>Ray's Arithmetic</title>
<link rel="icon" type="image/png" sizes="192x192" href="icon-192.png">
<link rel="manifest" href="manifest.webmanifest">
<link rel="apple-touch-icon" href="icon-192.png">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="Ray's Math">
<style>
:root{color-scheme:dark;--paper:#121212;--ink:#ececec;--soft:#a8a8a8;--accent:#2f8fbf;--warm:#d9733f;--good:#3fae6e;--bad:#ff6b5e;--board:#1d3527;--card:#1e1e1e;--line:#6a6a6a;--hi:#1f3340;--a:#f0a03c;--b:#5ab4f0}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{margin:0;height:100%;background:var(--paper);color:var(--ink);font-family:Georgia,"Times New Roman",serif;overflow:hidden;user-select:none;-webkit-user-select:none;-webkit-text-size-adjust:100%;text-size-adjust:100%}
.screen{position:absolute;inset:0;display:none;flex-direction:column;padding:10px 16px}
.screen.on{display:flex}
h1{margin:4px 0 10px;font-size:clamp(26px,6vmin,44px);text-align:center;letter-spacing:.04em}
h2{margin:4px 0;font-size:clamp(19px,4.2vmin,30px);text-align:center}
button{font:inherit;font-size:clamp(18px,4vmin,26px);border:3px solid var(--line);background:var(--card);color:var(--ink);border-radius:14px;padding:8px 16px;min-height:50px;cursor:pointer}
button:active{transform:scale(.96)}
button.big{background:var(--accent);color:#fff;border-color:#164a63;font-size:clamp(21px,4.6vmin,30px);padding:12px 26px}
button.ghost{border-color:transparent;background:transparent}
button:disabled{opacity:.35}
.row{display:flex;gap:10px;justify-content:center;flex-wrap:wrap;align-items:center}
.grow{flex:1;min-height:0;position:relative}
.kids button{min-width:30vmin;font-size:clamp(24px,6vmin,40px)}
.kids button.sel{background:var(--accent);border-color:var(--accent);color:#fff}
.kids button.add,.kids button.ghost,.kids button.big{min-width:0}
.kids input{font:inherit;font-size:clamp(22px,5vmin,34px);width:min(60vw,320px);padding:8px 14px;border-radius:14px;border:3px solid var(--line);background:var(--card);color:var(--ink)}
#home{overflow-y:auto}
.shelf{display:flex;gap:3vmin;justify-content:center;flex-wrap:wrap;margin-top:3vmin;padding:8px}
.book{width:min(34vmin,210px);aspect-ratio:3/4;border-radius:6px 14px 14px 6px;color:#fff;padding:14px;display:flex;flex-direction:column;justify-content:space-between;box-shadow:inset 10px 0 0 rgba(0,0,0,.18),0 4px 10px rgba(0,0,0,.25);border:none;text-align:left}
.book b{font-size:clamp(18px,4vmin,26px)}.book small{font-size:clamp(13px,2.6vmin,17px);opacity:.9}
.book .bp{font-size:clamp(14px,3vmin,19px);font-weight:bold;background:rgba(0,0,0,.35);border-radius:8px;padding:4px 8px;align-self:flex-start}
.book.soon{filter:grayscale(.6);opacity:.6}
.book.cur{outline:5px solid #ffd166;outline-offset:3px;animation:pulse 1.6s infinite}
.map{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(22vmin,120px),1fr));grid-auto-rows:min(24vmin,120px);gap:12px;overflow-y:auto;padding:6px;align-content:start}
.tile{height:100%;min-height:0;border-radius:18px;display:flex;flex-direction:column;align-items:center;justify-content:center;font-size:clamp(22px,6vmin,38px);padding:4px;line-height:1.1}
.tile small{font-size:clamp(11px,2.4vmin,15px);color:var(--soft)}
.tile .st{font-size:clamp(14px,3vmin,20px);color:#e0a000;letter-spacing:2px}
.tile.next{background:var(--hi);border-color:var(--accent);animation:pulse 1.4s infinite}
.tile.locked{opacity:.35}
.jump{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:6px 0;font-size:clamp(16px,3.4vmin,22px)}
.jump select{flex:1;min-width:0;max-width:100%;font:inherit;padding:8px;background:var(--card);color:var(--ink);border:2px solid var(--line);border-radius:12px}
.tile.rev{border-style:dashed}
@keyframes pulse{50%{transform:scale(1.05)}}
.top{display:flex;align-items:center;gap:8px}
.top .t{flex:1;text-align:center;font-size:clamp(17px,3.8vmin,26px)}
.steps{display:flex;gap:6px;justify-content:center;margin:4px 0}
.steps i{width:clamp(18px,4vmin,28px);height:clamp(18px,4vmin,28px);border-radius:50%;border:3px solid var(--soft);font-style:normal;font-size:12px;display:flex;align-items:center;justify-content:center}
.steps i.done{background:var(--good);border-color:var(--good)}.steps i.cur{border-color:var(--accent);background:var(--hi)}
.hint{font-size:clamp(15px,3.2vmin,20px);color:var(--soft);text-align:center;min-height:1.4em}
.toast{position:fixed;left:50%;top:40%;transform:translate(-50%,-50%);background:#2a2a2a;border:3px solid var(--accent);color:#fff;padding:18px 28px;border-radius:18px;font-size:clamp(24px,6vmin,40px);display:none;z-index:9;text-align:center}
.stars{font-size:clamp(40px,12vmin,90px);color:#e0a000;text-align:center;letter-spacing:6px}
.parent{font-size:15px;color:var(--soft)}
.col{display:flex;flex-direction:column;align-items:center;gap:1.2vmin;height:100%;overflow-y:auto;justify-content:center}
.big-n{font-size:clamp(70px,22vmin,170px);line-height:1;font-weight:bold}
.word{font-size:clamp(22px,5vmin,36px);color:var(--soft)}
.fact{font-size:clamp(30px,8vmin,64px);text-align:center;line-height:1.15}
.fact .sm{display:block;font-size:clamp(16px,3.4vmin,22px);color:var(--soft)}
.dots{display:flex;flex-wrap:wrap;gap:1.4vmin;justify-content:center;align-items:center;max-width:94vw}
.grp{display:grid;grid-template-columns:repeat(5,auto);gap:.8vmin;padding:1vmin;border-radius:10px;border:2px dashed transparent}
.grp.box{border-color:var(--line)}
.dot{width:clamp(14px,3.6vmin,26px);height:clamp(14px,3.6vmin,26px);border-radius:50%;background:var(--a)}
.dot.b{background:var(--b)}.dot.x{background:#444;position:relative}.dot.x::after{content:'';position:absolute;left:-2px;right:-2px;top:45%;height:3px;background:var(--bad);transform:rotate(-35deg)}
.op{font-size:clamp(26px,6vmin,44px);color:var(--soft)}
.chips{display:flex;flex-wrap:wrap;gap:6px;justify-content:center;max-height:24vh;overflow-y:auto}
.chip{font-size:clamp(14px,3vmin,19px);min-height:38px;padding:4px 10px;border-radius:10px}
.chip.cur{background:var(--hi);border-color:var(--accent)}.chip.seen{border-color:var(--good)}
.balls{display:flex;flex-wrap:wrap;gap:2vmin;justify-content:center;max-width:90vw}
.ball{width:clamp(44px,11vmin,80px);height:clamp(44px,11vmin,80px);border-radius:50%;border:none;background:radial-gradient(circle at 35% 30%,#ffd9a8,var(--warm) 60%,#7a3412);padding:0;min-height:0;font-size:clamp(18px,4vmin,28px);color:#fff;font-weight:bold}
.ball.on{background:radial-gradient(circle at 35% 30%,#b8f0c8,var(--good) 60%,#1b5a35)}
.rods{display:flex;gap:1vmin;align-items:flex-end;justify-content:center;flex-wrap:wrap}
.rod{display:grid;grid-template-rows:repeat(10,1fr);gap:2px;height:clamp(110px,26vmin,190px);width:clamp(14px,3.4vmin,22px)}
.rod i{background:var(--b);border-radius:3px}
.choices{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2vmin;width:min(90vw,520px)}
.choices button{font-size:clamp(40px,12vmin,86px);min-height:clamp(80px,18vmin,140px)}
.choices button.ok{background:var(--good);border-color:var(--good);color:#fff}.choices button.no{animation:shake .4s}
@keyframes shake{25%{transform:translateX(-8px)}75%{transform:translateX(8px)}}
.grid{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;overflow-y:auto;max-height:100%;align-content:flex-start;padding:4px}
.grid button{min-width:clamp(56px,14vmin,90px);font-size:clamp(24px,6vmin,40px)}
.grid button.seen{border-color:var(--good)}
/* question + number pad */
.study{gap:1vmin}.study .chips{max-height:15vh;flex-shrink:0}.art{flex:1;min-height:0;overflow-y:auto;width:min(94vw,760px);background:#fffdf6;border-radius:12px;padding:10px 14px;color:#222}
.art{display:flex;flex-direction:column;gap:10px}.art .figs{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;align-items:center}
.art img.fig{display:block;max-width:100%;max-height:26vh;mix-blend-mode:multiply}
@media (min-aspect-ratio:5/4){.art{flex-direction:row;align-items:flex-start}.art .figs{flex:0 0 38%;flex-direction:column;position:sticky;top:0}.art img.fig{max-height:30vh}.art p{flex:1}}
.art p{margin:0;font-size:clamp(18px,3.8vmin,28px);line-height:1.45}
.mc{display:flex;flex-direction:column;gap:1.4vmin;width:min(92vw,640px)}
.mc button{font-size:clamp(18px,4vmin,28px);min-height:56px;padding:8px 14px;text-align:left;line-height:1.3}
.mc button.ok{background:var(--good);border-color:var(--good);color:#fff}.mc button.no{animation:shake .4s;opacity:.55}
.qa{display:flex;flex-direction:column;align-items:center;gap:1vmin;height:100%;min-height:0}
.q{font-size:clamp(20px,4.6vmin,34px);line-height:1.35;text-align:center;overflow-y:auto;max-height:42%;padding:4px 10px;border-radius:12px}
.q .pt{opacity:.55}.q .pt.cur{opacity:1;background:var(--hi);border-radius:8px;padding:0 4px}
.q .got{display:inline-block;background:var(--good);color:#fff;border-radius:8px;padding:0 8px;margin:0 4px;font-weight:bold}
.q .miss{background:var(--warm)}
.q.has-stack{max-height:60%}.q.has-stack .pt{font-size:.85em}
.stack{display:table;margin:.2em auto;font-family:'Courier New',monospace;font-weight:bold;text-align:right;line-height:1.05;font-size:1.05em;border-bottom:3px solid currentColor;padding:0 .3em}
.stack b{float:left;margin-right:.6em}.stack .sum{color:var(--good);border-top:3px solid currentColor;margin-bottom:-3px}
.pic{font-size:clamp(30px,8vmin,56px);line-height:1}
.expr{font-size:clamp(46px,13vmin,100px);font-weight:bold;line-height:1.05;text-align:center}
.micb{min-width:min(86vw,360px);font-size:clamp(20px,4.6vmin,30px)}.micb.live{background:var(--bad);border-color:var(--bad);color:#fff;animation:pulse 1s infinite}
.expr.long{font-size:clamp(28px,7vmin,52px)}
.entry{min-width:3.4em;min-height:1.3em;font-size:clamp(36px,9vmin,64px);text-align:center;border-bottom:4px solid var(--accent);font-weight:bold;letter-spacing:.05em}
.entry.long{font-size:clamp(24px,6vmin,44px)}.entry.no{animation:shake .4s;border-color:var(--bad)}.entry.ok{color:var(--good)}
.pad{display:grid;grid-template-columns:repeat(3,1fr);gap:1.2vmin;width:min(86vw,360px)}
.pad button{font-size:clamp(24px,6vmin,38px);min-height:clamp(46px,9.5vmin,70px);padding:0}
.pad button.okb{background:var(--good);border-color:var(--good);color:#fff}
.algmode .entry{max-width:92vw;overflow-wrap:anywhere;letter-spacing:0}.algmode .entry.long{font-size:clamp(18px,4.2vmin,32px)}
.pad.alg,.algmode .pad{grid-template-columns:repeat(6,1fr);width:min(92vw,480px)}.pad.alg button,.algmode .pad button{font-size:clamp(20px,5vmin,32px);min-height:clamp(40px,8vmin,60px)}.pad.alg button.let{font-style:italic;font-family:Georgia,serif}
.seq{display:flex;flex-wrap:wrap;gap:6px;justify-content:center;max-height:22vh;overflow-y:auto}
.seq span{min-width:2.2em;text-align:center;border:2px solid var(--line);border-radius:8px;padding:2px 6px;font-size:clamp(18px,4vmin,28px)}
.seq span.got{border-color:var(--good);color:var(--good)}.seq span.cur{border-color:var(--accent);background:var(--hi)}
.sol{font-size:clamp(16px,3.4vmin,22px);color:#ffd166;text-align:center;max-width:90vw}
.tray{position:fixed;left:50%;bottom:2vh;transform:translateX(-50%);background:#1a1a1a;border:3px solid var(--accent);border-radius:16px;padding:10px;z-index:20;display:none;flex-direction:column;align-items:center;gap:8px}
.tray.on{display:flex}
.frame{display:grid;grid-template-columns:repeat(10,1fr);gap:5px}
.frame button{width:clamp(26px,6.5vmin,44px);height:clamp(26px,6.5vmin,44px);min-height:0;border-radius:50%;padding:0;border-width:2px}
.frame button.on{background:var(--a);border-color:var(--a)}
.timer{font-size:clamp(16px,3.4vmin,22px);color:var(--soft)}
.stk{font-size:clamp(40px,10vmin,72px)}
.stickers{display:flex;flex-wrap:wrap;gap:10px;justify-content:center;overflow-y:auto;font-size:clamp(34px,9vmin,60px)}
.stickers span{width:1.5em;height:1.5em;display:flex;align-items:center;justify-content:center;border:2px dashed var(--line);border-radius:12px}
.stickers span.got{border:2px solid #e0a000;background:#2a2410}
canvas{position:absolute;inset:0;width:100%;height:100%;touch-action:none;border-radius:14px}
.paper{background:#1a1a1a;border:3px solid var(--line);border-radius:14px}
.note{font-size:clamp(13px,2.8vmin,17px);color:var(--soft);text-align:center;max-width:90vw}
/* show your work: scratch paper beside the question (landscape) or under the number pad (portrait), never over them */
#controls button.on{background:var(--hi);border-color:var(--accent)}
#stage.working{display:flex;flex-direction:column;gap:8px}
#stage.working .qa{flex:1 1 auto;height:auto;min-height:0;overflow-y:auto}
#stage.working .qa .pic{display:none}
#stage.working .pad button{min-height:clamp(42px,7vmin,60px)}#stage.working .micb{min-height:44px;padding:4px 16px;font-size:clamp(17px,3.6vmin,24px)}#stage.working .entry{font-size:clamp(28px,6.5vmin,50px)}#stage.working .expr{font-size:clamp(32px,7.5vmin,64px)}#stage.working .expr.long{font-size:clamp(24px,5.5vmin,44px)}#stage.working .qa{gap:.6vmin;overflow:hidden}#stage.working .qa>*{flex-shrink:0}#stage.working .qa>.q{flex:0 1 auto;min-height:2.8em;max-height:24vh}#stage.working .qa>.picbox{flex:0 1 auto;overflow-y:auto}
.scratch{flex:0 0 35%;display:flex;flex-direction:column;gap:6px;min-height:0;min-width:0}
.sarea{flex:1;position:relative;min-height:0;border:3px solid var(--line);border-radius:14px;overflow:hidden;background:#fffdf6}
.sarea canvas{border-radius:0}
.stools{display:flex;gap:6px;justify-content:center;flex-wrap:wrap}
.stools button{font-size:clamp(16px,3.2vmin,22px);min-height:clamp(46px,8vmin,60px);padding:4px 12px;flex:1 1 0;max-width:180px;white-space:nowrap}
.stools button.on{background:var(--accent);border-color:#164a63;color:#fff}
.erz{display:inline-block;width:1.1em;height:.65em;background:linear-gradient(90deg,#f4a3b4 60%,#5a8fd0 60%);border-radius:3px;transform:rotate(-20deg);vertical-align:middle}
@media (min-aspect-ratio:5/4){#stage.working{flex-direction:row}#stage.working .qa{flex:0 0 44%;height:100%}#stage.working .qa .pic{display:block}.scratch{flex:1 1 0}}
.worklist{display:flex;flex-wrap:wrap;gap:12px;justify-content:center;align-content:flex-start;overflow-y:auto;padding:6px}
.wles{flex-basis:100%;margin:10px 0 0;font-size:clamp(17px,3.6vmin,24px)}
.wpage{display:flex;flex-direction:column;gap:4px;padding:6px;text-align:left;font-size:15px;line-height:1.3;max-width:min(316px,46vw);border-width:2px}
.wpage canvas,.workbig canvas{position:static;border-radius:6px}
.wcap{font-size:clamp(14px,2.8vmin,18px);max-height:4.2em;overflow:hidden}
.workbig .wcap{max-height:none;text-align:center;max-width:94vw}
.wres{color:var(--soft);font-size:14px}.wres.ok{color:var(--good)}.wres.miss{color:var(--a)}
.workbig{position:fixed;inset:0;background:var(--paper);z-index:30;display:none;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:12px}
.workbig.on{display:flex}
</style>
</head><body>
<section id="home" class="screen on">
<h1>Ray's Arithmetic</h1>
<h2>Who is doing math today?</h2>
<div class="row kids" id="kids"></div>
<div class="hint" id="whoHint"></div>
<div class="shelf" id="shelf"></div>
<div class="row" style="margin-top:auto"><button class="ghost parent" id="speedBtn">Voice: normal</button><button class="ghost parent" id="toStickers">Sticker book</button><a class="parent" href="/account/">Grown-ups: account</a><a class="parent" href="/readers/">Readers</a><a class="parent" href="/">About</a></div>
</section>
<section id="map" class="screen">
<div class="top"><button onclick="Rays.go('home')">◀</button><div class="t" id="mapTitle"></div></div>
<div class="jump"><label for="jumpSel">Go to lesson</label><select id="jumpSel"></select><button id="jumpGo">Go</button><button id="mapWork" class="parent" title="Grown-ups: the scratch paper saved with each question">✏️ See the work</button></div>
<div class="map grow" id="tiles"></div>
</section>
<section id="lesson" class="screen">
<div class="top"><button onclick="Rays.leave()">◀</button><div class="t" id="lesTitle"></div><button id="sayBtn" title="Say it again">🔊</button></div>
<div class="steps" id="steps"></div>
<h2 id="stepTitle"></h2>
<div class="grow" id="stage"></div>
<div class="hint" id="hint"></div>
<div class="row" id="controls"></div>
</section>
<section id="stickers" class="screen">
<div class="top"><button onclick="Rays.go('home')">◀</button><div class="t" id="stkTitle">Sticker book</div></div>
<div class="stickers grow" id="stkList"></div>
<div class="row"><button id="stkWork" class="parent">✏️ See the work</button></div>
</section>
<section id="work" class="screen">
<div class="top"><button id="workBack">◀</button><div class="t" id="workTitle">Work</div></div>
<div class="worklist grow" id="workList"></div>
<div class="row"><button id="workDel" class="ghost parent">Delete all work in this book</button></div>
<div class="workbig" id="workBig"></div>
</section>
<div class="tray" id="tray"><div class="frame" id="frame"></div><div class="row"><b id="trayN">0</b><button id="trayClear">Clear</button><button id="trayClose">Close</button></div></div>
<div class="toast" id="toast"></div>
<script src="hershey.js"></script>
<script src="trace.js"></script>
<script src="/account/stats.js"></script>
<script src="/account/sync.js"></script>
<script src="scratch.js"></script>
<script src="alg.js"></script>
<script src="app.js"></script>
<script>if ('serviceWorker' in navigator) navigator.serviceWorker.register('sw.js').catch(() => {});</script>
</body></html>
EOF
sw.js: offline support (now keeps Book 7 too).
cat > /root/rays-rebuild/sw.js <<'EOF'
// Offline support. App files: network first (so updates show), cached copy when offline.
// Voice clips (audio/*.mp3) never change for a given name: cache first, saved the first time they play.
const SHELL = 'rays-shell-v21', CLIPS = 'rays-clips-v1';
const FILES = ['./', 'index.html', 'app.js', 'prompts.json', 'trace.js', 'scratch.js', 'alg.js', 'hershey.js', 'books/primary1877.json', 'audio/primary1877.json', 'books/intellectual.json', 'audio/intellectual.json', 'books/practical.json', 'audio/practical.json', 'books/higher.json', 'audio/higher.json', 'books/geometry.json', 'audio/geometry.json', 'books/algebra1.json', 'audio/algebra1.json', 'books/algebra2.json', 'audio/algebra2.json', 'icon-192.png', 'manifest.webmanifest'];
self.addEventListener('install', e => { e.waitUntil(caches.open(SHELL).then(c => Promise.all(FILES.map(f => c.add(f).catch(() => {})))).then(() => self.skipWaiting())); });
self.addEventListener('activate', e => {
e.waitUntil(caches.keys().then(ks => Promise.all(ks.filter(k => k.startsWith('rays-') && k !== SHELL && k !== CLIPS).map(k => caches.delete(k)))).then(() => self.clients.claim()));
});
self.addEventListener('fetch', e => {
const r = e.request; if (r.method !== 'GET' || new URL(r.url).origin !== location.origin) return;
if (r.url.endsWith('.mp3')) {
e.respondWith(caches.open(CLIPS).then(c => c.match(r).then(hit => hit || fetch(r).then(res => { if (res.ok && res.status === 200) c.put(r, res.clone()); return res; }))));
return;
}
e.respondWith(fetch(r).then(res => { if (res.ok) caches.open(SHELL).then(c => c.put(r, res.clone())); return res; }).catch(() => caches.match(r)));
});
EOF
Rebuild, step by step
1. Build the book data
PC (PowerShell). It prints “88 lessons, 1663 questions, 2286 answers …”, or a list of problems:
powershell -ExecutionPolicy Bypass -File C:\RaysArithmetic\tools\make-book.ps1 -Book algebra2
2. Check the typed answers
PC (PowerShell). It prints “checked N fails 0” (any failure is listed):
powershell -ExecutionPolicy Bypass -File C:\RaysArithmetic\tools\selftest-alg.ps1 -Book algebra2
3. Record the voice
PC (PowerShell):
powershell -ExecutionPolicy Bypass -File C:\RaysArithmetic\tools\make-audio.ps1 -Id algebra2
4. Put it on the server
PC (PowerShell). -Audio sends only the recordings CT 306 (abc-web) doesn’t have yet. It ends with “RAYS-DONE”:
powershell -ExecutionPolicy Bypass -File C:\RaysArithmetic\deploy.ps1 -Audio
5. Check it
Open https://abcbooks.fyi/math/ , tap a name, and tap the blue Book 7. Lesson 1 starts reading article 1 (“Mathematics is the science of the exact relations of Quantity as to Magnitude or Form.”). In Lesson 4’s problems the first question is “From 7a take 4a.”; type 3a.
Troubleshooting
- Book 7 says “Coming soon”:
app.jsstill hassoon: trueon thealgebra2line of the shelf, orbooks/algebra2.jsonis missing on the server. - Book 7 is silent: check that its voice list exists (Proxmox host shell):
pct exec 306 -- ls -l /var/www/abcbooks/rays/audio/algebra2.json
and count the MP3s at one speed (all seven books together):
pct exec 306 -- ls /var/www/abcbooks/rays/audio/s60 | wc -l
- make-book.ps1 lists problems: each line names the lesson and question. “is not” means an answer doesn’t equal its check; “doesn’t make … true” means it doesn’t solve its equation.
- A right answer is marked wrong: it may not be written as simply as the book’s, or a root or exponent needs brackets: √(3a), a^(2/3).
- An old version shows after an update: change
rays-shell-v20insw.jsto the next number, deploy, and reload the page twice.
Notes
- All seven of Ray’s books are now on the shelf and playable.
- Stickers and the scratch paper work in Book 7 like in the others.