PhotFDTD
Phot FDTD 目前包含了基础器件和光器件的实现和测试用例,使用了fdtd库已经实现了的 Finite-difference time-domain method (时域有限差分)算法。
基础器件
- waveguide - 直波导
- arc - 圆弧
- sbend - s波导
- ysplitter - y分支
光器件
光器件由基础器件组成,光器件与光器件之间也可以连接。
- directional coupler - 方向耦合器
- mmi - 多模耦合干涉仪
- ring - 微环
安装
在命令行界面输入以下命令即可
pip install photfdtd
Demo
from photfdtd import Sbend
if __name__ == "__main__":
# 设置器件参数
sbend = Sbend(
xlength=40, ylength=60, zlength=1, x=10, y=10, z=1, direction=-1, width=10, refractive_index=1.7, name="sbend"
)
# 设置 grid 参数
sbend.set_grid(grid_xlength=80, grid_ylength=80, grid_zlength=1, grid_spacing=155e-9, total_time=200, pml_width=10)
# 设置光源
sbend.set_source()
# 保存画好的图,设置保存位置,以及从哪一个轴俯视画图
sbend.savefig(filepath="SbendZ.png", axis="z")
运行结果
各种光器件使用示例
在 tests 目录下,可以看到各种光器件的使用示例,例如 waveguide_test.py 代表着波导的使用示例。
开发者文档
开发者文档 提供了对于开发者的指导。
Metadata
Release files for photfdtd 0.0.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| photfdtd-0.0.5.tar.gz | 10.2 kB | Without provenance | Details for photfdtd-0.0.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| photfdtd-0.0.5-py3-none-any.whl | Python 3 | none | any | Details for photfdtd-0.0.5-py3-none-any.whl |
Total release size: 24.1 kB
Release files / photfdtd-0.0.5.tar.gz
| Download URL | photfdtd-0.0.5.tar.gz |
|---|---|
| Size | 10.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
17e2fc8d9df15e1a88e1566a0a8b0979e50a2e5bc0eadd41dd88445188e81f89
|
|
BLAKE2b-256 checksum How to use checksums |
a390d660de008314cf4ca8b4cffe98ec46fca747f99a563a16419124b114e555
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.2 CPython/3.10.7 Darwin/22.3.0
|
Release files / photfdtd-0.0.5-py3-none-any.whl
| Download URL | photfdtd-0.0.5-py3-none-any.whl |
|---|---|
| Size | 13.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a9b9045036905f1645f11c2137750f441c179555847f3eace0391467e845cfa8
|
|
BLAKE2b-256 checksum How to use checksums |
738bd47bcc388fdf6beb1243b0f28f23d9a99d13537aed8270e19029900b7969
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.3.2 CPython/3.10.7 Darwin/22.3.0
|
Security for photfdtd 0.0.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.