0% found this document useful (0 votes)
11 views

Geometry and Physics Modeling With Python

The document discusses several projects related to geometric modeling and simulation using Python: - Pyplasm embeds the Plasm geometric modeling language into Python to enable geometric computing capabilities. - Modeling with chain complexes represents geometric structures as cell complexes and their relationships as Hasse matrices. - Chompy allows dataflow streaming of geometry between Python and Erlang for distributed computing via message passing. - Towards Complex Systems Simulations discusses using these techniques within the ProtoPlasm framework for complex systems simulations. Python Embedding Chompy: Python → Python ∪ Erlang Examples Towards Complex Systems Simulations PLaSM (Programming Language for Solid Modeling)

Uploaded by

Drago Mir
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Geometry and Physics Modeling With Python

The document discusses several projects related to geometric modeling and simulation using Python: - Pyplasm embeds the Plasm geometric modeling language into Python to enable geometric computing capabilities. - Modeling with chain complexes represents geometric structures as cell complexes and their relationships as Hasse matrices. - Chompy allows dataflow streaming of geometry between Python and Erlang for distributed computing via message passing. - Towards Complex Systems Simulations discusses using these techniques within the ProtoPlasm framework for complex systems simulations. Python Embedding Chompy: Python → Python ∪ Erlang Examples Towards Complex Systems Simulations PLaSM (Programming Language for Solid Modeling)

Uploaded by

Drago Mir
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 100

Pyplasm: Plasm → Python

Modeling with Chain Complexes


Chompy: Python → Python ∪ Erlang
Towards Complex Systems Simulations

Geometry and Physics Modeling with Python

A. DiCarlo† A. Paoluzzi† G. Scorzelli‡


† University “Roma Tre“, Italy ‡ University of Utah, USA

July 3, 2010

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes
Chompy: Python → Python ∪ Erlang
Towards Complex Systems Simulations

Outline

1 Pyplasm: Plasm → Python


Geometric Computing with a functional language
Python Embedding
Examples
2 Modeling with Chain Complexes
Cell complexes vs Chain complexes
The Hasse Matrix Representation
3 Chompy: Python → Python ∪ Erlang
Dataflow streaming of geometry
Distributed Computing via Message Passing
4 Towards Complex Systems Simulations
The ProtoPlasm framework

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Motivations for a new entry

Python: multi-paradigm language with efficient built-in data


structures and simple/effective approach to OO programming.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Motivations for a new entry

Python: multi-paradigm language with efficient built-in data


structures and simple/effective approach to OO programming.

Python’s elegant syntax and dynamic typing, and its


interpreted nature, make it ideal for scripting and RAD

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Motivations for a new entry

Python: multi-paradigm language with efficient built-in data


structures and simple/effective approach to OO programming.

Python’s elegant syntax and dynamic typing, and its


interpreted nature, make it ideal for scripting and RAD

We wished for easy access to Biopython, NumPy, SciPy,


Femhub, and the geometry libraries already interfaced with
Python

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Motivations for a new entry

Python: multi-paradigm language with efficient built-in data


structures and simple/effective approach to OO programming.

Python’s elegant syntax and dynamic typing, and its


interpreted nature, make it ideal for scripting and RAD

We wished for easy access to Biopython, NumPy, SciPy,


Femhub, and the geometry libraries already interfaced with
Python

The easiest solution?


Pyplasm: Plasm → Python

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level

Points, curves, surfaces,


solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes Minkowski sums
Representations:
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes Minkowski sums
Representations: Charts and atlases
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes Minkowski sums
Representations: Charts and atlases
d -Skeletons, 0 ≤ d ≤ n
BSP trees
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes Minkowski sums
Representations: Charts and atlases
d -Skeletons, 0 ≤ d ≤ n
BSP trees Convex hulls
Polytopes
Hasse graphs

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Geometric extension of Backus’ FL (IBM Yorktown)

(Multidimensional) Geometric Programming at Function Level


Geometric operators:
Points, curves, surfaces,
Affine maps
solids and higher-dim
Hierarchical structures
manifolds Boolean Ops
Domain: Hierarchical Cartesian products
polyhedral complexes Minkowski sums
Representations: Charts and atlases
d -Skeletons, 0 ≤ d ≤ n
BSP trees Convex hulls
Polytopes Domain integrals of
Hasse graphs polynomials

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

PLaSM (Programming Language for Solid Modeling)


Documentation

Paoluzzi, A., Pascucci, V.


& Vicentino, M. (1995).
Geometric programming: a
programming approach to
geometric design.
ACM Trans. Graph. 14
(3), 266–306.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Three general rules to write pyplasm code

Plasm primitives
ALL CAPS all capital letters

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Three general rules to write pyplasm code

Plasm primitives
ALL CAPS all capital letters

Application
is always unary VIEW(CUBOID([1,4,9]))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Three general rules to write pyplasm code

Plasm primitives
ALL CAPS all capital letters

Application
is always unary VIEW(CUBOID([1,4,9]))

Higher-level functions
Unusual but legal in Python COLOR(RED)(CUBE(1))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Boolean ops example: polygon filling

polylines = STRUCT(AA(POLYLINE)(List))

List = [
[[0,0],[4,2],[2.5,3],
[4,5],[2,5],[0,3],
[-3,3],[0,0]],

[[0,3],[0,1],[2,2],
[2,4],[0,3]],

[[2,2],[1,3],[1,2],
[2,2]]
]

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Boolean ops example: polygon filling

polygon = SOLIDIFY(polylines)

List = [
[[0,0],[4,2],[2.5,3],
[4,5],[2,5],[0,3],
[-3,3],[0,0]],

[[0,3],[0,1],[2,2],
[2,4],[0,3]],

[[2,2],[1,3],[1,2],
[2,2]]
]

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Boolean ops example: polygon filling

cells = SKELETON(1)(polygon)

List = [
[[0,0],[4,2],[2.5,3],
[4,5],[2,5],[0,3],
[-3,3],[0,0]],

[[0,3],[0,1],[2,2],
[2,4],[0,3]],

[[2,2],[1,3],[1,2],
[2,2]]
]

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Boolean ops example: polygon filling

solid = PROD([polygon, Q(0.5)])


List = [
[[0,0],[4,2],[2.5,3],
[4,5],[2,5],[0,3],
[-3,3],[0,0]],

[[0,3],[0,1],[2,2],
[2,4],[0,3]],

[[2,2],[1,3],[1,2],
[2,2]]
]

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Boolean ops example: polygon filling

complement = DIFFERENCE([
BOX([1,2,3])(solid), solid ])
List = [
[[0,0],[4,2],[2.5,3],
[4,5],[2,5],[0,3],
[-3,3],[0,0]],

[[0,3],[0,1],[2,2],
[2,4],[0,3]],

[[2,2],[1,3],[1,2],
[2,2]]
]

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Coding a new pyplasm primitive

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

The pyplasm EXPL in plain python

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

EXPL examples
List = SPLITCELLS(SPHERE(1)([8,12]))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

EXPL examples
List = SPLITCELLS(SPHERE(1)([8,12]))

pol1=EXPL([1,2,3])([1.5,1.5,1.5])(List) pol2 = EXPL(3)(1.5)(List)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Minkowsky sum of cell complexes with a convex cell

polList1 = SPLITCELLS(SK(1)(pol1)) polList2 = SPLITCELLS(pol1)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Minkowsky sum of cell complexes with a convex cell

polList1 = SPLITCELLS(SK(1)(pol1)) polList2 = SPLITCELLS(pol1)

EXPL([1.5,1.5,1.5])(polList1)) EXPL([1.5,1.5,1.5])(polList2)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Minkowsky sum of cell complexes with a convex cell


def fun (poly): return COMP([ EXPL([1.5,1.5,1.5]), SPLITCELLS,
(OFFSET([.1,.1,.1]) ])(poly)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Minkowsky sum of cell complexes with a convex cell


def fun (poly): return COMP([ EXPL([1.5,1.5,1.5]), SPLITCELLS,
(OFFSET([.1,.1,.1]) ])(poly)

fun(SPHERE(1)([8,12]))) fun(SKELETON(1)(SPHERE(1)([8,12])))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


ACM/IEEE Symposium on Solid Modeling and Applications, 43–52. ACM Press, 1993.

a = 10*[1,-5]+[1]; b = MINUS(a); P = PROD

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


ACM/IEEE Symposium on Solid Modeling and Applications, 43–52. ACM Press, 1993.

a = 10*[1,-5]+[1]; b = MINUS(a); P = PROD

P([ Q(b),Q(b) ])

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


ACM/IEEE Symposium on Solid Modeling and Applications, 43–52. ACM Press, 1993.

a = 10*[1,-5]+[1]; b = MINUS(a); P = PROD

STRUCT([ P([ Q(a),Q(a) ]), P([ Q(a),Q(b) ]),


P([ Q(b),Q(b) ]) P([ Q(b),Q(a) ]) ])

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


plan = PROD([ Q(10), Q([5,5]) ]) section = MKPOL([
[[0,4],[10,4],[10,7],[5,10],[0,7],[0,0],[10,0]], [[1,2,3,4,5],[1,2,6,7]], [[1],[2]] ])

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


plan = PROD([ Q(10), Q([5,5]) ]) section = MKPOL([
[[0,4],[10,4],[10,7],[5,10],[0,7],[0,0],[10,0]], [[1,2,3,4,5],[1,2,6,7]], [[1],[2]] ])

SK(1)(plan)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


plan = PROD([ Q(10), Q([5,5]) ]) section = MKPOL([
[[0,4],[10,4],[10,7],[5,10],[0,7],[0,0],[10,0]], [[1,2,3,4,5],[1,2,6,7]], [[1],[2]] ])

SK(1)(plan) SK(1)(section)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


Intersection of extrusions. Special case of Cartesian product

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


Intersection of extrusions. Special case of Cartesian product
house = GPROD([[1,2,3],[1,3,2]])([Obj1,Obj2])

EXPL([1.1,1.1,1.1])(SPLITCELLS(house))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Cartesian product on cell complexes


Intersection of extrusions. Special case of Cartesian product
house = GPROD([[1,2,3],[1,3,2]])([Obj1,Obj2])

EXPL([1.1,1.1,1.1])(SPLITCELLS(house)) sk1 = OFFSET([.2,.2,.4])(SK(1)(house))

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Scene graph of assemblies

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Scene graph of assemblies

str1 = STRUCT(10*[sk1,T(1)(11)])

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Geometric Computing with a functional language
Modeling with Chain Complexes
Python Embedding
Chompy: Python → Python ∪ Erlang
Examples
Towards Complex Systems Simulations

Scene graph of assemblies

str1 = STRUCT(10*[sk1,T(1)(11)]) str2 = STRUCT(10*[str1,T(2)(31)])

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chain complexes and Cochain complexes

A chain complex is a sequence of linear spaces of d -chains,


0 ≤ d ≤ n, with a sequence of boundary operators, each
mapping the space of d -chains to the space of (d − 1)-chains

The dual of the chain complex is the cochain complex

The duals of the boundary operators ∂ are the coboundary


operator δ, that map the spaces of d -cochains to the spaces of
(d + 1)-cochains

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chain complexes and Cochain complexes

All meshes, say partitioning either the boundary or the interior


of a model, and their associated physical fields, are properly
represented by a (co)chain complex.

Such a complex therefore gives a complete discrete


representation of any type of field over any type of geometric
model.

Huge geometric structures may be properly and efficiently


represented by sparse matrices, and therefore efficiently
manipulated through linear computational algebra, in particular
by using the last-generation of highly parallel vector GPUs.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chain complexes and Cochain complexes


This representation apply to all cell complexes

The (co)chain representation captures formally and


unambiguously all the combinatorial relationships of abstract,
geometric, and physical modelling, via the standard topological
operators of boundary and coboundary.

This representation apply to all cell complexes, without


restriction of type, dimension, codimension, orientability,
manifoldness, etc.

Furthermore, this approach unifies the geometric and physical


computation in a common formal computational structure.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chains/cochains over a cell complex

A small 2-complex

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chains/cochains over a cell complex

Real-valued chains
A small 2-complex attach a signed
d -measure to d -cells

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chains/cochains over a cell complex

Real-valued chains
A small 2-complex attach a signed
d -measure to d -cells
such as length to
1-cells, area to 2-cells,
volume to 3-cells

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Chains/cochains over a cell complex

Real-valued chains
A small 2-complex attach a signed
d -measure to d -cells
such as length to
1-cells, area to 2-cells,
volume to 3-cells
they restore part of the
geometrical
information left out by
the purely topological
construction of a cell
complex

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

Hasse graph
Chains/cochains over a cell complex

already used in PyPlasm as the basic data structure

Hasse graph of the previous 2-complex

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

The Hasse matrix


A complete representation of the measured incidence between all cells of all dimensions

Discrete Physics using Metrized Chains. 2009. SIAM/ACM Conf. on


Geometric and Physical Modeling

Block structure of the Hasse matrix

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

The Hasse matrix


A complete representation of the measured incidence between all cells of all dimensions

Discrete Physics using Metrized Chains. 2009. SIAM/ACM Conf. on


Geometric and Physical Modeling

Block structure of the Hasse matrix


H(K ) is the sparse
bidiagonal matrix of
coboundary operators

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

The Hasse matrix


A complete representation of the measured incidence between all cells of all dimensions

Discrete Physics using Metrized Chains. 2009. SIAM/ACM Conf. on


Geometric and Physical Modeling

Block structure of the Hasse matrix


H(K ) is the sparse
bidiagonal matrix of
coboundary operators
H(K )> is the sparse
bidiagonal matrix of
boundary operators

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

The Hasse matrix


A complete representation of the measured incidence between all cells of all dimensions

Discrete Physics using Metrized Chains. 2009. SIAM/ACM Conf. on


Geometric and Physical Modeling

Block structure of the Hasse matrix


H(K ) is the sparse
bidiagonal matrix of
coboundary operators
H(K )> is the sparse
bidiagonal matrix of
boundary operators
k0 , k2 , ... are the sizes
of d -skeletons of even
dimensions

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Cell complexes vs Chain complexes
Chompy: Python → Python ∪ Erlang The Hasse Matrix Representation
Towards Complex Systems Simulations

The Hasse matrix


A complete representation of the measured incidence between all cells of all dimensions

Discrete Physics using Metrized Chains. 2009. SIAM/ACM Conf. on


Geometric and Physical Modeling

Block structure of the Hasse matrix


H(K ) is the sparse
bidiagonal matrix of
coboundary operators
H(K )> is the sparse
bidiagonal matrix of
boundary operators
k0 , k2 , ... are the sizes
of d -skeletons of even
dimensions
k1 , k3 , ... are the sizes
of d -skeletons of odd
dimensions
A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python
Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells
Cartesian product of cell complexes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells
Cartesian product of cell complexes
skeleton and boundary extraction

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells
Cartesian product of cell complexes
skeleton and boundary extraction
various types of local and global cell and (co)chain refinement

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells
Cartesian product of cell complexes
skeleton and boundary extraction
various types of local and global cell and (co)chain refinement
finite integration of polynomials over subcomplexes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Chompy
Python → Python ∪ Erlang

Chompy: to compute with (co)chain complexes using multi-paradigm and


concurrent computer languages (Python and Erlang, respectively).
—linear and higher order— dimension-independent simplicial
complexes
d -complexes of convex cells
Cartesian product of cell complexes
skeleton and boundary extraction
various types of local and global cell and (co)chain refinement
finite integration of polynomials over subcomplexes
and so on ...

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Erlang language
Concurrent processing done rigth

Powerful (open source and multi-platform) concurrent


functional programming language and runtime system

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Erlang language
Concurrent processing done rigth

Powerful (open source and multi-platform) concurrent


functional programming language and runtime system
Purely functional (single assignment, dynamic typing), easy to
understand and to debug

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Erlang language
Concurrent processing done rigth

Powerful (open source and multi-platform) concurrent


functional programming language and runtime system
Purely functional (single assignment, dynamic typing), easy to
understand and to debug
Fits well with multicore CPUs, clusters and SMP architectures

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Erlang language
Concurrent processing done rigth

Powerful (open source and multi-platform) concurrent


functional programming language and runtime system
Purely functional (single assignment, dynamic typing), easy to
understand and to debug
Fits well with multicore CPUs, clusters and SMP architectures
Even hot swapping of programs is supported — code can be
changed without stopping a system

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Erlang language
Concurrent processing done rigth

Powerful (open source and multi-platform) concurrent


functional programming language and runtime system
Purely functional (single assignment, dynamic typing), easy to
understand and to debug
Fits well with multicore CPUs, clusters and SMP architectures
Even hot swapping of programs is supported — code can be
changed without stopping a system
Developed by Ericsson to support distributed, fault-tolerant,
soft real-time, non-stop applications

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Disco: Erlang ∪ Python


Distributed computing framework developed by Nokia Research Center to solve real
problems in handling massive amounts of data

Disco users start Disco jobs in Python scripts.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Disco: Erlang ∪ Python


Distributed computing framework developed by Nokia Research Center to solve real
problems in handling massive amounts of data

Disco users start Disco jobs in Python scripts.

Jobs requests are sent over HTTP to the master.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Disco: Erlang ∪ Python


Distributed computing framework developed by Nokia Research Center to solve real
problems in handling massive amounts of data

Disco users start Disco jobs in Python scripts.

Jobs requests are sent over HTTP to the master.

Master is an Erlang process that receives requests over HTTP.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Disco: Erlang ∪ Python


Distributed computing framework developed by Nokia Research Center to solve real
problems in handling massive amounts of data

Disco users start Disco jobs in Python scripts.

Jobs requests are sent over HTTP to the master.

Master is an Erlang process that receives requests over HTTP.

Master launches another Erlang process, worker supervisor, on


each node over SSH.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Disco: Erlang ∪ Python


Distributed computing framework developed by Nokia Research Center to solve real
problems in handling massive amounts of data

Disco users start Disco jobs in Python scripts.

Jobs requests are sent over HTTP to the master.

Master is an Erlang process that receives requests over HTTP.

Master launches another Erlang process, worker supervisor, on


each node over SSH.

Worker supervisors run Disco jobs as Python processes.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP (Binary Space Partition) tree


Back to Chompy dataflow streaming

3 types of geometry nodes: FULL, EMPTY and FUZZY cells

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP (Binary Space Partition) tree


Back to Chompy dataflow streaming

3 types of geometry nodes: FULL, EMPTY and FUZZY cells

The FUZZY cells, to be split at next step, are in light gray

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP (Binary Space Partition) tree


Back to Chompy dataflow streaming

3 types of geometry nodes: FULL, EMPTY and FUZZY cells

The FUZZY cells, to be split at next step, are in light gray


The FULL cells are in dark gray

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP (Binary Space Partition) tree


Back to Chompy dataflow streaming

3 types of geometry nodes: FULL, EMPTY and FUZZY cells

The FUZZY cells, to be split at next step, are in light gray


The FULL cells are in dark gray
The EMPTY cells are not shown (of course :o)
A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python
Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Dataflow graph of the generating expression

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Dataflow graph of the generating expression

Dataflow graph of the pyplasm expression that produces the


mechanical piece

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Dataflow graph of the generating expression

Dataflow graph of the pyplasm expression that produces the


mechanical piece
The dataflow generation is from source preprocessing

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Dataflow graph of the generating expression

Dataflow graph of the pyplasm expression that produces the


mechanical piece
The dataflow generation is from source preprocessing
The various processes will run concurrently in an Erlang environment
A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python
Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: generation of the 2-circle


Splitting of both (a) the model and (b) the computation

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: generation of the 2-circle


Splitting of both (a) the model and (b) the computation

Dataflow refinement based on progressive splits of convex cells


with BSP tree nodes (hyperplanes)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: generation of the 2-circle


Splitting of both (a) the model and (b) the computation

Dataflow refinement based on progressive splits of convex cells


with BSP tree nodes (hyperplanes)
model partition induced by the BSP subtree closest to the root,
to be detailed independently on different computational nodes

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: biquadratic rational B-spline

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: biquadratic rational B-spline

each refinement is generated by splitting and is contained within the


previous cell

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: biquadratic rational B-spline

each refinement is generated by splitting and is contained within the


previous cell
In this case (approximation of a surface with a solid mesh) all of the
cells are either EMPTY or FUZZY, i.e. there are no solid cells
A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python
Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: the Leaning tower of Pisa


Parallel solid modeling using BSP dataflow. 2008. Journal of Comp. Geometry and Appl.

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: the Leaning tower of Pisa


Parallel solid modeling using BSP dataflow. 2008. Journal of Comp. Geometry and Appl.

Dataflow refinement of convex cells with BSP tree nodes


(hyperplanes)

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes Dataflow streaming of geometry
Chompy: Python → Python ∪ Erlang Distributed Computing via Message Passing
Towards Complex Systems Simulations

Progressive BSP: the Leaning tower of Pisa


Parallel solid modeling using BSP dataflow. 2008. Journal of Comp. Geometry and Appl.

Dataflow refinement of convex cells with BSP tree nodes


(hyperplanes)
model partition induced by the BSP subtree closest to the root,
detailed on different computational nodes
A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python
Pyplasm: Plasm → Python
Modeling with Chain Complexes
The ProtoPlasm framework
Chompy: Python → Python ∪ Erlang
Towards Complex Systems Simulations

The next step:

ProtoPlasm: A Parallel Language for Scalable Modeling of


Biosystems. 2009. Philosophical Transactions of the Royal Society
A, Vol. 366. Issue "The virtual physiological human: building a
framework for computational biomedicine I"

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python


Pyplasm: Plasm → Python
Modeling with Chain Complexes
The ProtoPlasm framework
Chompy: Python → Python ∪ Erlang
Towards Complex Systems Simulations

Thanks for your attention !!

A. DiCarlo, A. Paoluzzi, G. Scorzelli Geometry and Physics Modeling with Python

You might also like