# dope_reservoir

Synopsys: dope_reservoir(grid,interface,NEGF_class,molar_fraction,bondary_box)

dope_reservoir is a function which impose a doping equal to the molar_fraction (defined as the ration between the number of doping atoms over the number of atoms) in correspondence of the atoms of the NEGF_class, which are included in the hexahedric region defined by the numpy array boundary_box, containing its coordinate xmin, xmax, ymin, ymax, zmin, zmax.
Example:
If we have a (13,0) CNT, 30 nm long, and we want to define two reservoirs (source and drain), 10 nm long, with molar fraction 5e-3 and -5e-3, respectively, a python script could be the following:

#I create the (13,0) CNT, 30 nm long
CNT=nanotube(13,30);
#I create the grid
xg=linspace(-1,1,20);
yg=xg;
grid=grid3D(xg,yg,CNT.z,CNT.x,CNT.y,CNT.z);
# I then define the interface
p=interface3D(grid);
p.normpoisson=1e-1;
# I define the source reservoir 5e-3
dope_reservoir(grid,p,CNT,5e-3,array([grid.xmin,grid.xmax,grid.ymin,grid.ymax,0,10]));
# I define the drain reservoir doped -5e-3
dope_reservoir(grid,p,CNT,-5e-3,array([grid.xmin,grid.xmax,grid.ymin,grid.ymax,20,30]));

Please note that firstNEGF_class has to be defined, then the grid, and after that the interface.
Once all these three classes have been defined, the doping of the reservoir can be imposed.