# Integration over a subset of meshL

**URL:** <https://community.freefem.org/t/integration-over-a-subset-of-meshl/3549>\
**Category:** General Discussion\
**Created:** [October 16, 2024, 8:03am UTC](https://community.freefem.org/t/integration-over-a-subset-of-meshl/3549 "2024-10-16T08:03:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mhg](https://avatars.discourse-cdn.com/v4/letter/m/d07c76/32.png) [@mhg](https://community.freefem.org/u/mhg)\
**Post date:** [October 16, 2024, 8:03am UTC](https://community.freefem.org/t/integration-over-a-subset-of-meshl/3549/1 "2024-10-16T08:03:31Z")

</div>

```auto
load "msh3"
int nx = 10;
meshL ThLarge = segment(nx,[2*x,0.,0.],removeduplicate=true);
meshL Th = trunc(ThLarge,x<1,cleanmesh=true);

fespace Vh(ThLarge, P2);

varf testvarf(cf,testcf) = int1d(Th)(testcf); 
real[int] rhs = testvarf(0,Vh);

```

The above code gives me the error message:

> current line = 9  
> Assertion fail : (0)  
> line :8156, in file problem.cpp

For me it seems that it is currently not allowed to integrate only over a subset (Th) of a function defined on a larger meshL (ThLarge). Is this a bug/not implemented or do I make a mistake?
