{"id":1274,"date":"2014-07-14T11:55:15","date_gmt":"2014-07-14T02:55:15","guid":{"rendered":"http:\/\/www.lookingatnothing.com\/?p=1274"},"modified":"2014-07-14T11:55:15","modified_gmt":"2014-07-14T02:55:15","slug":"fancy-background-subtraction-a-second-look","status":"publish","type":"post","link":"https:\/\/lookingatnothing.com\/index.php\/archives\/1274","title":{"rendered":"Fancy background subtraction: a second look."},"content":{"rendered":"<p>During last week&#8217;s visit to <a href=\"http:\/\/www.bam.de\/en\/index.htm\">BAM<\/a> in Berlin, I and <a href=\"http:\/\/ingobressler.net\/\">Ingo<\/a> played around with some equations. In particular, we were curious if we need to do something special to get the scattering from a sample in a capillary, i.e. a sample between an upstream and a downstream sample cell wall. Long story short: we arrive at a rather\u00a0ordinary equation after a lengthy derivation.<\/p>\n<p><!--more--><\/p>\n<p>So we\u00a0derived the method\u00a0to extract the sample scattering from the total scattering signal\u00a0for this case. We discussed this topic before <a href=\"http:\/\/www.lookingatnothing.com\/index.php\/archives\/1045\">in this post<\/a> where self-absorption (discussed <a href=\"http:\/\/www.lookingatnothing.com\/index.php\/archives\/429\">in this post<\/a>) was considered, but where the derivation was not completely worked out. To make it easier to derive, we neglect the direction-dependent absorption of the scattered signal(s), but a future derivation may include this term (only for flat walls and phases, as the derivation thereof of round capillary-type cross-sections is ridiculously complex).<\/p>\n<figure id=\"attachment_1046\" aria-describedby=\"caption-attachment-1046\" style=\"width: 300px\" class=\"wp-caption alignright\"><a href=\"http:\/\/www.lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-1046\" src=\"http:\/\/www.lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic-300x167.png\" alt=\"Schematic overview of the considerations of the fancy background subtraction.\" width=\"300\" height=\"167\" srcset=\"https:\/\/lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic-300x167.png 300w, https:\/\/lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic-150x83.png 150w, https:\/\/lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic.png 668w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><figcaption id=\"caption-attachment-1046\" class=\"wp-caption-text\"><strong>Figure 1:<\/strong> Schematic overview of the considerations of the fancy background subtraction.<\/figcaption><\/figure>\n<p>We consider three separate processes as an incident photon beam travels through\u00a0a given phase: the attenuation\u00a0of the incident beam by the material before a scattering event, a probability for\u00a0scattering of this attenuated beam, and the attenuation of the scattered radiation by the remaining material of the phase. Each incident and scattered beam is further attenuated by the preceding and subsequent phases. We also assume that the scattering event does not significantly reduce the intensity of the remaining unscattered beam.<\/p>\n<p>The derivation is provided in a separate document <a href=\"http:\/\/www.lookingatnothing.com\/wp-content\/uploads\/2014\/07\/FancyBgnd_noSA.pdf\">here<\/a>, together with most of the text in this post. I cannot promise I did the derivation in the most efficient way, there may be shorter ways of doing it, and it most certainly will have been done before in literature. Apropos, it very much resembles a nice exercise for an exam question or class derivation, for those who are into teaching small-angle scattering.<\/p>\n<p>Despite the rather long intermediate equations in the derivation, the final equation is quite short:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=P_2+%3D+%5Cfrac%7B1%7D%7BD_2%7D+%5Cleft%5C%7B+%5Cfrac%7B+I_s+%7D%7B+I_0+%5Czeta_%7B%5Cmathrm%7B1%2B2%7D%7D+%7D+-+%5Cfrac%7BI_b%7D+%7B+I_0+%5Czeta_%7B%5Cmathrm%7B1%7D%7D+%7D+%5Cright%5C%7D&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"P_2 = &#92;frac{1}{D_2} &#92;left&#92;{ &#92;frac{ I_s }{ I_0 &#92;zeta_{&#92;mathrm{1+2}} } - &#92;frac{I_b} { I_0 &#92;zeta_{&#92;mathrm{1}} } &#92;right&#92;}\" class=\"latex\" \/><\/p>\n<p>where <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=D_2&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"D_2\" class=\"latex\" \/> is the thickness of the sample phase (only), <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=I_s&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"I_s\" class=\"latex\" \/> the measured intensity of sample + cell, <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=I_b&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"I_b\" class=\"latex\" \/> the measured intensity of the cell, <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=I_0&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"I_0\" class=\"latex\" \/> the primary beam flux, and <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=%5Czeta_%7B%5Cmathrm%7B1%2B2%7D%7D&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"&#92;zeta_{&#92;mathrm{1+2}}\" class=\"latex\" \/> and <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=%5Czeta_%7B%5Cmathrm%7B1%7D%7D&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"&#92;zeta_{&#92;mathrm{1}}\" class=\"latex\" \/> the transmission factors measured for the sample + cell and cell measurements, respectively.<\/p>\n<p>There are interesting aspects when we use this background subtraction equation in practice. Firstly, we find that it is not necessary to determine the sample cell wall thickness <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=D_1&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"D_1\" class=\"latex\" \/>. Secondly, both the sample measurement and the background measurement are normalised to the thickness of the sample phase <img decoding=\"async\" src=\"https:\/\/s0.wp.com\/latex.php?latex=D_2&#038;bg=ffffff&#038;fg=000&#038;s=0&#038;c=20201002\" alt=\"D_2\" class=\"latex\" \/> only. Lastly, it should be noted that this is, of course, only valid if the same sample cell is used for both the background and the sample measurement.<\/p>\n<p>So, nothing shocking here, but it is interesting that it can be derived from more basic considerations.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>During last week&#8217;s visit to BAM in Berlin, I and Ingo played around with some equations. In particular, we were curious if we need to <a class=\"mh-excerpt-more\" href=\"https:\/\/lookingatnothing.com\/index.php\/archives\/1274\" title=\"Fancy background subtraction: a second look.\">[&#8230;]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":1046,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[1],"tags":[],"class_list":["post-1274","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/lookingatnothing.com\/wp-content\/uploads\/2014\/03\/Schematic.png","jetpack_shortlink":"https:\/\/wp.me\/p1gZ2v-ky","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/posts\/1274","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/comments?post=1274"}],"version-history":[{"count":5,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/posts\/1274\/revisions"}],"predecessor-version":[{"id":1280,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/posts\/1274\/revisions\/1280"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/media\/1046"}],"wp:attachment":[{"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/media?parent=1274"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/categories?post=1274"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lookingatnothing.com\/index.php\/wp-json\/wp\/v2\/tags?post=1274"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}