Skip to content

Commit e6486d4

Browse files
committed
A bit more minot tweaks to the (format of) README.
1 parent 1664149 commit e6486d4

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

README.md

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,24 +15,24 @@ Basic arithmetic, integration, differentiation, evaluation, and root finding ove
1515

1616
## Available Types of Polynomials
1717

18-
* `Polynomial` –⁠ Standard basis polynomials, `a(x) = a₀ + a₁ x + a₂ x² + … + aₙ xⁿ`, `n ∈ ℕ`
19-
* `ImmutablePolynomial` –⁠ Standard basis polynomials backed by a [Tuple type](https://docs.julialang.org/en/v1/manual/functions/#Tuples-1) for faster evaluation of values
20-
* `SparsePolynomial` –⁠ Standard basis polynomial backed by a [dictionary](https://docs.julialang.org/en/v1/base/collections/#Dictionaries-1) to hold sparse high-degree polynomials
21-
* `LaurentPolynomial` –⁠ [Laurent polynomials](https://docs.julialang.org/en/v1/base/collections/#Dictionaries-1), `a(x) = aₘ xᵐ + … + aₙ xⁿ` `m ≤ n`, `m,n ∈ ℤ` backed by an [offset array](). For example, if `m<0` and `n>0`, `a(x) = aₘ xᵐ + … + a₋₁ x⁻¹ + a₀ + a₁ x + … + aₙ xⁿ`
18+
* `Polynomial` –⁠ standard basis polynomials, `a(x) = a₀ + a₁ x + a₂ x² + … + aₙ xⁿ`, `n ∈ ℕ`
19+
* `ImmutablePolynomial` –⁠ standard basis polynomials backed by a [Tuple type](https://docs.julialang.org/en/v1/manual/functions/#Tuples-1) for faster evaluation of values
20+
* `SparsePolynomial` –⁠ standard basis polynomial backed by a [dictionary](https://docs.julialang.org/en/v1/base/collections/#Dictionaries-1) to hold sparse high-degree polynomials
21+
* `LaurentPolynomial` –⁠ [Laurent polynomials](https://docs.julialang.org/en/v1/base/collections/#Dictionaries-1), `a(x) = aₘ xᵐ + … + aₙ xⁿ` `m ≤ n`, `m,n ∈ ℤ` backed by an [offset array](); for example, if `m<0` and `n>0`, `a(x) = aₘ xᵐ + … + a₋₁ x⁻¹ + a₀ + a₁ x + … + aₙ xⁿ`
2222
* `ChebyshevT` –⁠ [Chebyshev polynomials](https://en.wikipedia.org/wiki/Chebyshev_polynomials) of the first kind
2323

2424
## Usage
2525

2626
### Construction and Evaluation
2727

28-
Construct a polynomial from its coefficients, lowest order first.
28+
Construct a polynomial from an array (a vector) of its coefficients, lowest order first.
2929

3030
```julia
3131
julia> Polynomial([1,0,3,4])
3232
Polynomial(1 + 3x^2 + 4x^3)
3333
```
3434

35-
An optional variable parameter can be added.
35+
Optionally, the variable of the polynomial can be specified.
3636

3737
```julia
3838
julia> Polynomial([1,2,3], :s)
@@ -84,7 +84,7 @@ julia> q ÷ p # `div`, also `rem` and `divrem`
8484
Polynomial(0.25 - 0.5x)
8585
```
8686

87-
Note that operations involving polynomials with different variables will error.
87+
Operations involving polynomials with different variables will error.
8888

8989
```julia
9090
julia> p = Polynomial([1, 2, 3], :x)
@@ -95,7 +95,7 @@ ERROR: Polynomials must have same variable.
9595

9696
### Integrals and Derivatives
9797

98-
Integrate the polynomial `p` term by term, optionally adding constant
98+
Integrate the polynomial `p` term by term, optionally adding a constant
9999
term `k`. The degree of the resulting polynomial is one higher than the
100100
degree of `p`.
101101

@@ -119,8 +119,7 @@ Polynomial(3 - 2x)
119119

120120

121121
Return the roots (zeros) of `p`, with multiplicity. The number of
122-
roots returned is equal to the degree of `p`. By design, this is not type-stable,
123-
the returned roots may be real or complex.
122+
roots returned is equal to the degree of `p`. By design, this is not type-stable, the returned roots may be real or complex.
124123

125124
```julia
126125
julia> roots(Polynomial([1, 0, -1]))

0 commit comments

Comments
 (0)