Commits

Lisandro Dalcin committed 87105e5

Rename IGA_DersBasisFuns -> IGA_Basis_BSpline

Comments (0)

Files changed (3)

src/petigabasis.c

 }
 
 EXTERN_C_BEGIN
-extern void IGA_DersBasisFuns(PetscInt i,PetscReal u,PetscInt p,PetscInt d,const PetscReal U[],PetscReal N[]);
+extern void IGA_Basis_BSpline(PetscInt i,PetscReal u,PetscInt p,PetscInt d,const PetscReal U[],PetscReal N[]);
 EXTERN_C_END
 
 #undef  __FUNCT__
     detJ[iel] = J;
     for (iqp=0; iqp<nqp; iqp++) {
       u[iqp] = (X[iqp] + 1) * J + u0;
-      IGA_DersBasisFuns(k,u[iqp],p,d,U,&N[iqp*nen*ndr]);
+      IGA_Basis_BSpline(k,u[iqp],p,d,U,&N[iqp*nen*ndr]);
     }
     offset[iel] = k-p;
   }
     basis->bnd_detJ  [0] = 1.0; basis->bnd_detJ  [1] = 1.0;
     basis->bnd_weight[0] = 1.0; basis->bnd_weight[1] = 1.0;
     basis->bnd_point [0] =  u0; basis->bnd_point [1] = u1;
-    IGA_DersBasisFuns(k0,u0,p,d,U,basis->bnd_value[0]);
-    IGA_DersBasisFuns(k1,u1,p,d,U,basis->bnd_value[1]);
+    IGA_Basis_BSpline(k0,u0,p,d,U,basis->bnd_value[0]);
+    IGA_Basis_BSpline(k1,u1,p,d,U,basis->bnd_value[1]);
   }
 
   PetscFunctionReturn(0);
     offset[iel] = k-p;
     point[iel]  = u;
     detJ[iel]   = U[k+1]-U[k];
-    IGA_DersBasisFuns(k,u,p,d,U,N);
+    IGA_Basis_BSpline(k,u,p,d,U,N);
   }
 
   ierr = IGABasisReset(basis);CHKERRQ(ierr);

src/petigabsp.f90

 ! -*- f90 -*-
 
-subroutine IGA_DersBasisFuns(i,uu,p,d,U,N) &
-  bind(C, name="IGA_DersBasisFuns")
+subroutine IGA_Basis_BSpline(i,uu,p,d,U,N) &
+  bind(C, name="IGA_Basis_BSpline")
   use PetIGA
   implicit none
-  interface
-     pure subroutine DersBasisFuns(i,uu,p,d,U,ders)
-       use PetIGA
-       integer(kind=IGA_INTEGER_KIND), intent(in)  :: i, p, d
-       real   (kind=IGA_REAL_KIND   ), intent(in)  :: uu, U(0:i+p)
-       real   (kind=IGA_REAL_KIND   ), intent(out) :: ders(0:p,0:d)
-     end subroutine DersBasisFuns
-  end interface
   integer(kind=IGA_INTEGER_KIND), intent(in),value :: i, p, d
   real   (kind=IGA_REAL_KIND   ), intent(in),value :: uu
   real   (kind=IGA_REAL_KIND   ), intent(in)       :: U(0:i+p)
   real   (kind=IGA_REAL_KIND   ), intent(out)      :: N(0:d,0:p)
   real   (kind=IGA_REAL_KIND   )  :: ders(0:p,0:d)
-  call DersBasisFuns(i,uu,p,d,U,ders)
+  call BasisFunsDers(i,uu,p,d,U,ders)
   N = transpose(ders)
-end subroutine IGA_DersBasisFuns
-
-pure subroutine DersBasisFuns(i,uu,p,n,U,ders)
+contains
+pure subroutine BasisFunsDers(i,uu,p,n,U,ders)
   use PetIGA
   implicit none
   integer(kind=IGA_INTEGER_KIND), intent(in)  :: i, p, n
         end if
         if (r-1 <= pk) then
            j2 = k-1
-        else 
+        else
            j2 = p-r
         end if
         do j = j1, j2
      ders(:,k) = ders(:,k) * r
      r = r * (p-k)
   end do
-end subroutine DersBasisFuns
+end subroutine BasisFunsDers
+end subroutine IGA_Basis_BSpline

src/petigapoint.c

 }
 
 EXTERN_C_BEGIN
-extern void IGA_DersBasisFuns(PetscInt i,PetscReal u,PetscInt p,PetscInt d,const PetscReal U[],PetscReal N[]);
+extern void IGA_Basis_BSpline(PetscInt,PetscReal,PetscInt,PetscInt,const PetscReal[],PetscReal[]);
 extern void IGA_BasisFuns_1D(PetscInt,PetscInt,const PetscReal[],
 			     PetscInt,PetscInt,PetscInt,const PetscReal[],
 			     PetscReal[],PetscReal[],PetscReal[],PetscReal[]);
   for(i=0;i<element->dim;i++){
     nen[i] = element->parent->axis[i]->p + 1;
     ierr = PetscMalloc1(nen[i]*(order+1),PetscReal,&basis[i]);CHKERRQ(ierr);
-    IGA_DersBasisFuns(element->parent->axis[i]->span[element->ID[i]],
+    IGA_Basis_BSpline(element->parent->axis[i]->span[element->ID[i]],
 		      point->point[i],
 		      element->parent->axis[i]->p,
 		      order,