This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from fipy import * | |
| # | |
| # Solution mesh | |
| # | |
| nx = 200 | |
| dx = 0.01 | |
| L = nx * dx | |
| mesh = Grid1D(nx = nx, dx = dx) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| ######################################################################################### | |
| # | |
| # planar 1D DBR modified to export absolute electric field and Poynting vector profiles | |
| # | |
| ######################################################################################## | |
| from camfr import * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from datetime import * | |
| from clint.textui import colored, columns | |
| # | |
| # Using a module called Clint to take care of printing columns and text colour | |
| # | |
| # Examples: http://www.nicosphere.net/clint-command-line-library-for-python/ | |
| # Github: https://github.com/kennethreitz/clint | |
| # Install: pip install clint |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| brew install autogen --use-clang | |
| ==> Downloading http://ftpmirror.gnu.org/autogen/rel5.14/autogen-5.14.tar.gz | |
| File already downloaded in /Users/daniel/Library/Caches/Homebrew | |
| ==> ./configure --disable-debug --prefix=/usr/local/Cellar/autogen/5.14 | |
| ==> make | |
| make all-recursive | |
| Making all in compat | |
| : | |
| Making all in snprintfv | |
| for f in filament.c format.c printf.c mem.c stream.c custom.c ; do echo "#include \"$f\"" ; done > snv.c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import DAQ | |
| daq = DAQ("Dev1/ai0:2") | |
| volts = daq.voltage() | |
| amps = daq.current() |
NewerOlder