i would like to create a program which can display electronic circuits and simulate it. i wish to know where should i place my mathematic calculations or functions?