I have four conditions over the two-dimensional domain $x,y\in[a,b]$. I want to use NIntegrate
to compute the area of the union of the intersection of the two conditions con1 and con2 with the intersection of the two conditions con3 and con4, i.e. the region $(con1 \cap con2)\cup(con3 \cap con4)$. Does the following code give me the correct answer?
NIntegrate[
Boole[{con1 && con2}, {con3 && con4}],
{x, a, b}, {y, a, b}
]
NIntegrate
was the only way I knew! If it is so clear, why cannot you answer if this code is correct in general (for any conditions and not only for an example) or not? My question is for a general situation not only for a particular example! $\endgroup$