# in_element_aabb

## `in_element_aabb(queries, V, F)`

Given a triangle mesh or a polyline, computes the finite element gradient matrix assuming piecewise linear hat function basis.

Parameters:

Name Type Description Default
`queries` `numpy double array`

Matrix of query point coordinates

required
`V` `(n,d) numpy array`

vertex list of a triangle mesh

required
`F` `(m,3) or (m,4) numpy int array`

face/tet index list of a triangle/tet mesh

required

Returns:

Name Type Description
`I` `numpy int array`

Vector of indeces into F of the elements that contain each query point (-1 means no containing element).

Source code in `src/gpytoolbox/in_element_aabb.py`
 ``` 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41``` ``````def in_element_aabb(queries,V,F): """Finite element gradient matrix Given a triangle mesh or a polyline, computes the finite element gradient matrix assuming piecewise linear hat function basis. Parameters ---------- queries : numpy double array Matrix of query point coordinates V : (n,d) numpy array vertex list of a triangle mesh F : (m,3) or (m,4) numpy int array face/tet index list of a triangle/tet mesh Returns ------- I : numpy int array Vector of indeces into F of the elements that contain each query point (-1 means no containing element). See Also -------- Notes ----- Examples -------- TO-DO """ try: from gpytoolbox_bindings import _in_element_aabb_cpp_impl except: raise ImportError("Gpytoolbox cannot import its C++ binding.") I = _in_element_aabb_cpp_impl(queries,V,F.astype(np.int32)) return I ``````