Skip to content

Commit

Permalink
fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
tpapp committed Jun 18, 2024
1 parent d19d60b commit f0066e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@ f2((x1, x2)) = exp(x1) + exp(-abs2(x2))
```

We find the coefficients by solving with the collocation matrix.
```@example
```@example smolyak
θ = collocation_matrix(basis_t) \ f2.(grid(basis_t))
```

Finally, we check the approximation at a point.
```@example
```@example smolyak
z = (0.5, 0.7) # evaluate at this point
isapprox(f2(z), linear_combination(basis_t, θ)(z), rtol = 0.005)
```
Expand Down

0 comments on commit f0066e9

Please sign in to comment.