Skip to content

Instantly share code, notes, and snippets.

@danlkv
Last active June 5, 2020 21:15
Show Gist options
  • Save danlkv/ce37017f2a07827d7c6ee7b8fbc4706f to your computer and use it in GitHub Desktop.
Save danlkv/ce37017f2a07827d7c6ee7b8fbc4706f to your computer and use it in GitHub Desktop.

UNIX Philosophy

  1. Write programs that do one thing and do it well. 1 Write programs to work together. 1 Write programs to handle text streams, because that is a universal interface.

Different concerns

  • Parse the file
  • Simulate circuit
    • Optimise expression
    • Actually simulate

Example of usage

Simulator program: tensim

  • Simply simulate a circuit: cat circuit | tensim > result
  • Simulate a circuit in wierd format cat circuit | tensim parse -f wierd | tensim > result
  • Simulate N generated circuits in one command
generate_circ -n 1 >> circuits
generate_circ -n 2 >> circuits
....
cat circuits | tensim > results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment