Skip to content

Latest commit

 

History

11 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Arch × Rosetta

Automatic, multi-language bindings for the Arch library(private), a 3D BEM code — generated, not hand-written

PMP – remeshing & curvature analysis on the fandisk model PMP – remeshing & curvature analysis on the fandisk model

Arch Rosetta C++26 Bindings


This project points Rosetta at the Arch Library (successor Poly3D and iBem3D) and, from a single manifest.json, generates ready-to-build bindings without touching a line of Arch's source.

Arch is a private repos. So this project is provided for information (all the bindings are working of cource).

More info about the technology: Maerten, F., Maerten, L., & Pollard, D. D. (2014). iBem3D, a three-dimensional iterative boundary element method using angular dislocations for modeling geologic structures. Computers and Geosciences, 72, 1-17

Build

One-time bootstrap: fetch rosetta into extern/ and build rosetta_gen:

cmake -B build && cmake --build build -j12

Then, generate the generator + all the bindings and compile all of them:

./extern/rosetta/bin/rosetta_gen --build manifest.json -j12

Run the examples

Each backend has a ready-to-run demo in examples/. Build the matching binding above first, then run from anywhere (the scripts locate the binding relative to themselves):

1. Python

python3 examples/example_python.py

2. Node (native N-API addon)

node examples/example_node.js

3. WebAssembly with Node

node examples/example_wasm.js

4. Hector Mine slip inversion (python)

A real case: the 1999 Mw 7.1 Hector Mine InSAR slip inversion, replicating the historical Poly3Dinv run of examples/HectorMine/hector3.txt.

python3 examples/HectorMine/main.py

5. Tabular (layered) medium (python)

Solves the same forward model twice — homogeneous half-space, then with an arch.TabularMedium attached — and compares the fault slip, plus displacement and strain on a vertical cross-section and on the free surface.

python3 examples/tabular/main.py

It currently reports no difference on any field: TabularMedium::correction is applied only in DisplCoefficients::influence, which the forward path never calls (the solver assembles through StrainCoefficients, and Postprocess displacement goes through DisplCoefficients::value). Only influence-matrix consumers — the slip inversion — inherit the layering today. The script is the regression test for wiring the correction into the forward path.

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages