Posts

Showing posts from February 1, 2026

Double Integration

Image
Double Integration Examples with Graphs Double Integration: Solved Examples with Graphs Understanding Double Integration Double integration extends the concept of a single integral to functions of two variables, $$f(x, y)$$. Geometrically, it represents the volume under a surface within a given region $$D$$. Example 1: Rectangular Bounds Evaluate $$\iint_R (x + 2y) \, dA$$ over $$R = [0, 1] \times [0, 2]$$. x y Step 1: Setup Iterated Integral $$\int_{0}^{1} \int_{0}^{2} (x + 2y) \, dy \, dx$$ Step 2: Integrate w.r.t $y$ $$\int_{0}^{1} [xy + y^2]_{0}^{2} \, dx = \int_{0}^{1} (2x + 4) \, dx$$ Step 3: Integrate w.r.t $x$ $$[x^2 + 4x]_{0}^{1} = 1 + 4 = 5$$ Final Answer: 5 Example 2: Polar Transformation Find the area of a circle with radius $$a$$. $$\iint_D dA = \int_{0}^{2\pi} \int_{...

Weighted Sampling

What is Weighted Sampling? Weighted sampling is a sampling technique where each item is assigned a weight , and the probability of selecting that item is proportional to its weight. Higher weight $\Rightarrow$ higher chance of being selected Lower weight $\Rightarrow$ lower chance (but usually not zero) Mathematical Definition Given $n$ items with weights: $ w_1, w_2, \dots, w_n $ The probability of selecting item $i$ is: $ P(i) = \frac{w_i}{\sum_{j=1}^{n} w_j} $ Example: weights $[1,3,6] \Rightarrow [0.1,0.3,0.6]$ Visual Intuition Weighted bar representation: A | █ B | ███ C | ██████ Flattened view: | A | B B B | C C C C C C | Sampling is equivalent to picking a random point on this bar. Larger segments correspond to higher probability. Four Examples of Weighted Sampling Lottery: More tickets $\Rightarrow$ higher winning chance Online advertising: Higher bids shown more often Survey sampling: Oversampling rare groups G...