<?xml version="1.0" encoding="UTF-8"?>
<rss  xmlns:atom="http://www.w3.org/2005/Atom" 
      xmlns:media="http://search.yahoo.com/mrss/" 
      xmlns:content="http://purl.org/rss/1.0/modules/content/" 
      xmlns:dc="http://purl.org/dc/elements/1.1/" 
      version="2.0">
<channel>
<title>Ishaan&#39;s Blog</title>
<link>https://shrivastava95.github.io/blog-quarto/</link>
<atom:link href="https://shrivastava95.github.io/blog-quarto/index.xml" rel="self" type="application/rss+xml"/>
<description>A blog built with Quarto</description>
<generator>quarto-1.9.37</generator>
<lastBuildDate>Fri, 26 Jun 2026 17:04:10 GMT</lastBuildDate>
<item>
  <title>Multivariable Statistics</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/multivariable-statistics/</link>
  <description><![CDATA[ 





<p>While trying to understand what a <code>privileged-basis</code> means, I realised that I am significantly underequipped with the prerequisites. These are my notes for all the problems I have solved so far, and the things that I have learnt. I intend to turn this into something that is more like an index of theorems once I am more familiar with everything in here.</p>
<section id="prerequisite-notes-for-the-relu-privileged-basis-problem" class="level1">
<h1>Prerequisite Notes for the ReLU Privileged-Basis Problem</h1>
<p>This document records:</p>
<ol type="1">
<li>the concepts introduced,</li>
<li>the questions attempted,</li>
<li>my original solutions,</li>
<li>what was correct,</li>
<li>what was incorrect or incomplete,</li>
<li>the corrected derivations.</li>
</ol>
<hr>
</section>
<section id="question-1-covariance-and-second-moments" class="level1">
<h1>Question 1 — Covariance and second moments</h1>
<ul>
<li><p>Let <img src="https://latex.codecogs.com/png.latex?X%20%5Cin%20%5Cmathbb%7BR%7D%5Ed"> be a random vector with mean <img src="https://latex.codecogs.com/png.latex?%5Cmu=%5Cmathbb%7BE%7D%5BX%5D">. We know that, the covariance of (not necessarily independent) two random variables <img src="https://latex.codecogs.com/png.latex?A,%20B%20%5Cin%20%5Cmathbb%7BR%7D"> is expressed as: <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7BCov%7D(A,%20B)%20=%20%5Cmathbb%7BE%7D%5B(A%20-%20%5Cmathbb%7BE%7D%5BA%5D)(B%20-%20%5Cmathbb%7BE%7D%5BB%5D)%5D">. We can use this notion of covariance of two random variables to construct the notion of <u><strong>covariance of a vector</strong></u> with itself: <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7BCov%7D(X)_%7Bij%7D%20=%20%5Cmathbb%7BE%7D%5B(X_i%20-%20%5Cmathbb%7BE%7D%5BX%5D)(X_j%20-%20%5Cmathbb%7BE%7D%5BX%5D)%5D,"> or, in matrix form, equivalently: <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7BCov%7D(X)%20=%20%5Cmathbb%7BE%7D%5B(X%20-%20%5Cmathbb%7BE%7D%5BX%5D)(X%20-%20%5Cmathbb%7BE%7D%5BX%5D)%5ET%5D"></p></li>
<li><p>The diagonal entries are called the <u><strong>coordinate variances</strong></u> <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7BCov%7D(X)_%7Bii%7D%20=%20%5Cmathbb%20E%5B(X_i-%5Cmu_i)%5E2%5D%20=%20%5Coperatorname%7BVar%7D(X_i)"></p></li>
<li><p>The <u><strong>Euclidean norm</strong></u> is expressed as <img src="https://latex.codecogs.com/png.latex?%7Cx%7C%20=%20%5Csqrt%7B%5Csum_%7Bi=1%7D%5Ed%20x_i%5E2%7D"></p></li>
<li><p>Trivial Identity: <img src="https://latex.codecogs.com/png.latex?%5Cmathbb%20E%7CX-%5Cmu%7C%5E2%20=%20%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(X))"></p></li>
<li><p>Inner and Outer producs: For vectors <img src="https://latex.codecogs.com/png.latex?a,b%5Cin%5Cmathbb%7BR%7D%5Ed%20,"></p>
<ul>
<li>The standard <u><strong>Euclidean inner product</strong></u> is <img src="https://latex.codecogs.com/png.latex?%5Clangle%20a,b%5Crangle%20=%20%5Csum_%7Bi=1%7D%5Ed%20a_i%20b_i,"> equivalently expressed as <img src="https://latex.codecogs.com/png.latex?a%5ETb">.</li>
<li>The <u><strong>Outer product</strong></u> is <img src="https://latex.codecogs.com/png.latex?ab%5ET%20%5Cin%20%5Cmathbb%7BR%7D%5E%7Bd%20%5Ctimes%20d%7D"></li>
</ul></li>
<li><p><img src="https://latex.codecogs.com/png.latex?%7C(a%20+%20b)%7C%5E2%20=%20%7Ca%7C%5E2%20+%20%7Cb%7C%5E2%20+%202a%5ETb"> for vectors <img src="https://latex.codecogs.com/png.latex?a,b%5Cin%5Cmathbb%7BR%7D%5Ed"></p></li>
<li><p>Using the above trivial identity, one can derive another useful identity - <img src="https://latex.codecogs.com/png.latex?%7B%5Cmathbb%20E%7CX%7C%5E2%20=%20%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(X))%20+%20%7C%5Cmathbb%20E%5BX%5D%7C%5E2%7D"></p></li>
<li><p>Useful - <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7Btr%7D(xy%5ET)%20=%20x%5ETy"></p></li>
<li><p><u><strong>Linearity of Expectation</strong></u> - For integrable random variables <img src="https://latex.codecogs.com/png.latex?X,Y"> and constants <img src="https://latex.codecogs.com/png.latex?a,b%5Cin%5Cmathbb%7BR%7D,"> <img src="https://latex.codecogs.com/png.latex?%5Cmathbb%7BE%7D%5BaX+bY%5D%20=%20a%5Cmathbb%20E%5BX%5D+b%5Cmathbb%20E%5BY%5D"></p></li>
<li><p>If <img src="https://latex.codecogs.com/png.latex?X"> and <img src="https://latex.codecogs.com/png.latex?Y"> are independent and the relevant expectations exist, then <img src="https://latex.codecogs.com/png.latex?%5Cmathbb%20E%5BXY%5D%20=%20%5Cmathbb%20E%5BX%5D%5Cmathbb%20E%5BY%5D">. Independence is sufficient, but not necessary.</p></li>
<li><p>The second <u><strong>moment</strong></u> of a random variable is simply the expectation <img src="https://latex.codecogs.com/png.latex?%5Cmathbb%7BE%7D%5BX%5E2%5D"></p></li>
<li><p>For two random variables <img src="https://latex.codecogs.com/png.latex?A,%20B"> it is simple to see that <img src="https://latex.codecogs.com/png.latex?%5Coperatorname%7BCov%7D(X,%20Y)%20=%20%5Cmathbb%20E%5BXY%5D%20-%20%5Cmathbb%7BE%7D%5BX%5D%5Cmathbb%7BE%7D%5BY%5D"></p></li>
<li><p>Using the above, it can be seen that independence implies zero covariance - just expand the terms inside <img src="https://latex.codecogs.com/png.latex?%5Cmathbb%20E%5BXY%5D"> and write them elementwise for the entire probability space (use summation or integrals)</p></li>
</ul>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/multivariable-statistics/</guid>
  <pubDate>Fri, 26 Jun 2026 17:04:10 GMT</pubDate>
</item>
<item>
  <title>WTF is going on inside Gemma? Thoughts, and some experiments with hybrid post-pre-norm and Per-Layer-Embeddings (PLE)</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/gemma/</link>
  <description><![CDATA[ 





<p>Does anyone have any idea of what Gemma-style Per-Layer-Embeddings actually do? Lets pull up <strong>Gemma 4 E4B</strong> for a closer look.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/gemma-3n-parameters.png" class="img-fluid figure-img"></p>
<figcaption>gemma-3n-parameters.png</figcaption>
</figure>
</div>
<p>Google itself doesn’t offer much on this matter<sup>1</sup>, so let me explain. It’s simple - you can offload the per-layer embeddings to the CPU without impacting throughput. Think of it like a form of sparsity, different in nature from Mixture of Experts (MoE), since we are improving the capabilities of a model by adding additional sets of embeddings at every single layer, instead of scaling the model width or depth. This allows us to store the entire lookup table on flash storage (a whopping 3.5B params out of 8B!) rather than needing valuable VRAM meant for storing the rest of the model parameters.</p>
<p>Let’s do a <a href="https://en.wikipedia.org/wiki/Back-of-the-envelope_calculation">back-of-the-envelope calculation</a> on the memory transferred between the CPU-offloaded embedding table in the case. The core idea here is to observe that the memory traffic for the embeddings being sent between devices is far less than the whole size of the PLE table.</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/gemma4-ple-construction.webp" class="img-fluid figure-img"></p>
<figcaption>gemma4-ple-construction.webp</figcaption>
</figure>
</div>
<p><img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Baligned%7D%5Ctext%7BTotal%20PLE%20bytes%20%7D%20=%20%5Ctext%7B%20262,144%20vocabulary%20size%20*%2035%20N%20layers%20*%20256%20embed%20dim%20%7D%20=%202.35%20*%2010%5E9%5Ctext%7B%20%20bytes%7D%5Cend%7Baligned%7D"></p>
<p>whereas</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Ctext%7BMemory%20Traffic%20per%20token%20decoded%7D%20=%20%5Ctext%7B%201%20token%20indexed%20per%20layer%20per%20decode%20*%2035%20N%20layers%20*%20256%20embed%20dim%20%7D%20=%208.9%20*%2010%5E3%5Ctext%7B%20bytes%7D"></p>
<p>which is <em>6 orders of magnitude smaller</em> than the entire embedding table! Thus, we can index the embedding table on the CPU and then send the bytes over to the device for layerwise inference, and it doesn’t end up becoming a inference bottleneck.</p>
<p>I couldn’t find code to do this on the HuggingFace version of Gemma 3n, so I wrote my own little snippet to do this using pytorch hooks - <a href="https://gist.github.com/shrivastava95/6a6249c5d8cdb3d79376075a98678c63">Full reproducible script annotated with comments here</a></p>
<pre><code>Gemma3nForConditionalGeneration.from_pretrained('google/gemma-3n-e2b-it', torch_dtype=torch.bfloat16,).to('cuda').eval()

lm = model.model.language_model
lm.embed_tokens_per_layer.to(device="cpu", dtype=torch.float16)

@torch.no_grad()
def get_per_layer_inputs_cpu(self, input_ids: torch.LongTensor) -&gt; torch.Tensor:
    ids_cpu = input_ids.to("cpu", non_blocking=True)
    ple_cpu = self.embed_tokens_per_layer(ids_cpu)
    ple_cpu = ple_cpu.reshape(*ids_cpu.shape, self.config.num_hidden_layers, self.hidden_size_per_layer_input,)
    return ple_cpu.to(device=input_ids.device, dtype=torch.bfloat16, non_blocking=True)

lm.get_per_layer_inputs = types.MethodType(get_per_layer_inputs_cpu, lm)
del model.model.audio_tower, model.model.embed_audio
gc.collect()
torch.cuda.empty_cache()

generation = model.generate(**inputs, max_new_tokens=100, do_sample=False)
print(processor.decode(generation[0]), skip_special_tokens=True)

# **Overall Impression:** The image is a close-up shot of a vibrant garden scene,
# focusing on a cluster of pink cosmos flowers and a busy bumblebee.
# It has a slightly soft, natural feel, likely captured in daylight.</code></pre>
<p>Here are the VRAM savings, the GPU usage visibly drops right after the hook is applied, seen through <code>nvtop</code></p>
<p>Before CPU offload: <img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/gp1.png" class="img-fluid" alt="gemma01_before_cpu.png"></p>
<p>After CPU offload: <img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/gp2.png" class="img-fluid" alt="gemma02_after_cpu.png"></p>
<section id="ple-performance-gains" class="level3" data-number="0.1">
<h3 data-number="0.1" class="anchored" data-anchor-id="ple-performance-gains"><span class="header-section-number">0.1</span> PLE performance gains?</h3>
<p>It is not immediately obvious <em>HOW</em> PLE improves performance. Why even bother? What problem do they solve at this model scale? All I’ve been able to find so far on this matter are sloppy medium posts and I don’t trust them. I spent a good while trying to figure it out… honestly, I still don’t know for sure, I think it would make for a great mech-interp paper. Let’s try to work this out anyway!</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/layernorm.jpeg" class="img-fluid figure-img"></p>
<figcaption>layernorm.jpeg</figcaption>
</figure>
</div>
<p>My rough understanding of transformers is that attention approximates computation and MLP approximates memory. Looking at the architecture diagram, we can see two things:</p>
<ol type="1">
<li><p><strong>Residual stream gating the PLE lookup</strong> - A simple hypothesis I agree with<sup>2</sup> is that the layer-wise lookup allows the model to store and recall a great deal of information as the lookup is precomputed for every forward pass, instead of going through matmuls in the MLP, thereby increasing capacity without commensurate increases in VRAM occupancy.</p></li>
<li><p><strong>Mix-LayerNorm (pre + post)</strong> - The transformer blocks use post-norm as well as pre-norm. The disadvantage of Post-norm is that it keeps the L2 norm of the hidden state activations approximately constant across layers as there is no identity path, which means signals originating from early layers keep shrinking as they propagate forward, leading to vanishing influence on the output (and, correspondingly, vanishing gradients). This is a well known problem with post-norm, which is why most LLMs these days use pre-norm as it avoids training instability issues with increase in depth <a href="https://kindxiaoming.github.io/blog/2026/depth-1/">reference - blog by Ziming Liu</a>. Since gemma uses both, it might still suffer from the described post-norm limitation. I have a suspicion that if post-norm were not used in the Gemma architecture, these per-layer embeddings would correspondingly not also have been necessary (simply allow information from first layer token embeddings to flow through the residual stream and reach every layer normally).</p></li>
</ol>
</section>
<section id="implementing-ple---from-scratch-it-works" class="level2" data-number="1">
<h2 data-number="1" class="anchored" data-anchor-id="implementing-ple---from-scratch-it-works"><span class="header-section-number">1</span> Implementing PLE - from scratch (it works!)</h2>
<p>Out of curiosity, I cooked up a small-scale transformer baseline on the shakespeare corpus, modeled as NTP on raw byte pairs (yes, I didn’t use a tokenizer, literally next-byte prediction). Here are some results:</p>
<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://shrivastava95.github.io/blog-quarto/posts/gemma/depth_norm_depth_comparison.webp" class="img-fluid figure-img"></p>
<figcaption>depth_norm_depth_comparison.webp</figcaption>
</figure>
</div>
<pre><code>  - prenorm=False, postnorm=False
      - ple_dim=0: 1.601218
      - ple_dim=8: 1.571632
      - ple_dim=32: 1.550698
      - ple_dim=128: 1.622619

  - prenorm=False, postnorm=True
      - ple_dim=0: 1.581143
      - ple_dim=8: 1.595611
      - ple_dim=32: 1.579468
      - ple_dim=128: 1.559271

  - prenorm=True, postnorm=False
      - ple_dim=0: 1.541992
      - ple_dim=8: 1.546094
      - ple_dim=32: 1.537176
      - ple_dim=128: 1.529346

  - prenorm=True, postnorm=True
      - ple_dim=0: 1.541877
      - ple_dim=8: 1.544192
      - ple_dim=32: 1.534553
      - ple_dim=128: 1.528164

  Averaged across all four norm settings
  - ple_dim=0: 1.566558
  - ple_dim=8: 1.564382
  - ple_dim=32: 1.550474
  - ple_dim=128: 1.559850</code></pre>
<p>Ignoring the weird error bars on the rightmost chart for x=8, we can see that the average performance over validation generally improves with increase in PLE dimension which tells us that PLE does indeed improve performance on this simple toy task.</p>
<section id="wtf-is-matformer" class="level3" data-number="1.1">
<h3 data-number="1.1" class="anchored" data-anchor-id="wtf-is-matformer"><span class="header-section-number">1.1</span> wtf is MatFormer?</h3>
<p>I do not have the motivation nor understanding to explain what it is, but it has something to do with training nested subsets of the FFN blocks in such a way that they can be sliced width-wise in each layer with only negligible degradation. I’ve made some (minor) fixes to the demo colab - https://colab.research.google.com/drive/1g3S_On6aDHmHmeiRwf_-bI0yZvPiJelF</p>
<p>Do try it out. I’m tryna find good subsets smaller than E2B rn, here’s two I found that inferenced just fiiine. - <a href="https://huggingface.co/capriciousmarauder/test-submodel-3">capriciousmarauder/test-submodel-3</a> This one is more sliced than E2B. - <a href="https://huggingface.co/capriciousmarauder/test-submodel-4">capriciousmarauder/test-submodel-4</a> This one is very aggressively sliced, even more than the other one.</p>
<pre><code># score for google/gemma-3n-E2B-it, google's official published slice of Gemma3n-E4B-it
{
    "en_text_recognition": 0.6096878412118829,
    "en_text_detection": 0.23172620479653033,
    "en_text_spotting": 0.0,
    "en_element_parsing": 0.04,
    "en_mathematical_calculation": 0.3240026170865559,
    "en_visual_text_understanding": 0.7103983997859018,
    "en_knowledge_reasoning": 0.5074402603391522,
    "English Overall Score": 0.34617933188857475
}

# score for capriciousmarauder/test-submodel-3, which is a slice of Gemma3n-E4B-it
{
    "en_text_recognition": 0.5459304480487074,
    "en_text_detection": 0.21590682007667475,
    "en_text_spotting": 0.0,
    "en_element_parsing": 0.0275,
    "en_mathematical_calculation": 0.2693079603436732,
    "en_visual_text_understanding": 0.676684722674171,
    "en_knowledge_reasoning": 0.4669721878768469,
    "English Overall Score": 0.3146145912885819
}

# score for capriciousmarauder/test-submodel-4, which is a slice of Gemma3n-E4B-it
{
    "en_text_recognition": 0.34489594363685844,
    "en_text_detection": 0.14555663691294746,
    "en_text_spotting": 0.0,
    "en_element_parsing": 0.02,
    "en_mathematical_calculation": 0.20092149837002324,
    "en_visual_text_understanding": 0.5540588220515938,
    "en_knowledge_reasoning": 0.44284559706420745,
    "English Overall Score": 0.2440397854336615
}</code></pre>


</section>
</section>


<div id="quarto-appendix" class="default"><section id="footnotes" class="footnotes footnotes-end-of-document"><h2 class="anchored quarto-appendix-heading">Footnotes</h2>

<ol>
<li id="fn1"><p>Google generously spent the equivalent of a paragraph worth of tokens to explain Per-Layer-Embeddings in their <a href="https://ai.google.dev/gemma/docs/gemma-3n">blog on Gemma 3n</a> last year. Recently, they one-upped themselves, offering a <em>single sentence</em> worth of information about PLE in the docs for their latest open-source model series, <a href="https://ai.google.dev/gemma/docs/core">Gemma 4 - link here</a>. In other words, they offer zero explanation about why it improves the performance over simply injecting the embeddings into the residual stream, or why they could not have simply kept a normal embedding table and just made it larger, and so on.↩︎</p></li>
<li id="fn2"><p>The credit for this particular hypothesis as well as elicitation of a lot of the discussion in the blog is thanks to aletheia who is the creator of Mirage, a custom zeroth-order optimization library for Episteme, a superhuman UCI chess engine - <a href="https://aletheiaaaaa.github.io/index.html">check out their blog!</a>↩︎</p></li>
</ol>
</section></div> ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/gemma/</guid>
  <pubDate>Tue, 23 Jun 2026 12:12:51 GMT</pubDate>
</item>
<item>
  <title>Part-Whole training</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/part-whole-training/</link>
  <description><![CDATA[ 





<p>Reference - <a href="Daniel Gopher, 1989 - Practice under changing priorities: An approach to the training of complex skills">https://www.sciencedirect.com/science/article/abs/pii/0001691889900073?via%3Dihub</a></p>
<p>This is a common approach to the training of a task that is difficult and demanding and cannot be <strong>initially coped with.</strong></p>
<p>Under this approach, the whole task is <strong>decomposed into segments.</strong></p>
<p>There are several strategies to decompose tasks -</p>
<ul>
<li>segmentation - divide a task meaningfully across <strong>time</strong>.</li>
<li>fractionation - breaking down task into <strong>elements</strong></li>
<li>simplification - reduction in <strong>difficulty</strong></li>
</ul>
<section id="pitfalls" class="level1">
<h1>Pitfalls</h1>
<p>Training individual schemas has a negative transfer to performance on the whole task, as it is theorized that the main properties of schemas lie in the connections between them (which are not developed subsequently).</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/part-whole-training/</guid>
  <pubDate>Sun, 24 May 2026 14:38:49 GMT</pubDate>
</item>
<item>
  <title>Reproducing Attention is All you Need, from scratch - PyTorch</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/reproducing-attention-is-all-you-need-from-scratch-pytorch/</link>
  <description><![CDATA[ 





<section id="how-to-understand-transformer-in-one-image" class="level1">
<h1>How to understand transformer in one image?</h1>
<ul>
<li>Here is a useful diagram explaining the transformer encoder in great detail. <img src="https://shrivastava95.github.io/blog-quarto/posts/reproducing-attention-is-all-you-need-from-scratch-pytorch/pasted-image-20241011120647.png" class="img-fluid" alt="Transformer encoder diagram"></li>
</ul>
</section>
<section id="what-is-a-transformer" class="level1">
<h1>What is a Transformer?</h1>
<p>Transformers are a sequence modelling and transduction architecture heavily leveraging self-attention in order to eliminate the need for convolutions or gating. Advantages over RNNs and LSTMs include:</p>
<ol type="1">
<li><strong>Non recurrent computation</strong> - Computation for a layer at a given depth is completely parallelized, while in prior architectures the computation at a given position and depth required computing for all the depths before them.</li>
<li><strong>Global dependency modelling</strong> - Prior architectures featured a growth in computation required to relate information between positions with larger distance between them. Transformers do away with this limitation by modelling dependencies in a global fashion.</li>
<li><strong>Permutation invariance</strong> - The transformer architecture fundamentally looks at its inputs as a <u>set of elements</u><sup>1</sup>, as opposed to a sequence. This makes it incredibly powerful and widely applicable.</li>
</ol>
</section>
<section id="transformer-architecture" class="level1">
<h1>Transformer Architecture</h1>
<p>The transformer architecture features an encoder-decoder setup in the fashion of a typical neural machine translation task. The encoder maps a sequence of symbol representations <img src="https://latex.codecogs.com/png.latex?(x_1,%20...,%20x_n)"> to a sequence of continuous representations <img src="https://latex.codecogs.com/png.latex?%5Cbf%7Bz%7D"><img src="https://latex.codecogs.com/png.latex?%5Cspace=%20(z_1,%20...,%20z_n)">. Given <img src="https://latex.codecogs.com/png.latex?%5Cbf%7Bz%7D">, the decoder then generates the output sequence of symbols <img src="https://latex.codecogs.com/png.latex?(y_1,%20...,%20y_m)"> in an auto-regressive fashion.</p>
<p>Let us introduce the building blocks of the transformer architecture. ### 1. Scaled dot-product attention The output is calculated as a weighted sum of values of dimension <img src="https://latex.codecogs.com/png.latex?d_v">. The weights are softmaxed scores, and the scores are obtained by computing the dot-product of an input query with the key vector associated with that value, each being of dimension <img src="https://latex.codecogs.com/png.latex?d_k">.</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Cdisplaylines%7Bq_%7Bpos%7D%20=%20%5B...%5D_%7B1%20%5Ctimes%20d_k%7D%20%5C%5C%0AK%20=%20%5B...%5D_%7Bn%20%5Ctimes%20d_k%7D%20%5C%5C%0AV%20=%20%5B...%5D_%7Bn%20%5Ctimes%20d_v%7D%7D"></p>
<p>… which yields the scaled dot-product attention formula:</p>
<p><img src="https://latex.codecogs.com/png.latex?o_%7Bpos%7D%20=%20%5Ctext%7Bsoftmax%7D%5Cbigg(%5Cdfrac%7Bq_%7Bpos%7D%20%5Ccdot%20K%5ET%7D%7B%5Csqrt%7Bd_k%7D%7D%5Cbigg)%5Ccdot%20V"></p>
<p>… which, in practice, is further vectorized:</p>
<pre><code>$$O = \text{Attention}(Q, K, V) = \text{softmax}\bigg(\dfrac{Q\cdot K}{\sqrt{d_k}}\bigg)\cdot V$$</code></pre>
<section id="multi-head-attention" class="level3">
<h3 class="anchored" data-anchor-id="multi-head-attention">2. Multi-head attention</h3>
<p>It is found that a single attention function with <img src="https://latex.codecogs.com/png.latex?d_%7Bmodel%7D"> dimensional keys, queries and values can be improved upon. The input matrices <img src="https://latex.codecogs.com/png.latex?Q"> and <img src="https://latex.codecogs.com/png.latex?K"> are projected to <img src="https://latex.codecogs.com/png.latex?d_k">, and <img src="https://latex.codecogs.com/png.latex?V"> is projected to <img src="https://latex.codecogs.com/png.latex?d_v">, and this is done multiple times across <img src="https://latex.codecogs.com/png.latex?h"> different <u>heads</u><sup>2</sup>. The scaled dot-product attention outputs of each head are concatenated and finally projected once again.</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Cdisplaylines%7B%0A%5Ctext%7BMultiHeadAttention(Q,%20K,%20V)%20=%20Concat%7D(%5Ctext%7Bhead%7D_1,%20...,%20%5Ctext%7Bhead%7D_h)%5Ccdot%20W%5EO%20%5C%5C%0A%5Ctext%7Bwhere%20head%7D_i%20=%20Attention(Q%5Ccdot%20W%5EQ_i,%20K%5Ccdot%20K%5EQ_i,%20V%5Ccdot%20W%5EV_i)%0A%7D"></p>
</section>
<section id="types-of-attention" class="level3">
<h3 class="anchored" data-anchor-id="types-of-attention">3. Types of Attention</h3>
<ul>
<li>The encoder uses multi-head <strong>self-attention</strong> layers. In self-attention, all of the keys, queries, and values come from the same place, i.e.&nbsp;the output of the previous encoder layer.</li>
<li>The decoder uses two kinds of multi-head attention layers - <strong>cross-attention</strong> takes in keys and values from the encoder outputs, while the queries come from MHSA earlier within the same decoder block. This particular choice allows the decoder to relate the current position with representations from all positions of the encoder.</li>
<li>Additionally, the decoder uses <strong>self-attention layers with masking</strong> in order to allow each position in the decoder to attend to all positions up to and including that position. This is done to prevent leftward information flow in the decoder to preserve the auto-regressive property.<sup>3</sup></li>
</ul>
</section>
<section id="position-wise-feed-forward-networks" class="level3">
<h3 class="anchored" data-anchor-id="position-wise-feed-forward-networks">4. Position-wise feed forward networks</h3>
<p>Each encoder/decoder block applies a fully-connected feed-forward network on each position, identically and separately.</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Ctext%7BFFN%7D(x_i)%20=%20%5Ctext%7BLinear%7D(%5Ctext%7BReLU%7D(%5Ctext%7BLinear%7D(x_i)))"></p>
<p>The dimensionality of input and output is <img src="https://latex.codecogs.com/png.latex?d_%7Bmodel%7D%20=%20512">, while that of the middle layer is <img src="https://latex.codecogs.com/png.latex?d_%7Bf%20f%7D%20=%202048"></p>
</section>
<section id="positional-encoding" class="level3">
<h3 class="anchored" data-anchor-id="positional-encoding">5. Positional encoding</h3>
<p>Multi-head attention cannot keep track of temporal information unless explicitly given.<sup>4</sup> In order for the model to make use of the order of the sequence, we must inject some information about the relative or absolute position of elements in the sequence. To achieve this, we add positional embeddings to the input embeddings. These embeddings carry the same dimension <img src="https://latex.codecogs.com/png.latex?d_%7B%5Ctext%7Bmodel%7D%7D"> as the embeddings, allowing them to be summed.</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Cdisplaylines%7B%0APE_%7Bpos,%202i%7D%20=%20sin(pos/10000%5E%7B2i/d_%5Ctext%7Bmodel%7D%7D)%20%5C%5C%0APE_%7Bpos,%202i+1%7D%20=%20cos(pos/10000%5E%7B2i/d_%5Ctext%7Bmodel%7D%7D)%0A%7D"></p>
</section>
<section id="tokenizer" class="level3">
<h3 class="anchored" data-anchor-id="tokenizer">6. Tokenizer</h3>
<p>The tokenizer converts</p>
</section>
</section>
<section id="footnotes" class="level1">
<h1>Footnotes</h1>


</section>


<div id="quarto-appendix" class="default"><section id="footnotes" class="footnotes footnotes-end-of-document"><h2 class="anchored quarto-appendix-heading">Footnotes</h2>

<ol>
<li id="fn1"><p>One crucial characteristic of the multi-head self-attention is that it is permutation-invariant with respect to its inputs. This means that if we switch between two inputs elements in the sequence, e.g.&nbsp;X1 &lt;-&gt; X2, the output is exactly the same besides the elements 1 and 2 switched. Read more <a href="https://uvadlc-notebooks.readthedocs.io/en/latest/tutorial_notebooks/tutorial6/Transformers_and_MHAttention.html#:~:text=One%20crucial%20characteristic%20of%20the,elements%201%20and%202%20switched.">here.</a>↩︎</p></li>
<li id="fn2"><p>Each head can be thought of as computing information from different representation subspaces, attending information from different positions. Using some inspiration from <a href="https://transformer-circuits.pub/2022/toy_model/index.html#phase-change">Toy Models of Superposition</a>, I opine that a head could be thought of as a coarse computation across different feature sets, which would benefit the availability of different heads.↩︎</p></li>
<li id="fn3"><p>I suppose that information flows where the gradient goes? I do not completely understand the reasons motivating this choice.↩︎</p></li>
<li id="fn4"><p>One crucial characteristic of the multi-head self-attention is that it is permutation-invariant with respect to its inputs. This means that if we switch between two inputs elements in the sequence, e.g.&nbsp;X1 &lt;-&gt; X2, the output is exactly the same besides the elements 1 and 2 switched. Read more <a href="https://uvadlc-notebooks.readthedocs.io/en/latest/tutorial_notebooks/tutorial6/Transformers_and_MHAttention.html#:~:text=One%20crucial%20characteristic%20of%20the,elements%201%20and%202%20switched.">here.</a>↩︎</p></li>
</ol>
</section></div> ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/reproducing-attention-is-all-you-need-from-scratch-pytorch/</guid>
  <pubDate>Sun, 24 May 2026 14:37:59 GMT</pubDate>
</item>
<item>
  <title>Rotating Emphasis Manipulation</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/rotating-emphasis-manipulation/</link>
  <description><![CDATA[ 





<p>Reference - <a href="Daniel Gopher, 1989 - Practice under changing priorities: An approach to the training of complex skills">https://www.sciencedirect.com/science/article/abs/pii/0001691889900073?via%3Dihub</a></p>
<section id="why" class="level1">
<h1>Why</h1>
<p>The core of <strong>expert performance</strong> is an <u>organised set of response strategies</u> than can be employed flexibly to meet task demands.</p>
<p>Subjects trained under <u>rotating emphasis manipulation</u> performed significantly better than control players, and experienced a <strong>continued advantage increase after experiment</strong> termination.</p>
</section>
<section id="what" class="level1">
<h1>What</h1>
<p>The schema model of executive function observes the formation of <strong>schemas</strong>, individual and indivisible units of control that can be composed together (many, and often multiple at the same time together) in order to meet the demands of a complex task.</p>
<p>When performing a complicated task, human subjects often have little knowledge of, and do not spontaneously <strong>explore, alternative strategies</strong>. When led to do so, performance improves.</p>
<p>Performance under high-attention load conditions benefits most when subjects are trained on <strong>several, varying levels of subelement priorities.</strong></p>
</section>
<section id="how" class="level1">
<h1>How</h1>
<p>Divide skills into core components, train individually, together and then experiments with their composition. This is aptly called <strong><a href="../part-whole-training/">Part-Whole training</a></strong>.</p>
<p>However, instead of training individual schemas in isolation of each other and in absence of the entire goal, only attempt to manipulate and assign the <strong>relative emphasis (priority)</strong> of selected subcomponents in a rotating manner.</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/rotating-emphasis-manipulation/</guid>
  <pubDate>Sun, 24 May 2026 14:37:43 GMT</pubDate>
</item>
<item>
  <title>speculative-decoding</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/speculative-decoding/</link>
  <description><![CDATA[ 





<section id="algorithm-for-greedy-sampling" class="level1">
<h1>Algorithm for greedy sampling</h1>
</section>
<section id="todo-make-the-sampling-safe-for-zero-division-errors" class="level1">
<h1>TODO: make the sampling safe for zero division errors</h1>
</section>
<section id="todo-add-stopping-condition-max_new_tokens-eos-token-for-verifier-and-draft-model-as-pointed-out-in-both-the-model-forward-pass-line-comments" class="level1">
<h1>TODO: add stopping condition (max_new_tokens, EOS token) for verifier and draft model as pointed out in both the model forward pass line comments</h1>
</section>
<section id="todo-implement-get_probs_from_logits" class="level1">
<h1>TODO: implement get_probs_from_logits</h1>
</section>
<section id="todo-convert-logits-to-probs-add-temperature" class="level1">
<h1>TODO: convert logits to probs, add temperature</h1>
</section>
<section id="todo-add-analysis-of-temperature-to-acceptance-rate" class="level1">
<h1>TODO: add analysis of temperature to acceptance rate</h1>
</section>
<section id="todo-add-sft-simple-for-both" class="level1">
<h1>TODO: add SFT simple for both</h1>
</section>
<section id="todo-add-rl-with-acceptance-rate" class="level1">
<h1>TODO: add RL with acceptance rate</h1>
<p>def remove_last_t_from_kvcache(kvcache, t): for i, (k_layer, v_layer) in enumerate(kvcache): if k_layer is not None: kvcache[i] = ( k_layer[:, :, :-t, :], # remove last num_to_remove keys v_layer[:, :, :-t, :] # remove last num_to_remove values ) ““” 1. Inference loop: - inputs object with keys “input_ids” and “attention_mask” # TODO: code currently works for mask of shape [1, L] but won’t for a 3d [1, L, L] square mask. - past_key_values_draft : (DynamicCache(config=draft_model.config)) - past_key_values_verifier: (DynamicCache(config=draft_model.config)) - k = 10 - max_new_tokens = 100 ““”</p>
</section>
<section id="initialize-generated_ids-for-the-recursion" class="level1">
<h1>initialize generated_ids for the recursion</h1>
<p>generated_ids = inputs[“input_ids”]</p>
</section>
<section id="infer-draft-model-k-times" class="level1">
<h1>infer draft model k times</h1>
<p>start_position = 0 if past_key_values_draft[0][0] is None else past_key_values_draft[0].shape[-2] draft_cache_position = torch.arange(start_position, inputs.input_ids.shape[1], dtype=torch.int64, device=draft_model.device) draft_logits = torch.empty_like(inputs.input_ids[:, 0:0]) # tensor of shape [N, 0]</p>
<p>for draft_iter in range(k): outputs = draft_model(**inputs, cache_position=draft_cache_position, past_key_values=past_key_values_draft, use_cache=True) # TODO: add stopping condition here.</p>
<pre><code># sampling - greedy
next_token_ids = outputs.logits[:, -1].argmax(-1)
draft_logits = torch.concat([draft_logits, outputs.logits[:, -1:, :]], dim=-2)

generated_ids = torch.cat([generated_ids, next_token_ids], dim=-1)
attention_mask = inputs["attention_mask"]
attention_mask = torch.cat([attention_mask, attention_mask.new_ones((attention_mask.shape[0], 1))], dim=-1)
inputs = {"input_ids": next_token_ids, "attention_mask": attention_mask}
draft_cache_position = draft_cache_position[-1:] + 1 # add one more position for the next token to be decoded.</code></pre>
</section>
<section id="run-verifier-in-parallel" class="level1">
<h1>run verifier in parallel</h1>
<p>inputs = {“input_ids”: generated_ids, “attention_mask”: inputs[“attention_mask”]} start_position = 0 if past_key_values_verifier[0][0] is None else past_key_values_verifier[0].shape[-2] verifier_cache_position = torch.arange(start_position, inputs.input_ids.shape[1], dtype=torch.int64, device=verifier_model.device) outputs = verifier_model(**inputs, cache_position=verifier_cache_position, past_key_values=past_key_values_verifier, use_cache=True) # TODO: add stopping condition here.</p>
</section>
<section id="determine-the-number-of-accepted-guesses-n" class="level1">
<h1>determine the number of accepted guesses n</h1>
<p>verifier_logits = outputs.logits[:, -(draft_logits.shape[-2]+1):-1, :] verifier_probs = verifier_logits.softmax(-1) draft_probs = draft_logits.softmax(-1) prob_ratios = verifier_probs / draft_probs # TODO: make the sampling safe for zero division errors? prob_ratios_per_token = torch.gather(prob_ratios, dim=-2, index=generated_ids.unsqueeze(dim=-2))</p>
<section id="sample-tokens-until-rejection-criteria-is-met" class="level2">
<h2 class="anchored" data-anchor-id="sample-tokens-until-rejection-criteria-is-met">sample tokens until rejection criteria is met</h2>
<section id="r1-u0-1-.-.-.-rγ-u0-1" class="level3">
<h3 class="anchored" data-anchor-id="r1-u0-1-.-.-.-rγ-u0-1">r1 ∼ U(0, 1), . . . , rγ ∼ U(0, 1)</h3>
<p>uniform_mask = torch.randn_like(prob_ratios_per_token) &gt; prob_ratios_per_token uniform_mask = torch.concat([uniform_mask, torch.ones(uniform_mask.shape[0], 1, dtype=torch.bool)]) # verifier token index, if all accept. ### n ← min({i − 1 | 1 ≤ i ≤ γ, ri &gt; pi(x) / qi(x)} ∪ {γ}) n = argmax(uniform_mask, dim=-1)</p>
</section>
</section>
</section>
<section id="destroy-the-last-k-n-key-values-from-draft-kvcache" class="level1">
<h1>destroy the last (k-n) key-values from draft kvcache</h1>
<section id="note-that-this-implementation-is-not-batched." class="level2">
<h2 class="anchored" data-anchor-id="note-that-this-implementation-is-not-batched.">note that this implementation is not batched.</h2>
<p>remove_last_t_from_kvcache(past_key_values_draft, k-n)</p>
</section>
</section>
<section id="destroy-the-last-k-n-key-values-from-verifier-kvcache" class="level1">
<h1>destroy the last (k-n) key-values from verifier kvcache</h1>
<p>remove_last_t_from_kvcache(past_key_values_verifier, k-n)</p>
</section>
<section id="adjust-the-final-token-from-verifier-if-needed" class="level1">
<h1>adjust the final token from verifier if needed</h1>
<p>if n &lt; k: extra_token_logits = norm * (max(0, draft_logits[:, -1-(k-n), :] - verifier_logits[:, -1-(k-n), :])) else: extra_token_logits = verifier_logits[:, -1:, :] extra_token_logits = extra_token_logits.unsqueeze(1)</p>
</section>
<section id="sample-one-extra-token-from-adjusted-distribution" class="level1">
<h1>sample one extra token from adjusted distribution</h1>
</section>
<section id="sampling---greedy" class="level1">
<h1>sampling - greedy</h1>
<p>extra_token = extra_token_logits.argmax(-1)</p>
</section>
<section id="add-the-generated-ids-to-inputs-object-to-close-the-recursion-and-adjust-attention-mask.-rebuild-attention-mask-entirely" class="level1">
<h1>add the generated ids to inputs object to close the recursion, and adjust attention mask. rebuild attention mask entirely?</h1>
<p>generated_ids = torch.concat([generated_ids, extra_token], dim=-1) attention_mask = attention_mask.new_ones((attention_mask.shape[0], generated_ids.shape[-1])) inputs = {“inputs”: generated_ids, “attention_mask”: attention_mask}</p>
<hr>
<p>if q(x) &lt;= p(x): q(x) if q(x) &gt; p(x): - sample (p(x) / q(x)) * ( q(x) ) + (1 - p(x) / q(x)) * ( norm(max(0, p(x) - q(x))) )</p>
<p>desired probability of selecting x: p(x) actual selection: q(x)</p>
<p>distribution that is being sampled from is:</p>
<p>note: alpha is the normalization constant multiplied with the random variable: alpha * (max(0, p(x) - q(x))) to get a probability distribution.</p>
<ol type="1">
<li>q(x) + alpha</li>
</ol>
<p>let us suppose there are two groups of events for the decoding of an N-vocabulary.</p>
<p>A = {xk : p(xi) &gt;= q(xi) for i in range(N)} R = {xk : p(xi) &lt; q(xi) for i in range(N)}</p>
<p>now, say that the probability that x ~ q(x) is in A is pA = sum( q(xi) * (1 if p(xi) &gt;= q(xi) else 0) ) and, say that the probability that x ~ p(x) is in R is pR = sum( q(xi) * (1 if p(xi) &lt; q(xi) else 0) )</p>
<p>now, we need to show that the final sampling results in the final token sampling probability being equal to p(x).</p>
<p>probability of a token xt (from set A) being sampled = pA * ( q(xt) / pA ) + pR * rejection probability * probabilty that xt is resampled from adjusted dist. = pA * (q(xt) / pA) + pR * rejection probability * norm * max(0, p(xt) - q(xt)) = q(xt) + pR * rejection probability * norm * (p(xt) - q(xt))</p>
<p>now, we need to compute norm and rejection prob. note: rejection probability in the above is conditioned on sample being from B. so lets compute it.</p>
<p>note: P is not p.&nbsp;P is probability of any event function while p is the verifier distribution on tokens. rejection prob. = P(sampled token is rejected | sampled token is from R) = [P(rejected and from R)] / [P(from R)] = [ sum( q(xi) * (1 - p(xi) / q(xi)) if p(xi) &lt; q(xi) else 0) ] / pR = [ sum(q(xi) - p(xi) if p(xi) &lt; q(xi) else 0) ] / pR</p>
<p>-&gt; probability of a token xt from set A being sampled = q(xt) + [ sum(q(xi) - p(xi) if p(xi) &lt; q(xi) else 0) ] * norm * (p(xt) - q(xt))</p>
<p>so, the normalizing constant <code>norm</code> comes out to be: norm = 1 / [ sum(q(xi) - p(xi) if p(xi) &lt; q(xi) else 0) ]</p>
<p>and, we have:</p>
<p>-&gt; probability of a token xt from set A being sampled = q(xt) + (p(xt) - q(xt)) = p(xt)</p>
<hr>
<p>similarly, let us compute: probability of a token xt (from set R) being sampled = pR * ( q(xt) / pR) * acceptance probability = q(xt) * ( p(xt) / q(xt) ) = p(xt)</p>
<hr>
<p>hence, we have proven the correctness of the sampling scheme and also found the normalizing constant.</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/speculative-decoding/</guid>
  <pubDate>Mon, 10 Nov 2025 18:30:00 GMT</pubDate>
  <media:content url="https://shrivastava95.github.io/blog-quarto/posts/speculative-decoding/assets/card-speculative-decoding.png" medium="image" type="image/png" height="117" width="144"/>
</item>
<item>
  <title>Measure Theory</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/measure-theory/</link>
  <description><![CDATA[ 





<div class="quarto-figure quarto-figure-center">
<figure class="figure">
<p><img src="https://shrivastava95.github.io/blog-quarto/posts/measure-theory/mt01.png" class="img-fluid figure-img"></p>
<figcaption>measure theory playlist by The Bright Side of Mathematics</figcaption>
</figure>
</div>
<section id="sigma-algebra" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> <img src="https://latex.codecogs.com/png.latex?%5Csigma">-Algebra</h1>
<p>A sigma algebra <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BA%7D"> on a set <img src="https://latex.codecogs.com/png.latex?X"> is a nonempty set of subsets of <img src="https://latex.codecogs.com/png.latex?X"> that is closed under complement, countable union, and countable intersection. In other words:</p>
<pre><code>$$\begin{aligned} &amp;\mathcal{A} \subseteq \mathcal{P}(X) \text{ is a } \sigma\text{-algebra on }X\text{ if:} \\ (a) \text{ } &amp;\phi, X \in \mathcal{A}&amp; \\ (b) \text{ } &amp; A \in \mathcal{A} \implies A^c \coloneqq X \setminus A \in \mathcal{A} \\ (c) \text{ } &amp; A_i \in \mathcal{A}, i \in \mathbb{N} \implies \bigcup^\infty_{i=1} A_i \in \mathcal{A}\end{aligned}$$</code></pre>
<p><img src="https://latex.codecogs.com/png.latex?A%20%5Cin%20%5Cmathcal%7BA%7D"> is also called a <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BA%7D">-measurable set. In other words, a measure (which is a kind of generalised notion of volume) can be assigned to a <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebra. This notion is formally established later in Measure</p>
<section id="borel-sigma-algebra" class="level3" data-number="1.0.1">
<h3 data-number="1.0.1" class="anchored" data-anchor-id="borel-sigma-algebra"><span class="header-section-number">1.0.1</span> Borel <img src="https://latex.codecogs.com/png.latex?%5Csigma">-Algebra</h3>
<p>For every <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BM%7D%20%5Csubseteq%20%5Cmathcal%7BP%7D(X)">, there is a smallest <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebra that contains <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BM%7D">:</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Csigma(%5Cmathcal%7BM%7D)%5Ccoloneqq%20%5Cbigcap_%7B%5Cbegin%7Baligned%7D%20&amp;%5Cmathcal%7BA%7D%5Csupseteq%20%5Cmathcal%7BM%7D%20%5C%5C%20&amp;%5Cmathcal%7BA%7D%20%5Ctext%7B%20%7D%20%5Csigma%20%5Ctext%7B-algebras%7D%20%5Cend%7Baligned%7D%7D%20%5Cmathcal%7BA%7D%20%5Cspace%20%5Cspace%20%5Cleftarrow%20%5Csigma%5Ctext%7B-algebra%20generated%20by%20%7D%5Cmathcal%7BM%7D"></p>
<p>Note that uncountable unions of <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebras (<img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BA%7D_i%20%5Csubseteq%20%5Cmathcal%7BP%7D(X),%20i%20%5Cin%20%5Ctext%7Bindex%20set%20(uncountable)%7D">) are again valid <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebras. Easily provable using the original <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebra definition.</p>
<p>A Borel <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebra on a topological space <img src="https://latex.codecogs.com/png.latex?(X,%20%5Ctau)"> (noted as <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BB%7D(X)">) is the <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebra generated by the open sets <img src="https://latex.codecogs.com/png.latex?%5Ctau">. In other words:</p>
<p><img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BB%7D(X)%5Ccoloneqq%20%5Csigma(%5Ctau)"></p>
<p>These Borel <img src="https://latex.codecogs.com/png.latex?%5Csigma">-algebras have some interesting properties that allow us to define a measure, or a generalised notion of volume, upon them, which we will later find is impossible to do on the entire powerset <img src="https://latex.codecogs.com/png.latex?%5Cmathcal%7BP%7D(X)"></p>
</section>
<section id="measure" class="level3" data-number="1.0.2">
<h3 data-number="1.0.2" class="anchored" data-anchor-id="measure"><span class="header-section-number">1.0.2</span> Measure</h3>
<p>Let us say that <img src="https://latex.codecogs.com/png.latex?(X,%20%5Cmathcal%7BA%7D)"> is a measurable space.</p>
<pre><code>$$\begin{aligned} &amp;\text{A map } \mu \colon \mathcal{A} \rightarrow [0, \infty) \cup\{\infty\} \text{ is called a measure if:} \\ (a) \space &amp; \mu(\phi) =  0\\ (b) \space &amp; \mu\biggl(\bigcup_{i=1}^n A_i \biggr) =  \sum_{i=1}^{n}\sigma(A_i), \space\space\space\space\space\space\space\space \text{with }A_i \cap A_j = \phi, i \neq j \text{ }\forall \text{ countable sequences } A_i \in \mathcal{A}\end{aligned}$$</code></pre>
<p>Collectively, <img src="https://latex.codecogs.com/png.latex?(X,%20%5Cmathcal%7BA%7D,%20%5Cmu)"> are referred to as a <em>measure space</em>.</p>


</section>
</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/measure-theory/</guid>
  <pubDate>Thu, 30 Jan 2025 08:31:10 GMT</pubDate>
</item>
<item>
  <title>Answer Key: Linear Algebra Course Quiz</title>
  <link>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-course-quiz/answer.html</link>
  <description><![CDATA[ 





<section id="answers" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> Answers</h1>
<ol type="1">
<li>(r(t)=(1,2)+t(3,-1)=(1+3t,2-t)).</li>
<li>It contains (0), and if (Au=0) and (Av=0), then (A(au+bv)=aAu+bAv=0).</li>
<li>The inner product is (2+0-3=-1); the norms are () and ().</li>
<li>().</li>
<li>().</li>
<li>If (A=[a_1&nbsp;&nbsp;a_n]), then (Ax=_i x_ia_i), so the columns encode the images of the standard basis vectors.</li>
<li>No: ((2,4)=2(1,2)).</li>
<li>Solve (a(1,1)+b(2,-1)=(5,1)), giving ().</li>
<li>().</li>
<li>((V)=(A)+(A)); dimensions split into independent output directions and input directions sent to zero.</li>
<li>Free variables are parameters; pivot variables are expressed in terms of them, producing infinitely many solutions when at least one free variable remains.</li>
<li>().</li>
<li>A square matrix is invertible iff ((A)).</li>
<li>(p_A()=(3-)(2-)).</li>
<li>For (), (E_3={(1,0)}); for (), (E_2={(-1,1)}).</li>
<li>A linear dependence among eigenvectors with distinct eigenvalues, acted on by (A), produces a second relation with distinct scalar factors; subtracting forces all coefficients to vanish.</li>
</ol>
</section>
<section id="grading" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Grading</h1>
<p>Award 2 points for a correct and explicit answer, 1 for the correct method with a minor error, and 0 for a missing or materially incorrect answer.</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-course-quiz/answer.html</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
<item>
  <title>Linear Algebra Course: An Eight-Unit Study Guide and Quiz</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-course-quiz/</link>
  <description><![CDATA[ 





<section id="scope" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> Scope</h1>
<p>This guide follows the public lessons retrieved from the <a href="https://www.youtube.com/playlist?list=PLBh2i93oe2quLc5zaxD0WHzQTGrXMwAI6">Linear Algebra playlist</a>. Members-only and unavailable lessons are excluded.</p>
</section>
<section id="unit-1-foundations-of-vector-spaces" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Unit 1 — Foundations of vector spaces</h1>
<p>Videos: 1, 2, 4, 5.</p>
<p>Vectors in (R^n) are tuples of scalars. A line through a point (p) with direction (v) is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL=%5C%7B%5Cmathbf%20p+t%5Cmathbf%20v:t%5Cin%5Cmathbb%20R%5C%7D.%0A"></p>
<p>A vector space is closed under vector addition and scalar multiplication and satisfies the vector-space axioms. A subspace (UV) must contain (0) and satisfy</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20u,%5Cmathbf%20v%5Cin%20U,%5C%20a,b%5Cin%5Cmathbb%20R%0A%5Cquad%5CLongrightarrow%5Cquad%0Aa%5Cmathbf%20u+b%5Cmathbf%20v%5Cin%20U.%0A"></p>
<p>Representative problem: determine whether the solution set of (x+2y-z=0) is a subspace of (R^3), and parameterize it.</p>
</section>
<section id="unit-2-subspaces-inner-products-and-geometry" class="level1" data-number="3">
<h1 data-number="3"><span class="header-section-number">3</span> Unit 2 — Subspaces, inner products, and geometry</h1>
<p>Videos: 6, 9, 10.</p>
<p>The Euclidean inner product and norm are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Clangle%5Cmathbf%20u,%5Cmathbf%20v%5Crangle=%5Csum_i%20u_iv_i,%0A%5Cqquad%0A%5C%7C%5Cmathbf%20v%5C%7C=%5Csqrt%7B%5Clangle%5Cmathbf%20v,%5Cmathbf%20v%5Crangle%7D.%0A"></p>
<p>The angle relation is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Clangle%5Cmathbf%20u,%5Cmathbf%20v%5Crangle=%5C%7C%5Cmathbf%20u%5C%7C%5C%7C%5Cmathbf%20v%5C%7C%5Ccos%5Ctheta.%0A"></p>
<p>In (R^3), (uv) is perpendicular to both inputs and has magnitude equal to the parallelogram area:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7C%5Cmathbf%20u%5Ctimes%5Cmathbf%20v%5C%7C=%5C%7C%5Cmathbf%20u%5C%7C%5C%7C%5Cmathbf%20v%5C%7C%5Csin%5Ctheta.%0A"></p>
<p>Representative problem: compute the projection of (u) onto nonzero (v):</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7Bproj%7D_%7B%5Cmathbf%20v%7D(%5Cmathbf%20u)=%0A%5Cfrac%7B%5Clangle%5Cmathbf%20u,%5Cmathbf%20v%5Crangle%7D%7B%5Clangle%5Cmathbf%20v,%5Cmathbf%20v%5Crangle%7D%5Cmathbf%20v.%0A"></p>
</section>
<section id="unit-3-matrices-and-linear-maps" class="level1" data-number="4">
<h1 data-number="4"><span class="header-section-number">4</span> Unit 3 — Matrices and linear maps</h1>
<p>Videos: 11, 13, 14, 16, 17, 19, 20.</p>
<p>A linear map satisfies</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AT(a%5Cmathbf%20u+b%5Cmathbf%20v)=aT(%5Cmathbf%20u)+bT(%5Cmathbf%20v).%0A"></p>
<p>For a matrix (A=[a_1&nbsp;&nbsp;a_n]),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA%5Cmathbf%20x=x_1%5Cmathbf%20a_1+%5Ccdots+x_n%5Cmathbf%20a_n.%0A"></p>
<p>Composition is matrix multiplication:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(AB)%5Cmathbf%20x=A(B%5Cmathbf%20x).%0A"></p>
<p>The matrix of a linear map is determined by the images of the standard basis vectors. Special matrices include diagonal, triangular, symmetric, and identity matrices.</p>
<p>Representative problem: find the matrix of (T(x,y)=(2x-y,x+3y)), then compute (T(1,2)).</p>
</section>
<section id="unit-4-independence-bases-coordinates-and-dimension" class="level1" data-number="5">
<h1 data-number="5"><span class="header-section-number">5</span> Unit 4 — Independence, bases, coordinates, and dimension</h1>
<p>Videos: 22, 23, 25, 26, 28.</p>
<p>Vectors (v_1,,v_k) are linearly independent when</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ac_1%5Cmathbf%20v_1+%5Ccdots+c_k%5Cmathbf%20v_k=0%0A%5Cquad%5CLongrightarrow%5Cquad%0Ac_1=%5Ccdots=c_k=0.%0A"></p>
<p>A basis is an independent spanning set. Coordinates relative to a basis (B=(b_1,,b_n)) satisfy</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20v=%5B%5Cmathbf%20v%5D_B%7B%7D_1%5Cmathbf%20b_1+%5Ccdots+%5B%5Cmathbf%20v%5D_B%7B%7D_n%5Cmathbf%20b_n.%0A"></p>
<p>The exchange lemma explains why all bases of a finite-dimensional space have the same number of vectors: the dimension.</p>
<p>Representative problem: express ((5,1)) in the basis ({(1,1),(2,-1)}).</p>
</section>
<section id="unit-5-inverses-and-transposes" class="level1" data-number="6">
<h1 data-number="6"><span class="header-section-number">6</span> Unit 5 — Inverses and transposes</h1>
<p>Videos: 29, 31, 32.</p>
<p>An inverse satisfies</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AAA%5E%7B-1%7D=A%5E%7B-1%7DA=I.%0A"></p>
<p>For a (2) matrix,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Bbmatrix%7Da&amp;b%5C%5Cc&amp;d%5Cend%7Bbmatrix%7D%5E%7B-1%7D%0A=%5Cfrac1%7Bad-bc%7D%5Cbegin%7Bbmatrix%7Dd&amp;-b%5C%5C-c&amp;a%5Cend%7Bbmatrix%7D,%0A%5Cqquad%20ad-bc%5Cne0.%0A"></p>
<p>The transpose is defined by</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(A%5ET)_%7Bij%7D=A_%7Bji%7D,%0A%5Cqquad%20(AB)%5ET=B%5ETA%5ET.%0A"></p>
Representative problem: find the inverse of (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D2&amp;1%5C%5C1&amp;1%5Cend%7Bbmatrix%7D">
<p>) and verify it by multiplication.</p>
</section>
<section id="unit-6-range-kernel-rank-nullity-and-solving-systems" class="level1" data-number="7">
<h1 data-number="7"><span class="header-section-number">7</span> Unit 6 — Range, kernel, rank-nullity, and solving systems</h1>
<p>Videos: 34, 35, 37, 38, 40, 42.</p>
<p>The kernel and range are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cker(A)=%5C%7B%5Cmathbf%20x:A%5Cmathbf%20x=0%5C%7D,%0A%5Cqquad%0A%5Coperatorname%7Brange%7D(A)=%5C%7BA%5Cmathbf%20x:%5Cmathbf%20x%5Cin%20V%5C%7D.%0A"></p>
<p>The rank-nullity theorem is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdim(V)=%5Coperatorname%7Brank%7D(A)+%5Coperatorname%7Bnullity%7D(A).%0A"></p>
<p>Row operations preserve the solution set of a system when applied to its augmented matrix. In row-echelon form, pivot variables are determined and free variables parameterize the remaining solutions.</p>
<p>Representative problem: row-reduce an augmented matrix and state whether the system has no solution, one solution, or infinitely many solutions.</p>
</section>
<section id="unit-7-determinants" class="level1" data-number="8">
<h1 data-number="8"><span class="header-section-number">8</span> Unit 7 — Determinants</h1>
<p>Videos: 43, 44, 46, 47, 48, 50, 51.</p>
<p>For a (2) matrix,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdet%5Cbegin%7Bbmatrix%7Da&amp;b%5C%5Cc&amp;d%5Cend%7Bbmatrix%7D=ad-bc.%0A"></p>
<p>The determinant is multilinear and alternating, and satisfies</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdet(AB)=%5Cdet(A)%5Cdet(B).%0A"></p>
<p>For an (nn) matrix, Laplace expansion along row (i) is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdet(A)=%5Csum_j(-1)%5E%7Bi+j%7Da_%7Bij%7D%5Cdet(A_%7Bij%7D).%0A"></p>
<p>Geometrically, (|(A)|) is volume scaling. A square matrix is invertible exactly when its determinant is nonzero.</p>
Representative problem: compute the determinant of (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D1&amp;2&amp;3%5C%5C0&amp;4&amp;5%5C%5C1&amp;0&amp;6%5Cend%7Bbmatrix%7D">
<p>) by expansion or elimination.</p>
</section>
<section id="unit-8-eigenvalues-and-eigenvectors" class="level1" data-number="9">
<h1 data-number="9"><span class="header-section-number">9</span> Unit 8 — Eigenvalues and eigenvectors</h1>
<p>Videos: 53, 54, 55.</p>
<p>An eigenvector is a nonzero vector satisfying</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA%5Cmathbf%20v=%5Clambda%5Cmathbf%20v.%0A"></p>
<p>Eigenvalues solve the characteristic equation</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ap_A(%5Clambda)=%5Cdet(A-%5Clambda%20I)=0.%0A"></p>
<p>The algebraic multiplicity of an eigenvalue is its multiplicity as a root of (p_A). Eigenvectors for () form the eigenspace</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AE_%5Clambda=%5Cker(A-%5Clambda%20I).%0A"></p>
Representative problem: find the eigenvalues and eigenspaces of (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D3&amp;1%5C%5C0&amp;2%5Cend%7Bbmatrix%7D">
<p>).</p>
</section>
<section id="quiz" class="level1" data-number="10">
<h1 data-number="10"><span class="header-section-number">10</span> Quiz</h1>
<p>Attempt this closed-notes. Each question is worth 2 points.</p>
<ol type="1">
<li>Parameterize the line through ((1,2)) parallel to ((3,-1)).</li>
<li>Prove that the solution set of a homogeneous linear system is a subspace.</li>
<li>Compute ((1,2,-1),(2,0,3)) and both vector norms.</li>
<li>Compute ((1,2,0)(2,-1,1)).</li>
<li>Find the matrix of (T(x,y)=(2x-y,x+3y)).</li>
<li>Explain why the columns of a matrix determine its matrix-vector product.</li>
<li>Test whether ((1,2)) and ((2,4)) are linearly independent.</li>
<li>Find the coordinates of ((5,1)) in the basis ({(1,1),(2,-1)}).</li>
<li>Find the inverse of (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D2&amp;1%5C%5C1&amp;1%5Cend%7Bbmatrix%7D">
).</li>
<li>State and interpret the rank-nullity theorem.</li>
<li>Describe how free variables appear in a row-echelon solution.</li>
<li>Compute (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D4&amp;1%5C%5C2&amp;3%5Cend%7Bbmatrix%7D">
).</li>
<li>State the determinant criterion for invertibility.</li>
<li>Find the characteristic polynomial of (
<img src="https://latex.codecogs.com/png.latex?%5Cbegin%7Bbmatrix%7D3&amp;1%5C%5C0&amp;2%5Cend%7Bbmatrix%7D">
).</li>
<li>Find the eigenspaces of that matrix.</li>
<li>Explain why eigenvectors belonging to distinct eigenvalues are linearly independent.</li>
</ol>
<section id="scoring" class="level2" data-number="10.1">
<h2 data-number="10.1" class="anchored" data-anchor-id="scoring"><span class="header-section-number">10.1</span> Scoring</h2>
<ul>
<li>28–32: ready for proof-heavy linear algebra.</li>
<li>20–27: review the units containing missed questions.</li>
<li>Below 20: revisit Units 1, 3, 4, and 6 before continuing.</li>
</ul>
<p>See the <a href="../../posts/linear-algebra-course-quiz/answer.html">answer key</a> after attempting the quiz.</p>


</section>
</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-course-quiz/</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
<item>
  <title>Answer Key: Essential Linear Algebra Quiz</title>
  <link>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-quiz/answer.html</link>
  <description><![CDATA[ 





<section id="answers" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> Answers</h1>
<ol type="1">
<li>The equations are (a+2b=7) and (2a-b=1), giving <img src="https://latex.codecogs.com/png.latex?%0A%5Cboxed%7Ba=%5Cfrac95,%5Cquad%20b=%5Cfrac%7B13%7D5%7D.%0A"></li>
<li>The set must span the space and be linearly independent.</li>
<li>The columns are (T(1,0)) and (T(0,1)), so <img src="https://latex.codecogs.com/png.latex?%0A%5Cboxed%7BA=%5Cbegin%7Bbmatrix%7D1&amp;2%5C%5C3&amp;-1%5Cend%7Bbmatrix%7D%7D.%0A"></li>
<li><img src="https://latex.codecogs.com/png.latex?%0A%5Cboxed%7B%5Cbegin%7Bbmatrix%7D4%5C%5C10%5Cend%7Bbmatrix%7D%7D.%0A"></li>
<li>Adding the equations gives (3x=6), so (oxed{x=2,y=3}).</li>
<li>Yes, since (1(2)+2(-1)+3(0)=0).</li>
<li><img src="https://latex.codecogs.com/png.latex?%0A%5Cboxed%7B%5Cbegin%7Bbmatrix%7D-1%5C%5C2%5C%5C1%5Cend%7Bbmatrix%7D%7D.%0A"></li>
<li>(oxed{10}).</li>
<li>Since (A) is triangular, the eigenvalues are its diagonal entries: (oxed{4,2}).</li>
<li>Write (c_1(1+x)+c_2x+c_3x<sup>2=2+5x-x</sup>2). Thus (oxed{[p]_{B}=[2,3,-1]^T}).</li>
<li>Applying (B) and then (A) gives (A(Bx)=(AB)x), so (AB) represents composition.</li>
<li>A zero determinant collapses volume into a lower-dimensional set, so distinct inputs can map to the same output; therefore no inverse exists.</li>
</ol>
</section>
<section id="grading" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Grading</h1>
<p>Questions 1–10 are computational and worth 2 points each. Questions 11–12 are conceptual and worth 2 points each. Award 1 point for the correct method with an arithmetic or notation error, and 2 for a correct, explicit answer.</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-quiz/answer.html</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
<item>
  <title>Essential Linear Algebra: A Five-Unit Quiz</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-quiz/</link>
  <description><![CDATA[ 





<section id="how-to-use-this-guide" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> How to use this guide</h1>
<p>Study one unit, solve its representative problem, and only then attempt the final quiz. The sequence follows the conceptual dependencies in the 3Blue1Brown <em>Essence of Linear Algebra</em> playlist.</p>
</section>
<section id="unit-1-vectors-combinations-and-bases" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Unit 1 — Vectors, combinations, and bases</h1>
<p>A vector is an ordered list of scalars:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20v=%5Cbegin%7Bbmatrix%7Dv_1%5C%5Cv_2%5C%5C%5Cvdots%5C%5Cv_n%5Cend%7Bbmatrix%7D.%0A"></p>
<p>The essential operations are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20u+%5Cmathbf%20v=%5Cbegin%7Bbmatrix%7Du_1+v_1%5C%5Cu_2+v_2%5Cend%7Bbmatrix%7D,%0A%5Cqquad%20c%5Cmathbf%20v=%5Cbegin%7Bbmatrix%7Dcv_1%5C%5Ccv_2%5Cend%7Bbmatrix%7D.%0A"></p>
<p>A linear combination has the form</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ac_1%5Cmathbf%20v_1+%5Ccdots+c_k%5Cmathbf%20v_k.%0A"></p>
<p>A basis is a linearly independent spanning set. Coordinates tell us which linear combination of the basis vectors produces a vector.</p>
<section id="representative-problem" class="level2" data-number="2.1">
<h2 data-number="2.1" class="anchored" data-anchor-id="representative-problem"><span class="header-section-number">2.1</span> Representative problem</h2>
<p>Find (a,b) such that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Aa%5Cbegin%7Bbmatrix%7D1%5C%5C2%5Cend%7Bbmatrix%7D+b%5Cbegin%7Bbmatrix%7D2%5C%5C-1%5Cend%7Bbmatrix%7D=%5Cbegin%7Bbmatrix%7D7%5C%5C1%5Cend%7Bbmatrix%7D.%0A"></p>
</section>
</section>
<section id="unit-2-linear-transformations-and-matrices" class="level1" data-number="3">
<h1 data-number="3"><span class="header-section-number">3</span> Unit 2 — Linear transformations and matrices</h1>
<p>A transformation (T) is linear when</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AT(%5Cmathbf%20u+%5Cmathbf%20v)=T(%5Cmathbf%20u)+T(%5Cmathbf%20v),%0A%5Cqquad%20T(c%5Cmathbf%20v)=cT(%5Cmathbf%20v).%0A"></p>
<p>Every linear transformation can be written as</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AT(%5Cmathbf%20x)=A%5Cmathbf%20x.%0A"></p>
<p>The columns of (A) are the images of the standard basis vectors. Matrix multiplication is composition:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(AB)%5Cmathbf%20x=A(B%5Cmathbf%20x).%0A"></p>
<p>For a (2) matrix,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Cbegin%7Bbmatrix%7Da&amp;b%5C%5Cc&amp;d%5Cend%7Bbmatrix%7D,%0A%5Cqquad%20%5Cdet(A)=ad-bc.%0A"></p>
<p>The matrix is invertible exactly when its determinant is nonzero.</p>
<section id="representative-problem-1" class="level2" data-number="3.1">
<h2 data-number="3.1" class="anchored" data-anchor-id="representative-problem-1"><span class="header-section-number">3.1</span> Representative problem</h2>
<p>For</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Cbegin%7Bbmatrix%7D2&amp;1%5C%5C0&amp;3%5Cend%7Bbmatrix%7D,%0A"></p>
<p>compute (A[1,2]^T), (det(A)), and decide whether (A) is invertible.</p>
</section>
</section>
<section id="unit-3-systems-dot-products-and-cross-products" class="level1" data-number="4">
<h1 data-number="4"><span class="header-section-number">4</span> Unit 3 — Systems, dot products, and cross products</h1>
<p>A linear system is represented by</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA%5Cmathbf%20x=%5Cmathbf%20b.%0A"></p>
<p>The dot product is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20u%5Ccdot%5Cmathbf%20v=%5Csum_i%20u_iv_i=%5C%7C%5Cmathbf%20u%5C%7C%5C%7C%5Cmathbf%20v%5C%7C%5Ccos%5Ctheta.%0A"></p>
<p>Perpendicular vectors have dot product zero.</p>
<p>In three dimensions,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbf%20u%5Ctimes%5Cmathbf%20v=%0A%5Cbegin%7Bbmatrix%7D%0Au_2v_3-u_3v_2%5C%5C%0Au_3v_1-u_1v_3%5C%5C%0Au_1v_2-u_2v_1%0A%5Cend%7Bbmatrix%7D.%0A"></p>
<p>The cross product is perpendicular to both inputs, and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7C%5Cmathbf%20u%5Ctimes%5Cmathbf%20v%5C%7C=%5C%7C%5Cmathbf%20u%5C%7C%5C%7C%5Cmathbf%20v%5C%7C%5Csin%5Ctheta.%0A"></p>
<section id="representative-problem-2" class="level2" data-number="4.1">
<h2 data-number="4.1" class="anchored" data-anchor-id="representative-problem-2"><span class="header-section-number">4.1</span> Representative problem</h2>
<p>For (mathbf u=[1,2,0]^T) and (mathbf v=[2,-1,1]^T), compute (mathbf uv) and (mathbf uv).</p>
</section>
</section>
<section id="unit-4-determinants-basis-changes-and-eigenvalues" class="level1" data-number="5">
<h1 data-number="5"><span class="header-section-number">5</span> Unit 4 — Determinants, basis changes, and eigenvalues</h1>
<p>Important determinant identities are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdet(AB)=%5Cdet(A)%5Cdet(B),%0A%5Cqquad%20%5Cdet(A%5E%7B-1%7D)=%5Cfrac1%7B%5Cdet(A)%7D.%0A"></p>
<p>Eigenvectors satisfy</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA%5Cmathbf%20v=%5Clambda%5Cmathbf%20v,%0A%5Cqquad%20%5Cmathbf%20v%5Cne%5Cmathbf0.%0A"></p>
<p>Eigenvalues solve the characteristic equation</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cdet(A-%5Clambda%20I)=0.%0A"></p>
<p>If (A) has enough independent eigenvectors, then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=PDP%5E%7B-1%7D,%0A%5Cqquad%20A%5En=PD%5EnP%5E%7B-1%7D.%0A"></p>
<p>For a (2) matrix,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Clambda_1+%5Clambda_2=%5Coperatorname%7Btr%7D(A),%0A%5Cqquad%20%5Clambda_1%5Clambda_2=%5Cdet(A).%0A"></p>
<section id="representative-problem-3" class="level2" data-number="5.1">
<h2 data-number="5.1" class="anchored" data-anchor-id="representative-problem-3"><span class="header-section-number">5.1</span> Representative problem</h2>
<p>Find the eigenvalues and eigenvectors of</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Cbegin%7Bbmatrix%7D3&amp;1%5C%5C0&amp;2%5Cend%7Bbmatrix%7D.%0A"></p>
</section>
</section>
<section id="unit-5-abstract-vector-spaces" class="level1" data-number="6">
<h1 data-number="6"><span class="header-section-number">6</span> Unit 5 — Abstract vector spaces</h1>
<p>Vectors need not be arrows: polynomials, matrices, functions, and sequences can also form vector spaces. For the polynomial basis</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20B=%5C%7B1,x,x%5E2%5C%7D,%0A"></p>
<p>the polynomial (p(x)=4-2x+3x^2) has coordinate vector</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Bp%5D_%7B%5Cmathcal%20B%7D=%5Cbegin%7Bbmatrix%7D4%5C%5C-2%5C%5C3%5Cend%7Bbmatrix%7D.%0A"></p>
<p>The same ideas—span, independence, basis, coordinates, and linear transformations—apply in every vector space.</p>
<section id="representative-problem-4" class="level2" data-number="6.1">
<h2 data-number="6.1" class="anchored" data-anchor-id="representative-problem-4"><span class="header-section-number">6.1</span> Representative problem</h2>
<p>Express (p(x)=2+5x-x^2) in coordinates relative to</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20B=%5C%7B1+x,x,x%5E2%5C%7D.%0A"></p>
</section>
</section>
<section id="quiz" class="level1" data-number="7">
<h1 data-number="7"><span class="header-section-number">7</span> Quiz</h1>
<p>Attempt these closed-notes first. Each question is worth 2 points.</p>
<ol type="1">
<li>Find (a,b) such that (a[1,2]<sup>T+b[2,-1]</sup>T=[7,1]^T).</li>
<li>State the two conditions a set must satisfy to be a basis.</li>
<li>Find the matrix for (T(x,y)=(x+2y,3x-y)).</li>
<li>Compute <img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Bbmatrix%7D1&amp;2%5C%5C3&amp;4%5Cend%7Bbmatrix%7D%5Cbegin%7Bbmatrix%7D2%5C%5C1%5Cend%7Bbmatrix%7D.%0A"></li>
<li>Solve (x+y=5) and (2x-y=1).</li>
<li>Are ([1,2,3]^T) and ([2,-1,0]^T) perpendicular?</li>
<li>Compute ([1,0,1]<sup>T</sup>T).</li>
<li>Find the determinant of ([]).</li>
<li>Find the eigenvalues of ([]).</li>
<li>Express (2+5x-x^2) in the basis ({1+x,x,x^2}).</li>
<li>Explain why matrix multiplication represents composition of transformations.</li>
<li>Explain why the determinant being zero prevents invertibility.</li>
</ol>
<section id="scoring" class="level2" data-number="7.1">
<h2 data-number="7.1" class="anchored" data-anchor-id="scoring"><span class="header-section-number">7.1</span> Scoring</h2>
<ul>
<li>20–24: ready for a cumulative problem set.</li>
<li>14–19: review the missed units and retry.</li>
<li>0–13: work through the representative problems slowly, then retake the quiz.</li>
</ul>
<p>The <a href="../../posts/linear-algebra-quiz/answer.html">answer key</a> gives worked solutions.</p>


</section>
</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/linear-algebra-quiz/</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
<item>
  <title>ANSWER KEY TO PRIVILEGED BASIS AND RELU QUIZ</title>
  <link>https://shrivastava95.github.io/blog-quarto/posts/privileged-basis/answer.html</link>
  <description><![CDATA[ 





<section id="answer-sheet" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> answer sheet</h1>
<p><a href="../../posts/privileged-basis/index.html">Here is the answer sheet - index.qmd</a></p>
</section>
<section id="grading-rule" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Grading rule</h1>
<p>Each main question is worth (2) points.</p>
<ul>
<li>(0): absent, materially false, circular, or confuses object types;</li>
<li>(1): correct central idea with a missing definition, assumption, or proof step;</li>
<li>(2): correct, explicit, and type-consistent.</li>
</ul>
<p>Equivalent formulations are acceptable.</p>
</section>
<section id="part-i-measurability-and-information" class="level1" data-number="3">
<h1 data-number="3"><span class="header-section-number">3</span> Part I — Measurability and information</h1>
<section id="answer-1" class="level2" data-number="3.1">
<h2 data-number="3.1" class="anchored" data-anchor-id="answer-1"><span class="header-section-number">3.1</span> Answer 1</h2>
<p>A sigma-algebra (F^) satisfies:</p>
<ol type="1">
<li>(F);</li>
<li>(EFE^cF);</li>
<li>(E_nF) for all (n_{n=1}^E_nF).</li>
</ol>
<p>A probability space is a triple</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(%5COmega,%5Cmathcal%20F,%5Cmathbb%20P)%0A"></p>
<p>where (F) is a sigma-algebra and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P:%5Cmathcal%20F%5Cto%5B0,1%5D%0A"></p>
<p>satisfies</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P(%5COmega)=1%0A"></p>
<p>and countable additivity on pairwise disjoint events.</p>
</section>
<section id="answer-2" class="level2" data-number="3.2">
<h2 data-number="3.2" class="anchored" data-anchor-id="answer-2"><span class="header-section-number">3.2</span> Answer 2</h2>
<p>For (G):</p>
<ul>
<li>(,G);</li>
<li>complements swap ({1,2}) and ({3,4});</li>
<li>every countable union reduces to one of the four listed sets.</li>
</ul>
<p>Thus (G) is a sigma-algebra.</p>
<p>For (H), note</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7B1,2%5C%7D%5Ccup%5C%7B1,3%5C%7D%0A=%0A%5C%7B1,2,3%5C%7D%5Cnotin%5Cmathcal%20H.%0A"></p>
<p>Therefore (H) is not closed under unions and is not a sigma-algebra.</p>
</section>
<section id="answer-3" class="level2" data-number="3.3">
<h2 data-number="3.3" class="anchored" data-anchor-id="answer-3"><span class="header-section-number">3.3</span> Answer 3</h2>
<p>(X) is measurable iff</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5E%7B-1%7D(B)%5Cin%5Cmathcal%20F%0A%5Cqquad%0A%5Cforall%20B%5Cin%5Cmathcal%20E.%0A"></p>
<p>Preimages are used because they preserve complements and arbitrary unions:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5E%7B-1%7D(B%5Ec)%0A=%0A(X%5E%7B-1%7D(B))%5Ec,%0A"></p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5E%7B-1%7D%5Cleft(%5Cbigcup_n%20B_n%5Cright)%0A=%0A%5Cbigcup_nX%5E%7B-1%7D(B_n).%0A"></p>
<p>Images do not generally preserve complements or intersections in the required way.</p>
</section>
<section id="answer-4" class="level2" data-number="3.4">
<h2 data-number="3.4" class="anchored" data-anchor-id="answer-4"><span class="header-section-number">3.4</span> Answer 4</h2>
<p>For any (CS),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(f%5Ccirc%20X)%5E%7B-1%7D(C)%0A=%0AX%5E%7B-1%7D(f%5E%7B-1%7D(C)).%0A"></p>
<p>Since (f) is measurable,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Af%5E%7B-1%7D(C)%5Cin%5Cmathcal%20E.%0A"></p>
<p>Since (X) is measurable,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5E%7B-1%7D(f%5E%7B-1%7D(C))%5Cin%5Cmathcal%20F.%0A"></p>
<p>Hence (fX) is measurable.</p>
</section>
<section id="answer-5" class="level2" data-number="3.5">
<h2 data-number="3.5" class="anchored" data-anchor-id="answer-5"><span class="header-section-number">3.5</span> Answer 5</h2>
<p>The fibres of (X) are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AF_0=%5C%7B%5Comega_1,%5Comega_2%5C%7D,%0A%5Cqquad%0AF_1=%5C%7B%5Comega_3%5C%7D,%0A%5Cqquad%0AF_2=%5C%7B%5Comega_4%5C%7D.%0A"></p>
<p>Therefore ((X)) consists of every union of these fibres:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Csigma(X)=%5C%7B&amp;%0A%5Cvarnothing,%5COmega,%0AF_0,F_1,F_2,%5C%5C%0A&amp;F_0%5Ccup%20F_1,%0AF_0%5Ccup%20F_2,%0AF_1%5Ccup%20F_2%0A%5C%7D.%0A%5Cend%7Baligned%7D%0A"></p>
<p>Observing (X) distinguishes the three fibres but cannot distinguish (_1) from (_2).</p>
</section>
<section id="answer-6" class="level2" data-number="3.6">
<h2 data-number="3.6" class="anchored" data-anchor-id="answer-6"><span class="header-section-number">3.6</span> Answer 6</h2>
<p>The atomic masses are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P_X(%5C%7B0%5C%7D)%0A=%0A0.1+0.2%0A=%0A0.3,%0A"></p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P_X(%5C%7B1%5C%7D)%0A=%0A0.3,%0A"></p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P_X(%5C%7B2%5C%7D)%0A=%0A0.4.%0A"></p>
<p>Therefore:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Barray%7D%7Bc%7Cc%7D%0AB&amp;%5Cmathbb%20P_X(B)%5C%5C%0A%5Chline%0A%5Cvarnothing&amp;0%5C%5C%0A%5C%7B0%5C%7D&amp;0.3%5C%5C%0A%5C%7B1%5C%7D&amp;0.3%5C%5C%0A%5C%7B2%5C%7D&amp;0.4%5C%5C%0A%5C%7B0,1%5C%7D&amp;0.6%5C%5C%0A%5C%7B0,2%5C%7D&amp;0.7%5C%5C%0A%5C%7B1,2%5C%7D&amp;0.7%5C%5C%0A%5C%7B0,1,2%5C%7D&amp;1%0A%5Cend%7Barray%7D%0A"></p>
</section>
<section id="answer-7" class="level2" data-number="3.7">
<h2 data-number="3.7" class="anchored" data-anchor-id="answer-7"><span class="header-section-number">3.7</span> Answer 7</h2>
<p>In the real- or Euclidean-valued setting used here:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY%5Ctext%7B%20is%20%7D%5Csigma(X)%5Ctext%7B-measurable%7D%0A%5Ciff%0A%5Cexists%5Ctext%7B%20measurable%20%7Df%5Ctext%7B%20such%20that%20%7DY=f(X).%0A"></p>
<p>An estimator that uses only the information contained in (A) must be ((A))-measurable. The theorem then gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cwidehat%20Z=g(A)%0A"></p>
<p>for some measurable (g). Conversely, every measurable (g(A)) is ((A))-measurable.</p>
</section>
<section id="answer-8" class="level2" data-number="3.8">
<h2 data-number="3.8" class="anchored" data-anchor-id="answer-8"><span class="header-section-number">3.8</span> Answer 8</h2>
<ol type="1">
<li>(A) is a measurable map (R^d).</li>
<li>(a) is a deterministic vector in (R^d).</li>
<li>((A)) is a collection of subsets of (), specifically a sub-sigma-algebra of (F).</li>
<li>({AB}=A^{-1}(B)) is an event in (F).</li>
<li>(E[ZA]) is a random vector, defined up to almost-sure equality, and is ((A))-measurable.</li>
</ol>
</section>
<section id="answer-9" class="level2" data-number="3.9">
<h2 data-number="3.9" class="anchored" data-anchor-id="answer-9"><span class="header-section-number">3.9</span> Answer 9</h2>
<p>The map</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Az%5Cmapsto%20Qz%0A"></p>
<p>is linear and continuous, hence Borel measurable.</p>
<p>Coordinatewise ReLU</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ar(y)_i=%5Cmax(0,y_i)%0A"></p>
<p>is continuous, hence Borel measurable.</p>
<p>Since (Z) is measurable and compositions of measurable maps are measurable,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=r%5Ccirc%20Q%5Ccirc%20Z%0A"></p>
<p>is measurable.</p>
</section>
</section>
<section id="part-ii-conditional-expectation" class="level1" data-number="4">
<h1 data-number="4"><span class="header-section-number">4</span> Part II — Conditional expectation</h1>
<section id="answer-10" class="level2" data-number="4.1">
<h2 data-number="4.1" class="anchored" data-anchor-id="answer-10"><span class="header-section-number">4.1</span> Answer 10</h2>
<p>A conditional expectation (Y=E[XG]) satisfies:</p>
<ol type="1">
<li>(Y) is (G)-measurable;</li>
<li>(YL^1);</li>
<li>for every (GG), <img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_G%5D%0A=%0A%5Cmathbb%20E%5BY1_G%5D.%0A"></li>
</ol>
<p>It is unique up to almost-sure equality.</p>
</section>
<section id="answer-11" class="level2" data-number="4.2">
<h2 data-number="4.2" class="anchored" data-anchor-id="answer-11"><span class="header-section-number">4.2</span> Answer 11</h2>
<p>The two atoms of (G) are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AG_1=%5C%7B1,2%5C%7D,%0A%5Cqquad%0AG_2=%5C%7B3,4%5C%7D.%0A"></p>
<p>On (G_1),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%20G_1%5D%0A=%0A%5Cfrac%7B0.1(2)+0.2(-1)%7D%7B0.1+0.2%7D%0A=%0A0.%0A"></p>
<p>On (G_2),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%20G_2%5D%0A=%0A%5Cfrac%7B0.3(4)+0.4(0)%7D%7B0.3+0.4%7D%0A=%0A%5Cfrac%7B12%7D%7B7%7D.%0A"></p>
<p>Hence</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%0A=%0A%5Cleft(0,0,%5Cfrac%7B12%7D%7B7%7D,%5Cfrac%7B12%7D%7B7%7D%5Cright).%0A"></p>
</section>
<section id="answer-12" class="level2" data-number="4.3">
<h2 data-number="4.3" class="anchored" data-anchor-id="answer-12"><span class="header-section-number">4.3</span> Answer 12</h2>
<p>The events in (G) are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cvarnothing,%5COmega,G_1,G_2.%0A"></p>
<p>For (), both sides are zero.</p>
<p>For (G_1),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_%7BG_1%7D%5D%0A=%0A0.1(2)+0.2(-1)%0A=%0A0,%0A"></p>
<p>while</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D1_%7BG_1%7D%5D%0A=%0A0.%0A"></p>
<p>For (G_2),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_%7BG_2%7D%5D%0A=%0A1.2,%0A"></p>
<p>while</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D1_%7BG_2%7D%5D%0A=%0A(0.3+0.4)%5Cfrac%7B12%7D%7B7%7D%0A=%0A1.2.%0A"></p>
<p>For (), add the two block identities.</p>
</section>
<section id="answer-13" class="level2" data-number="4.4">
<h2 data-number="4.4" class="anchored" data-anchor-id="answer-13"><span class="header-section-number">4.4</span> Answer 13</h2>
<p>(X) itself is (G)-measurable and integrable. For every (GG),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_G%5D%0A=%0A%5Cmathbb%20E%5BX1_G%5D.%0A"></p>
<p>Thus (X) satisfies the defining properties of (E[XG]). By almost-sure uniqueness,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D=X%0A%5Cquad%5Ctext%7Ba.s.%7D%0A"></p>
</section>
<section id="answer-14" class="level2" data-number="4.5">
<h2 data-number="4.5" class="anchored" data-anchor-id="answer-14"><span class="header-section-number">4.5</span> Answer 14</h2>
<p>The constant (E[X]) is (G)-measurable. For (GG), independence gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_G%5D%0A=%0A%5Cmathbb%20E%5BX%5D%5Cmathbb%20E%5B1_G%5D%0A=%0A%5Cmathbb%20E%5BX%5D%5Cmathbb%20P(G).%0A"></p>
<p>Also,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5D1_G%5D%0A=%0A%5Cmathbb%20E%5BX%5D%5Cmathbb%20P(G).%0A"></p>
<p>Hence the constant (E[X]) satisfies the defining property.</p>
</section>
<section id="answer-15" class="level2" data-number="4.6">
<h2 data-number="4.6" class="anchored" data-anchor-id="answer-15"><span class="header-section-number">4.6</span> Answer 15</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY=%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%5Cmid%5Cmathcal%20H%5D.%0A"></p>
<p>Then (Y) is (H)-measurable.</p>
<p>For every (HH), since (HG),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Cmathbb%20E%5BY1_H%5D%0A&amp;=%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D1_H%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5BX1_H%5D.%0A%5Cend%7Baligned%7D%0A"></p>
<p>Thus (Y) satisfies the defining property of (E[XH]). Uniqueness gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY=%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20H%5D%0A%5Cquad%5Ctext%7Ba.s.%7D%0A"></p>
</section>
<section id="answer-16" class="level2" data-number="4.7">
<h2 data-number="4.7" class="anchored" data-anchor-id="answer-16"><span class="header-section-number">4.7</span> Answer 16</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Write</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX-%5Cmathbb%20E%5BX%5D%0A=%0A(X-m)+(m-%5Cmathbb%20E%5BX%5D).%0A"></p>
<p>Then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Coperatorname%7BVar%7D(X)%0A&amp;=%0A%5Cmathbb%20E%5B(X-m)%5E2%5D%0A+%0A%5Cmathbb%20E%5B(m-%5Cmathbb%20E%5BX%5D)%5E2%5D%5C%5C%0A&amp;%5Cquad+%0A2%5Cmathbb%20E%5B(X-m)(m-%5Cmathbb%20E%5BX%5D)%5D.%0A%5Cend%7Baligned%7D%0A"></p>
<p>The cross term is zero because (m-E[X]) is (G)-measurable:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Cmathbb%20E%5B(X-m)(m-%5Cmathbb%20E%5BX%5D)%5D%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Cmathbb%20E%5B(X-m)(m-%5Cmathbb%20E%5BX%5D)%5Cmid%5Cmathcal%20G%5D%0A%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%0A(m-%5Cmathbb%20E%5BX%5D)%0A%5Cmathbb%20E%5BX-m%5Cmid%5Cmathcal%20G%5D%0A%5D%5C%5C%0A&amp;=0.%0A%5Cend%7Baligned%7D%0A"></p>
<p>Also,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(X-m)%5E2%5D%0A=%0A%5Cmathbb%20E%5B%5Coperatorname%7BVar%7D(X%5Cmid%5Cmathcal%20G)%5D,%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(m-%5Cmathbb%20E%5BX%5D)%5E2%5D%0A=%0A%5Coperatorname%7BVar%7D(m).%0A"></p>
</section>
<section id="answer-17" class="level2" data-number="4.8">
<h2 data-number="4.8" class="anchored" data-anchor-id="answer-17"><span class="header-section-number">4.8</span> Answer 17</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BZ%5Cmid%5Cmathcal%20G%5D,%0A%5Cqquad%0A%5Cmu=%5Cmathbb%20E%5BZ%5D.%0A"></p>
<p>Use</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ-%5Cmu=(Z-m)+(m-%5Cmu)%0A"></p>
<p>and expand the outer product. The cross terms vanish because</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ-m%5Cmid%5Cmathcal%20G%5D=0.%0A"></p>
<p>Thus</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Coperatorname%7BCov%7D(Z)%0A&amp;=%0A%5Cmathbb%20E%5B(Z-m)(Z-m)%5ET%5D%0A+%0A%5Cmathbb%20E%5B(m-%5Cmu)(m-%5Cmu)%5ET%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G)%5D%0A+%0A%5Coperatorname%7BCov%7D(m).%0A%5Cend%7Baligned%7D%0A"></p>
<p>Expectation of a random matrix is taken entrywise.</p>
</section>
<section id="answer-18" class="level2" data-number="4.9">
<h2 data-number="4.9" class="anchored" data-anchor-id="answer-18"><span class="header-section-number">4.9</span> Answer 18</h2>
<p>By definition,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G)%0A=%0A%5Cmathbb%20E%5B(Z-m)(Z-m)%5ET%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Using linearity of trace and conditional expectation,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G))%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D((Z-m)(Z-m)%5ET)%0A%5Cmid%5Cmathcal%20G%0A%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%5C%7CZ-m%5C%7C%5E2%5Cmid%5Cmathcal%20G%5D.%0A%5Cend%7Baligned%7D%0A"></p>
<p>Taking expectations and applying the tower property gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G))%0A%5D%0A=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2.%0A"></p>
</section>
<section id="answer-19" class="level2" data-number="4.10">
<h2 data-number="4.10" class="anchored" data-anchor-id="answer-19"><span class="header-section-number">4.10</span> Answer 19</h2>
<p>If (A&gt;0), then (Z=A).</p>
<p>If (A=0), then (Z), and conditionally (Z) is uniform on ([-1,0]). Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A=0%5D%0A=%0A-%5Cfrac12,%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BVar%7D(Z%5Cmid%20A=0)%0A=%0A%5Cfrac%7B1%7D%7B12%7D.%0A"></p>
<p>Hence</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ah(a)%0A=%0A%5Cbegin%7Bcases%7D%0A-%5Cfrac12,&amp;a=0,%5C%5C%0Aa,&amp;a%3E0.%0A%5Cend%7Bcases%7D%0A"></p>
<p>The conditional variance is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BVar%7D(Z%5Cmid%20A)%0A=%0A%5Cbegin%7Bcases%7D%0A%5Cfrac1%7B12%7D,&amp;A=0,%5C%5C%0A0,&amp;A%3E0.%0A%5Cend%7Bcases%7D%0A"></p>
<p>Since (P(A=0)=1/2),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BMMSE%7D%0A=%0A%5Cfrac12%5Ccdot%5Cfrac1%7B12%7D%0A=%0A%5Cfrac1%7B24%7D.%0A"></p>
</section>
<section id="answer-20" class="level2" data-number="4.11">
<h2 data-number="4.11" class="anchored" data-anchor-id="answer-20"><span class="header-section-number">4.11</span> Answer 20</h2>
<p>If (A&gt;0), then (Z=A).</p>
<p>If (A=0), then (Z), so</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A=0%5D%0A=%0A-%5Csqrt%7B%5Cfrac2%5Cpi%7D.%0A"></p>
<p>Thus</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ah(a)%0A=%0A%5Cbegin%7Bcases%7D%0A-%5Csqrt%7B%5Cfrac2%5Cpi%7D,&amp;a=0,%5C%5C%0Aa,&amp;a%3E0.%0A%5Cend%7Bcases%7D%0A"></p>
<p>All conditional error occurs on (A=0). Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BMMSE%7D%0A=%0A%5Cmathbb%20P(Z%5Cle0)%0A%5Coperatorname%7BVar%7D(Z%5Cmid%20Z%5Cle0)%0A=%0A%5Cfrac12%5Cleft(1-%5Cfrac2%5Cpi%5Cright).%0A"></p>
</section>
<section id="answer-21" class="level2" data-number="4.12">
<h2 data-number="4.12" class="anchored" data-anchor-id="answer-21"><span class="header-section-number">4.12</span> Answer 21</h2>
<p>For continuously distributed (A),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P(A=a)=0%0A"></p>
<p>for each fixed (a), so the elementary ratio divides by zero.</p>
<p>The primary object is instead</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%5Csigma(A)%5D,%0A"></p>
<p>defined by measurability and integral identities. Under standard regularity conditions it has a version</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ah(A),%0A"></p>
<p>and one may use (h(a)) as a version of (E[ZA=a]). Values of (h) on sets of (A)-measure zero are arbitrary.</p>
</section>
<section id="answer-22" class="level2" data-number="4.13">
<h2 data-number="4.13" class="anchored" data-anchor-id="answer-22"><span class="header-section-number">4.13</span> Answer 22</h2>
<p>Since (Z) almost surely,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Coperatorname%7BReLU%7D(Z)=Z%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A%5D%0A=%0AA%0A=%0AZ%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>and the MMSE is zero.</p>
</section>
</section>
<section id="part-iii-l2-geometry-and-mmse" class="level1" data-number="5">
<h1 data-number="5"><span class="header-section-number">5</span> Part III — (L^2) geometry and MMSE</h1>
<section id="answer-23" class="level2" data-number="5.1">
<h2 data-number="5.1" class="anchored" data-anchor-id="answer-23"><span class="header-section-number">5.1</span> Answer 23</h2>
<p><img src="https://latex.codecogs.com/png.latex?%0AL%5E2(%5COmega,%5Cmathcal%20F,%5Cmathbb%20P)%0A=%0A%5C%7BX:%5COmega%5Cto%5Cmathbb%20R:%0AX%5Ctext%7B%20measurable%20and%20%7D%5Cmathbb%20E%5BX%5E2%5D%3C%5Cinfty%5C%7D/%5C!%5Csim%0A"></p>
<p>where</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5Csim%20Y%0A%5Ciff%0AX=Y%5Cquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>The inner product and norm are</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Clangle%20X,Y%5Crangle%0A=%0A%5Cmathbb%20E%5BXY%5D,%0A"></p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7CX%5C%7C_%7BL%5E2%7D%0A=%0A%5Csqrt%7B%5Cmathbb%20E%5BX%5E2%5D%7D.%0A"></p>
<p>If (X=Y) a.s., then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7CX-Y%5C%7C_%7BL%5E2%7D=0.%0A"></p>
<p>A normed space must identify zero-distance objects.</p>
</section>
<section id="answer-24" class="level2" data-number="5.2">
<h2 data-number="5.2" class="anchored" data-anchor-id="answer-24"><span class="header-section-number">5.2</span> Answer 24</h2>
<p><img src="https://latex.codecogs.com/png.latex?%0AL%5E2(%5COmega,%5Cmathcal%20G,%5Cmathbb%20P)%0A"></p>
<p>is the set of square-integrable (G)-measurable random variables modulo a.s. equality.</p>
<p>If (X,Y) are (G)-measurable, then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AaX+bY%0A"></p>
<p>is (G)-measurable for (a,bR), and remains square-integrable. Hence it is a linear subspace.</p>
<p>The projection theorem requires the subspace to be <strong>closed</strong>. This subspace is indeed closed in (L^2).</p>
</section>
<section id="answer-25" class="level2" data-number="5.3">
<h2 data-number="5.3" class="anchored" data-anchor-id="answer-25"><span class="header-section-number">5.3</span> Answer 25</h2>
<p>Let (M) be a nonempty closed linear subspace of a Hilbert space (H). For each (xH), there is a unique (mM) such that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7Cx-m%5C%7C%0A=%0A%5Cinf_%7Bv%5Cin%20M%7D%5C%7Cx-v%5C%7C.%0A"></p>
<p>This (m=P_Mx) is equivalently characterized by</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ax-m%5Cperp%20M,%0A"></p>
<p>meaning</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Clangle%20x-m,v%5Crangle=0%0A%5Cqquad%0A%5Cforall%20v%5Cin%20M.%0A"></p>
</section>
<section id="answer-26" class="level2" data-number="5.4">
<h2 data-number="5.4" class="anchored" data-anchor-id="answer-26"><span class="header-section-number">5.4</span> Answer 26</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>For (V=1_G), (GG), the defining property gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(X-m)1_G%5D=0.%0A"></p>
<p>By linearity, this holds for every (G)-measurable simple function (V).</p>
<p>For general (VL^2(G)), choose simple (V_nV) in (L^2). Since (X-mL^2), Cauchy–Schwarz gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%7C%5Cmathbb%20E%5B(X-m)(V-V_n)%5D%7C%0A%5Cle%0A%5C%7CX-m%5C%7C_2%5C%7CV-V_n%5C%7C_2%0A%5Cto0.%0A"></p>
<p>Since each</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(X-m)V_n%5D=0,%0A"></p>
<p>the limit is zero.</p>
</section>
<section id="answer-27" class="level2" data-number="5.5">
<h2 data-number="5.5" class="anchored" data-anchor-id="answer-27"><span class="header-section-number">5.5</span> Answer 27</h2>
<p>Write</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ-T=(Z-m)+(m-T).%0A"></p>
<p>Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5C%7CZ-T%5C%7C%5E2%0A&amp;=%0A%5C%7CZ-m%5C%7C%5E2+%5C%7Cm-T%5C%7C%5E2%5C%5C%0A&amp;%5Cquad+2(Z-m)%5ET(m-T).%0A%5Cend%7Baligned%7D%0A"></p>
<p>Taking expectations, the cross term is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(Z-m)%5ET(m-T)%5D.%0A"></p>
<p>The vector (m-T) is (G)-measurable, while</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ-m%5Cmid%5Cmathcal%20G%5D=0.%0A"></p>
<p>Hence</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5Cmathbb%20E%5B(Z-m)%5ET(m-T)%5D%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Cmathbb%20E%5B(Z-m)%5ET(m-T)%5Cmid%5Cmathcal%20G%5D%0A%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Cmathbb%20E%5BZ-m%5Cmid%5Cmathcal%20G%5D%5ET(m-T)%0A%5D%5C%5C%0A&amp;=0.%0A%5Cend%7Baligned%7D%0A"></p>
<p>The decomposition follows.</p>
</section>
<section id="answer-28" class="level2" data-number="5.6">
<h2 data-number="5.6" class="anchored" data-anchor-id="answer-28"><span class="header-section-number">5.6</span> Answer 28</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20G=%5Csigma(A).%0A"></p>
<p>Every admissible estimator using only (A) is a square-integrable (G)-measurable random vector and therefore has the form (g(A)), up to a.s. equality.</p>
<p>Set</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BZ%5Cmid%20A%5D.%0A"></p>
<p>Question 27 gives</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5C%7CZ-g(A)%5C%7C%5E2%0A=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2%0A+%0A%5Cmathbb%20E%5C%7Cm-g(A)%5C%7C%5E2.%0A"></p>
<p>The second term is nonnegative and is zero for (g(A)=m). Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cinf_g%0A%5Cmathbb%20E%5C%7CZ-g(A)%5C%7C%5E2%0A=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2.%0A"></p>
<p>The minimizer is unique as an element of (L^2), hence unique up to almost-sure equality.</p>
<p>If a candidate (g(A)) is not square-integrable, its squared risk is infinite or not an admissible finite-risk competitor.</p>
</section>
<section id="answer-29" class="level2" data-number="5.7">
<h2 data-number="5.7" class="anchored" data-anchor-id="answer-29"><span class="header-section-number">5.7</span> Answer 29</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BZ%5Cmid%20A%5D.%0A"></p>
<p>Then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0AL(Q)%0A&amp;=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Cmathbb%20E%5B%5C%7CZ-m%5C%7C%5E2%5Cmid%20A%5D%0A%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%0A%5Cmathbb%20E%5B(Z-m)(Z-m)%5ET%5Cmid%20A%5D%0A)%0A%5D%5C%5C%0A&amp;=%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%0A%5D.%0A%5Cend%7Baligned%7D%0A"></p>
<p>The second equality is the tower property. The third uses</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5C%7Cx%5C%7C%5E2=%5Coperatorname%7Btr%7D(xx%5ET).%0A"></p>
</section>
<section id="answer-30" class="level2" data-number="5.8">
<h2 data-number="5.8" class="anchored" data-anchor-id="answer-30"><span class="header-section-number">5.8</span> Answer 30</h2>
<p>Since</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%0A=%0A%5Cmathbb%20E%5C%7CZ-%5Cmathbb%20E%5BZ%5Cmid%20A%5D%5C%7C%5E2,%0A"></p>
<p>we have (L(Q)=0) iff</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=%5Cmathbb%20E%5BZ%5Cmid%20A%5D%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>The right-hand side is ((A))-measurable, so this is equivalent to (Z) being ((A))-measurable up to a.s. equality.</p>
<p>By the factorization theorem, this is equivalent to the existence of measurable (g) with</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=g(A)%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>This only requires recovery on a set carrying probability one. The deterministic observation map may fail to be injective elsewhere, including on points or sets that the law of (Z) never visits.</p>
</section>
<section id="answer-31" class="level2" data-number="5.9">
<h2 data-number="5.9" class="anchored" data-anchor-id="answer-31"><span class="header-section-number">5.9</span> Answer 31</h2>
<p>The unrestricted class contains every measurable square-integrable function of (A). The affine class contains only</p>
<p><img src="https://latex.codecogs.com/png.latex?%0ABA+b.%0A"></p>
<p>The unrestricted optimum is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A%5D.%0A"></p>
<p>Example: let (AN(0,1)) and define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=A%5E2.%0A"></p>
<p>Then (Z) is already known from (A), so</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A%5D=A%5E2%0A"></p>
<p>and the unrestricted MMSE is zero.</p>
<p>No affine function (bA+c) equals (A^2) almost surely under a nondegenerate Gaussian law. Hence the best affine risk is strictly positive.</p>
</section>
<section id="answer-32" class="level2" data-number="5.10">
<h2 data-number="5.10" class="anchored" data-anchor-id="answer-32"><span class="header-section-number">5.10</span> Answer 32</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY=QZ.%0A"></p>
<p>Since (ZN(0,I_d)) and (Q) is orthogonal,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY%5Csim%5Cmathcal%20N(0,I_d).%0A"></p>
<p>Also,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=Q%5ETY%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Coperatorname%7BReLU%7D(Y).%0A"></p>
<p>For any decoder (g), define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ah(a)=Qg(a).%0A"></p>
<p>This is a bijection between measurable decoders (g) and measurable decoders (h). Since (Q) preserves norms,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cbegin%7Baligned%7D%0A%5C%7CZ-g(A)%5C%7C%0A&amp;=%0A%5C%7CQZ-Qg(A)%5C%7C%5C%5C%0A&amp;=%0A%5C%7CY-h(%5Coperatorname%7BReLU%7D(Y))%5C%7C.%0A%5Cend%7Baligned%7D%0A"></p>
<p>Therefore</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%0A=%0A%5Cinf_h%0A%5Cmathbb%20E%5C%7C%0AY-h(%5Coperatorname%7BReLU%7D(Y))%0A%5C%7C%5E2.%0A"></p>
<p>The right-hand side depends only on the distribution of (Y), which is (N(0,I_d)) for every (Q). Hence (L(Q)) is constant.</p>
</section>
</section>
<section id="bridge-problems" class="level1" data-number="6">
<h1 data-number="6"><span class="header-section-number">6</span> Bridge problems</h1>
<section id="bridge-1" class="level2" data-number="6.1">
<h2 data-number="6.1" class="anchored" data-anchor-id="bridge-1"><span class="header-section-number">6.1</span> Bridge 1</h2>
<p>If (Z) coordinatewise almost surely, then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BReLU%7D(Z)=Z%0A"></p>
<p>almost surely. At (Q=I),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=Z,%0A"></p>
<p>so (g(a)=a) reconstructs (Z) exactly. Thus (L(I)=0).</p>
<p>Sparsity and the exponential amplitude distribution are irrelevant because only nonnegativity is used.</p>
</section>
<section id="bridge-2" class="level2" data-number="6.2">
<h2 data-number="6.2" class="anchored" data-anchor-id="bridge-2"><span class="header-section-number">6.2</span> Bridge 2</h2>
<p>The collision argument is incomplete because:</p>
<ol type="1">
<li>the two points may both have probability zero;</li>
<li>one or both points may lie outside the support of (Z);</li>
<li>the collision may occur only on a null subset of latent space;</li>
<li>the conditional law given the shared observation may still be degenerate almost surely;</li>
<li>for continuous distributions, pointwise collisions do not by themselves establish positive conditional variance on a positive-probability set of observations.</li>
</ol>
<p>The required claim is probabilistic, not merely set-theoretic.</p>
</section>
<section id="bridge-3" class="level2" data-number="6.3">
<h2 data-number="6.3" class="anchored" data-anchor-id="bridge-3"><span class="header-section-number">6.3</span> Bridge 3</h2>
<p>Since</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%0A=%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%0A%5D,%0A"></p>
<p>and the integrand is nonnegative,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%3E0%0A"></p>
<p>iff</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%3E0%0A"></p>
<p>with positive probability.</p>
<p>A concrete sufficient condition is: there exists a measurable set (B) in observation space with</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P(A%5Cin%20B)%3E0%0A"></p>
<p>and a constant (&gt;0) such that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%0A%5Cge%5Cvarepsilon%0A"></p>
<p>almost surely on ({AB}). Then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%5Cge%0A%5Cvarepsilon%5C,%5Cmathbb%20P(A%5Cin%20B)%3E0.%0A"></p>
<p>The uniform lower bound can be weakened; it is enough that the nonnegative conditional trace be positive on a set of positive probability.</p>
</section>
<section id="bridge-4" class="level2" data-number="6.4">
<h2 data-number="6.4" class="anchored" data-anchor-id="bridge-4"><span class="header-section-number">6.4</span> Bridge 4</h2>
<p>Here</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AQZ%0A=%0A%5Cfrac1%7B%5Csqrt2%7D%0A%5Cbegin%7Bbmatrix%7D%0AZ_1-Z_2%5C%5C%0AZ_1+Z_2%0A%5Cend%7Bbmatrix%7D.%0A"></p>
<p>Since (Z_1,Z_2),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA_2=%5Cfrac%7BZ_1+Z_2%7D%7B%5Csqrt2%7D.%0A"></p>
<p>Also,</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA_1%0A=%0A%5Cfrac%7B(Z_1-Z_2)_+%7D%7B%5Csqrt2%7D.%0A"></p>
<p>On the region</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A0%3CZ_1%3CZ_2,%0A"></p>
<p>we observe</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA_1=0,%0A%5Cqquad%0AA_2=%5Cfrac%7BZ_1+Z_2%7D%7B%5Csqrt2%7D.%0A"></p>
<p>Thus the observation reveals the sum but not the split.</p>
<p>A rigorous positivity proof can proceed by:</p>
<ol type="1">
<li>restricting to the event that both coordinates are active;</li>
<li>identifying the joint density on (0&lt;z_1&lt;z_2);</li>
<li>changing variables to <img src="https://latex.codecogs.com/png.latex?%0As=z_1+z_2,%0A%5Cqquad%0Au=z_1;%0A"></li>
<li>showing that, conditional on a nontrivial interval of sums (s), the variable (u) has a nondegenerate conditional density on <img src="https://latex.codecogs.com/png.latex?%0A0%3Cu%3Cs/2;%0A"></li>
<li>concluding that <img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BVar%7D(Z_1%5Cmid%20A)%3E0%0A"> on a positive-probability set of observations;</li>
<li>hence <img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%3E0%0A"> there and (L(Q)&gt;0).</li>
</ol>
<p>The main technical issue is that conditioning on an exact continuous value of the sum requires a regular conditional distribution or a density calculation. Merely drawing the fibre is not enough.</p>


</section>
</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/privileged-basis/answer.html</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
<item>
  <title>Prerequisite Study Guide: ReLU Privileged-Basis Reconstruction</title>
  <dc:creator>Ishaan Shrivastava</dc:creator>
  <link>https://shrivastava95.github.io/blog-quarto/posts/privileged-basis/</link>
  <description><![CDATA[ 





<section id="purpose" class="level1" data-number="1">
<h1 data-number="1"><span class="header-section-number">1</span> Purpose</h1>
<p>The target object is</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%0A=%0A%5Cinf_g%0A%5Cmathbb%20E%5C!%5Cleft%5B%0A%5Cleft%5C%7CZ-g(%5Coperatorname%7BReLU%7D(QZ))%5Cright%5C%7C%5E2%0A%5Cright%5D.%0A"></p>
<p>Your existing notes already cover the algebraic prerequisites:</p>
<ul>
<li>expectation,</li>
<li>covariance,</li>
<li>independence,</li>
<li>finite second moments,</li>
<li>norms, traces, and outer products.</li>
</ul>
<p>This guide covers only the remaining load-bearing material:</p>
<ol type="1">
<li>measurable spaces, measurable maps, generated sigma-algebras, and laws;</li>
<li>conditional expectation, tower property, and conditional variance;</li>
<li>conditional expectation as an orthogonal projection in (L^2), hence the MMSE theorem.</li>
</ol>
</section>
<section id="primary-reading" class="level1" data-number="2">
<h1 data-number="2"><span class="header-section-number">2</span> Primary reading</h1>
<p>Use:</p>
<p><strong>Nima Moshayedi, <em>Lectures on Probability Theory</em>, University of Zurich</strong></p>
<p><a href="https://arxiv.org/pdf/2010.16280" class="uri">https://arxiv.org/pdf/2010.16280</a></p>
<p>The page numbers below refer to the printed page numbers in the notes.</p>
<section id="level-1-information-and-measurability" class="level2" data-number="2.1">
<h2 data-number="2.1" class="anchored" data-anchor-id="level-1-information-and-measurability"><span class="header-section-number">2.1</span> Level 1 — Information and measurability</h2>
<p>Read only:</p>
<ul>
<li>Appendix A, §1, <strong>Measurable Spaces</strong>, pp.&nbsp;143–144.</li>
<li>Appendix A, §3, <strong>Borel Sets</strong>, pp.&nbsp;146–147.</li>
<li>Appendix A, §5, <strong>Measurable Maps</strong>, pp.&nbsp;151–152.</li>
<li>Chapter 2, §1 and §1.1, <strong>General Definitions</strong> and <strong>Law of a Random Variable</strong>, pp.&nbsp;25–28.</li>
<li>Chapter 2, §2.4 and Proposition 2.2, <strong>Sigma-algebras generated by a random variable</strong>, pp.&nbsp;33–34.</li>
</ul>
<p>You should leave this level knowing precisely:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX:(%5COmega,%5Cmathcal%20F)%5Cto(E,%5Cmathcal%20E)%0A"></p>
<p>is measurable iff</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX%5E%7B-1%7D(B)%5Cin%5Cmathcal%20F%0A%5Cqquad%0A%5Ctext%7Bfor%20every%20%7DB%5Cin%5Cmathcal%20E,%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Csigma(X)%0A=%0A%5C%7BX%5E%7B-1%7D(B):B%5Cin%5Cmathcal%20E%5C%7D.%0A"></p>
<p>The crucial factorization theorem is:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY%5Ctext%7B%20is%20%7D%5Csigma(X)%5Ctext%7B-measurable%7D%0A%5Ciff%0AY=f(X)%0A"></p>
<p>for some measurable (f), in the setting used here.</p>
</section>
<section id="level-2-conditional-expectation" class="level2" data-number="2.2">
<h2 data-number="2.2" class="anchored" data-anchor-id="level-2-conditional-expectation"><span class="header-section-number">2.2</span> Level 2 — Conditional expectation</h2>
<p>Read only:</p>
<ul>
<li>Chapter 3, §2.2, <strong>Discrete construction</strong>, pp.&nbsp;80–82.</li>
<li>Chapter 3, §2.3 through Theorem 2.18, <strong>General construction and basic properties</strong>, pp.&nbsp;82–84.</li>
<li>Theorem 2.29, <strong>Tower property</strong>, p.&nbsp;86.</li>
</ul>
<p>Skip on the first pass:</p>
<ul>
<li>the Radon–Nikodym construction;</li>
<li>transition kernels;</li>
<li>martingales.</li>
</ul>
<p>You should leave this level knowing that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%0A"></p>
<p>is a (G)-measurable random variable satisfying</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_G%5D%0A=%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D1_G%5D%0A%5Cqquad%0A%5Ctext%7Bfor%20every%20%7DG%5Cin%5Cmathcal%20G,%0A"></p>
<p>and that, for (HG),</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%5Cmid%5Cmathcal%20H%5D%0A=%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20H%5D.%0A"></p>
</section>
<section id="level-3-l2-geometry-and-mmse" class="level2" data-number="2.3">
<h2 data-number="2.3" class="anchored" data-anchor-id="level-3-l2-geometry-and-mmse"><span class="header-section-number">2.3</span> Level 3 — (L^2) geometry and MMSE</h2>
<p>Read only:</p>
<ul>
<li>Chapter 3, §1, <strong>(L^2(,F,P)) as a Hilbert space</strong>, pp.&nbsp;73–75.</li>
<li>Chapter 3, §1.2, <strong>Orthogonal projection</strong>, pp.&nbsp;78–79.</li>
<li>Definitions 2.12 and 2.15 and Remarks 2.13–2.14, pp.&nbsp;82–83.</li>
<li>The first two paragraphs of §4.1.2, pp.&nbsp;90–91, emphasizing the distinction between:
<ul>
<li>projection onto all ((A))-measurable functions;</li>
<li>projection onto the much smaller linear span of the observed variables.</li>
</ul></li>
</ul>
<p>You should leave this level able to prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5C%7CZ-g(A)%5C%7C%5E2%0A=%0A%5Cmathbb%20E%5C%7CZ-%5Cmathbb%20E%5BZ%5Cmid%20A%5D%5C%7C%5E2%0A+%0A%5Cmathbb%20E%5C%7C%5Cmathbb%20E%5BZ%5Cmid%20A%5D-g(A)%5C%7C%5E2.%0A"></p>
<p>This identity is the actual reason conditional expectation is the MMSE decoder.</p>
</section>
</section>
<section id="optional-terse-reference" class="level1" data-number="3">
<h1 data-number="3"><span class="header-section-number">3</span> Optional terse reference</h1>
<p>For a compact formal reference:</p>
<p><strong>Matija Vidmar, <em>Probability with Measure</em></strong></p>
<p><a href="https://arxiv.org/pdf/2604.01685" class="uri">https://arxiv.org/pdf/2604.01685</a></p>
<p>Relevant sections:</p>
<ul>
<li>§1.1, measurable sets;</li>
<li>§1.3, measurable maps and generated sigma-fields;</li>
<li>§3.3, conditioning.</li>
</ul>
<p>Do not use this as the first exposition unless you prefer definition-dense notes.</p>
</section>
<section id="how-to-use-the-quiz" class="level1" data-number="4">
<h1 data-number="4"><span class="header-section-number">4</span> How to use the quiz</h1>
<p>Do three passes.</p>
<ol type="1">
<li><strong>Closed-notes pass:</strong> attempt every question without reading the answer key.</li>
<li><strong>Open-notes repair pass:</strong> repair incomplete definitions and proofs.</li>
<li><strong>Compression pass:</strong> rewrite each starred proof in at most ten lines without omitting assumptions.</li>
</ol>
<p>Each ordinary question is worth (2) points:</p>
<ul>
<li>(0): absent, materially false, or circular;</li>
<li>(1): right idea but missing a required definition, assumption, or proof step;</li>
<li>(2): correct and explicit.</li>
</ul>
<p>A starred question is load-bearing. A zero on any starred question means the corresponding level is not yet secure, regardless of total score.</p>
</section>
<section id="quiz" class="level1" data-number="5">
<h1 data-number="5"><span class="header-section-number">5</span> Quiz</h1>
</section>
<section id="part-i-measurability-and-information" class="level1" data-number="6">
<h1 data-number="6"><span class="header-section-number">6</span> Part I — Measurability and information</h1>
<section id="question-1-sigma-algebra" class="level2" data-number="6.1">
<h2 data-number="6.1" class="anchored" data-anchor-id="question-1-sigma-algebra"><span class="header-section-number">6.1</span> Question 1 ★ — Sigma-algebra</h2>
<p>State the definition of a sigma-algebra (F) on a set ().</p>
<p>Then state the definition of a probability space</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(%5COmega,%5Cmathcal%20F,%5Cmathbb%20P).%0A"></p>
<p>Do not explain by analogy. Give the axioms.</p>
</section>
<section id="question-2-finite-examples" class="level2" data-number="6.2">
<h2 data-number="6.2" class="anchored" data-anchor-id="question-2-finite-examples"><span class="header-section-number">6.2</span> Question 2 — Finite examples</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5COmega=%5C%7B1,2,3,4%5C%7D%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20G%0A=%0A%5C%7B%5Cvarnothing,%5COmega,%5C%7B1,2%5C%7D,%5C%7B3,4%5C%7D%5C%7D.%0A"></p>
<ol type="1">
<li>Prove that (G) is a sigma-algebra.</li>
<li>Let <img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20H%0A=%0A%5Cmathcal%20G%5Ccup%5C%7B%5C%7B1,3%5C%7D,%5C%7B2,4%5C%7D%5C%7D.%0A"> Is (H) a sigma-algebra? Prove your answer.</li>
</ol>
</section>
<section id="question-3-measurable-map" class="level2" data-number="6.3">
<h2 data-number="6.3" class="anchored" data-anchor-id="question-3-measurable-map"><span class="header-section-number">6.3</span> Question 3 ★ — Measurable map</h2>
<p>Let ((,F)) and ((E,E)) be measurable spaces.</p>
<p>State precisely what it means for</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX:%5COmega%5Cto%20E%0A"></p>
<p>to be measurable.</p>
<p>Why is the definition written using <strong>preimages</strong>, not images?</p>
</section>
<section id="question-4-composition" class="level2" data-number="6.4">
<h2 data-number="6.4" class="anchored" data-anchor-id="question-4-composition"><span class="header-section-number">6.4</span> Question 4 — Composition</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX:(%5COmega,%5Cmathcal%20F)%5Cto(E,%5Cmathcal%20E)%0A"></p>
<p>and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Af:(E,%5Cmathcal%20E)%5Cto(S,%5Cmathcal%20S)%0A"></p>
<p>be measurable.</p>
<p>Prove directly from the definition that (fX) is measurable.</p>
</section>
<section id="question-5-generated-sigma-algebra" class="level2" data-number="6.5">
<h2 data-number="6.5" class="anchored" data-anchor-id="question-5-generated-sigma-algebra"><span class="header-section-number">6.5</span> Question 5 ★ — Generated sigma-algebra</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5COmega=%5C%7B%5Comega_1,%5Comega_2,%5Comega_3,%5Comega_4%5C%7D%0A"></p>
<p>and define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX(%5Comega_1)=0,%5Cqquad%0AX(%5Comega_2)=0,%5Cqquad%0AX(%5Comega_3)=1,%5Cqquad%0AX(%5Comega_4)=2.%0A"></p>
<p>Assume the codomain has the full power-set sigma-algebra.</p>
<p>List every element of ((X)).</p>
<p>Interpret ((X)) as the information revealed by observing (X).</p>
</section>
<section id="question-6-law-or-pushforward-distribution" class="level2" data-number="6.6">
<h2 data-number="6.6" class="anchored" data-anchor-id="question-6-law-or-pushforward-distribution"><span class="header-section-number">6.6</span> Question 6 — Law or pushforward distribution</h2>
<p>Suppose</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P(%5C%7B%5Comega_1%5C%7D)=0.1,%5Cquad%0A%5Cmathbb%20P(%5C%7B%5Comega_2%5C%7D)=0.2,%5Cquad%0A%5Cmathbb%20P(%5C%7B%5Comega_3%5C%7D)=0.3,%5Cquad%0A%5Cmathbb%20P(%5C%7B%5Comega_4%5C%7D)=0.4.%0A"></p>
<p>Using the (X) from Question 5, compute the law</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20P_X%0A=%0A%5Cmathbb%20P%5Ccirc%20X%5E%7B-1%7D.%0A"></p>
<p>Give its value on every subset of ({0,1,2}).</p>
</section>
<section id="question-7-factorization-through-the-observation" class="level2" data-number="6.7">
<h2 data-number="6.7" class="anchored" data-anchor-id="question-7-factorization-through-the-observation"><span class="header-section-number">6.7</span> Question 7 ★ — Factorization through the observation</h2>
<p>State the factorization theorem relating these two statements:</p>
<ol type="1">
<li>(Y) is ((X))-measurable.</li>
<li>(Y=f(X)) for some measurable function (f).</li>
</ol>
<p>Use it to explain rigorously why an estimator that is allowed to use only (A) has the form</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ag(A).%0A"></p>
</section>
<section id="question-8-type-checking" class="level2" data-number="6.8">
<h2 data-number="6.8" class="anchored" data-anchor-id="question-8-type-checking"><span class="header-section-number">6.8</span> Question 8 — Type checking</h2>
<p>For a random vector (A:R^d), distinguish the types of:</p>
<ol type="1">
<li>(A);</li>
<li>(aR^d);</li>
<li>((A));</li>
<li>({AB}), where (BB(R^d));</li>
<li>(E[ZA]).</li>
</ol>
</section>
<section id="question-9-measurability-of-the-relu-observation" class="level2" data-number="6.9">
<h2 data-number="6.9" class="anchored" data-anchor-id="question-9-measurability-of-the-relu-observation"><span class="header-section-number">6.9</span> Question 9 ★ — Measurability of the ReLU observation</h2>
<p>Assume</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ:(%5COmega,%5Cmathcal%20F)%5Cto(%5Cmathbb%20R%5Ed,%5Cmathcal%20B(%5Cmathbb%20R%5Ed))%0A"></p>
<p>is measurable and (QR^{dd}) is fixed.</p>
<p>Prove that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Coperatorname%7BReLU%7D(QZ)%0A"></p>
<p>is measurable.</p>
<p>State every closure fact you use.</p>
</section>
</section>
<section id="part-ii-conditional-expectation" class="level1" data-number="7">
<h1 data-number="7"><span class="header-section-number">7</span> Part II — Conditional expectation</h1>
<section id="question-10-definition" class="level2" data-number="7.1">
<h2 data-number="7.1" class="anchored" data-anchor-id="question-10-definition"><span class="header-section-number">7.1</span> Question 10 ★ — Definition</h2>
<p>Let (XL^1) and let (GF) be a sub-sigma-algebra.</p>
<p>State the defining properties of</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AY=%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Include the sense in which (Y) is unique.</p>
</section>
<section id="question-11-finite-partition-calculation" class="level2" data-number="7.2">
<h2 data-number="7.2" class="anchored" data-anchor-id="question-11-finite-partition-calculation"><span class="header-section-number">7.2</span> Question 11 — Finite partition calculation</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5COmega=%5C%7B1,2,3,4%5C%7D,%0A"></p>
<p>with probabilities</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A(0.1,0.2,0.3,0.4),%0A"></p>
<p>and let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AX=(2,-1,4,0)%0A"></p>
<p>on these four outcomes.</p>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20G%0A=%0A%5Csigma(%5C%7B1,2%5C%7D,%5C%7B3,4%5C%7D).%0A"></p>
<p>Compute (E[XG]) as a random variable on ().</p>
</section>
<section id="question-12-verify-from-the-definition" class="level2" data-number="7.3">
<h2 data-number="7.3" class="anchored" data-anchor-id="question-12-verify-from-the-definition"><span class="header-section-number">7.3</span> Question 12 ★ — Verify from the definition</h2>
<p>For your answer to Question 11, verify explicitly that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX1_G%5D%0A=%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D1_G%5D%0A"></p>
<p>for every (GG).</p>
</section>
<section id="question-13-already-known-information" class="level2" data-number="7.4">
<h2 data-number="7.4" class="anchored" data-anchor-id="question-13-already-known-information"><span class="header-section-number">7.4</span> Question 13 — Already known information</h2>
<p>Prove:</p>
<p>If (X) is (G)-measurable and integrable, then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D=X%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
</section>
<section id="question-14-irrelevant-information" class="level2" data-number="7.5">
<h2 data-number="7.5" class="anchored" data-anchor-id="question-14-irrelevant-information"><span class="header-section-number">7.5</span> Question 14 — Irrelevant information</h2>
<p>Prove:</p>
<p>If (X) is integrable and independent of (G), then</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%0A=%0A%5Cmathbb%20E%5BX%5D%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
</section>
<section id="question-15-tower-property" class="level2" data-number="7.6">
<h2 data-number="7.6" class="anchored" data-anchor-id="question-15-tower-property"><span class="header-section-number">7.6</span> Question 15 ★ — Tower property</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathcal%20H%5Csubseteq%5Cmathcal%20G%5Csubseteq%5Cmathcal%20F%0A"></p>
<p>and (XL^1).</p>
<p>State and prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%5Cmid%5Cmathcal%20H%5D%0A=%0A%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20H%5D.%0A"></p>
<p>Use the defining property of conditional expectation, not an informal averaging argument.</p>
</section>
<section id="question-16-law-of-total-variance" class="level2" data-number="7.7">
<h2 data-number="7.7" class="anchored" data-anchor-id="question-16-law-of-total-variance"><span class="header-section-number">7.7</span> Question 16 ★ — Law of total variance</h2>
<p>For (XL^2), prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BVar%7D(X)%0A=%0A%5Cmathbb%20E%5B%5Coperatorname%7BVar%7D(X%5Cmid%5Cmathcal%20G)%5D%0A+%0A%5Coperatorname%7BVar%7D(%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D).%0A"></p>
<p>Define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BVar%7D(X%5Cmid%5Cmathcal%20G)%0A=%0A%5Cmathbb%20E%5B(X-%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D)%5E2%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Identify exactly where the cross term vanishes.</p>
</section>
<section id="question-17-vector-version" class="level2" data-number="7.8">
<h2 data-number="7.8" class="anchored" data-anchor-id="question-17-vector-version"><span class="header-section-number">7.8</span> Question 17 — Vector version</h2>
<p>For (ZL^2(;R^d)), prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7BCov%7D(Z)%0A=%0A%5Cmathbb%20E%5B%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G)%5D%0A+%0A%5Coperatorname%7BCov%7D(%5Cmathbb%20E%5BZ%5Cmid%5Cmathcal%20G%5D).%0A"></p>
<p>All quantities are matrices. State what expectation of a random matrix means.</p>
</section>
<section id="question-18-trace-of-conditional-covariance" class="level2" data-number="7.9">
<h2 data-number="7.9" class="anchored" data-anchor-id="question-18-trace-of-conditional-covariance"><span class="header-section-number">7.9</span> Question 18 ★ — Trace of conditional covariance</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BZ%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G))%0A=%0A%5Cmathbb%20E%5B%5C%7CZ-m%5C%7C%5E2%5Cmid%5Cmathcal%20G%5D.%0A"></p>
<p>Then prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%5Cmathcal%20G))%0A%5D%0A=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2.%0A"></p>
<p>Do not remove the conditional expectation in the first identity.</p>
</section>
<section id="question-19-scalar-relu-with-a-uniform-latent" class="level2" data-number="7.10">
<h2 data-number="7.10" class="anchored" data-anchor-id="question-19-scalar-relu-with-a-uniform-latent"><span class="header-section-number">7.10</span> Question 19 — Scalar ReLU with a uniform latent</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Csim%5Coperatorname%7BUnif%7D%5B-1,1%5D,%0A%5Cqquad%0AA=%5Coperatorname%7BReLU%7D(Z).%0A"></p>
<p>Compute explicitly:</p>
<ol type="1">
<li>(E[ZA]) as a function (h(A));</li>
<li>((ZA));</li>
<li>the MMSE <img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(Z-%5Cmathbb%20E%5BZ%5Cmid%20A%5D)%5E2%5D.%0A"></li>
</ol>
</section>
<section id="question-20-scalar-gaussian-relu" class="level2" data-number="7.11">
<h2 data-number="7.11" class="anchored" data-anchor-id="question-20-scalar-gaussian-relu"><span class="header-section-number">7.11</span> Question 20 — Scalar Gaussian ReLU</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Csim%5Cmathcal%20N(0,1),%0A%5Cqquad%0AA=%5Coperatorname%7BReLU%7D(Z).%0A"></p>
<p>You may use</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20Z%5Cle%200%5D%0A=%0A-%5Csqrt%7B%5Cfrac%7B2%7D%7B%5Cpi%7D%7D,%0A%5Cqquad%0A%5Coperatorname%7BVar%7D(Z%5Cmid%20Z%5Cle%200)%0A=%0A1-%5Cfrac%7B2%7D%7B%5Cpi%7D.%0A"></p>
<p>Compute (E[ZA]) and the MMSE.</p>
</section>
<section id="question-21-conditioning-on-a-continuously-distributed-observation" class="level2" data-number="7.12">
<h2 data-number="7.12" class="anchored" data-anchor-id="question-21-conditioning-on-a-continuously-distributed-observation"><span class="header-section-number">7.12</span> Question 21 — Conditioning on a continuously distributed observation</h2>
<p>Explain why the notation</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A=a%5D%0A"></p>
<p>cannot generally be defined by the elementary formula</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cfrac%7B%5Cmathbb%20E%5BZ1_%7B%5C%7BA=a%5C%7D%7D%5D%7D%7B%5Cmathbb%20P(A=a)%7D%0A"></p>
<p>when (A) is continuous.</p>
<p>Explain why</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5BZ%5Cmid%20A%5D%0A=%0A%5Cmathbb%20E%5BZ%5Cmid%5Csigma(A)%5D%0A"></p>
<p>remains well-defined.</p>
</section>
<section id="question-22-sparse-nonnegative-scalar" class="level2" data-number="7.13">
<h2 data-number="7.13" class="anchored" data-anchor-id="question-22-sparse-nonnegative-scalar"><span class="header-section-number">7.13</span> Question 22 — Sparse nonnegative scalar</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=%0A%5Cbegin%7Bcases%7D%0A0,&amp;%5Ctext%7Bwith%20probability%20%7D1-p,%5C%5C%0AX,&amp;%5Ctext%7Bwith%20probability%20%7Dp,%0A%5Cend%7Bcases%7D%0A%5Cqquad%0AX%5Csim%5Coperatorname%7BExp%7D(1),%0A"></p>
<p>and let (A=(Z)).</p>
<p>Compute (E[ZA]) and the MMSE.</p>
</section>
</section>
<section id="part-iii-l2-geometry-and-mmse" class="level1" data-number="8">
<h1 data-number="8"><span class="header-section-number">8</span> Part III — (L^2) geometry and MMSE</h1>
<section id="question-23-l2-as-an-inner-product-space" class="level2" data-number="8.1">
<h2 data-number="8.1" class="anchored" data-anchor-id="question-23-l2-as-an-inner-product-space"><span class="header-section-number">8.1</span> Question 23 ★ — (L^2) as an inner-product space</h2>
<p>Define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL%5E2(%5COmega,%5Cmathcal%20F,%5Cmathbb%20P)%0A"></p>
<p>and its inner product and norm.</p>
<p>Why are random variables that are equal almost surely treated as the same element of (L^2)?</p>
</section>
<section id="question-24-the-observable-subspace" class="level2" data-number="8.2">
<h2 data-number="8.2" class="anchored" data-anchor-id="question-24-the-observable-subspace"><span class="header-section-number">8.2</span> Question 24 — The observable subspace</h2>
<p>For a sub-sigma-algebra (G), define</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL%5E2(%5COmega,%5Cmathcal%20G,%5Cmathbb%20P).%0A"></p>
<p>Prove it is a linear subspace of (L^2(,F,P)).</p>
<p>State the additional property needed before the orthogonal projection theorem applies.</p>
</section>
<section id="question-25-projection-theorem" class="level2" data-number="8.3">
<h2 data-number="8.3" class="anchored" data-anchor-id="question-25-projection-theorem"><span class="header-section-number">8.3</span> Question 25 ★ — Projection theorem</h2>
<p>State the orthogonal projection theorem for a closed linear subspace (M) of a Hilbert space (H).</p>
<p>Give both equivalent characterizations of the projection (P_Mx):</p>
<ol type="1">
<li>closest point;</li>
<li>orthogonality of the residual.</li>
</ol>
</section>
<section id="question-26-conditional-expectation-is-the-projection" class="level2" data-number="8.4">
<h2 data-number="8.4" class="anchored" data-anchor-id="question-26-conditional-expectation-is-the-projection"><span class="header-section-number">8.4</span> Question 26 ★ — Conditional expectation is the projection</h2>
<p>Let (XL^2).</p>
<p>Prove that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Am=%5Cmathbb%20E%5BX%5Cmid%5Cmathcal%20G%5D%0A"></p>
<p>satisfies</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5B(X-m)V%5D=0%0A"></p>
<p>for every (VL^2(,G,P)).</p>
<p>First prove it for indicator functions, then simple functions, then general (V).</p>
</section>
<section id="question-27-pythagorean-risk-decomposition" class="level2" data-number="8.5">
<h2 data-number="8.5" class="anchored" data-anchor-id="question-27-pythagorean-risk-decomposition"><span class="header-section-number">8.5</span> Question 27 ★ — Pythagorean risk decomposition</h2>
<p>Let</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Cin%20L%5E2(%5COmega;%5Cmathbb%20R%5Ed),%0A%5Cqquad%0Am=%5Cmathbb%20E%5BZ%5Cmid%5Cmathcal%20G%5D,%0A"></p>
<p>and let (T) be any square-integrable (G)-measurable random vector.</p>
<p>Prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cmathbb%20E%5C%7CZ-T%5C%7C%5E2%0A=%0A%5Cmathbb%20E%5C%7CZ-m%5C%7C%5E2%0A+%0A%5Cmathbb%20E%5C%7Cm-T%5C%7C%5E2.%0A"></p>
<p>Expand the square and prove that the cross term is exactly zero.</p>
</section>
<section id="question-28-mmse-decoder" class="level2" data-number="8.6">
<h2 data-number="8.6" class="anchored" data-anchor-id="question-28-mmse-decoder"><span class="header-section-number">8.6</span> Question 28 ★ — MMSE decoder</h2>
<p>Set</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Coperatorname%7BReLU%7D(QZ).%0A"></p>
<p>Using Questions 7 and 27, prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0A%5Cinf_g%0A%5Cmathbb%20E%5C%7CZ-g(A)%5C%7C%5E2%0A=%0A%5Cmathbb%20E%5C%7CZ-%5Cmathbb%20E%5BZ%5Cmid%20A%5D%5C%7C%5E2.%0A"></p>
<p>State:</p>
<ol type="1">
<li>the admissible class of (g);</li>
<li>the integrability condition;</li>
<li>the sense in which the minimizer is unique.</li>
</ol>
</section>
<section id="question-29-conditional-covariance-formula-for-lq" class="level2" data-number="8.7">
<h2 data-number="8.7" class="anchored" data-anchor-id="question-29-conditional-covariance-formula-for-lq"><span class="header-section-number">8.7</span> Question 29 ★ — Conditional covariance formula for (L(Q))</h2>
<p>Prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%0A=%0A%5Cmathbb%20E%5B%0A%5Coperatorname%7Btr%7D(%5Coperatorname%7BCov%7D(Z%5Cmid%20A))%0A%5D,%0A%5Cqquad%0AA=%5Coperatorname%7BReLU%7D(QZ).%0A"></p>
<p>Your proof should be a chain of explicit equalities.</p>
</section>
<section id="question-30-exact-recoverability" class="level2" data-number="8.8">
<h2 data-number="8.8" class="anchored" data-anchor-id="question-30-exact-recoverability"><span class="header-section-number">8.8</span> Question 30 ★ — Exact recoverability</h2>
<p>Prove the equivalence</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)=0%0A"></p>
<p>if and only if</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Ctext%7B%20is%20%7D%5Csigma(A)%5Ctext%7B-measurable%7D,%0A"></p>
<p>if and only if there exists a measurable (g) such that</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ=g(A)%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>Explain why this is an <strong>almost-sure recoverability</strong> statement, not necessarily a statement that the deterministic map</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Az%5Cmapsto%5Coperatorname%7BReLU%7D(Qz)%0A"></p>
<p>is globally injective on all of (R^d).</p>
</section>
<section id="question-31-arbitrary-decoder-versus-linear-decoder" class="level2" data-number="8.9">
<h2 data-number="8.9" class="anchored" data-anchor-id="question-31-arbitrary-decoder-versus-linear-decoder"><span class="header-section-number">8.9</span> Question 31 ★ — Arbitrary decoder versus linear decoder</h2>
<p>Explain the difference between minimizing over:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0Ag(A)%5Cquad%5Ctext%7Bfor%20every%20measurable%20%7Dg%0A"></p>
<p>and minimizing over:</p>
<p><img src="https://latex.codecogs.com/png.latex?%0ABA+b.%0A"></p>
<p>Give a concrete example in which the MMSE decoder is nonlinear and therefore cannot be represented by an affine decoder.</p>
</section>
<section id="question-32-gaussian-rotational-invariance" class="level2" data-number="8.10">
<h2 data-number="8.10" class="anchored" data-anchor-id="question-32-gaussian-rotational-invariance"><span class="header-section-number">8.10</span> Question 32 ★ — Gaussian rotational invariance</h2>
<p>Assume</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Csim%5Cmathcal%20N(0,I_d)%0A"></p>
<p>and (QO(d)).</p>
<p>Prove that (L(Q)) is independent of (Q).</p>
<p>Your proof must use:</p>
<ol type="1">
<li>(Y=QZN(0,I_d));</li>
<li>preservation of Euclidean norm by (Q);</li>
<li>a bijection between decoders for (Z) and decoders for (Y).</li>
</ol>
</section>
</section>
<section id="bridge-problems-toward-the-privileged-basis-proof" class="level1" data-number="9">
<h1 data-number="9"><span class="header-section-number">9</span> Bridge problems toward the privileged-basis proof</h1>
<p>These are not prerequisites. They test whether you can now begin the actual problem.</p>
<section id="bridge-1-identity-basis-for-nonnegative-latents" class="level2" data-number="9.1">
<h2 data-number="9.1" class="anchored" data-anchor-id="bridge-1-identity-basis-for-nonnegative-latents"><span class="header-section-number">9.1</span> Bridge 1 — Identity basis for nonnegative latents</h2>
<p>Assume</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AZ%5Cin%5B0,%5Cinfty)%5Ed%0A%5Cqquad%5Ctext%7Ba.s.%7D%0A"></p>
<p>Prove</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(I)=0.%0A"></p>
<p>The sparsity and exponential assumptions are irrelevant for this step. Explain why.</p>
</section>
<section id="bridge-2-why-one-collision-is-insufficient" class="level2" data-number="9.2">
<h2 data-number="9.2" class="anchored" data-anchor-id="bridge-2-why-one-collision-is-insufficient"><span class="header-section-number">9.2</span> Bridge 2 — Why one collision is insufficient</h2>
<p>Someone argues:</p>
<blockquote class="blockquote">
<p>I found (zz’) such that [ (Qz) = (Qz’). ] Therefore (L(Q)&gt;0).</p>
</blockquote>
<p>Give at least three reasons this argument is incomplete.</p>
</section>
<section id="bridge-3-correct-positivity-criterion" class="level2" data-number="9.3">
<h2 data-number="9.3" class="anchored" data-anchor-id="bridge-3-correct-positivity-criterion"><span class="header-section-number">9.3</span> Bridge 3 — Correct positivity criterion</h2>
<p>State a rigorous condition, in terms of conditional covariance, sufficient and necessary for</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AL(Q)%3E0.%0A"></p>
<p>Then state a more concrete sufficient condition involving a positive-probability set of observations.</p>
</section>
<section id="bridge-4-forty-five-degree-sparse-case" class="level2" data-number="9.4">
<h2 data-number="9.4" class="anchored" data-anchor-id="bridge-4-forty-five-degree-sparse-case"><span class="header-section-number">9.4</span> Bridge 4 — Forty-five-degree sparse case</h2>
<p>Let (d=2) and</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AQ%0A=%0A%5Cfrac%7B1%7D%7B%5Csqrt%202%7D%0A%5Cbegin%7Bbmatrix%7D%0A1&amp;-1%5C%5C%0A1&amp;1%0A%5Cend%7Bbmatrix%7D.%0A"></p>
<p>Let (Z_1,Z_2) be independent sparse nonnegative exponential variables.</p>
<p>Write</p>
<p><img src="https://latex.codecogs.com/png.latex?%0AA=%5Coperatorname%7BReLU%7D(QZ)%0A"></p>
<p>coordinatewise.</p>
<p>Identify a region of latent space on which one ReLU coordinate is zero and the other reveals only (Z_1+Z_2).</p>
<p>Formulate a rigorous route to proving that the conditional distribution of (Z) on this region has nonzero variance. You do not need to complete all measure-theoretic details, but you must identify exactly what must be proved.</p>
</section>
</section>
<section id="readiness-criterion" class="level1" data-number="10">
<h1 data-number="10"><span class="header-section-number">10</span> Readiness criterion</h1>
<p>There are (32) main questions, for (64) points.</p>
<p>You are ready to begin the privileged-basis proof when:</p>
<ul>
<li>total score is at least (52/64);</li>
<li>no starred question receives (0);</li>
<li>Questions 27–30 can be reproduced without notes;</li>
<li>you can explain in one paragraph why the problem is fundamentally about the conditional spread of ReLU fibres under the law of (Z).</li>
</ul>
<p>The answer key is a separate file. Do not open it until completing the closed-notes pass.</p>


</section>

 ]]></description>
  <guid>https://shrivastava95.github.io/blog-quarto/posts/privileged-basis/</guid>
  <pubDate>Sat, 31 Oct 2026 16:45:49 GMT</pubDate>
</item>
</channel>
</rss>
