:orphan: # MatHtoolSetKernel Sets the kernel and context used for the assembly of a `MATHTOOL`. ## Synopsis ``` #include "petscmat.h" PETSC_EXTERN PetscErrorCode MatHtoolSetKernel(Mat A, MatHtoolKernel kernel, void *kernelctx) ``` ## Input Parameters - ***A -*** hierarchical matrix - ***kernel -*** computational kernel (or `NULL`) - ***kernelctx -*** kernel context (if kernel is `NULL`, the pointer must be of type htool::VirtualGenerator*) ## See Also [](ch_matrices), `Mat`, `MATHTOOL`, `MatCreateHtoolFromKernel()` ## Level advanced ## Location src/mat/impls/htool/htool.cxx ## Implementations MatHtoolSetKernel_Htool in src/mat/impls/htool/htool.cxx
--- [Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/impls/htool/htool.cxx) [Index of all Mat routines](index.md) [Table of Contents for all manual pages](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)