Skip to main content

COMPAS CRA

build GitHub - License pip downloads PyPI - Python Version PyPI - Latest Release DOI

Coupled Rigid-Block Analysis (CRA) implementation using COMPAS framework.

developed with by Gene Ting-Chun Kao

Installation

pip install compas_sandbox

Nothing else is needed on Windows, macOS (Apple Silicon and Intel) or Linux. The IPOPT 3.14.19 solver (Eclipse Public License 2.0, MUMPS linear solver, no HSL) is compiled into the compas_sandbox_native dependency as a Python extension module with nanobind, so solving happens in-process — no solver executables, no subprocess, no conda. See native/README.md for how the extension is built and packaging/README.md for the IPOPT build itself.

Rhino 8

The easiest way is to let the ScriptEditor install everything for you. Start a new Python 3 script with this header and run it — on the first run Rhino installs compas_sandbox and all of its dependencies into its own environment (this takes a couple of minutes, watch the progress in the ScriptEditor console):

#! python3
# venv: compas-sandbox
# r: compas_sandbox

No extra # r: lines are needed for compas, numpy, shapely or the solver — they are dependencies of compas_sandbox and pip installs them automatically.

Ready-to-run examples for the ScriptEditor are in scripts/:

  • scripts/rhino_cra_cubes.py — three stacked cubes, baked as wireframe blocks with interface outlines and resultant contact forces.
  • scripts/rhino_cra_arch.py — a parametric masonry arch (span, rise, thickness, number of voussoirs, friction) solved and baked the same way.

Alternatively, install manually into Rhino's Python with the shell that ships with Rhino (Tools > Options > Plugins > Rhino Code > Open Shell, or ~/.rhinocode/py39-rh8/shell/open-shell on macOS):

pip install compas_sandbox

Note that Rhino 8 ships CPython 3.9, which is fully supported: solver wheels exist for CPython 3.9–3.13 on all platforms. Since the solver is a regular Python extension module rather than an executable, it is also not affected by the antivirus policies that quarantine unknown .exe files on managed Windows machines. To verify the solver in any environment, run scripts/rhino_ipopt_check.py.

To find out more about CRA, please refer to our paper in the CAD Computer-Aided Design journal: https://doi.org/10.1016/j.cad.2022.103216

Coupled Rigid-Block Analysis: Stability-Aware Design of Complex Discrete-Element Assemblies

image

Abstract

The rigid-block equilibrium (RBE) method uses a penalty formulation to measure structural infeasibility or to guide the design of stable discrete-element assemblies from unstable geometry. However, RBE is a purely force-based formulation, and it incorrectly describes stability when complex interface geometries are involved. To overcome this issue, this paper introduces the coupled rigid-block analysis (CRA) method, a more robust approach building upon RBE’s strengths. The CRA method combines equilibrium and kinematics in a penalty formulation in a nonlinear programming problem. An extensive benchmark campaign is used to show how CRA enables accurate modelling of complex three-dimensional discrete-element assemblies formed by rigid blocks. In addition, an interactive stability-aware design process to guide user design towards structurally-sound assemblies is proposed. Finally, the potential of our method for real-world problems are demonstrated by designing complex and scaffolding-free physical models.

Please cite our work if you use CRA in your research

Paper

@article{kao2022coupled,
    title     = {Coupled Rigid-Block Analysis: Stability-Aware Design of Complex Discrete-Element Assemblies},
    author    = {Kao, Gene Ting-Chun and Iannuzzo, Antonino and Thomaszewski, Bernhard and Coros, Stelian and Van Mele, Tom and Block, Philippe},
    journal   = {Computer-Aided Design},
    volume    = {146},
    pages     = {103216},
    year      = {2022},
    publisher = {Elsevier},
    doi       = {10.1016/j.cad.2022.103216},
    url       = {https://doi.org/10.1016/j.cad.2022.103216}
}

Software implementation

@misc{compas-sandbox,
    title  = {{COMPAS CRA}: Coupled Rigid-Block Analysis ({CRA}) for the {COMPAS} framework},
    author = {Kao, Gene Ting-Chun},
    note   = {https://github.com/BlockResearchGroup/compas\_cra},
    year   = {2020-2022},
    doi    = {10.5281/zenodo.7043135},
    url    = {https://doi.org/10.5281/zenodo.7043135},
}

Read the docs

https://github.com/petrasvestartas/compas_sandbox

Examples to reproduce our paper results

See examples in docs or try them in docs/examples.

Download files

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

Source Distribution

compas_sandbox-0.7.0.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

compas_sandbox-0.7.0-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file compas_sandbox-0.7.0.tar.gz.

File metadata

  • Download URL: compas_sandbox-0.7.0.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for compas_sandbox-0.7.0.tar.gz
Algorithm Hash digest
SHA256 ee1d6c3bfb52e5548b91f90c40644397d51f23fb3ec915ca52be3ba6da0bbd9e
MD5 4388e5cad8e7586c47e2eec6e9caa84f
BLAKE2b-256 4be34f99c65c83c1061713a6dc1e2dcbdf2aeb05ece0b780cc7ad0747a2ea8d0

See more details on using hashes here.

Provenance

The following attestation bundles were made for compas_sandbox-0.7.0.tar.gz:

Publisher: release.yml on petrasvestartas/compas_sandbox

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

File details

Details for the file compas_sandbox-0.7.0-py3-none-any.whl.

File metadata

  • Download URL: compas_sandbox-0.7.0-py3-none-any.whl
  • Upload date:
  • Size: 1.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for compas_sandbox-0.7.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7536f85c20b997046f3686511d7b4890646f5b5f4730c467e7e6639074c4fe7a
MD5 66c96404629d712d06ead97ea4333716
BLAKE2b-256 840a6240b1e84233ece7e4626c92b78ce38a55f97f126d41157f1f73e1e6d56a

See more details on using hashes here.

Provenance

The following attestation bundles were made for compas_sandbox-0.7.0-py3-none-any.whl:

Publisher: release.yml on petrasvestartas/compas_sandbox

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

Release history Release notifications | RSS feed

0.7.6

26 files

0.7.5

26 files

0.7.2

2 files

0.7.1

2 files

This release

0.7.0 This release

2 files

0.6.5

6 files

0.6.4

6 files

0.6.3

6 files

0.6.2

6 files

0.6.1

6 files

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