<div class="xblock xblock-public_view xblock-public_view-vertical" data-init="VerticalStudentView" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@vertical+block@Quantum_basics_I" data-block-type="vertical" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<h2 class="hd hd-2 unit-title">Quantum basics I</h2>
<div class="vert-mod">
<div class="vert vert-0" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Approximation" class="problems-wrapper" role="group"
aria-labelledby="Approximation-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="1"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Approximation-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation-problem-progress" tabindex="-1">
Approximation
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Approximation-problem-progress"></div>
<div class="problem">
<div>
<p>
[mathjaxinline]\binom {n}{n/3}[/mathjaxinline] is approximately [mathjaxinline]2^{cn}[/mathjaxinline] for some constant [mathjaxinline]0&lt;c&lt;1[/mathjaxinline]. (Here &#8220;approximately" means up to factors of at most [mathjaxinline]O(n)[/mathjaxinline].) </p>
<p>
What is [mathjaxinline]c[/mathjaxinline] up to three digits of precision? </p>
<ul class="itemize">
<li>
<p>
<p style="display:inline">[mathjaxinline]c =[/mathjaxinline]</p>
<div class="inline" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_Approximation_2_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_Approximation_2_1" id="input_Approximation_2_1" aria-describedby="status_Approximation_2_1" value=""/>
<span class="trailing_text" id="trailing_text_Approximation_2_1"/>
<span class="status unanswered" id="status_Approximation_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_Approximation_2_1" class="answer"/>
</div>
</div></div>
</p>
</li>
</ul>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Approximation" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Approximation" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Approximation">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Approximation-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Approximation-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Approximation-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-1" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Matrices" class="problems-wrapper" role="group"
aria-labelledby="Matrices-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="1"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Matrices-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices-problem-progress" tabindex="-1">
Matrices
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Matrices-problem-progress"></div>
<div class="problem">
<div>
<p>
Let [mathjaxinline]|{\Phi }\rangle = \frac{1}{\sqrt{d}}\sum _{i=1}^ d |{i}\rangle \otimes |{i}\rangle[/mathjaxinline]. For any matrix [mathjaxinline]X[/mathjaxinline], there exists a matrix [mathjaxinline]Y[/mathjaxinline] such that </p>
<table id="a0000000002" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax](X \otimes I) |{\Phi }\rangle =(I \otimes Y) |{\Phi }\rangle .[/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none">&#160;</td>
</tr>
</table>
<p>
What is [mathjaxinline]Y_{i,j}[/mathjaxinline] as a function of the entries of [mathjaxinline]X[/mathjaxinline]? </p>
<span>
<div class="wrapper-problem-response" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_Matrices_2_1" class="capa_inputtype">
<div class="drag_and_drop_problem_div" id="drag_and_drop_div_Matrices_2_1" data-plain-id="Matrices_2_1">
</div>
<div class="drag_and_drop_problem_json" id="drag_and_drop_json_Matrices_2_1" style="display:none;">{"draggables": [{"target_fields": [], "label": "", "icon": "/assets/courseware/v1/b7874de35cfa19174813b92e98319223/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label1.png", "can_reuse": "", "id": "Phi"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/cd7f0db6ecdcf93a25a02932af982df3/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label2.png", "can_reuse": "", "id": "I"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/f84180feb6fde5233368b900909679f4/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label3.png", "can_reuse": "", "id": "X"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/b1c0519fd7591c1288204c5b13686969/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label4.png", "can_reuse": "", "id": "Y"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/bf779df73d99187b04abadc36a8fbc87/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label5.png", "can_reuse": "", "id": "d"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/ffca1ad6cd8a31680d6a9583ec57feee/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label6.png", "can_reuse": "", "id": "i"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/d1eabe8b45f82035ae176625d6e5ab1b/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd_label7.png", "can_reuse": "", "id": "j"}], "label_bg_color": "rgb(222, 139, 238)", "base_image": "/assets/courseware/v1/2b318cff2821aa7615309665ddfe39ae/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p2_ps0_p2_dnd.png", "target_outline": "false", "targets": [{"w": "121", "y": "1", "x": "110", "id": "1", "h": "85"}, {"w": "120", "y": "61", "x": "254", "id": "3", "h": "85"}, {"w": "120", "y": "61", "x": "406", "id": "2", "h": "85"}], "one_per_target": "true"}</div>
<div class="script_placeholder" data-src="/static/js/capa/drag_and_drop.a31124208b9b.js"/>
<div class="unanswered" id="status_Matrices_2_1">
<input type="text" name="input_Matrices_2_1" id="input_Matrices_2_1" aria-describedby="answer_Matrices_2_1" value="" style="display:none;"/>
<p class="indicator-container drag-and-drop--status" aria-describedby="input_Matrices_2_1">
<span class="status unanswered" id="status_Matrices_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
</p>
<p id="answer_Matrices_2_1" class="answer"/>
</div>
</div></div>
<div class="solution-span">
<span id="solution_Matrices_solution_1"/>
</div></span>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Matrices" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Matrices" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Matrices">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Matrices-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Matrices-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Matrices-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-2" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Probability_I" class="problems-wrapper" role="group"
aria-labelledby="Probability_I-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="2"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Probability_I-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I-problem-progress" tabindex="-1">
Probability I
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_I-problem-progress"></div>
<div class="problem">
<div>
<p>
Suppose that [mathjaxinline]A,B[/mathjaxinline] are events such that [mathjaxinline]\Pr [A]=1/2[/mathjaxinline] and [mathjaxinline]\Pr [B]=1/3[/mathjaxinline]. Based on this we know that [mathjaxinline]\Pr [A\cup B][/mathjaxinline] is in some range, i.e. </p>
<table id="a0000000003" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax]x \leq \Pr [A\cup B] \leq y.[/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none">&#160;</td>
</tr>
</table>
<p>
What are [mathjaxinline]x,y[/mathjaxinline]? </p>
<p>
<p style="display:inline">[mathjaxinline]x =[/mathjaxinline]</p>
<div class="inline" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_Probability_I_2_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_Probability_I_2_1" id="input_Probability_I_2_1" aria-describedby="status_Probability_I_2_1" value=""/>
<span class="trailing_text" id="trailing_text_Probability_I_2_1"/>
<span class="status unanswered" id="status_Probability_I_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_Probability_I_2_1" class="answer"/>
</div>
</div></div>
</p>
<p>
<p style="display:inline">[mathjaxinline]y =[/mathjaxinline]</p>
<div class="inline" tabindex="-1" aria-label="Question 2" role="group"><div id="inputtype_Probability_I_3_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_Probability_I_3_1" id="input_Probability_I_3_1" aria-describedby="status_Probability_I_3_1" value=""/>
<span class="trailing_text" id="trailing_text_Probability_I_3_1"/>
<span class="status unanswered" id="status_Probability_I_3_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_Probability_I_3_1" class="answer"/>
</div>
</div></div>
</p>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Probability I" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Probability_I" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Probability_I">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_I-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_I-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_I-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-3" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Probability_II" class="problems-wrapper" role="group"
aria-labelledby="Probability_II-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="2"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Probability_II-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II-problem-progress" tabindex="-1">
Probability II
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Probability_II-problem-progress"></div>
<div class="problem">
<div>
<p>
[mathjaxinline]X[/mathjaxinline] is a real-valued random variable with [mathjaxinline]\mathbb {E} [X]=5[/mathjaxinline] and [mathjaxinline]X \geq 0[/mathjaxinline]. </p>
<ul class="itemize">
<li>
<p>
What is the best (among choices given) you can say about [mathjaxinline]\Pr [X\geq 3][/mathjaxinline]? </p>
<span>
<div class="wrapper-problem-response" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_Probability_II_2_1" class="capa_inputtype">
<div class="drag_and_drop_problem_div" id="drag_and_drop_div_Probability_II_2_1" data-plain-id="Probability_II_2_1">
</div>
<div class="drag_and_drop_problem_json" id="drag_and_drop_json_Probability_II_2_1" style="display:none;">{"draggables": [{"target_fields": [], "label": "", "icon": "/assets/courseware/v1/7002aefeefc47d9d57a4d615947acbfb/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label1.png", "can_reuse": "", "id": "minusfive"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/9d68229efba32b42834064320bf7e436/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label2.png", "can_reuse": "", "id": "minusthree"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/30a7016035807e49fe33516c7825f554/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label3.png", "can_reuse": "", "id": "minusone"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/9137bce32c9e0ca1085397539c6b75ff/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label4.png", "can_reuse": "", "id": "zero"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/5b70d2fff0ae7383bfcdb9dac5665c7e/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label5.png", "can_reuse": "", "id": "one"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/410609a5aa27591f841c6e01ecd594b9/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label6.png", "can_reuse": "", "id": "three"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/529a4840a43a8d91b572efd9395ae281/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd_label7.png", "can_reuse": "", "id": "five"}], "label_bg_color": "rgb(222, 139, 238)", "base_image": "/assets/courseware/v1/406167eb79ca784a9fb5666e760cb1a2/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4_ps0_p4_dnd.png", "target_outline": "false", "targets": [{"w": "120", "y": "1", "x": "1", "id": "1", "h": "85"}, {"w": "120", "y": "1", "x": "389", "id": "2", "h": "85"}], "one_per_target": "true"}</div>
<div class="script_placeholder" data-src="/static/js/capa/drag_and_drop.a31124208b9b.js"/>
<div class="unanswered" id="status_Probability_II_2_1">
<input type="text" name="input_Probability_II_2_1" id="input_Probability_II_2_1" aria-describedby="answer_Probability_II_2_1" value="" style="display:none;"/>
<p class="indicator-container drag-and-drop--status" aria-describedby="input_Probability_II_2_1">
<span class="status unanswered" id="status_Probability_II_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
</p>
<p id="answer_Probability_II_2_1" class="answer"/>
</div>
</div></div>
<div class="solution-span">
<span id="solution_Probability_II_solution_1"/>
</div></span>
</li>
<li>
<p>
What about [mathjaxinline]\Pr [X\geq 20][/mathjaxinline]? </p>
<span>
<div class="wrapper-problem-response" tabindex="-1" aria-label="Question 2" role="group"><div id="inputtype_Probability_II_3_1" class="capa_inputtype">
<div class="drag_and_drop_problem_div" id="drag_and_drop_div_Probability_II_3_1" data-plain-id="Probability_II_3_1">
</div>
<div class="drag_and_drop_problem_json" id="drag_and_drop_json_Probability_II_3_1" style="display:none;">{"draggables": [{"target_fields": [], "label": "", "icon": "/assets/courseware/v1/c87ca20704156dd8d64290548492a1f2/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label1.png", "can_reuse": "", "id": "minusone"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/750f4ffd1955a362fbffed8908b00c93/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label2.png", "can_reuse": "", "id": "minusonetwo"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/3b1849b9400c46d2d0f1cd43ceef048d/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label3.png", "can_reuse": "", "id": "minusonefour"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/aaaa9a9a342a33435e71d55b9c1fa211/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label4.png", "can_reuse": "", "id": "zero"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/bd3ea1ed8e40089c118b9075f289c740/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label5.png", "can_reuse": "", "id": "onefour"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/e0a75fd2b4d2ec8c4584e5311b6c594f/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label6.png", "can_reuse": "", "id": "onetwo"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/b04002d3e13315027df4960406c8f82b/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label7.png", "can_reuse": "", "id": "one"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/929295475eace2547a80bc61c88522cf/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd_label8.png", "can_reuse": "", "id": "three"}], "label_bg_color": "rgb(222, 139, 238)", "base_image": "/assets/courseware/v1/eeeb04c0ffde17a43a18c6c3eab2a1e1/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p4b_ps0_p4b_dnd.png", "target_outline": "false", "targets": [{"w": "120", "y": "1", "x": "1", "id": "1", "h": "84"}, {"w": "120", "y": "1", "x": "406", "id": "2", "h": "84"}], "one_per_target": "true"}</div>
<div class="script_placeholder" data-src="/static/js/capa/drag_and_drop.a31124208b9b.js"/>
<div class="unanswered" id="status_Probability_II_3_1">
<input type="text" name="input_Probability_II_3_1" id="input_Probability_II_3_1" aria-describedby="answer_Probability_II_3_1" value="" style="display:none;"/>
<p class="indicator-container drag-and-drop--status" aria-describedby="input_Probability_II_3_1">
<span class="status unanswered" id="status_Probability_II_3_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
</p>
<p id="answer_Probability_II_3_1" class="answer"/>
</div>
</div></div>
<div class="solution-span">
<span id="solution_Probability_II_solution_2"/>
</div></span>
</li>
</ul>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Probability II" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Probability_II" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Probability_II">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_II-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_II-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Probability_II-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-4" data-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@html_site_search_box1xxxx">
<div class="xblock xblock-public_view xblock-public_view-html xmodule_display xmodule_HtmlBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@html_site_search_box1xxxx" data-block-type="html" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "HTMLModule"}
</script>
<span><a href="/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/NONE" id="dummy_course_static_link" style="display:none"/><a href="/courses/course-v1:MITx+8.371.1x+2T2018/jump_to_id/NONE" id="dummy_jump_link" style="display:none"/><script type="text/javascript">
var add_site_search = function(){
course_static_url = $('#dummy_course_static_link').attr('href').replace('/NONE', '');
jump_to_url = $('#dummy_jump_link').attr('href').replace('/NONE', '');
if (typeof String.prototype.startsWith != 'function') {
// see below for better implementation!
String.prototype.startsWith = function (str){
return this.indexOf(str) === 0;
};
}
if(typeof(String.prototype.trim) === "undefined")
{
String.prototype.trim = function()
{
return String(this).replace(/^\s+|\s+$/g, '');
};
}
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var amp = String.fromCharCode(38);
var rlb = rb + lb;
var mke = function(x){ return lb + x + rb; }
var search_module_url = "";
var get_search_module_ficus = function(){
var cid = $('div.xblock').data('course-id');
if (cid){
console.log("cid = ", cid);
// search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/" + cid + "/courseware/welcome/Search_this_course/";
search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/courseware/welcome/Search_this_course/"; // automatically rewritten
console.log("3. search_module_url = ", search_module_url);
return;
}
var course_root_link = $('span.nav-item-course').find('a').attr('href');
if (course_root_link){
console.log("course_root_link = ", course_root_link);
search_module_url = course_root_link.replace("course/", "courseware/welcome/Search_this_course/");
console.log("2. search_module_url = ", search_module_url);
return
}
console.log("cannot determine search module url");
}
var get_search_module = function(){
// find search this module link
if (!($('div.course-index').length)){
return get_search_module_ficus();
}
$('div.course-index').find('nav').find('a').each(function(){
if ($(this).text().trim().startsWith("Search this course")){
search_module_url = $(this).attr('href');
console.log("search_module_url = ", search_module_url);
}
});
}
var go_to_search = function(){
get_search_module();
var sterm = $('#site-search-box').val();
// new_url = jump_to_url + "/Search_this_module/?q=" + sterm;
new_url = search_module_url + "?q=" + sterm;
console.log("sterm = ", sterm, " ; going to ", new_url);
window.location.href = new_url;
}
if (!$('#site-search-box').length){
$("nav.courseware").find("ol").append(lb + "section style='float:right'" + rlb + "input size='20'"
+ " id='site-search-box'"
+ rlb + "img src='" + course_static_url
+ "/images_search_glass.png'/" + rlb + "/input" + rlb + "/section" + rb);
}
$("#site-search-box").keypress(function(event) {
if (event.which == 13) {
event.preventDefault();
go_to_search();
}
});
// $('#site-search-box').bind("enterKey", go_to_search);
var get = function(x){
return eval(x);
}
return {'course_static_url': course_static_url,
'jump_to_url': jump_to_url,
'go_to_search': go_to_search,
'get_search_module': get_search_module,
'get_search_module_ficus': get_search_module_ficus,
'get': get,
}
}
var the_site_search = add_site_search();
var add_fix_transcript = function(){
if ($('div.wrap-instructor-info').length==0){
return;
}
$('div.xblock-student_view-video').each(function(key, vblock_e){
var vblock = $(vblock_e);
var vuid = vblock.data('usage-id').split('@');
var vid;
if (vuid.length==1){
vuid = vblock.data('usage-id').split(';_')
vid = vuid[5];
}else{
vid = vuid[2];
}
var mfnpre = vid.split("_video",1)[0];
var mfnid = mfnpre; // no periods
mfnpre = mfnpre.replace('8_370', '8.370'); // periods in gh filename
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var mke = function(x){ return lb + x + rb; }
var ftid = "fix_transcript_" + mfnid;
if (!$('#' + ftid).length){
var html = lb + "span id='" + ftid + "' style='float:right'" + rb + lb + "a href='#'" + rb;
html += "contribute transcript fix" + mke("/a") + mke("/span");
console.log("html = ", html);
vblock.after(html)
}
$('#' + ftid).click(function(){
var cst = $('ol.subtitles').find('li.current');
var cindex = Number(cst.data('index'));
var gurl;
if (mfnpre.endsWith('_cq_sol')){
gurl = "https://github.com/mitocw/content-mit-8370x-cq-sol-subtitles/blob/master/";
}else{
gurl = "https://github.com/mitocw/content-mit-8370x-subtitles/blob/master/";
}
gurl += mfnpre + ".txt#L" + String(cindex + 10 + 1);
console.log("going to ", gurl);
window.open(gurl, "MITx 8.370x subtitle source");
});
});
}
try{
add_fix_transcript();
}
catch(err){
console.log(err);
}
try{
var rb = String.fromCharCode(62);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 3000);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 8000);
}
catch(err){
console.log(err);
}
</script></span>
</div>
</div>
</div>
</div>
<div class="xblock xblock-public_view xblock-public_view-vertical" data-init="VerticalStudentView" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@vertical+block@Quantum_basics_II" data-block-type="vertical" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<h2 class="hd hd-2 unit-title">Quantum basics II</h2>
<div class="vert-mod">
<div class="vert vert-0" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Positive_semi-definite_operators" class="problems-wrapper" role="group"
aria-labelledby="Positive_semi-definite_operators-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="1"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Positive_semi-definite_operators-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators-problem-progress" tabindex="-1">
Positive semi-definite operators
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Positive_semi-definite_operators-problem-progress"></div>
<div class="problem">
<div>
<p>
[mathjaxinline]X[/mathjaxinline] and [mathjaxinline]Y[/mathjaxinline] are Hermitian and positive semi-definite (PSD). Which expressions are always PSD? </p>
<p>
<div class="wrapper-problem-response" tabindex="-1" aria-label="Question 1" role="group"><div class="choicegroup capa_inputtype" id="inputtype_Positive_semi-definite_operators_2_1">
<fieldset aria-describedby="status_Positive_semi-definite_operators_2_1">
<div class="field">
<input type="checkbox" name="input_Positive_semi-definite_operators_2_1[]" id="input_Positive_semi-definite_operators_2_1_choice_0" class="field-input input-checkbox" value="choice_0"/><label id="Positive_semi-definite_operators_2_1-choice_0-label" for="input_Positive_semi-definite_operators_2_1_choice_0" class="response-label field-label label-inline" aria-describedby="status_Positive_semi-definite_operators_2_1">
<text>[mathjaxinline]X^2[/mathjaxinline]</text>
</label>
</div>
<div class="field">
<input type="checkbox" name="input_Positive_semi-definite_operators_2_1[]" id="input_Positive_semi-definite_operators_2_1_choice_1" class="field-input input-checkbox" value="choice_1"/><label id="Positive_semi-definite_operators_2_1-choice_1-label" for="input_Positive_semi-definite_operators_2_1_choice_1" class="response-label field-label label-inline" aria-describedby="status_Positive_semi-definite_operators_2_1">
<text>[mathjaxinline]XY[/mathjaxinline]</text>
</label>
</div>
<div class="field">
<input type="checkbox" name="input_Positive_semi-definite_operators_2_1[]" id="input_Positive_semi-definite_operators_2_1_choice_2" class="field-input input-checkbox" value="choice_2"/><label id="Positive_semi-definite_operators_2_1-choice_2-label" for="input_Positive_semi-definite_operators_2_1_choice_2" class="response-label field-label label-inline" aria-describedby="status_Positive_semi-definite_operators_2_1">
<text>[mathjaxinline]XYX[/mathjaxinline]</text>
</label>
</div>
<div class="field">
<input type="checkbox" name="input_Positive_semi-definite_operators_2_1[]" id="input_Positive_semi-definite_operators_2_1_choice_3" class="field-input input-checkbox" value="choice_3"/><label id="Positive_semi-definite_operators_2_1-choice_3-label" for="input_Positive_semi-definite_operators_2_1_choice_3" class="response-label field-label label-inline" aria-describedby="status_Positive_semi-definite_operators_2_1">
<text>[mathjaxinline]X+Y[/mathjaxinline]</text>
</label>
</div>
<span id="answer_Positive_semi-definite_operators_2_1"/>
</fieldset>
<div class="indicator-container">
<span class="status unanswered" id="status_Positive_semi-definite_operators_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
</div>
</div></div>
</p>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Positive semi-definite operators" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Positive_semi-definite_operators" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Positive_semi-definite_operators">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Positive_semi-definite_operators-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Positive_semi-definite_operators-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Positive_semi-definite_operators-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-1" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_Quantum_states_and_matrices" class="problems-wrapper" role="group"
aria-labelledby="Quantum_states_and_matrices-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="1"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="Quantum_states_and_matrices-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices-problem-progress" tabindex="-1">
Quantum states and matrices
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@Quantum_states_and_matrices-problem-progress"></div>
<div class="problem">
<div>
<p>
Complete the following sequence of logic to show that the following are all equivalent, for matrices [mathjaxinline]A[/mathjaxinline] and [mathjaxinline]B[/mathjaxinline], and quantum states [mathjaxinline]|x\rangle[/mathjaxinline]: </p>
<ul class="itemize">
<li>
<p>
(1) [mathjaxinline]A[/mathjaxinline] has nonnegative eigenvalues, </p>
</li>
<li>
<p>
(2) [mathjaxinline]A = B^\dagger B[/mathjaxinline], </p>
</li>
<li>
<p>
(3) [mathjaxinline]\langle x|A|x\rangle \geq 0[/mathjaxinline] for all [mathjaxinline]|x\rangle[/mathjaxinline] </p>
</li>
</ul>
<span>
<div class="wrapper-problem-response" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_Quantum_states_and_matrices_2_1" class="capa_inputtype">
<div class="drag_and_drop_problem_div" id="drag_and_drop_div_Quantum_states_and_matrices_2_1" data-plain-id="Quantum_states_and_matrices_2_1">
</div>
<div class="drag_and_drop_problem_json" id="drag_and_drop_json_Quantum_states_and_matrices_2_1" style="display:none;">{"draggables": [{"target_fields": [], "label": "", "icon": "/assets/courseware/v1/a39f1b6d2e323a92574213d63aed9a7e/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label1.png", "can_reuse": "true", "id": "rmunitary"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/73590fbf09c6df9b8dd7414c6242daa7/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label2.png", "can_reuse": "true", "id": "rmpolar"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/0322aa35be40f8f2102e877a1f73ad49/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label3.png", "can_reuse": "true", "id": "rmsingularvalue"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/c71069cd5fb65e0d3d5375dadab44363/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label4.png", "can_reuse": "true", "id": "rmsignificant"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/2ddb6d6726ae12d792a209ea5d5ffe84/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label5.png", "can_reuse": "true", "id": "rmspectral"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/4375c1d6e1112ec535bdb9d6b5d08836/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label6.png", "can_reuse": "true", "id": "rmdiagonal"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/bc2d5b3620dc4f6cbefb37b8c90348b7/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label7.png", "can_reuse": "true", "id": "VdaggerV"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/cb5a11200df2a1dbb760c5988c29b95e/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label8.png", "can_reuse": "true", "id": "UdaggerU"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/f4fdb174b0b9831f3eacb60a26d0bb21/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label9.png", "can_reuse": "true", "id": "U"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/5ea2f8003e572a93706d5200d7e0d33d/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label10.png", "can_reuse": "true", "id": "D"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/5b555fd3e3d86bbe10a4cd184932fd25/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label11.png", "can_reuse": "true", "id": "UdaggerDU"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/f4bb903c30bf4d9ef4e03f2474617197/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label12.png", "can_reuse": "true", "id": "leq"}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/fb67ac949cd3891f098aca24c7b9934a/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label13.png", "can_reuse": "true", "id": ""}, {"target_fields": [], "label": "", "icon": "/assets/courseware/v1/54c65d12f3b27afe75aa495efbe71909/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd_label14.png", "can_reuse": "true", "id": "geq"}], "label_bg_color": "rgb(222, 139, 238)", "base_image": "/assets/courseware/v1/af9d559c865294b1faf2df8befbcd783/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_ps0_p6a_ps0_p6a_dnd.png", "target_outline": "false", "targets": [{"w": "141", "y": "0", "x": "277", "id": "1", "h": "54"}, {"w": "142", "y": "70", "x": "6", "id": "2", "h": "54"}, {"w": "141", "y": "70", "x": "319", "id": "3", "h": "54"}, {"w": "142", "y": "163", "x": "364", "id": "4", "h": "53"}, {"w": "141", "y": "336", "x": "661", "id": "16", "h": "53"}, {"w": "142", "y": "406", "x": "254", "id": "5", "h": "54"}, {"w": "142", "y": "406", "x": "535", "id": "15", "h": "54"}, {"w": "142", "y": "520", "x": "442", "id": "17", "h": "53"}, {"w": "142", "y": "597", "x": "237", "id": "6", "h": "53"}, {"w": "142", "y": "674", "x": "237", "id": "7", "h": "53"}], "one_per_target": "true"}</div>
<div class="script_placeholder" data-src="/static/js/capa/drag_and_drop.a31124208b9b.js"/>
<div class="unanswered" id="status_Quantum_states_and_matrices_2_1">
<input type="text" name="input_Quantum_states_and_matrices_2_1" id="input_Quantum_states_and_matrices_2_1" aria-describedby="answer_Quantum_states_and_matrices_2_1" value="" style="display:none;"/>
<p class="indicator-container drag-and-drop--status" aria-describedby="input_Quantum_states_and_matrices_2_1">
<span class="status unanswered" id="status_Quantum_states_and_matrices_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
</p>
<p id="answer_Quantum_states_and_matrices_2_1" class="answer"/>
</div>
</div></div>
<div class="solution-span">
<span id="solution_Quantum_states_and_matrices_solution_1"/>
</div></span>
<p>
<div class="solution-span">
<span id="solution_Quantum_states_and_matrices_solution_2"/>
</div></p>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Quantum states and matrices" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_Quantum_states_and_matrices" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_Quantum_states_and_matrices">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Quantum_states_and_matrices-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Quantum_states_and_matrices-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="Quantum_states_and_matrices-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-2" data-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@html_site_search_box2xxx">
<div class="xblock xblock-public_view xblock-public_view-html xmodule_display xmodule_HtmlBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@html_site_search_box2xxx" data-block-type="html" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "HTMLModule"}
</script>
<span><a href="/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/NONE" id="dummy_course_static_link" style="display:none"/><a href="/courses/course-v1:MITx+8.371.1x+2T2018/jump_to_id/NONE" id="dummy_jump_link" style="display:none"/><script type="text/javascript">
var add_site_search = function(){
course_static_url = $('#dummy_course_static_link').attr('href').replace('/NONE', '');
jump_to_url = $('#dummy_jump_link').attr('href').replace('/NONE', '');
if (typeof String.prototype.startsWith != 'function') {
// see below for better implementation!
String.prototype.startsWith = function (str){
return this.indexOf(str) === 0;
};
}
if(typeof(String.prototype.trim) === "undefined")
{
String.prototype.trim = function()
{
return String(this).replace(/^\s+|\s+$/g, '');
};
}
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var amp = String.fromCharCode(38);
var rlb = rb + lb;
var mke = function(x){ return lb + x + rb; }
var search_module_url = "";
var get_search_module_ficus = function(){
var cid = $('div.xblock').data('course-id');
if (cid){
console.log("cid = ", cid);
// search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/" + cid + "/courseware/welcome/Search_this_course/";
search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/courseware/welcome/Search_this_course/"; // automatically rewritten
console.log("3. search_module_url = ", search_module_url);
return;
}
var course_root_link = $('span.nav-item-course').find('a').attr('href');
if (course_root_link){
console.log("course_root_link = ", course_root_link);
search_module_url = course_root_link.replace("course/", "courseware/welcome/Search_this_course/");
console.log("2. search_module_url = ", search_module_url);
return
}
console.log("cannot determine search module url");
}
var get_search_module = function(){
// find search this module link
if (!($('div.course-index').length)){
return get_search_module_ficus();
}
$('div.course-index').find('nav').find('a').each(function(){
if ($(this).text().trim().startsWith("Search this course")){
search_module_url = $(this).attr('href');
console.log("search_module_url = ", search_module_url);
}
});
}
var go_to_search = function(){
get_search_module();
var sterm = $('#site-search-box').val();
// new_url = jump_to_url + "/Search_this_module/?q=" + sterm;
new_url = search_module_url + "?q=" + sterm;
console.log("sterm = ", sterm, " ; going to ", new_url);
window.location.href = new_url;
}
if (!$('#site-search-box').length){
$("nav.courseware").find("ol").append(lb + "section style='float:right'" + rlb + "input size='20'"
+ " id='site-search-box'"
+ rlb + "img src='" + course_static_url
+ "/images_search_glass.png'/" + rlb + "/input" + rlb + "/section" + rb);
}
$("#site-search-box").keypress(function(event) {
if (event.which == 13) {
event.preventDefault();
go_to_search();
}
});
// $('#site-search-box').bind("enterKey", go_to_search);
var get = function(x){
return eval(x);
}
return {'course_static_url': course_static_url,
'jump_to_url': jump_to_url,
'go_to_search': go_to_search,
'get_search_module': get_search_module,
'get_search_module_ficus': get_search_module_ficus,
'get': get,
}
}
var the_site_search = add_site_search();
var add_fix_transcript = function(){
if ($('div.wrap-instructor-info').length==0){
return;
}
$('div.xblock-student_view-video').each(function(key, vblock_e){
var vblock = $(vblock_e);
var vuid = vblock.data('usage-id').split('@');
var vid;
if (vuid.length==1){
vuid = vblock.data('usage-id').split(';_')
vid = vuid[5];
}else{
vid = vuid[2];
}
var mfnpre = vid.split("_video",1)[0];
var mfnid = mfnpre; // no periods
mfnpre = mfnpre.replace('8_370', '8.370'); // periods in gh filename
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var mke = function(x){ return lb + x + rb; }
var ftid = "fix_transcript_" + mfnid;
if (!$('#' + ftid).length){
var html = lb + "span id='" + ftid + "' style='float:right'" + rb + lb + "a href='#'" + rb;
html += "contribute transcript fix" + mke("/a") + mke("/span");
console.log("html = ", html);
vblock.after(html)
}
$('#' + ftid).click(function(){
var cst = $('ol.subtitles').find('li.current');
var cindex = Number(cst.data('index'));
var gurl;
if (mfnpre.endsWith('_cq_sol')){
gurl = "https://github.com/mitocw/content-mit-8370x-cq-sol-subtitles/blob/master/";
}else{
gurl = "https://github.com/mitocw/content-mit-8370x-subtitles/blob/master/";
}
gurl += mfnpre + ".txt#L" + String(cindex + 10 + 1);
console.log("going to ", gurl);
window.open(gurl, "MITx 8.370x subtitle source");
});
});
}
try{
add_fix_transcript();
}
catch(err){
console.log(err);
}
try{
var rb = String.fromCharCode(62);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 3000);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 8000);
}
catch(err){
console.log(err);
}
</script></span>
</div>
</div>
</div>
</div>
<div class="xblock xblock-public_view xblock-public_view-vertical" data-init="VerticalStudentView" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@vertical+block@Density_matrices_and_unravelings" data-block-type="vertical" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<h2 class="hd hd-2 unit-title">Density matrices and unravelings</h2>
<div class="vert-mod">
<div class="vert vert-0" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_s12-wk1-denmat" class="problems-wrapper" role="group"
aria-labelledby="s12-wk1-denmat-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="4"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="s12-wk1-denmat-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat-problem-progress" tabindex="-1">
Density matrices and unravelings (1 of 3)
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat-problem-progress"></div>
<div class="problem">
<div>
<p>
This problem illustrates the many possible physical interpretations of a density matrix, based on the infinite number possible <em>unravelings</em> of density matrices into different possible statistical mixtures of pure states. </p>
<p>
Consider the bipartite quantum state </p>
<table id="a0000000013" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax]|\psi _{AB}\rangle = \sqrt{\frac{3}{4}} |00\rangle + \sqrt{\frac{1}{4}} |11\rangle[/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none;text-align:right">(1.1)</td>
</tr>
</table>
<p>
jointly held by Alice and Bob (each has one qubit). Suppose Bob measures his qubit in the computational basis. We may depict this with the quantum circuit: </p>
<p>
<center>
<img src="/assets/courseware/v1/884624d0e94ac1af1cf3db8c44449694/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_denmat-measure-basis1.png" width="420"/>
</center>
</p>
<p>
What state does Alice have? Answer this by writing down, at first, Alice's state [mathjaxinline]|\psi '_{A,k}\rangle[/mathjaxinline] (after Bob's measurement) conditioned on Bob obtaining result [mathjaxinline]k[/mathjaxinline] (either [mathjaxinline]k=0[/mathjaxinline] or [mathjaxinline]k=1[/mathjaxinline]) from his measurement; include the probability of this result occuring. </p>
<p>
Be sure that [mathjaxinline]|\psi '_{A,k}\rangle[/mathjaxinline] is properly normalized. </p>
<p>
Recall that states should be entered using &#8220;ket" notation, e.g. [mathjaxinline]|0\rangle[/mathjaxinline] is [mathjaxinline]{\tt |0&gt;}[/mathjaxinline]. </p>
<ul class="itemize">
<li>
<p>
<p style="display:inline">Alice's state [mathjaxinline]|\psi '_{A,0}\rangle[/mathjaxinline] when Bob measures [mathjaxinline]k=0[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_s12-wk1-denmat_2_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="text-input-dynamath_data inline" data-preprocessor="MathjaxPreprocessorForQM"/>
<div class="script_placeholder" data-src="/assets/courseware/v1/95fe583d41f010195cf50c9f61992d94/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/mathjax_preprocessor_for_QM_H.js"/>
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat_2_1" id="input_s12-wk1-denmat_2_1" aria-describedby="status_s12-wk1-denmat_2_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat_2_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat_2_1" class="answer"/>
<div id="display_s12-wk1-denmat_2_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat_2_1_dynamath" name="input_s12-wk1-denmat_2_1_dynamath"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Probability of Bob measuring [mathjaxinline]k=0[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 2" role="group"><div id="inputtype_s12-wk1-denmat_3_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat_3_1" id="input_s12-wk1-denmat_3_1" aria-describedby="status_s12-wk1-denmat_3_1" value="" size="10"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat_3_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat_3_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat_3_1" class="answer"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Alice's state [mathjaxinline]|\psi '_{A,1}\rangle[/mathjaxinline] when Bob measures [mathjaxinline]k=1[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 3" role="group"><div id="inputtype_s12-wk1-denmat_4_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="text-input-dynamath_data inline" data-preprocessor="MathjaxPreprocessorForQM"/>
<div class="script_placeholder" data-src="/assets/courseware/v1/95fe583d41f010195cf50c9f61992d94/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/mathjax_preprocessor_for_QM_H.js"/>
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat_4_1" id="input_s12-wk1-denmat_4_1" aria-describedby="status_s12-wk1-denmat_4_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat_4_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat_4_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat_4_1" class="answer"/>
<div id="display_s12-wk1-denmat_4_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat_4_1_dynamath" name="input_s12-wk1-denmat_4_1_dynamath"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Probability of Bob measuring [mathjaxinline]k=1[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 4" role="group"><div id="inputtype_s12-wk1-denmat_5_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat_5_1" id="input_s12-wk1-denmat_5_1" aria-describedby="status_s12-wk1-denmat_5_1" value="" size="10"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat_5_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat_5_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat_5_1" class="answer"/>
</div>
</div></div>
</p>
</li>
</ul>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Density matrices and unravelings (1 of 3)" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_s12-wk1-denmat" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_s12-wk1-denmat">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-1" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_s12-wk1-denmat2" class="problems-wrapper" role="group"
aria-labelledby="s12-wk1-denmat2-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="4"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="s12-wk1-denmat2-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2-problem-progress" tabindex="-1">
Density matrices and unravelings (2 of 3)
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat2-problem-progress"></div>
<div class="problem">
<div>
<p>
Now suppose that Bob did the measurement of his qubit in a different basis, say by first applying a Hadamard gate then measuring in the computational basis. We may depict this with the quantum circuit (recall [mathjaxinline]|\psi _{AB}\rangle = \sqrt{\frac{3}{4}} |00\rangle + \sqrt{\frac{1}{4}} |11\rangle[/mathjaxinline]): </p>
<p>
<center>
<img src="/assets/courseware/v1/383828b46ac92af8574748f0252be53b/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/images_denmat-measure-basis2.png" width="420"/>
</center>
</p>
<p>
What state does Alice have? Again, answer this by writing down Alice's state [mathjaxinline]|\psi "_{A,k}\rangle[/mathjaxinline] (after Bob's measurement) conditioned on Bob obtaining result [mathjaxinline]k[/mathjaxinline] (either [mathjaxinline]k=0[/mathjaxinline] or [mathjaxinline]k=1[/mathjaxinline]) from his measurement; include the probability of this result occuring. Be sure that [mathjaxinline]|\psi "_{A,k}\rangle[/mathjaxinline] is properly normalized: </p>
<ul class="itemize">
<li>
<p>
<p style="display:inline">Alice's state [mathjaxinline]|\psi "_{A,0}\rangle[/mathjaxinline] when Bob measures [mathjaxinline]k=0[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_s12-wk1-denmat2_2_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="text-input-dynamath_data inline" data-preprocessor="MathjaxPreprocessorForQM"/>
<div class="script_placeholder" data-src="/assets/courseware/v1/95fe583d41f010195cf50c9f61992d94/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/mathjax_preprocessor_for_QM_H.js"/>
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat2_2_1" id="input_s12-wk1-denmat2_2_1" aria-describedby="status_s12-wk1-denmat2_2_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat2_2_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat2_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat2_2_1" class="answer"/>
<div id="display_s12-wk1-denmat2_2_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat2_2_1_dynamath" name="input_s12-wk1-denmat2_2_1_dynamath"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Probability of Bob measuring [mathjaxinline]k=0[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 2" role="group"><div id="inputtype_s12-wk1-denmat2_3_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat2_3_1" id="input_s12-wk1-denmat2_3_1" aria-describedby="status_s12-wk1-denmat2_3_1" value="" size="10"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat2_3_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat2_3_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat2_3_1" class="answer"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Alice's state [mathjaxinline]|\psi "_{A,1}\rangle[/mathjaxinline] when Bob measures [mathjaxinline]k=1[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 3" role="group"><div id="inputtype_s12-wk1-denmat2_4_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="text-input-dynamath_data inline" data-preprocessor="MathjaxPreprocessorForQM"/>
<div class="script_placeholder" data-src="/assets/courseware/v1/95fe583d41f010195cf50c9f61992d94/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/mathjax_preprocessor_for_QM_H.js"/>
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat2_4_1" id="input_s12-wk1-denmat2_4_1" aria-describedby="status_s12-wk1-denmat2_4_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat2_4_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat2_4_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat2_4_1" class="answer"/>
<div id="display_s12-wk1-denmat2_4_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat2_4_1_dynamath" name="input_s12-wk1-denmat2_4_1_dynamath"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Probability of Bob measuring [mathjaxinline]k=1[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 4" role="group"><div id="inputtype_s12-wk1-denmat2_5_1" class=" capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat2_5_1" id="input_s12-wk1-denmat2_5_1" aria-describedby="status_s12-wk1-denmat2_5_1" value="" size="10"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat2_5_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat2_5_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat2_5_1" class="answer"/>
</div>
</div></div>
</p>
</li>
</ul>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Density matrices and unravelings (2 of 3)" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_s12-wk1-denmat2" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_s12-wk1-denmat2">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat2-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat2-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat2-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-2" data-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3">
<div class="xblock xblock-public_view xblock-public_view-problem xmodule_display xmodule_ProblemBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3" data-block-type="problem" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="True">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "Problem"}
</script>
<div id="problem_s12-wk1-denmat3" class="problems-wrapper" role="group"
aria-labelledby="s12-wk1-denmat3-problem-title"
data-problem-id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3" data-url="/courses/course-v1:MITx+8.371.1x+2T2018/xblock/block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3/handler/xmodule_handler"
data-problem-score="0"
data-problem-total-possible="2"
data-attempts-used="0"
data-content="
<h3 class="hd hd-3 problem-header" id="s12-wk1-denmat3-problem-title" aria-describedby="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3-problem-progress" tabindex="-1">
Density matrices and unravelings (3 of 3)
</h3>
<div class="problem-progress" id="block-v1:MITx+8.371.1x+2T2018+type@problem+block@s12-wk1-denmat3-problem-progress"></div>
<div class="problem">
<div>
<p>
The two sets of states [mathjaxinline]\{ |\psi '_{A,k}\rangle \}[/mathjaxinline] and [mathjaxinline]\{ |\psi "_{A,k}\rangle \}[/mathjaxinline] look quite different, somehow implying that the state Alice holds after Bob's measurement is different, and depends on what Bob's measurement result is, and also how Bob chooses to measure his qubit. </p>
<p>
However, it is conceptually problematic to think that Alice's state depends in any way on Bob's measurement. What if Bob chose how to do his measurement long after Alice inquires about the state of her qubit? What if Alice and Bob were far apart &#8211; so fat away from each other that they could each do operations on their own qubits faster than information (eg carried at the speed of light) could travel between them? It should not be possible for Bob to be able to signal Alice faster than the speed of light! </p>
<p>
This apparant paradox can be manifestly resolved (or more accurtately, perhaps, <em>avoided</em>) by using a better mathematical tool to represent the <em>statistical mixture</em> which describes each of the ensemble of states Alice may hold, in the two scenarios above. For an ensemble of states [mathjaxinline]|\psi _ k\rangle[/mathjaxinline] which occur with probability [mathjaxinline]p_ k[/mathjaxinline], the density matrix is </p>
<table id="a0000000014" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax]\rho = \sum p_ k |\psi _ k\rangle \langle \psi _ k|[/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none;text-align:right">(1.2)</td>
</tr>
</table>
<p>
where [mathjaxinline]|\psi _ k\rangle \langle \psi _ k|[/mathjaxinline] is an <a href="http://en.wikipedia.org/wiki/Outer_product" target="_blank"><em>outer product</em></a> of [mathjaxinline]|\psi _ k\rangle[/mathjaxinline] and [mathjaxinline]\langle \psi _ k|[/mathjaxinline]. For example, </p>
<table id="a0000000015" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax]|0\rangle \langle 0| = \left[ \begin{array}{cc}{1}&amp; {0}\\ {0}&amp; {0}\end{array}\right][/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none;text-align:right">(1.3)</td>
</tr>
</table>
<p>
and </p>
<table id="a0000000016" class="equation" width="100%" cellspacing="0" cellpadding="7" style="table-layout:auto">
<tr>
<td class="equation" style="width:80%; border:none">[mathjax]|0\rangle \langle 1| = \left[ \begin{array}{cc}{0}&amp; {1}\\ {0}&amp; {0}\end{array}\right][/mathjax]</td>
<td class="eqnnum" style="width:20%; border:none;text-align:right">(1.4)</td>
</tr>
</table>
<p>
Think of the column labels as the inputs, and the row labels as the outputs. </p>
<p>
Give the density matrices for the ensembles resulting in the two scenarios above. Recall that matrices are specified using an input which is a list of row vectors, eg [mathjaxinline]|0\rangle \langle 1|[/mathjaxinline] is <tt class="tt">[[0,1],[0,0]]</tt>: </p>
<ul class="itemize">
<li>
<p>
<p style="display:inline">Density matrix [mathjaxinline]\rho '[/mathjaxinline] for Alice's state [mathjaxinline]|\psi '_{A,k}\rangle[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 1" role="group"><div id="inputtype_s12-wk1-denmat3_2_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat3_2_1" id="input_s12-wk1-denmat3_2_1" aria-describedby="status_s12-wk1-denmat3_2_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat3_2_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat3_2_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat3_2_1" class="answer"/>
<div id="display_s12-wk1-denmat3_2_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat3_2_1_dynamath" name="input_s12-wk1-denmat3_2_1_dynamath"/>
</div>
</div></div>
</p>
</li>
<li>
<p>
<p style="display:inline">Density matrix [mathjaxinline]\rho "[/mathjaxinline] for Alice's state [mathjaxinline]|\psi "_{A,k}\rangle[/mathjaxinline]:</p>
<div class="inline" tabindex="-1" aria-label="Question 2" role="group"><div id="inputtype_s12-wk1-denmat3_3_1" class="text-input-dynamath capa_inputtype inline textline">
<div class="unanswered inline">
<input type="text" name="input_s12-wk1-denmat3_3_1" id="input_s12-wk1-denmat3_3_1" aria-describedby="status_s12-wk1-denmat3_3_1" value="" class="math" size="60"/>
<span class="trailing_text" id="trailing_text_s12-wk1-denmat3_3_1"/>
<span class="status unanswered" id="status_s12-wk1-denmat3_3_1" data-tooltip="Not yet answered.">
<span class="sr">unanswered</span><span class="status-icon" aria-hidden="true"/>
</span>
<p id="answer_s12-wk1-denmat3_3_1" class="answer"/>
<div id="display_s12-wk1-denmat3_3_1" class="equation">`{::}`</div>
<textarea style="display:none" id="input_s12-wk1-denmat3_3_1_dynamath" name="input_s12-wk1-denmat3_3_1_dynamath"/>
</div>
</div></div>
</p>
</li>
</ul>
<p>
<div class="solution-span">
<span id="solution_s12-wk1-denmat3_solution_1"/>
</div></p>
</div>
<div class="action">
<input type="hidden" name="problem_id" value="Density matrices and unravelings (3 of 3)" />
<div class="submit-attempt-container">
<button type="button" class="submit btn-brand" data-submitting="Submitting" data-value="Submit" data-should-enable-submit-button="True" aria-describedby="submission_feedback_s12-wk1-denmat3" >
<span class="submit-label">Submit</span>
</button>
<div class="submission-feedback" id="submission_feedback_s12-wk1-denmat3">
<span class="sr">Some problems have options such as save, reset, hints, or show answer. These options follow the Submit button.</span>
</div>
</div>
<div class="problem-action-buttons-wrapper">
<span class="problem-action-button-wrapper">
<button type="button" class="save problem-action-btn btn-default btn-small" data-value="Save">
<span class="icon fa fa-floppy-o" aria-hidden="true"></span>
<span aria-hidden="true">Save</span>
<span class="sr">Save your answer</span>
</button>
</span>
</div>
</div>
<div class="notification warning notification-gentle-alert
is-hidden"
tabindex="-1">
<span class="icon fa fa-exclamation-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat3-problem-title">
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification warning notification-save
is-hidden"
tabindex="-1">
<span class="icon fa fa-save" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat3-problem-title">None
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
<div class="notification general notification-show-answer
is-hidden"
tabindex="-1">
<span class="icon fa fa-info-circle" aria-hidden="true"></span>
<span class="notification-message" aria-describedby="s12-wk1-denmat3-problem-title">Answers are displayed within the problem
</span>
<div class="notification-btn-wrapper">
<button type="button" class="btn btn-default btn-small notification-btn review-btn sr">Review</button>
</div>
</div>
</div>
"
data-graded="True">
<p class="loading-spinner">
<i class="fa fa-spinner fa-pulse fa-2x fa-fw"></i>
<span class="sr">Loading…</span>
</p>
</div>
</div>
</div>
<div class="vert vert-3" data-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@site_search_box003109">
<div class="xblock xblock-public_view xblock-public_view-html xmodule_display xmodule_HtmlBlock" data-init="XBlockToXModuleShim" data-course-id="course-v1:MITx+8.371.1x+2T2018" data-request-token="6f013dc8ed6511eeb90f16ffd59041e1" data-graded="True" data-usage-id="block-v1:MITx+8.371.1x+2T2018+type@html+block@site_search_box003109" data-block-type="html" data-runtime-class="LmsRuntime" data-runtime-version="1" data-has-score="False">
<script type="json/xblock-args" class="xblock-json-init-args">
{"xmodule-type": "HTMLModule"}
</script>
<span><a href="/asset-v1:MITx+8.371.1x+2T2018+type@asset+block/NONE" id="dummy_course_static_link" style="display:none"/><a href="/courses/course-v1:MITx+8.371.1x+2T2018/jump_to_id/NONE" id="dummy_jump_link" style="display:none"/><script type="text/javascript">
var add_site_search = function(){
course_static_url = $('#dummy_course_static_link').attr('href').replace('/NONE', '');
jump_to_url = $('#dummy_jump_link').attr('href').replace('/NONE', '');
if (typeof String.prototype.startsWith != 'function') {
// see below for better implementation!
String.prototype.startsWith = function (str){
return this.indexOf(str) === 0;
};
}
if(typeof(String.prototype.trim) === "undefined")
{
String.prototype.trim = function()
{
return String(this).replace(/^\s+|\s+$/g, '');
};
}
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var amp = String.fromCharCode(38);
var rlb = rb + lb;
var mke = function(x){ return lb + x + rb; }
var search_module_url = "";
var get_search_module_ficus = function(){
var cid = $('div.xblock').data('course-id');
if (cid){
console.log("cid = ", cid);
// search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/" + cid + "/courseware/welcome/Search_this_course/";
search_module_url = "/courses/course-v1:MITx+8.371.1x+2T2018/courseware/welcome/Search_this_course/"; // automatically rewritten
console.log("3. search_module_url = ", search_module_url);
return;
}
var course_root_link = $('span.nav-item-course').find('a').attr('href');
if (course_root_link){
console.log("course_root_link = ", course_root_link);
search_module_url = course_root_link.replace("course/", "courseware/welcome/Search_this_course/");
console.log("2. search_module_url = ", search_module_url);
return
}
console.log("cannot determine search module url");
}
var get_search_module = function(){
// find search this module link
if (!($('div.course-index').length)){
return get_search_module_ficus();
}
$('div.course-index').find('nav').find('a').each(function(){
if ($(this).text().trim().startsWith("Search this course")){
search_module_url = $(this).attr('href');
console.log("search_module_url = ", search_module_url);
}
});
}
var go_to_search = function(){
get_search_module();
var sterm = $('#site-search-box').val();
// new_url = jump_to_url + "/Search_this_module/?q=" + sterm;
new_url = search_module_url + "?q=" + sterm;
console.log("sterm = ", sterm, " ; going to ", new_url);
window.location.href = new_url;
}
if (!$('#site-search-box').length){
$("nav.courseware").find("ol").append(lb + "section style='float:right'" + rlb + "input size='20'"
+ " id='site-search-box'"
+ rlb + "img src='" + course_static_url
+ "/images_search_glass.png'/" + rlb + "/input" + rlb + "/section" + rb);
}
$("#site-search-box").keypress(function(event) {
if (event.which == 13) {
event.preventDefault();
go_to_search();
}
});
// $('#site-search-box').bind("enterKey", go_to_search);
var get = function(x){
return eval(x);
}
return {'course_static_url': course_static_url,
'jump_to_url': jump_to_url,
'go_to_search': go_to_search,
'get_search_module': get_search_module,
'get_search_module_ficus': get_search_module_ficus,
'get': get,
}
}
var the_site_search = add_site_search();
var add_fix_transcript = function(){
if ($('div.wrap-instructor-info').length==0){
return;
}
$('div.xblock-student_view-video').each(function(key, vblock_e){
var vblock = $(vblock_e);
var vuid = vblock.data('usage-id').split('@');
var vid;
if (vuid.length==1){
vuid = vblock.data('usage-id').split(';_')
vid = vuid[5];
}else{
vid = vuid[2];
}
var mfnpre = vid.split("_video",1)[0];
var mfnid = mfnpre; // no periods
mfnpre = mfnpre.replace('8_370', '8.370'); // periods in gh filename
var lb = String.fromCharCode(60);
var rb = String.fromCharCode(62);
var mke = function(x){ return lb + x + rb; }
var ftid = "fix_transcript_" + mfnid;
if (!$('#' + ftid).length){
var html = lb + "span id='" + ftid + "' style='float:right'" + rb + lb + "a href='#'" + rb;
html += "contribute transcript fix" + mke("/a") + mke("/span");
console.log("html = ", html);
vblock.after(html)
}
$('#' + ftid).click(function(){
var cst = $('ol.subtitles').find('li.current');
var cindex = Number(cst.data('index'));
var gurl;
if (mfnpre.endsWith('_cq_sol')){
gurl = "https://github.com/mitocw/content-mit-8370x-cq-sol-subtitles/blob/master/";
}else{
gurl = "https://github.com/mitocw/content-mit-8370x-subtitles/blob/master/";
}
gurl += mfnpre + ".txt#L" + String(cindex + 10 + 1);
console.log("going to ", gurl);
window.open(gurl, "MITx 8.370x subtitle source");
});
});
}
try{
add_fix_transcript();
}
catch(err){
console.log(err);
}
try{
var rb = String.fromCharCode(62);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 3000);
setTimeout(function(){ $('.math' + rb + 'span').css("border-left-color","transparent"); }, 8000);
}
catch(err){
console.log(err);
}
</script></span>
</div>
</div>
</div>
</div>
© All Rights Reserved