Skip to main content

organic electronic device simulator

Project description

Travis-CI-badge Readthedocs-badge Binder-badge

This is work in progress. See doc/ for documentation, and examples/ for examples of use.

Installation

pip install oedes

It is recommended to run test suite after installing

python -c "import oedes; oedes.test()"

Example simulation

This builds and solves a model of abrupt PN junction:

import oedes
from oedes import models

# Define doping profile
def doping_profile(mesh, ctx, eq):
    Nd = ctx.param(eq, 'Nd')
    Na = ctx.param(eq,'Na')
    return oedes.ad.where(mesh.x<mesh.length*0.5,Nd,-Na)

# Define device model
poisson = models.PoissonEquation()
temperature = models.ConstTemperature()
electron = models.BandTransport(poisson=poisson, name='electron', z=-1, thermal=temperature)
hole = models.BandTransport(poisson=poisson, name='hole', z=1, thermal=temperature)
doping = models.FixedCharge(poisson, density=doping_profile)
semiconductor = models.Electroneutrality([electron, hole, doping],name='semiconductor')
recombination = models.DirectRecombination(semiconductor)
anode = models.OhmicContact(poisson, semiconductor, 'electrode0')
cathode = models.OhmicContact(poisson, semiconductor, 'electrode1')
equations=[ poisson, temperature, electron, hole,
            doping, semiconductor, anode, cathode,
            recombination ]

# Define device parameters
params={
    'T':300,
    'epsilon_r':12,
    'Na':1e24,
    'Nd':1e24,
    'hole.mu':1,
    'electron.mu':1,
    'hole.energy':-1.1,
    'electron.energy':0,
    'electrode0.voltage':0,
    'electrode1.voltage':0,
    'hole.N0':1e27,
    'electron.N0':1e27,
    'beta':1e-9
}

# Discretize and solve discrete model
mesh = oedes.fvm.mesh1d(100e-9)
model = oedes.fvm.discretize(equations, mesh)
c=oedes.context(model)
c.solve(params)

# Plot bands and quasi Fermi potentials
import matplotlib.pylab as plt
p=c.mpl(plt.gcf(), plt.gca())
p.plot(['electron.Eband'],label='$E_c$')
p.plot(['hole.Eband'],label='$E_v$')
p.plot(['electron.Ef'],linestyle='--',label='$E_{Fn}$')
p.plot(['hole.Ef'],linestyle='-.',label='$E_{Fp}$')
p.apply_settings({'xunit':'n','xlabel':'nm'})
p.ax.legend(loc=0,frameon=False)
plt.show()
doc/fig/tutorial-pn.png

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

oedes-0.0.18.tar.gz (1.9 MB view details)

Uploaded Source

File details

Details for the file oedes-0.0.18.tar.gz.

File metadata

  • Download URL: oedes-0.0.18.tar.gz
  • Upload date:
  • Size: 1.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.0

File hashes

Hashes for oedes-0.0.18.tar.gz
Algorithm Hash digest
SHA256 1863fce1d0665910a6d424feff3d96efe9b913ef91885dce11af2bc4f282dd5a
MD5 570e64d1dce1a74af938efeb22d36ca2
BLAKE2b-256 5a0b7f2e9a0c9f2e3248a9bc384169ef7dd91bbeb3610290e5f16d4561d84a0f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page