1 /// @file 2 /// Test creation and destruction of a 2D Simplex non-tensor H(curl) basis 3 /// \test Test creation and destruction of a 2D Simplex non-tensor H(curl) basis 4 #include "t340-basis.h" 5 6 #include <ceed.h> 7 8 int main(int argc, char **argv) { 9 Ceed ceed; 10 const CeedInt p = 8, q = 4, dim = 2; 11 CeedBasis basis; 12 CeedScalar q_ref[dim * q], q_weight[q]; 13 CeedScalar interp[dim * p * q], curl[p * q]; 14 15 CeedInit(argv[1], &ceed); 16 17 // Test skipped if using single precision 18 if (CEED_SCALAR_TYPE == CEED_SCALAR_FP32) return CeedError(ceed, CEED_ERROR_UNSUPPORTED, "Test not implemented in single precision"); 19 20 BuildHcurl2DSimplex(q_ref, q_weight, interp, curl); 21 CeedBasisCreateHcurl(ceed, CEED_TOPOLOGY_TRIANGLE, 1, p, q, interp, curl, q_ref, q_weight, &basis); 22 CeedBasisView(basis, stdout); 23 24 CeedBasisDestroy(&basis); 25 CeedDestroy(&ceed); 26 return 0; 27 } 28