Python wrapper around blockMeshDict creation
Project description
#+TITLE: pyblockmesh
#+AUTHOR: Vishakh Pradeep Kumar
#+EMAIL: grokkingStuff@gmail.com
Python Library
#+BEGIN_SRC sh :exports results
.
├── CHANGELOG.md
├── CONTRIBUTING.md
├── index.org
├── LICENSE
├── pyblockmesh
│ ├── edge.py
│ ├── face.py
│ ├── hexahedron.py
│ ├── __init__.py
│ └── vertex.py
├── pytest.ini
├── README.md
├── README.org
├── requirements.txt
├── script
│ └── test
├── setup.py
└── tests
├── helpers
│ ├── __init__.py
│ └── my_helper.py
├── __init__.py
├── tests_helper.py
└── unit
├── __init__.py
├── test_example.py
└── test_version.py
5 directories, 22 files
#+END_SRC
* Example
#+BEGIN_SRC ipython :session pyblockmesh
import pyblockmesh as pbm
v0 = pbm.Vertex(-1,-1,-1)
v1 = pbm.Vertex( 1,-1,-1)
v2 = pbm.Vertex( 1, 1,-1)
v3 = pbm.Vertex(-1, 1,-1)
v4 = pbm.Vertex(-1,-1, 1)
v5 = pbm.Vertex( 1,-1, 1)
v6 = pbm.Vertex( 1, 1, 1)
v7 = pbm.Vertex(-1, 1, 1)
h1 = pbm.Hexahedron([v0,v1,v2,v3,v4,v5,v6,v7],numberOfCells=[3,3,3])
string = pbm.buildBlockMesh()
print(string)
blockMeshDict = open("foo.txt", "wb")
blockMeshDict.write(string)
#+END_SRC
#+RESULTS:
: # Out[1]:
* Requirements
Package requirements are handled using pip. To install them do
#+BEGIN_SRC sh
pip install -r requirements.txt
#+END_SRC
#+AUTHOR: Vishakh Pradeep Kumar
#+EMAIL: grokkingStuff@gmail.com
Python Library
#+BEGIN_SRC sh :exports results
.
├── CHANGELOG.md
├── CONTRIBUTING.md
├── index.org
├── LICENSE
├── pyblockmesh
│ ├── edge.py
│ ├── face.py
│ ├── hexahedron.py
│ ├── __init__.py
│ └── vertex.py
├── pytest.ini
├── README.md
├── README.org
├── requirements.txt
├── script
│ └── test
├── setup.py
└── tests
├── helpers
│ ├── __init__.py
│ └── my_helper.py
├── __init__.py
├── tests_helper.py
└── unit
├── __init__.py
├── test_example.py
└── test_version.py
5 directories, 22 files
#+END_SRC
* Example
#+BEGIN_SRC ipython :session pyblockmesh
import pyblockmesh as pbm
v0 = pbm.Vertex(-1,-1,-1)
v1 = pbm.Vertex( 1,-1,-1)
v2 = pbm.Vertex( 1, 1,-1)
v3 = pbm.Vertex(-1, 1,-1)
v4 = pbm.Vertex(-1,-1, 1)
v5 = pbm.Vertex( 1,-1, 1)
v6 = pbm.Vertex( 1, 1, 1)
v7 = pbm.Vertex(-1, 1, 1)
h1 = pbm.Hexahedron([v0,v1,v2,v3,v4,v5,v6,v7],numberOfCells=[3,3,3])
string = pbm.buildBlockMesh()
print(string)
blockMeshDict = open("foo.txt", "wb")
blockMeshDict.write(string)
#+END_SRC
#+RESULTS:
: # Out[1]:
* Requirements
Package requirements are handled using pip. To install them do
#+BEGIN_SRC sh
pip install -r requirements.txt
#+END_SRC
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pyblockMesh-0.0.2.tar.gz
(5.3 kB
view hashes)