From 0a4967d7024d29c8853e359f52147e30315c6e79 Mon Sep 17 00:00:00 2001 From: Edwin Vollebregt Date: Tue, 23 Apr 2024 10:33:06 +0200 Subject: [PATCH] fix compilation issues --- examples/basis_cexample.c | 2 +- examples/geometry_cexample.c | 4 ++-- src/Cgismo.h | 16 ++++++++-------- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/examples/basis_cexample.c b/examples/basis_cexample.c index 83da8c8..34f65e0 100644 --- a/examples/basis_cexample.c +++ b/examples/basis_cexample.c @@ -38,7 +38,7 @@ int main(int argc, char* argv[]) udata[3]=1.00; gsCMatrix * u = gsMatrix_create_rcd(1,4,udata); gsCMatrix * result = gsMatrix_create(); - eval_into(b, u, result); + gsFunctionSet_eval_into(b, u, result); printf("Matrix with %d rows and %d columns:\n", rows(result), cols(result) ); print(result); printf("\n"); diff --git a/examples/geometry_cexample.c b/examples/geometry_cexample.c index cddc96e..b78b6b7 100644 --- a/examples/geometry_cexample.c +++ b/examples/geometry_cexample.c @@ -53,7 +53,7 @@ int main(int argc, char* argv[]) // evaluate positions (x,y,z) at given parameter values gsCMatrix * out_p = gsMatrix_create(); - eval_into(G, uvm, out_p); + gsFunctionSet_eval_into(G, uvm, out_p); double* out_data = data(out_p); int out_rows = rows(out_p), out_cols = cols(out_p); @@ -71,7 +71,7 @@ int main(int argc, char* argv[]) // evaluate first derivatives d(x,y,z)/du and d(x,y,z)/dv at given parameter values gsCMatrix * out_d = gsMatrix_create(); - deriv_into(G, uvm, out_d); + gsFunctionSet_deriv_into(G, uvm, out_d); out_data = data(out_d); out_rows = rows(out_d); out_cols = cols(out_d); diff --git a/src/Cgismo.h b/src/Cgismo.h index bb33e0a..84ed915 100644 --- a/src/Cgismo.h +++ b/src/Cgismo.h @@ -26,31 +26,31 @@ #define rows(X) _Generic((X), \ gsCVector * : gsVector_rows, \ gsCVectorInt *: gsVectorInt_rows, \ - gsCMatrix * : gsMatrix_rows, + gsCMatrix * : gsMatrix_rows, \ gsCMatrixInt *: gsMatrixInt_rows)(X) #define cols(X) _Generic((X), \ gsCVector * : gsVector_cols, \ gsCVectorInt *: gsVectorInt_cols, \ - gsCMatrix * : gsMatrix_cols, + gsCMatrix * : gsMatrix_cols, \ gsCMatrixInt *: gsMatrixInt_cols)(X) #define data(X) _Generic((X), \ gsCVector * : gsVector_data, \ gsCVectorInt *: gsVectorInt_data, \ - gsCMatrix * : gsMatrix_data, + gsCMatrix * : gsMatrix_data, \ gsCMatrixInt *: gsMatrixInt_data)(X) -#define transposeInPlace(X) _Generic((X), \ - gsCVector * : gsVector_transposeInPlace, \ +#define transposeInPlace(X) _Generic((X), \ + gsCVector * : gsVector_transposeInPlace, \ gsCVectorInt *: gsVectorInt_transposeInPlace, \ - gsCMatrix * : gsMatrix_transposeInPlace, + gsCMatrix * : gsMatrix_transposeInPlace, \ gsCMatrixInt *: gsMatrixInt_transposeInPlace)(X) #define setZero(X) _Generic((X), \ gsCVector * : gsVector_setZero, \ gsCVectorInt *: gsVectorInt_setZero, \ - gsCMatrix * : gsMatrix_setZero, + gsCMatrix * : gsMatrix_setZero, \ gsCMatrixInt *: gsMatrixInt_setZero)(X) #define destroy(X) _Generic((X), \ @@ -58,7 +58,7 @@ gsCKnotVector * : gsKnotVector_delete, \ gsCVector * : gsVector_delete, \ gsCVectorInt * : gsVectorInt_delete, \ - gsCMatrixInt * : gsMatrixInt_delete, + gsCMatrixInt * : gsMatrixInt_delete, \ gsCMatrix * : gsMatrix_delete)(X) #endif // CGISMO_H