Skip to main content

NestedTwoTerminal

Struct NestedTwoTerminal 

Source
pub struct NestedTwoTerminal { /* private fields */ }
Expand description

A two-terminal device solved by nested dissection (see the module documentation).

Implementations§

Source§

impl NestedTwoTerminal

Source

pub fn from_model( device: &Model, lead: &Model, region: &Region, axis: usize, ) -> Self

Two-terminal system built from a model on a region cut along primitive vector axis, as crate::TwoTerminal::from_model: both leads continue the first and last slices of the region with the clean lead model.

Source

pub fn block_count(&self) -> usize

Number of independent blocks solved separately.

Source

pub fn transmission(&self, energy: f64) -> Result<f64, GreenError>

Caroli transmission T(E) = Tr[Γ_L G_LR Γ_R G_LR†], with mode-matching self-energies.

Source

pub fn transmissions(&self, energies: &[f64]) -> Vec<Result<f64, GreenError>>

Transmissions at many energies, in parallel.

Source

pub fn transmissions_checked( &self, energies: &[f64], options: &PrecisionOptions, ) -> (Vec<Result<f64, GreenError>>, PrecisionReport)

Transmissions at many energies in the precision of options, checked against double precision on a sample of the energies (see crate::checked).

Source

pub fn self_energies(&self, energy: f64) -> Result<LeadSelfEnergies, GreenError>

Lead self-energies at energy, for each independent block. They serve every system with the same leads and blocks: in a disorder average, the leads are solved once per energy instead of once per configuration.

ⓘ
let sigma = reference.self_energies(e)?;
let mean = configurations.iter().map(|sys| sys.transmission_with(&sigma)).sum::<Result<f64, _>>()?
    / configurations.len() as f64;
Source

pub fn transmission_with( &self, sigma: &LeadSelfEnergies, ) -> Result<f64, GreenError>

Transmission at the energy of sigma, with its lead self-energies, computed by Self::self_energies on this system or on one with the same leads and blocks.

Panics if the leads or the blocks differ.

Source

pub fn transmission_with_precision( &self, sigma: &LeadSelfEnergies, precision: Precision, ) -> Result<f64, GreenError>

Self::transmission_with with the fronts in precision (see Precision), unchecked: Self::transmissions_checked or crate::checked measure the error.

Source

pub fn smatrix(&self, energy: f64) -> Result<SMatrix, GreenError>

Scattering matrix at energy in the basis of the propagating lead modes (lead 0 on the left, lead 1 on the right), as kwant.smatrix (see crate::SMatrix).

Source

pub fn transmission_eigenvalues( &self, energy: f64, ) -> Result<Vec<f64>, GreenError>

Transmission eigenvalues τ_n at energy, in decreasing order: the squared singular values of t = W_L† G_LR W_R (W_p W_p† = Γ_p), the same as those of the transmission block of the scattering matrix. Their sum is the transmission.

Source

pub fn fano_factor(&self, energy: f64) -> Result<f64, GreenError>

Fano factor F = Σ τ (1 − τ) / Σ τ at energy: the shot noise over the Poisson value, at zero temperature and small bias (0 for perfect channels, 1 for a tunnel barrier, 1/3 for a diffusive wire).

Source

pub fn scattering_states( &self, energy: f64, ) -> Result<ScatteringStates, GreenError>

Scattering states at energy: ψ_p = G W_p on every device orbital for each lead p, with W_p W_p† = Γ_p (one column per channel). The elimination keeps its factors, and a back-substitution from the lead slices gives the states everywhere: memory grows with the factors (O(N log N) for a 2D sample of N orbitals) and with N times the channels.

Source

pub fn bond_currents( &self, states: &ScatteringStates, f: &[f64], ) -> Vec<BondCurrent>

Spectral bond currents 2 Re Tr[H_ij G^<_ji] between every pair of coupled sites, from the scattering states and the lead occupations f (G^< = i Σ_p f_p ψ_p ψ_p†). Each bond appears once, from the site of lower index in the region.

Source

pub fn operator_currents( &self, states: &ScatteringStates, f: &[f64], op: &CMat, ) -> Vec<BondCurrent>

Bond currents of an on-site operator O (a spin current for O = s_z): Re Tr[(O H_ij + H_ij O) G^<_ji], 2 Re Tr[H_ij G^<_ji] for O = 1.

Source

pub fn site_densities( &self, states: &ScatteringStates, f: &[f64], op: Option<&CMat>, ) -> Vec<f64>

Spectral density Σ_p f_p ψ_p† O ψ_p / 2π of every site (O = 1 for None): the occupied density, or a spin density.

Source

pub fn region(&self) -> &Region

The device region (orbital layout of the scattering states).

Trait Implementations§

Source§

impl Clone for NestedTwoTerminal

Source§

fn clone(&self) -> NestedTwoTerminal

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for NestedTwoTerminal

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> ByRef<T> for T

§

fn by_ref(&self) -> &T

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Imply<T> for U
where T: ?Sized, U: ?Sized,

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T> Pointable for T

§

const ALIGN: usize

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.