Skip to content
noooway edited this page Oct 16, 2017 · 14 revisions

Minimal options in config file. If it will be run, you get hdf5 file with empty mesh grid. # uses for comments.

[Time grid]
total_time = 1.0e-9
time_step_size = 1.0e-9
time_save_step = 1.0e-9

[Spatial mesh]
grid_x_size = 5.0
grid_x_step = 0.5
grid_y_size = 5.0
grid_y_step = 0.5
grid_z_size = 15.0
grid_z_step = 1.5

[Particle interaction model]
# 'noninteracting' or 'PIC'; without quotes
particle_interaction_model = noninteracting
# particle_interaction_model = PIC

[Boundary conditions]
boundary_phi_left = 0.0 
boundary_phi_right = 0.0
boundary_phi_bottom = 0.0
boundary_phi_top = 0.0
boundary_phi_near = 0.0
boundary_phi_far = 0.0	

[Output filename]
# No quotes; no spaces till end of line
output_filename_prefix = example_
output_filename_suffix = .h5

It is possible to add several types of particle source. It depends from geometry of region where particle will be appear.

[Particle_source_cylinder.cathode_emitter]
initial_number_of_particles = 5000
particles_to_generate_each_step = 5000
cylinder_axis_start_x = 2.5
cylinder_axis_start_y = 2.5
cylinder_axis_start_z = 0.51
cylinder_axis_end_x = 2.5
cylinder_axis_end_y = 2.5
cylinder_axis_end_z = 0.52
cylinder_radius = 0.5
mean_momentum_x = 0
mean_momentum_y = 0
mean_momentum_z = 6.641e-15
temperature = 0.0
charge = -1.799e-6
mass = 3.672e-24

[Particle_source_box.cathode_emitter]
initial_number_of_particles = 50
particles_to_generate_each_step = 50
box_x_left = 0.175
box_x_right = 0.125
box_y_bottom = 0.6
box_y_top = 1.4
box_z_near = 0.11
box_z_far = 0.12
mean_momentum_x = 0
mean_momentum_y = 0
mean_momentum_z = 8.85e-17
temperature = 0.0
charge = -2.398e-08
mass = 4.89e-26

Different kind of geometric model with potential is available in simulation region. Such as cylinder, tube, box and sphere:

[Inner_region_cylinder.cylinder]
potential = 1.0
cylinder_axis_start_x = 2.0
cylinder_axis_start_y = 2.0
cylinder_axis_start_z = 0.1
cylinder_axis_end_x = 2.0
cylinder_axis_end_y = 2.0
cylinder_axis_end_z = 0.5
cylinder_radius = 0.5

[Inner_region_tube.tube]
potential = 0.0
tube_axis_start_x = 0.2
tube_axis_start_y = 0.2
tube_axis_start_z = 0.04
tube_axis_end_x = 0.2
tube_axis_end_y = 0.2
tube_axis_end_z = 1.76
tube_inner_radius = 0.10
tube_outer_radius = 0.18

[Inner_region_box.anode]
potential = +0.36667
box_x_left = 5.99
box_x_right = 0.01
box_y_bottom = 0.01
box_y_top = 5.99
box_z_near = 0.9
box_z_far = 0.98

[Inner_region_sphere.sphere]
potential = 3.0
sphere_origin_x = 5.0
sphere_origin_y = 5.0
sphere_origin_z = 5.0
sphere_radius = 0.5

Uniform magnetic field in some direction is possible to add:

[External magnetic field]
magnetic_field_x = 0.0
magnetic_field_y = 0.0
magnetic_field_z = 40000
speed_of_light = 3.0e10

In dev-branch:
Uniform electric and magnetic fields:

[External_magnetic_field_uniform.mgn_uni]
magnetic_field_x = 0.0
magnetic_field_y = 0.0
magnetic_field_z = 500

[External_electric_field_uniform.el_uni]
electric_field_x = 0.0
electric_field_y = 0.0
electric_field_z = 100

(no need to specify speed of light for magnetic field; it is hardcoded)

Analytical expressions for B(x,y,z,t) and E(x,y,z,t) can be specified:

[External_magnetic_field_tinyexpr.mgn_tiny]
magnetic_field_x = x + y + z + t
magnetic_field_y = t^2
magnetic_field_z = 100 * ( sin(x) + cos(y) )

[External_electric_field_tinyexpr.el_tiny]
electric_field_x = x * y * z * t
electric_field_y = t^3
electric_field_z = 100 * ( tan(x) + exp(y) )
Clone this wiki locally