source code to generate .nec files for helical wire antennas. Purpose is to generate simulations that will help with the mechanical design of the antenna.
Will have a class to handle creating the correct geometry for the antenna. Then we'll use a handler to translate the geometry into a .nec file for simulation.
will need following modules
- nec card gen (python script)
- nec parser (using necpp)
- output generator (using necpp, or shell script nec2++)
- parameter learner (some machine learning framework)
- graphic generator (python) DONE
stuff on python-necpp nec card generator
- Class description: Include a description of the parameters and a link to the relevant page in nec manual
- Initialisation: initialise the parameters for that nec line
- Construct: Function to create a string for that line of nec code
- Verification: Verify that the parameters in the class fit NEC2 specification
- (Optional) relevant functions: Any other functions relevant to that class
you can use nec2++ to generate an output file from a given .nec file. example usage:
nec2++ -i example1.nec -o example1.out
Installing nec2++ is can be done using:
sudo apt-get install nec2++
- clone the NECPP repo
git clone https://github.com/tmolteno/necpp
-
follow the instructions to install necpp here. make sure you are in the necpp folder.
-
copy the configuration header into the 4NEC2... folder
cp (necpp_location)/config.h (4NEC2_location)/
- go to the src folder and export the NECPP_SRC_PATH environmental variable
export NECPP_SRC_PATH=$PWD
- to compile, just go into the cpp folder and call make
make