17 #pragma warning(disable:4503)
28#include "viennagrid/config/default_configs.hpp"
58template <
typename DeviceType>
61 typedef typename DeviceType::segment_type SegmentType;
64 SegmentType
const & contact_left = device.segment(0);
65 SegmentType
const & n_left = device.segment(1);
66 SegmentType
const & i_center = device.segment(2);
67 SegmentType
const & n_right = device.segment(3);
68 SegmentType
const & contact_right = device.segment(4);
84 std::cout <<
"* init_device(): Setting doping..." << std::endl;
85 device.set_doping_n(1e25, n_left);
86 device.set_doping_p(1e6, n_left);
88 device.set_doping_n(1e20, i_center);
89 device.set_doping_p(1e11, i_center);
91 device.set_doping_n(1e25, n_right);
92 device.set_doping_p(1e6, n_right);
95 device.set_contact_potential(0.0, contact_left);
96 device.set_contact_potential(0.5, contact_right);
118 std::cout <<
"* main(): Creating device..." << std::endl;
149 device.generate_mesh(generator_params);
154 std::cout <<
"* main(): Initializing device..." << std::endl;
164 std::cout <<
"* main(): Creating DD simulator..." << std::endl;
195 std::cout <<
"* main(): Launching simulator..." << std::endl;
211 std::cout <<
"* main(): Setting up SHE..." << std::endl;
253 std::cout <<
"* main(): Computing SHE..." << std::endl;
268 std::cout <<
"* main(): Writing SHE result..." << std::endl;
271 she_simulator.config(),
272 she_simulator.quantities().electron_distribution_function(),
290 EDFWrapperType(she_simulator.config(), she_simulator.quantities().electron_distribution_function()),
297 she_simulator.electron_density(),
301 std::cout <<
"* main(): Results can now be viewed with your favorite VTK viewer (e.g. ParaView)." << std::endl;
302 std::cout <<
"* main(): Don't forget to scale the z-axis by about a factor of 1e12 when examining the distribution function." << std::endl;
303 std::cout << std::endl;
304 std::cout <<
"*********************************************************" << std::endl;
305 std::cout <<
"* ViennaSHE finished successfully *" << std::endl;
306 std::cout <<
"*********************************************************" << std::endl;
The main SHE configuration class. To be adjusted by the user for his/her needs.
double min_kinetic_energy_range(viennashe::carrier_type_id ctype) const
Returns the minimum kinetic energy range for the selected carrier.
long max_expansion_order() const
Returns the current maximum expansion order.
bool with_holes() const
Returns true if holes are considered in the simulation.
nonlinear_solver_config_type & nonlinear_solver()
Returns the configuration object for the nonlinear solver.
void set_electron_equation(equation_id equ_id)
double energy_spacing() const
Returns the uniform energy spacing of discrete energies.
void set_hole_equation(equation_id equ_id)
bool with_electrons() const
Returns true if electrons are considered in the simulation.
viennashe::she::scatter_config & scattering()
Returns the configuration object for scattering.
Defines the physical properties of a device, e.g. doping. This is the implementation for 2d and highe...
A convenience wrapper for accessing the generalized energy distribution function (f * Z,...
ionized_impurity_scattering_parameters const & ionized_impurity() const
Returns the parameters for ionized impurity scattering. Const-version.
impact_ionization_scattering_parameters const & impact_ionization() const
Returns the parameters for impact ionization scattering. Const-version.
acoustic_phonon_scattering_parameters const & acoustic_phonon() const
Returns the parameters for acoustic phonon scattering. Const-version.
optical_phonon_scattering_parameters const & optical_phonon() const
Returns the parameters for optical phonon scattering. Const-version.
bool electron_electron() const
Returns true if electron-electron scattering is activated.
Class for self-consistent SHE simulations.
std::size_t max_iters() const
Returns the maximum number of nonlinear solver iterations.
double damping() const
Returns the damping for the nonlinear solver.
void set(long solver_id)
Sets a new linear solver. Provide IDs defined in.
Configuration class for the simple mesh generator.
void add_segment(double start_x, double start_y, double len_x, double len_y, unsigned long points_x, unsigned long points_y)
Convenience header, which includes all core functionality available in ViennaSHE.
void init_device(DeviceType &device, double Vg_init, double Nd, double Na)
Initalizes the MOS 1D device for testing.
void write_quantities_to_VTK_file(viennashe::simulator< DeviceType > const &simulator_obj, std::string filename, bool include_debug_information=false)
Generic interface function for writing simulated quantities to a VTK file.
std::string hole_density()
std::string electron_density()
std::string preamble()
Prints the ViennaSHE preamble (header). Used in all the examples as well as the standalone-applicatio...
Writes the energy distribution function to a file which can be processed by Gnuplot....
Writes quantities to a file which can be processed by Gnuplot. Works for 1d, 2d and 3d only.
A class referring to silicon and providing certain material parameters Note that this is the default ...
static const double q
Elementary charge.
@ newton_nonlinear_solver
Gummel iteration.
A trivial filter, all objects are accepted.