-
Notifications
You must be signed in to change notification settings - Fork 836
/
pymatgen.analysis.interface.html
783 lines (630 loc) · 52.9 KB
/
pymatgen.analysis.interface.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
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>pymatgen.analysis.interface module — pymatgen 2021.1.28 documentation</title>
<link rel="canonical" href="https://pymatgen.orgpymatgen.analysis.interface.html"/>
<script type="text/javascript" src="_static/js/modernizr.min.js"></script>
<script type="text/javascript" id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></script>
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/doctools.js"></script>
<script src="_static/language_data.js"></script>
<script async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
<script type="text/javascript" src="_static/js/theme.js"></script>
<link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="_static/css/custom.css" type="text/css" />
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="pymatgen.analysis.interface_reactions module" href="pymatgen.analysis.interface_reactions.html" />
<link rel="prev" title="pymatgen.analysis.hhi module" href="pymatgen.analysis.hhi.html" />
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-33990148-1']);
_gaq.push(['_trackPageview']);
</script>
</head>
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search" style="background: linear-gradient(0deg, rgba(23,63,162,1) 0%, rgba(0,70,192,1) 100%)" >
<a href="index.html" class="icon icon-home"> pymatgen
</a>
<div class="version">
2021.1.28
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="introduction.html">Introduction</a></li>
<li class="toctree-l1"><a class="reference internal" href="installation.html">Installation</a></li>
<li class="toctree-l1"><a class="reference internal" href="change_log.html">Change log</a></li>
<li class="toctree-l1"><a class="reference internal" href="usage.html">Usage</a></li>
<li class="toctree-l1"><a class="reference internal" href="team.html">Development Team</a></li>
<li class="toctree-l1"><a class="reference internal" href="references.html">References</a></li>
<li class="toctree-l1 current"><a class="reference internal" href="modules.html">API Docs</a><ul class="current">
<li class="toctree-l2 current"><a class="reference internal" href="pymatgen.html">pymatgen package</a><ul class="current">
<li class="toctree-l3 current"><a class="reference internal" href="pymatgen.html#subpackages">Subpackages</a><ul class="current">
<li class="toctree-l4"><a class="reference internal" href="pymatgen.alchemy.html">pymatgen.alchemy package</a></li>
<li class="toctree-l4 current"><a class="reference internal" href="pymatgen.analysis.html">pymatgen.analysis package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.apps.html">pymatgen.apps package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.cli.html">pymatgen.cli package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.command_line.html">pymatgen.command_line package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.core.html">pymatgen.core package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.electronic_structure.html">pymatgen.electronic_structure package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.entries.html">pymatgen.entries package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.ext.html">pymatgen.ext package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.io.html">pymatgen.io package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.optimization.html">pymatgen.optimization package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.phonon.html">pymatgen.phonon package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.plugins.html">pymatgen.plugins package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.symmetry.html">pymatgen.symmetry package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.transformations.html">pymatgen.transformations package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.util.html">pymatgen.util package</a></li>
<li class="toctree-l4"><a class="reference internal" href="pymatgen.vis.html">pymatgen.vis package</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="pymatgen.html#submodules">Submodules</a></li>
<li class="toctree-l3"><a class="reference internal" href="pymatgen.html#module-pymatgen">Module contents</a></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="index.html">pymatgen</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content style-external-links">
<div role="navigation" aria-label="breadcrumbs navigation">
<ul class="wy-breadcrumbs">
<li><a href="index.html">Docs</a> »</li>
<li><a href="modules.html">pymatgen</a> »</li>
<li><a href="pymatgen.html">pymatgen package</a> »</li>
<li><a href="pymatgen.analysis.html">pymatgen.analysis package</a> »</li>
<li>pymatgen.analysis.interface module</li>
<li class="wy-breadcrumbs-aside">
<a href="https://github.com/materialsproject/pymatgen/blob/master/docs_rst/pymatgen.analysis.interface.rst" class="fa fa-github"> Edit on GitHub</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="module-pymatgen.analysis.interface">
<span id="pymatgen-analysis-interface-module"></span><h1>pymatgen.analysis.interface module<a class="headerlink" href="#module-pymatgen.analysis.interface" title="Permalink to this headline">¶</a></h1>
<p>This module provides classes to store, generate, and manipulate material interfaces.</p>
<dl class="py class">
<dt id="pymatgen.analysis.interface.Interface">
<em class="property">class </em><code class="sig-name descname">Interface</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">lattice</span></em>, <em class="sig-param"><span class="n">species</span></em>, <em class="sig-param"><span class="n">coords</span></em>, <em class="sig-param"><span class="n">sub_plane</span></em>, <em class="sig-param"><span class="n">film_plane</span></em>, <em class="sig-param"><span class="n">sub_init_cell</span></em>, <em class="sig-param"><span class="n">film_init_cell</span></em>, <em class="sig-param"><span class="n">modified_sub_structure</span></em>, <em class="sig-param"><span class="n">modified_film_structure</span></em>, <em class="sig-param"><span class="n">strained_sub_structure</span></em>, <em class="sig-param"><span class="n">strained_film_structure</span></em>, <em class="sig-param"><span class="n">validate_proximity</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">coords_are_cartesian</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">init_inplane_shift</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">charge</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">site_properties</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">to_unit_cell</span><span class="o">=</span><span class="default_value">False</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L34-L362"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><code class="xref py py-class docutils literal notranslate"><span class="pre">pymatgen.core.structure.Structure</span></code></a></p>
<p>This class stores data for defining an interface between two structures.
It is a subclass of pymatgen.core.structure.Structure.</p>
<p>Makes an interface structure, a Structure object with additional
information and methods pertaining to interfaces.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>lattice</strong> (<em>Lattice/3x3 array</em>) – The lattice, either as a
<a class="reference internal" href="pymatgen.core.lattice.html#pymatgen.core.lattice.Lattice" title="pymatgen.core.lattice.Lattice"><code class="xref py py-class docutils literal notranslate"><span class="pre">pymatgen.core.lattice.Lattice</span></code></a> or
simply as any 2D array. Each row should correspond to a lattice
vector. E.g., [[10,0,0], [20,10,0], [0,0,30]] specifies a
lattice with lattice vectors [10,0,0], [20,10,0] and [0,0,30].</p></li>
<li><p><strong>species</strong> (<em>[</em><a class="reference internal" href="pymatgen.core.periodic_table.html#pymatgen.core.periodic_table.Species" title="pymatgen.core.periodic_table.Species"><em>Species</em></a><em>]</em>) – <p>Sequence of species on each site. Can take in
flexible input, including:
i. A sequence of element / species specified either as string</p>
<blockquote>
<div><p>symbols, e.g. [“Li”, “Fe2+”, “P”, …] or atomic numbers,
e.g., (3, 56, …) or actual Element or Species objects.</p>
</div></blockquote>
<ol class="lowerroman simple" start="2">
<li><p>List of dict of elements/species and occupancies, e.g.,
[{“Fe” : 0.5, “Mn”:0.5}, …]. This allows the setup of
disordered structures.</p></li>
</ol>
</p></li>
<li><p><strong>coords</strong> (<em>Nx3 array</em>) – list of fractional/cartesian coordinates of
each species.</p></li>
<li><p><strong>sub_plane</strong> (<em>list</em>) – Substrate plane in the form of a list of integers
(based on the sub_init_cell), e.g.: [1, 2, 3].</p></li>
<li><p><strong>film_plane</strong> (<em>list</em>) – Film plane in the form of a list of integers
(based on the film_init_cell), e.g. [1, 2, 3].</p></li>
<li><p><strong>sub_init_cell</strong> (<a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><em>Structure</em></a>) – initial bulk substrate structure</p></li>
<li><p><strong>film_init_cell</strong> (<a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><em>Structure</em></a>) – initial bulk film structure</p></li>
<li><p><strong>site_properties</strong> (<em>dict</em>) – Properties associated with the sites as a
dict of sequences. The sequences have to be the same length as
the atomic species and fractional_coords. For an interface, you should
have the ‘interface_label’ properties to classify the sites as
‘substrate’ and ‘film’.</p></li>
<li><p><strong>modified_sub_structure</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – substrate supercell slab.</p></li>
<li><p><strong>modified_film_structure</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – film supercell slab.</p></li>
<li><p><strong>strained_sub_structure</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – strained substrate supercell slab</p></li>
<li><p><strong>strained_film_structure</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – strained film supercell slab</p></li>
<li><p><strong>validate_proximity</strong> (<em>bool</em>) – Whether to check if there are sites
that are less than 0.01 Ang apart. Defaults to False.</p></li>
<li><p><strong>coords_are_cartesian</strong> (<em>bool</em>) – Set to True if you are providing
coordinates in cartesian coordinates. Defaults to False.</p></li>
<li><p><strong>init_inplane_shift</strong> (<em>length-2 list of float</em><em>, </em><em>in Cartesian coordinates</em>) – The initial shift of the film relative to the substrate
in the plane of the interface.</p></li>
<li><p><strong>charge</strong> (<em>float</em><em>, </em><em>optional</em>) – overal charge of the structure</p></li>
</ul>
</dd>
</dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.ab_shift">
<em class="property">property </em><code class="sig-name descname">ab_shift</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.ab_shift" title="Permalink to this definition">¶</a></dt>
<dd><p>The 2D component of offset_vector along the interface plane
in fractional coordinates. I.e. if ab_shift = [a, b], the
Cartesian coordinate shift in the interface plane
is a * (first lattice vector) + b * (second lattice vector).</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.as_dict">
<code class="sig-name descname">as_dict</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L320-L336"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.as_dict" title="Permalink to this definition">¶</a></dt>
<dd><dl class="field-list simple">
<dt class="field-odd">Returns</dt>
<dd class="field-odd"><p>MSONable dict</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.change_z_shift">
<code class="sig-name descname">change_z_shift</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">dz</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L147-L154"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.change_z_shift" title="Permalink to this definition">¶</a></dt>
<dd><p>Adjust the spacing between the substrate and film layers by dz Angstroms</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>dz</strong> (<em>float</em>) – shift perpendicular to the plane (in Angstroms)</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.copy">
<code class="sig-name descname">copy</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">site_properties</span><span class="o">=</span><span class="default_value">None</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L273-L301"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.copy" title="Permalink to this definition">¶</a></dt>
<dd><p>Convenience method to get a copy of the structure, with options to add
site properties.</p>
<dl class="field-list simple">
<dt class="field-odd">Returns</dt>
<dd class="field-odd"><p>A copy of the Interface.</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.film">
<em class="property">property </em><code class="sig-name descname">film</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.film" title="Permalink to this definition">¶</a></dt>
<dd><p>Return the film (Structure) of the interface.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.film_sites">
<em class="property">property </em><code class="sig-name descname">film_sites</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.film_sites" title="Permalink to this definition">¶</a></dt>
<dd><p>Return the film sites of the interface.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.from_dict">
<em class="property">classmethod </em><code class="sig-name descname">from_dict</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">d</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L338-L362"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.from_dict" title="Permalink to this definition">¶</a></dt>
<dd><dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>d</strong> – Dict representation</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>Interface</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.get_film_indices">
<code class="sig-name descname">get_film_indices</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L245-L253"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.get_film_indices" title="Permalink to this definition">¶</a></dt>
<dd><p>Retrieve the indices of the film sites</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.get_sorted_structure">
<code class="sig-name descname">get_sorted_structure</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">key</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">reverse</span><span class="o">=</span><span class="default_value">False</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L303-L318"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.get_sorted_structure" title="Permalink to this definition">¶</a></dt>
<dd><p>Get a sorted copy of the structure. The parameters have the same
meaning as in list.sort. By default, sites are sorted by the
electronegativity of the species.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>key</strong> – Specifies a function of one argument that is used to extract
a comparison key from each list element: key=str.lower. The
default value is None (compare the elements directly).</p></li>
<li><p><strong>reverse</strong> (<em>bool</em>) – If set to True, then the list elements are sorted
as if each comparison were reversed.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.offset_vector">
<em class="property">property </em><code class="sig-name descname">offset_vector</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.offset_vector" title="Permalink to this definition">¶</a></dt>
<dd><p>Displacement of the origin of the film structure relative to that
of the substrate structure in Cartesian coordinates.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.shift_film">
<code class="sig-name descname">shift_film</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">delta</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L156-L172"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.shift_film" title="Permalink to this definition">¶</a></dt>
<dd><p>Shift the film’s position relative to the substrate.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>delta</strong> (<em>length-3 list of float</em><em> or </em><em>numpy array</em>) – Cartesian coordinate
vector by which to shift the film. After this operation
self.offset_vector -> self.offset_vector + delta.</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.shift_film_along_surface_lattice">
<code class="sig-name descname">shift_film_along_surface_lattice</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">da</span></em>, <em class="sig-param"><span class="n">db</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L134-L145"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.shift_film_along_surface_lattice" title="Permalink to this definition">¶</a></dt>
<dd><p>Given two floats da and db, adjust the shift vector
by da * (first lattice vector) + db * (second lattice vector).
This shift is in the plane of the interface.
I.e. da and db are fractional coordinates.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>da</strong> (<em>float</em>) – shift in the first lattice vector</p></li>
<li><p><strong>db</strong> (<em>float</em>) – shift in the second lattice vector</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.substrate">
<em class="property">property </em><code class="sig-name descname">substrate</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.substrate" title="Permalink to this definition">¶</a></dt>
<dd><p>Return the substrate (Structure) of the interface.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.substrate_sites">
<em class="property">property </em><code class="sig-name descname">substrate_sites</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.substrate_sites" title="Permalink to this definition">¶</a></dt>
<dd><p>Return the substrate sites of the interface.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.vacuum_thickness">
<em class="property">property </em><code class="sig-name descname">vacuum_thickness</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.vacuum_thickness" title="Permalink to this definition">¶</a></dt>
<dd><p>Vacuum buffer above the film.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.Interface.z_shift">
<em class="property">property </em><code class="sig-name descname">z_shift</code><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.Interface.z_shift" title="Permalink to this definition">¶</a></dt>
<dd><p>The 1D component of offset_vector along the interface plane
in fractional coordinates. I.e. if z_shift = z, the distance
between the substrate and film planes is z.</p>
</dd></dl>
</dd></dl>
<dl class="py class">
<dt id="pymatgen.analysis.interface.InterfaceBuilder">
<em class="property">class </em><code class="sig-name descname">InterfaceBuilder</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">substrate_structure</span></em>, <em class="sig-param"><span class="n">film_structure</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L365-L893"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder" title="Permalink to this definition">¶</a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>This class constructs the epitaxially matched interfaces between two crystalline slabs</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>substrate_structure</strong> (<a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><em>Structure</em></a>) – structure of substrate</p></li>
<li><p><strong>film_structure</strong> (<a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><em>Structure</em></a>) – structure of film</p></li>
</ul>
</dd>
</dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.apply_transformation">
<code class="sig-name descname">apply_transformation</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">structure</span></em>, <em class="sig-param"><span class="n">matrix</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L638-L672"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.apply_transformation" title="Permalink to this definition">¶</a></dt>
<dd><p>Make a supercell of structure using matrix</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>structure</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – Slab to make supercell of</p></li>
<li><p><strong>matrix</strong> (<em>3x3 np.ndarray</em>) – supercell matrix</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>(Slab) The supercell of structure</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.apply_transformations">
<code class="sig-name descname">apply_transformations</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">match</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L674-L735"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.apply_transformations" title="Permalink to this definition">¶</a></dt>
<dd><p>Using ZSL match, transform all of the film_structures by the ZSL
supercell transformation.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>match</strong> (<em>dict</em>) – ZSL match returned by ZSLGenerator.__call__</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.combine_slabs">
<code class="sig-name descname">combine_slabs</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L737-L787"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.combine_slabs" title="Permalink to this definition">¶</a></dt>
<dd><p>Combine the slabs generated by get_oriented_slabs into interfaces</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.generate_interfaces">
<code class="sig-name descname">generate_interfaces</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">film_millers</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">substrate_millers</span><span class="o">=</span><span class="default_value">None</span></em>, <em class="sig-param"><span class="n">film_layers</span><span class="o">=</span><span class="default_value">3</span></em>, <em class="sig-param"><span class="n">substrate_layers</span><span class="o">=</span><span class="default_value">3</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">kwargs</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L476-L502"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.generate_interfaces" title="Permalink to this definition">¶</a></dt>
<dd><p>Generate a list of Interface (Structure) objects and store them to self.interfaces.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>film_millers</strong> (<em>list of</em><em> [</em><em>int</em><em>]</em>) – list of film surfaces</p></li>
<li><p><strong>substrate_millers</strong> (<em>list of</em><em> [</em><em>int</em><em>]</em>) – list of substrate surfaces</p></li>
<li><p><strong>film_layers</strong> (<em>int</em>) – number of layers of film to include in Interface structures.</p></li>
<li><p><strong>substrate_layers</strong> (<em>int</em>) – number of layers of substrate to include in Interface structures.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.get_oriented_slabs">
<code class="sig-name descname">get_oriented_slabs</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">film_layers</span><span class="o">=</span><span class="default_value">3</span></em>, <em class="sig-param"><span class="n">substrate_layers</span><span class="o">=</span><span class="default_value">3</span></em>, <em class="sig-param"><span class="n">match_index</span><span class="o">=</span><span class="default_value">0</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">kwargs</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L504-L636"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.get_oriented_slabs" title="Permalink to this definition">¶</a></dt>
<dd><p>Get a list of oriented slabs for constructing interfaces and put them
in self.film_structures, self.substrate_structures, self.modified_film_structures,
and self.modified_substrate_structures.
Currently only uses first match (lowest SA) in the list of matches</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>film_layers</strong> (<em>int</em>) – number of layers of film to include in Interface structures.</p></li>
<li><p><strong>substrate_layers</strong> (<em>int</em>) – number of layers of substrate to include in Interface structures.</p></li>
<li><p><strong>match_index</strong> (<em>int</em>) – ZSL match from which to construct slabs.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.get_summary_dict">
<code class="sig-name descname">get_summary_dict</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L417-L439"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.get_summary_dict" title="Permalink to this definition">¶</a></dt>
<dd><p>Return dictionary with information about the InterfaceBuilder,
with currently generated structures included.</p>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.make_interface">
<code class="sig-name descname">make_interface</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">slab_substrate</span></em>, <em class="sig-param"><span class="n">slab_film</span></em>, <em class="sig-param"><span class="n">offset</span><span class="o">=</span><span class="default_value">None</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L789-L863"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.make_interface" title="Permalink to this definition">¶</a></dt>
<dd><p>Strain a film to fit a substrate and generate an interface.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>slab_substrate</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – substrate structure supercell</p></li>
<li><p><strong>slab_film</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – film structure supercell</p></li>
<li><p><strong>offset</strong> (<em>[</em><em>int</em><em>]</em>) – separation vector of film and substrate</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.visualize_interface">
<code class="sig-name descname">visualize_interface</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">interface_index</span><span class="o">=</span><span class="default_value">0</span></em>, <em class="sig-param"><span class="n">show_atoms</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">n_uc</span><span class="o">=</span><span class="default_value">2</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L865-L893"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.visualize_interface" title="Permalink to this definition">¶</a></dt>
<dd><p>Plot the film-substrate superlattice match, the film superlattice,
and the substrate superlattice in three separate plots and show them.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>interface_index</strong> (<em>int</em><em>, </em><em>0</em>) – Choice of interface to plot</p></li>
<li><p><strong>show_atoms</strong> (<em>bool</em><em>, </em><em>False</em>) – Whether to plot atomic sites</p></li>
<li><p><strong>n_uc</strong> (<em>int</em><em>, </em><em>2</em>) – Number of 2D unit cells of the interface in each direction.
(The unit cell of the interface is the supercell of th substrate
that matches a supercel of the film.)</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pymatgen.analysis.interface.InterfaceBuilder.write_all_structures">
<code class="sig-name descname">write_all_structures</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L441-L474"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.InterfaceBuilder.write_all_structures" title="Permalink to this definition">¶</a></dt>
<dd><p>Write all of the structures relevant for
the interface calculation to VASP POSCAR files.</p>
</dd></dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.align_x">
<code class="sig-name descname">align_x</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">slab</span></em>, <em class="sig-param"><span class="n">orthogonal_basis</span><span class="o">=</span><span class="default_value">[[1, 0, 0], [0, 1, 0], [0, 0, 1]]</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1253-L1270"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.align_x" title="Permalink to this definition">¶</a></dt>
<dd><p>Align the a lattice vector of slab with the x axis. Optionally specify
an orthogonal_basis to align according to a different set of axes</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>slab</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – input structure</p></li>
<li><p><strong>basis</strong> (<em>orthogonal</em>) – If specified, align with
orthogonal_basis[0] rather than [1,0,0]</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>The slab, which has been aligned with the specified axis in place.</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.get_ortho_axes">
<code class="sig-name descname">get_ortho_axes</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">structure</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1231-L1250"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.get_ortho_axes" title="Permalink to this definition">¶</a></dt>
<dd><p>Get an orthonormal set of axes for the structure with the first axis
pointing along the a lattice vector.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>structure</strong> (<a class="reference internal" href="pymatgen.core.structure.html#pymatgen.core.structure.Structure" title="pymatgen.core.structure.Structure"><em>Structure</em></a>) – </p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>3x3 numpy matrix with the axes</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.get_shear_reduced_slab">
<code class="sig-name descname">get_shear_reduced_slab</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">slab</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1302-L1331"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.get_shear_reduced_slab" title="Permalink to this definition">¶</a></dt>
<dd><p>Reduce the vectors of the slab plane according to the algorithm in
substrate_analyzer, then make a new Slab with a Lattice with those
reduced vectors.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>slab</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – Slab to reduce</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>Slab object of identical structure to the input slab
but rduced in-plane lattice vectors</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.merge_slabs">
<code class="sig-name descname">merge_slabs</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">substrate</span></em>, <em class="sig-param"><span class="n">film</span></em>, <em class="sig-param"><span class="n">slab_offset</span></em>, <em class="sig-param"><span class="n">x_offset</span></em>, <em class="sig-param"><span class="n">y_offset</span></em>, <em class="sig-param"><span class="n">vacuum</span><span class="o">=</span><span class="default_value">20</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">kwargs</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1119-L1177"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.merge_slabs" title="Permalink to this definition">¶</a></dt>
<dd><p>Given substrate and film supercells (oriented to match as closely as possible),
strain the film to match the substrate lattice and combine the slabs.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>slab_offset</strong> – spacing between the substrate and film</p></li>
<li><p><strong>y_offset</strong> (<em>x_offset</em>) – in-plane displacement of the film in Cartesian coordinates</p></li>
<li><p><strong>vacuum</strong> – vacuum buffer above the film</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><dl class="simple">
<dt>A structure with the strained film and substrate</dt><dd><p>combined into one structure</p>
</dd>
</dl>
</p>
</dd>
<dt class="field-odd">Return type</dt>
<dd class="field-odd"><p>combined_structure (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab">Slab</a>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.strain_slabs">
<code class="sig-name descname">strain_slabs</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">sub_slab</span></em>, <em class="sig-param"><span class="n">film_slab</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1180-L1228"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.strain_slabs" title="Permalink to this definition">¶</a></dt>
<dd><p>Strain the film_slab to match the sub_slab,
orient the structures to match each other,
and return the new matching structures.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>sub_slab</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – substrate supercell slab</p></li>
<li><p><strong>film_slab</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – film supercell slab</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><dl class="simple">
<dt>substrate structure oriented</dt><dd><p>to match the film supercell</p>
</dd>
<dt>film_struct (Slab): film structure strained to match</dt><dd><p>the substrate supercell lattice.</p>
</dd>
</dl>
</p>
</dd>
<dt class="field-odd">Return type</dt>
<dd class="field-odd"><p>sub_struct (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab">Slab</a>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.third_vect">
<code class="sig-name descname">third_vect</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">a</span></em>, <em class="sig-param"><span class="n">b</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1288-L1299"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.third_vect" title="Permalink to this definition">¶</a></dt>
<dd><p>Get a unit vector proportional to cross(a, b).</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>b</strong> (<em>a</em><em>,</em>) – 3D vectors.</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>unit vector proportional to cross(a, b).</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.transf_mat">
<code class="sig-name descname">transf_mat</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">A</span></em>, <em class="sig-param"><span class="n">B</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1273-L1285"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.transf_mat" title="Permalink to this definition">¶</a></dt>
<dd><p>Get the matrix to transform from the set of axes A
to the set of axes B.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>A</strong> (<em>3x3 numpy array</em>) – original axis basis</p></li>
<li><p><strong>B</strong> (<em>3x3 numpy array</em>) – new axis basis</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p>3x3 numpy array transformation between the bases</p>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.visualize_interface">
<code class="sig-name descname">visualize_interface</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">interface</span></em>, <em class="sig-param"><span class="n">show_atoms</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">n_uc</span><span class="o">=</span><span class="default_value">2</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L896-L1002"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.visualize_interface" title="Permalink to this definition">¶</a></dt>
<dd><p>Plot the match of the substrate and film superlattices.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>interface</strong> (<a class="reference internal" href="#pymatgen.analysis.interface.Interface" title="pymatgen.analysis.interface.Interface"><em>Interface</em></a>) – Interface object</p></li>
<li><p><strong>show_atoms</strong> (<em>bool</em><em>, </em><em>False</em>) – Whether to plot atomic sites</p></li>
<li><p><strong>n_uc</strong> (<em>int</em><em>, </em><em>2</em>) – Number of 2D unit cells of the interface in each direction.
(The unit cell of the interface is the supercell of th substrate
that matches a supercel of the film.)</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py function">
<dt id="pymatgen.analysis.interface.visualize_superlattice">
<code class="sig-name descname">visualize_superlattice</code><span class="sig-paren">(</span><em class="sig-param"><span class="n">struct</span></em>, <em class="sig-param"><span class="n">modified_struct</span></em>, <em class="sig-param"><span class="n">film</span><span class="o">=</span><span class="default_value">True</span></em>, <em class="sig-param"><span class="n">show_atoms</span><span class="o">=</span><span class="default_value">False</span></em>, <em class="sig-param"><span class="n">n_uc</span><span class="o">=</span><span class="default_value">2</span></em><span class="sig-paren">)</span><a class="reference external" href="https://github.com/materialsproject/pymatgen/blob/v2021.1.28/pymatgen/analysis/interface.py#L1005-L1116"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pymatgen.analysis.interface.visualize_superlattice" title="Permalink to this definition">¶</a></dt>
<dd><p>Visualize the unit cell-supercell match for either the film or substrate
(specified by film boolean tag).</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>struct</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – unit cell slab</p></li>
<li><p><strong>modified_struct</strong> (<a class="reference internal" href="pymatgen.core.surface.html#pymatgen.core.surface.Slab" title="pymatgen.core.surface.Slab"><em>Slab</em></a>) – supercell slab</p></li>
<li><p><strong>film</strong> (<em>bool</em><em>, </em><em>True</em>) – True=label plot as film, False=label plot as substrate</p></li>
<li><p><strong>show_atoms</strong> (<em>bool</em><em>, </em><em>False</em>) – Whether to plot atomic sites</p></li>
<li><p><strong>n_uc</strong> (<em>int</em><em>, </em><em>2</em>) – Number of 2D unit cells of the interface in each direction.
(The unit cell of the interface is the supercell of th substrate
that matches a supercel of the film.)</p></li>
</ul>
</dd>
</dl>
</dd></dl>
</div>
</div>
</div>
<footer>
<hr/>
<div role="contentinfo">
<p>
© Copyright 2011, Pymatgen Development Team
</p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});
</script>
<div class="footer">This page uses <a href="http://analytics.google.com/">
Google Analytics</a> to collect statistics. You can disable it by blocking
the JavaScript coming from www.google-analytics.com.
<script type="text/javascript">
(function() {
var ga = document.createElement('script');
ga.src = ('https:' == document.location.protocol ?
'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
ga.setAttribute('async', 'true');
document.documentElement.firstChild.appendChild(ga);
})();
</script>
</div>
</body>
</html>