asysc is an analog system compiler based on the lightweight Computer Algebra System lightcas.
Using a Computer Algebra System (CAS), you can write your own components by using algebraic descriptions.
Description example for a resistor:
NAME.CR(@1,@2,R) := {
NAME.U=ACROSS(@1,@2);
NAME.I=THROUGH(@1,@2);
NAME.U=R*NAME.I
};
For more examples, see the component.rule and examples directories.
The analog system compiler is invoked with the following command (Example with the RLC circuit in AC mode analysis):
cd examples/ac/RLC
../../../lightcas/bin/asysc -i RLC.cir -o RLC.py -t ac
This command generates Python code containing equations for AC simulation.
- g++ or clang
- make
- numpy
- matplotlib
git clone https://github.com/analog-system-compiler/asysc.git
cd asysc
git submodule update --init
make clean
make
make run
To execute a particular test, type:
cd examples
make
cd examples/<directory>
python3 simulation.py
This project is licensed under the GNU General Public License - see the LICENSE file for details.