Bivot-Savart Law for calculating the Magnetic field of some parametrization curves
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
Matlab only
- Clone this repository,
- Open
main.m
file and there you have parameters to tweak.
To get some data out of the system one should:
- Modify the parameters in the
main.m
file:
x_start = -2;
x_stop = 2;
x_inst = 40;
y_start = -2;
y_stop = 2;
y_inst = 40;
z_start = -5;
z_stop = 5;
z_inst = 40;
Where x_start
and x_stop
(y_start
, z_start
etc..) specefies how big will the render be in terms of axes. Variables x_inst
, y_inst
and z_inst
respectivly are defining how much points are there to calculate magnetic field in their position.
Also, user should define some curve to draw. Lets draw coil for example: To draw a coil user should write this line below.
line = define_coil([0, 0, -4]', 0.5, 5, 7, 1000);
The function define_coil
is defined as define_coil(c_point, Radius, Num_of_turns, Length, Instances)
where:
c_point
is major-column vector of bottom center of coil,Radius
is radius of coil,Num_of_turns
is how much turns the coil has over its lenght,Length
is length of coil,Instances
is number of points of the coil. For more precise calculation bigger number is better.
- Press Run button.
This project is licensed under the MIT License - see the LICENSE file for details