Skip to main content

BEACH(BEM + Accumulated CHarge)

GitHub Pages Fortran Docs Fortran Format PyPI version Python versions License: Apache 2.0

BEACH は、境界要素法(BEM)による表面電場計算テスト粒子追跡を組み合わせた表面帯電シミュレータです。

  • beach: Fortran 製のシミュレーション実行バイナリ
  • beachx: 設定検査、可視化、ワークロード見積もりなどの Python CLI
  • beach/: Fortran 出力を読むための Python ライブラリ

現行の主対象は 絶縁体表面への電荷蓄積(insulator accumulation) です。 各 batch で電場計算、Boris pusher による粒子前進、メッシュ衝突判定、表面への電荷堆積を行い、表面電位の時間発展を出力します。

帯電シミュレーションの電位変化

電子ビーム照射下での絶縁体メッシュ上の電位分布の時間発展

3D model: Rubber Duck PBR Game Ready (TurboSquid)

必要なもの

Python パッケージのインストール時に Fortran 実行バイナリもビルドします。通常の pip installではfpmも隔離build環境へ自動導入されるため、事前に必要なのはmakeと Fortran compilerです。

make --version
gfortran --version
python --version

gfortran 以外の Fortran compiler を使う場合は、環境に合わせて FC / FPM_FC などを設定してください。

クイックスタート

通常利用では PyPI から導入します。

python -m pip install -U pip setuptools wheel
python -m pip install beach-bem

ユーザーインストール時に beach / beachx が見つからない場合は PATH を確認してください。

export PATH="$HOME/.local/bin:$PATH"

小さな設定を作って実行します。

mkdir run_periodic2
cd run_periodic2

beachx config init
beachx lint beach.toml
beach beach.toml

結果は既定で outputs/latest/ に出力されます。

beachx inspect outputs/latest
beachx animate outputs/latest --quantity potential --save-gif potential_history.gif

開発版を直接試す場合:

python -m pip install "git+https://github.com/Nkzono99/BEACH.git"

設定ファイル

実行時にbeachが読むのはbeach.tomlです。box_origin / box_sizeinject_region_mode = "face_fraction"placement_modemesh.groupsなどの座標・配置パラメータもFortran側で直接解決されます。 まずは beachx config init が生成したファイルを編集し、実行前に beachx lint beach.toml で検査してください。

詳細:

よく使うコマンド

コマンド 用途
beach beach.toml Fortran シミュレーションを実行
beachx config init [path] 小さな実行可能設定を作成
beachx lint beach.toml TOML / JSON Schema / BEACH 制約を検査
beachx inspect outputs/latest 出力ディレクトリの概要表示
beachx animate outputs/latest 電荷・電位履歴のアニメーション生成
beachx workload beach.toml --threads 8 実行前のワークロード見積もり
beachx model close-pack 密充填球モデルの設定生成

旧 CLI 名(beach-inspectbeach-animate-historybeach-estimate-workload など)は互換用 alias です。新しい利用者には beachx ... を推奨します。

ドキュメント

利用者向け・開発者向けドキュメントは GitHub Pages に集約しています。

Pages ビルド:

  • make docs-deps: Starlight 依存を npm ci でインストール
  • make docs-starlight: Starlight 本体のみを生成
  • make docs-pages: Starlight 本体と FORD サブサイトを build/starlight-site/ に生成

リポジトリ構成

開発者向け

ローカル checkout を編集する場合:

python -m pip install fpm
python -m pip install -e . --no-build-isolation
make check

--no-build-isolationmakeを直接使う開発では、fpmをPATH上へ用意してください。

Python 側の確認:

pytest -q
ruff check .

Fortran を含むテストは時間がかかるため、目的に応じて tiered target を選んでください。

make test-l0
make test-l1
make test-l2
make test-l3

KUDPC のログインノードでは make test* / fpm test / 長時間の Fortran 実行を直接走らせず、計算ノードへ投入してください。詳細は Fortran 中心ワークフロー を参照してください。

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

beach_bem-1.6.2.tar.gz (906.9 kB view details)

Uploaded Source

File details

Details for the file beach_bem-1.6.2.tar.gz.

File metadata

  • Download URL: beach_bem-1.6.2.tar.gz
  • Upload date:
  • Size: 906.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for beach_bem-1.6.2.tar.gz
Algorithm Hash digest
SHA256 f73eb89233a6f7ea0eff8af4592a1194711db892b89713973e718e32527fe050
MD5 ce245484bb3d3d78a32092be323de715
BLAKE2b-256 fa746662ff0c5b75d10d4e72819e1fe08b2e5d553df1685dafb5526c5ceddbf7

See more details on using hashes here.

Provenance

The following attestation bundles were made for beach_bem-1.6.2.tar.gz:

Publisher: publish-pypi.yml on Nkzono99/BEACH

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

1.6.2 This release

1 file

1.6.1

1 file

1.6.0

1 file

1.5.0

1 file

1.4.0

1 file

1.3.0

1 file

1.2.0

1 file

1.1.0

1 file

1.0.0

1 file

0.8.0

1 file

0.7.3

1 file

0.7.2

1 file

0.7.1

1 file

0.7.0

1 file

0.6.5

1 file

0.6.4

1 file

0.6.2

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page