Skip to content

Commit

Permalink
Template polyset over float type (#660)
Browse files Browse the repository at this point in the history
* Template polyset

* Comment for doxygen

* Constrain type

* Improve doc formatting

* Remove macOS 11 from CI.

Compiler is too old.

---------

Co-authored-by: Chris Richardson <[email protected]>
  • Loading branch information
garth-wells and chrisrichardson authored Apr 17, 2023
1 parent 060a0cd commit 0b4fd1d
Show file tree
Hide file tree
Showing 4 changed files with 214 additions and 157 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-11, macos-12]
os: [macos-12]

steps:
- uses: actions/checkout@v3
Expand Down
4 changes: 2 additions & 2 deletions cpp/basix/lattice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ tabulate_dlagrange(std::size_t n, std::span<const double> x)
equi_pts.data(), n + 1, 1);

const auto [dual_values_b, dshape]
= polyset::tabulate(cell::type::interval, n, 0, equi_pts_v);
= polyset::tabulate<double>(cell::type::interval, n, 0, equi_pts_v);
stdex::mdspan<const double, stdex::dextents<std::size_t, 3>> dual_values(
dual_values_b.data(), dshape);

Expand All @@ -179,7 +179,7 @@ tabulate_dlagrange(std::size_t n, std::span<const double> x)
using cmdspan2_t
= stdex::mdspan<const double,
stdex::extents<std::size_t, stdex::dynamic_extent, 1>>;
const auto [tabulated_values_b, tshape] = polyset::tabulate(
const auto [tabulated_values_b, tshape] = polyset::tabulate<double>(
cell::type::interval, n, 0, cmdspan2_t(x.data(), x.size(), 1));
stdex::mdspan<const double, stdex::dextents<std::size_t, 3>> tabulated_values(
tabulated_values_b.data(), tshape);
Expand Down
Loading

0 comments on commit 0b4fd1d

Please sign in to comment.