all: convert ' to ′ and '' to ′′

This is necessary because gofmt in go1.19 imposes smart quotes on comments
that use pairs of single quotes. Doubled-up single tick, U+2032, is chosen
over double tick, U+2033, since the latter is harder to distinguish in many
fonts at normally used font sizes, sometimes being indistinguishable from
other superscript marks such as asterisk. Comparison: ′ ″ *
This commit is contained in:
Dan Kortschak
2022-08-05 20:20:00 +09:30
parent 8af7678edb
commit b2a1b49ea5
5 changed files with 19 additions and 19 deletions

View File

@@ -17,14 +17,14 @@ func ExampleDerivative() {
return math.Sin(x)
}
// Compute the first derivative of f at 0 using the default settings.
fmt.Println("f'(0) ≈", fd.Derivative(f, 0, nil))
fmt.Println("f(0) ≈", fd.Derivative(f, 0, nil))
// Compute the first derivative of f at 0 using the forward approximation
// with a custom step size.
df := fd.Derivative(f, 0, &fd.Settings{
Formula: fd.Forward,
Step: 1e-3,
})
fmt.Println("f'(0) ≈", df)
fmt.Println("f(0) ≈", df)
f = func(x float64) float64 {
return math.Pow(math.Cos(x), 3)
@@ -38,12 +38,12 @@ func ExampleDerivative() {
OriginKnown: true,
OriginValue: f(0),
})
fmt.Println("f''(0) ≈", df)
fmt.Println("f(0) ≈", df)
// Output:
// f'(0) ≈ 1
// f'(0) ≈ 0.9999998333333416
// f''(0) ≈ -2.999999981767587
// f(0) ≈ 1
// f(0) ≈ 0.9999998333333416
// f(0) ≈ -2.999999981767587
}
func ExampleJacobian() {