-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathindex.html
626 lines (520 loc) · 25.3 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
<!DOCTYPE HTML>
<html>
<head>
<title>Quantum 4 Life</title>
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="0" />
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<!-- https://github.com/IonDen/ion.rangeSlider -->
<link rel="stylesheet" type="text/css" href="css/ion.rangeSlider.css">
<link rel="stylesheet" type="text/css" href="css/ion.rangeSlider.skinNice.css">
<script src="js/lib/ion.rangeSlider.min.js"></script>
<script src="js/lib/three.js"></script>
<!-- <script type="module" src='https://cdn.skypack.dev/[email protected]'></script> -->
<!-- <script type="text/css" src='https://cdn.skypack.dev/pin/[email protected]/mode=imports/optimized/three.js'></script> -->
<!-- <script src='https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js'></script> -->
<!-- <script src="https://threejs.org/build/three.js"></script> -->
<!-- <script type="module">
export * from '/-/[email protected]/dist=es2020,mode=imports,min/optimized/three.js';
export {THREE} from '/-/[email protected]/dist=es2020,mode=imports,min/optimized/three.js';</script> -->
<!-- <script type="module">
import * as THREE from 'https://cdn.skypack.dev/three';
import {OrbitControls} from 'https://cdn.skypack.dev/three/examples/jsm/controls/OrbitControls.js';
</script> -->
<!-- <script type="module">import * as THREE from 'https://cdn.skypack.dev/[email protected]';</script> -->
<script src="js/lib/OrbitControls.js"></script>
<script src="js/lib/helvetiker_regular.typeface.js"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"
integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd"
crossorigin="anonymous"></script>
<script src="js/lib/math.js"></script>
<script src="js/computeVector.js"></script>
<script src="js/gui.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<center>
<div id="app" class="blue">
<div id="titleblock" class="col-md-12 colspace alpha60 spaceRow grid-title">
<h1 id="titel">
Quantum Bloch sphere Simulator
<div style="float:right">
<button type="button" class="btn btn-default glyphicon glyphicon-info-sign" data-toggle="modal"
data-target="#infoModal"></button>
</div>
</h1>
</div>
<div id="inputfields" class="grid-user-inputs">
<!-- 1st row spaceRow -->
<div class="row spaceRow">
<div class="alpha60">
<ul class="nav nav-tabs">
<li class="active">
<a data-toggle="tab" href="#section1" id='tab1'>
<div class="tabTop">
<img src="img/blok1.png" style="width:20px;height:20px;" />
<h3> Ψ₁ </h3>
</div>
<!--<img src="img/psi1.png" style="width:33px;height:25px;"/>-->
</a>
</li>
<li>
<a data-toggle="tab" href="#section2" id='tab2'>
<div class="tabTop">
<img src="img/blok2.png" style="width:20px;height:20px;" />
<h3> Ψ₂ </h3>
</div>
</a>
</li>
<li>
<a data-toggle="tab" href="#section3" id='tab3'>
<div class="tabTop">
<img src="img/blok3.png" style="width:20px;height:20px;" />
<h3> Ψ₃ </h3>
</div>
</a>
</li>
<li>
<a data-toggle="tab" href="#section4" id='tab4'>
<div class="tabTop">
<img src="img/blok4.png" style="width:20px;height:20px;" />
<h3> Ψ₄ </h3>
</div>
</a>
</li>
</ul>
<div class="tab-content">
<div id="section1" class="tab-pane fade in active"></div>
<div id="section2" class="tab-pane fade"></div>
<div id="section3" class="tab-pane fade"></div>
<div id="section4" class="tab-pane fade"></div>
</div>
</div>
</div>
<!-- 2nd row spaceRow -->
<div class="row spaceRow">
<div class="alpha60">
<ul class="nav nav-tabs">
<li class="active">
<a data-toggle="tab" href="#bottom-section1" id='bottom-tab1'>
<h3>Add Noise</h3>
</a>
</li>
<li>
<a data-toggle="tab" href="#bottom-section2" id='bottom-tab2'>
<h3>Mixed State</h3>
</a>
</li>
<li>
<a data-toggle="tab" href="#bottom-section3" id='bottom-tab3'>
<h3>Unitary Transformation</h3>
</a>
</li>
</ul>
<div class="tab-content">
<div id="bottom-section1" class="tab-pane fade in active">
<div class="row">
<div class="col-md-6">
<h4 class="indentText"> Noise type: </h4>
<select autocomplete="off" id="noise-select">
<option value="D" selected="selected">Depolarizing </option>
<option value="PhX">Dephase X</option>
<option value="PhZ">Dephase Z</option>
<option value="A">Amplitude damping</option>
<option value="user">User defined transformation</option>
</select>
<button class="btn btn-default btn-md buttonMargin"
id="noise-update_button">Show transformed state</button>
</div>
<div class="col-md-6">
<img src="img/noiseEq_D.png" id="noise-equation-img" width="200px" />
</div>
</div>
<div class='row'>
<div class="col-md-6">
<h4 class="indentText">Noise matrix E<sub>1</sub></h4>
<input id="input_noise_E1_a" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<input id="input_noise_E1_b" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<br />
<input id="input_noise_E1_c" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<input id="input_noise_E1_d" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
</div>
<div class="col-md-6">
<h4 class="indentText">Noise matrix E<sub>2</sub></h4>
<input id="input_noise_E2_a" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<input id="input_noise_E2_b" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<br />
<input id="input_noise_E2_c" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
<input id="input_noise_E2_d" class="input_noise" type="text"
style="width:80px; margin:10px;"></input>
</div>
</div>
<div class='col-md-12'>
<div class='spaceRow row'>
<div class="col-md-1 smallPadding greekAngles">
<h5>r</h5>
</div>
<div class="col-md-1 smallPadding">
<input id="noise_r" class="inputAngles" type="text" value="1.0">
</div>
<div class='range-slider col-md-10'>
<input id="noise_slider" type='text' class='js-range-slider-noise'
value='' />
</div>
</div>
</div>
</div>
<div id="bottom-section2" class="tab-pane fade">
<p id="mixedStateFunction">Wave function: Ψ = <span
class='state-1'>0</span>·Ψ₁ + <span
class='state-2'>0</span>·Ψ₂ + <span
class='state-3'>0</span>·Ψ₃ + <span
class='state-4'>0</span>·Ψ₄</p>
<div class='row'>
<div class='range-slider'>
<div class='col-md-6 checkboxes'>
<div class='col-md-2'>
<h4 class="state-1">Ψ₁</h4>
</div>
<div class='col-md-10'>
<label><input type="checkbox" autocomplete="off" id="check-active-1"
name="checkbox" value="value" onchange="checkActive(this)">
Active </label>
<label><input type="checkbox" autocomplete="off" id="check-lock-1"
name="checkbox" value="value" onchange="checkLock(this)"
disabled='true'> Lock probability </label>
</div>
</div>
<div class='col-md-6'>
<input type='text' class='js-range-slider-mixed-1' value='' />
</div>
</div>
<div class='range-slider'>
<div class='col-md-6 checkboxes'>
<div class='col-md-2'>
<h4 class="state-2">Ψ₂</h4>
</div>
<div class='col-md-10'>
<label><input type="checkbox" autocomplete="off" id="check-active-2"
name="checkbox" value="value" onchange="checkActive(this)">
Active </label>
<label><input type="checkbox" autocomplete="off" id="check-lock-2"
name="checkbox" value="value" onchange="checkLock(this)"
disabled='true'> Lock probability </label>
</div>
</div>
<div class='col-md-6'>
<input type='text' class='js-range-slider-mixed-2' value='' />
</div>
</div>
<div class='range-slider'>
<div class='col-md-6 checkboxes'>
<div class='col-md-2'>
<h4 class="state-3">Ψ₃</h4>
</div>
<div class='col-md-10'>
<label><input type="checkbox" autocomplete="off" id="check-active-3"
name="checkbox" value="value" onchange="checkActive(this)">
Active </label>
<label><input type="checkbox" autocomplete="off" id="check-lock-3"
name="checkbox" value="value" onchange="checkLock(this)"
disabled='true'> Lock probability </label>
</div>
</div>
<div class='col-md-6'>
<input type='text' class='js-range-slider-mixed-3' value='' />
</div>
</div>
<div class='range-slider'>
<div class='col-md-6 checkboxes'>
<div class='col-md-2'>
<h4 class="state-4">Ψ₄</h4>
</div>
<div class='col-md-10'>
<label><input type="checkbox" autocomplete="off" id="check-active-4"
name="checkbox" value="value" onchange="checkActive(this)">
Active </label>
<label><input type="checkbox" autocomplete="off" id="check-lock-4"
name="checkbox" value="value" onchange="checkLock(this)"
disabled='true'> Lock probability </label>
</div>
</div>
<div class='col-md-6'>
<input type='text' class='js-range-slider-mixed-4' value='' />
</div>
</div>
<div class='col-md-12'>
<button id='btn_compute_mixed'
class='btn btn-default btn-md buttonMargin'>Compute mixed state</button>
</div>
</div>
</div>
<div id="bottom-section3" class="tab-pane fade">
<div class="row">
<div class="col-md-6">
<h4 class="indentText"> Choose unitary: </h4>
<select autocomplete="off" id="gate-select">
<option value="X" selected="selected">Pauli-X gate</option>
<option value="Y">Pauli-Y gate</option>
<option value="Z">Pauli-Z gate</option>
<option value="H">Hadamard gate</option>
<option value="R">Phase Shift</option>
<option value="hamil">Evolving State</option>
<option value="user">User defined unitary</option>
</select>
<div id="angle-for-uni" class="col-md-12" invisible>
Phase: <input id="angle_input" type="text" value="0"
style="width:60px; margin:10px; text-align:right;"></input> π
</div>
</div>
<div class="col-md-6">
<button class="btn btn-default btn-md buttonMargin "
id="gate-update_button">Show transformed state</button>
</div>
</div>
<div class='row'>
<div class="col-md-6">
<h4 class="indentText">Unitary</h4>
<input id="input_gate_a" class="input_gate" type="text"
style="width:85px; margin:10px;" disabled></input>
<input id="input_gate_b" class="input_gate" type="text"
style="width:85px; margin:10px;" disabled></input>
<br />
<input id="input_gate_c" class="input_gate" type="text"
style="width:85px; margin:10px;" disabled></input>
<input id="input_gate_d" class="input_gate" type="text"
style="width:85px; margin:10px;" disabled></input>
</div>
<div id="hamiltonian" class="col-md-6">
<h4 class="indentText">Hamiltonian</h4>
<input id="input_hamil_a" type="text" style="width:85px; margin:10px;"
value="0"></input>
<input id="input_hamil_b" type="text" style="width:85px; margin:10px;"
value="1"></input>
<br />
<input id="input_hamil_c" type="text" style="width:85px; margin:10px;"
value="1"></input>
<input id="input_hamil_d" type="text" style="width:85px; margin:10px;"
value="0"></input>
</div>
</div>
<div id='timeslider' class='col-md-12'>
<div class='spaceRow row'>
<div class="col-md-1 smallPadding greekAngles">
<h5>t</h5>
</div>
<div class="col-md-1 smallPadding">
<input id="time_t" class="inputAngles" type="number" value="0.00" ,
step=".05">
</div>
<div class='range-slider col-md-10'>
<input id="time_slider" type='text' class='js-range-slider-unitary'
value='' />
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col-md-5 colspace grid-bloch-sphere">
<div id="sphere" class="sphere">
<canvas id="canvas-top" class="canvasSphere" width="500" height="500"></canvas>
</div>
<div id="sphere-noise" class="sphere">
<canvas id="canvas-bottom" class="canvasSphere" width="500" height="500"></canvas>
</div>
</div>
</div>
</center>
<!-- Error Modal -->
<div class="modal fade" id="errorModal" tabindex="-1" role="dialog" aria-labelledby="errorModalTitle"
aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
aria-hidden="true">×</span></button>
<h4 class="modal-title" id="errorModalTitle">Error</h4>
</div>
<div class="modal-body">
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div>
</div>
</div>
</div>
<!-- Info Modal -->
<div class="modal multi-step fade" id="infoModal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<!-- <div class="navbar-header"> -->
<!-- <div class="navbar-left"> -->
<h4 class="modal-title step-1 left" data-step="1">Quantum Bloch-sphere Simulator</h4>
<h4 class="modal-title step-2" data-step="2">Bloch Spheres</h4>
<h4 class="modal-title step-3" data-step="3">Quantum States</h4>
<h4 class="modal-title step-4" data-step="4">Add Noise</h4>
<h4 class="modal-title step-5" data-step="5">Mixed State</h4>
<h4 class="modal-title step-6" data-step="6">Unitary Transformation</h4>
<!-- </div> -->
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
aria-hidden="true">×</span></button>
<!-- <div> -->
<!-- <div class="close"> -->
<!-- <div class='col-md-4'> -->
<!-- <div class="navbar-right btn-nav">
<button type="button" class="btn btn-primary step step-2" data-step="2" onclick="sendEvent('#infoModal', 1)">Back</button>
<button type="button" class="btn btn-primary step step-3" data-step="3" onclick="sendEvent('#infoModal', 2)">Back</button>
<button type="button" class="btn btn-primary step step-4" data-step="4" onclick="sendEvent('#infoModal', 3)">Back</button>
<button type="button" class="btn btn-primary step step-5" data-step="5" onclick="sendEvent('#infoModal', 4)">Back</button>
<button type="button" class="btn btn-primary step step-6" data-step="6" onclick="sendEvent('#infoModal', 5)">Back</button>
<button type="button" class="btn btn-primary step step-1" data-step="1" onclick="sendEvent('#infoModal', 2)">Continue</button>
<button type="button" class="btn btn-primary step step-2" data-step="2" onclick="sendEvent('#infoModal', 3)">Continue</button>
<button type="button" class="btn btn-primary step step-3" data-step="3" onclick="sendEvent('#infoModal', 4)">Continue</button>
<button type="button" class="btn btn-primary step step-4" data-step="4" onclick="sendEvent('#infoModal', 5)">Continue</button>
<button type="button" class="btn btn-primary step step-5" data-step="5" onclick="sendEvent('#infoModal', 6)">Continue</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div> -->
</div>
<div style="min-height:30em">
<div class="modal-body step step-1" data-step="1">
<p>Simulate quantum states, both pure and mixed, in a Bloch-sphere with various quantum noise
channels and gates.
The effects of the various components are shown in real time on the right hand side in the
Bloch-spheres.</p>
</div>
<div class="modal-body step step-2" data-step="2">
<p>Two Bloch-spheres are shown here: one at the top and one at the bottom. The top sphere
represents the Bloch-sphere without any influences from settings in the tabs at the bottom
left. These changes will be made visible in the bottom sphere. The top sphere can be rotated
by the user, the bottom sphere will move with it. <br><br>
Computing the vector in the Bloch-sphere that represents a density matrix is done with the
following formula: <br>
ρ = 1/2 (I + a⋅ σ) <br>
Here a is the Bloch vector of the system and I is the identity. σ represents the three
Hermitian, traceless Pauli matrices, also known as the matrices used as the X-, Y- and
Z-gate. The Bloch vector can be retrieved by computing the trace of the multication of these
Pauli-matrices with the density matrix. The resulting numbers will be the coordinates of the
vector.
</p>
</div>
<div class="modal-body step step-3" data-step="3">
<p>In the top left panel up to 4 states can constructed and added to the Bloch-spheres. The
states can be constructed with two methods: <br><br>
The first one is specifying the polor coordinates the state vector will have in the bloch
sphere. As the length of the vector can not be specified, this will always be 1, so these
states will always be pure states. From the coordinates the wave function can be determined
using the following formula: |Ψ> = cos(θ/2)|0> + sin(θ/2) e<sup>iφ</sup>
<br>
The density matrix can then be constructed by computing |Ψ><Ψ| <br><br>
The second way is to directly fill in values in the density matrix. If the user chooses
this method, the wave function and polar coordinates will not be updated. This is
because not all density matrices can be represented this way. If the density matrix that
is filled in is a mixed state, it is impossible to find the wave function.
</p>
</div>
<div class="modal-body step step-4" data-step="4">
<p> In the noise tab various parameters can be set to visualize how noise changes the shape of
the bloch sphere, and thus how it changes the pure states, which are on the surface of the
sphere. The provided matrices will act on the density matrix according to the following
formula: E<sub>1</sub>ρ
E<sub>1</sub><sup>†</sup>+E<sub>2</sub>ρE<sub>2</sub><sup>†</sup>
<br><br>
There are 4 predetermined noise types available: Depolarizing, Dephasing (X or Z) and
Amplitude Damping. The corresponding noise matrices and formula for the chosen type of noise
will be shown upon selection. For these 4 noise types the amount of noise can be set with
the slider at the bottom of the tab. r = 1 means no noise (matrix E<sub>1</sub> will be the
identiy and E<sub>2</sub> will be zero) and r = 0 means maximum noise. <br><br>
It is also possible for the user to set its own noise matrices. In this case everything is
read and computed directly from the matrices the user provides, so the slider with amount of
noise 'r' will no longer be of influence. The provided noise matrices have to satisfy the
condition: ∑ E<sub>i</sub> E<sub>i</sub><sup>†</sup> = I, with I the identity
matrix. If this condition is not met, the transformed Bloch-sphere will not be computed.
</p>
</div>
<div class="modal-body step step-5" data-step="5">
<p>In this tab the user can create a mixed state. The components of the mixed state are the
existing states the user created in the top panel. The sliders next to each state show the
probability that the state will be created. The active box has to be ticked to include a
state with a probability. The sum of all probabilities always adds up to 1, so when
including more than two states it becomes difficult for the user to control the sliders to
construct the right distribution. For this the 'Lock probability' checkbox was constructed.
When ticked, the probability for that state will not change anymore and the other active
states will make sure the total probability adds up to 1. <br><br>
The generated mixed state is shown as a white arrow in the bloch sphere. Mixed state Bloch
vectors have a lenght smaller than 1, so they will end in the Bloch sphere and not on the
surface. The transformations in the other tabs will also affect the mixed state.
</p>
</div>
<div class="modal-body step step-6" data-step="6">
<p>In the last tab unitary tranformations can be applied to the states. All the states will be
multiplied by the unitary in the following way: U ρ U<sup>†</sup>
<br><br>
There are 5 predetermined unitaries or gates available in the dropdown menu. The first three
are the Pauli-gates, X, Y, Z. On top of that the Hadamard gate and a phase shift gate can be
chosen. For the latter one the user has to specify the phase shift in radians. By choosing
'user defined unitary' the user can decide and fill in any valid unitary.
<br><br>
The other option where user input is needed is the Evolving State. In this case, the unitary
is determined by a Hamiltonian and time. The unitary which is applied to the density matrix
is time-dependent and can be written as follows: U(t) = e<sup>itH</sup>, where H is the
hamiltionian. A slider at the bottom of the tab is provided to see how the states evolve
with different time settings to construct an new Unitary.
</p>
</div>
</div>
<div class="modal-footer">
<div class='row'>
<div class='col-md-8' style='text-align: left'>
<p>Copyright © 2015, created by Annemieke Verbraeck, Frank Marsman and Tung Phan</p>
</div>
<div class='col-md-4'>
<button type="button" class="btn btn-primary step step-2" data-step="2"
onclick="sendEvent('#infoModal', 1)">Back</button>
<button type="button" class="btn btn-primary step step-3" data-step="3"
onclick="sendEvent('#infoModal', 2)">Back</button>
<button type="button" class="btn btn-primary step step-4" data-step="4"
onclick="sendEvent('#infoModal', 3)">Back</button>
<button type="button" class="btn btn-primary step step-5" data-step="5"
onclick="sendEvent('#infoModal', 4)">Back</button>
<button type="button" class="btn btn-primary step step-6" data-step="6"
onclick="sendEvent('#infoModal', 5)">Back</button>
<button type="button" class="btn btn-primary step step-1" data-step="1"
onclick="sendEvent('#infoModal', 2)">Continue</button>
<button type="button" class="btn btn-primary step step-2" data-step="2"
onclick="sendEvent('#infoModal', 3)">Continue</button>
<button type="button" class="btn btn-primary step step-3" data-step="3"
onclick="sendEvent('#infoModal', 4)">Continue</button>
<button type="button" class="btn btn-primary step step-4" data-step="4"
onclick="sendEvent('#infoModal', 5)">Continue</button>
<button type="button" class="btn btn-primary step step-5" data-step="5"
onclick="sendEvent('#infoModal', 6)">Continue</button>
<!-- <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> -->
</div>
</div>
</div>
</div>
</div>
</div>
<!-- https://github.com/ngzhian/multi-step-modal -->
<script src="js/lib/multi-step-modal.js"></script>
<script>
sendEvent = function (sel, step) {
$(sel).trigger('next.m.' + step);
}
</script>
</body>
</html>