{ "info": { "author": "Bradley Froehle", "author_email": "brad.froehle@gmail.com", "bugtrack_url": null, "classifiers": [ "Operating System :: POSIX :: Linux", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.2", "Topic :: Scientific/Engineering :: Mathematics" ], "description": "PyDistMesh_: A Simple Mesh Generator in Python\n==============================================\n\nPyDistMesh_ is a simple Python code for generating unstructured\ntriangular and tetrahedral meshes using *signed distance functions*. It\nintends to have the same functionality as and similar interface to the\nMATLAB-based DistMesh_. Like DistMesh, upon which it is based,\nPyDistMesh is distributed under the `GNU GPL`_.\n\n.. _PyDistMesh: https://github.com/bfroehle/pydistmesh\n.. _DistMesh: http://persson.berkeley.edu/distmesh/\n.. _`GNU GPL`: http://www.gnu.org/copyleft/gpl.html\n\n2-D Examples\n------------\n\n* Uniform Mesh on Unit Circle::\n\n >>> import distmesh as dm\n >>> import numpy as np\n >>> fd = lambda p: np.sqrt((p**2).sum(1))-1.0\n >>> p, t = dm.distmesh2d(fd, dm.huniform, 0.2, (-1,-1,1,1))\n\n* Rectangle with circular hole, refined at circle boundary::\n\n >>> import distmesh as dm\n >>> fd = lambda p: dm.ddiff(dm.drectangle(p,-1,1,-1,1),\n ... dm.dcircle(p,0,0,0.5))\n >>> fh = lambda p: 0.05+0.3*dm.dcircle(p,0,0,0.5)\n >>> p, t = dm.distmesh2d(fd, fh, 0.05, (-1,-1,1,1),\n ... [(-1,-1),(-1,1),(1,-1),(1,1)])\n\n\n3-D Examples\n------------\n\n* 3-D Unit ball::\n\n >>> import distmesh as dm\n >>> import numpy as np\n >>> fd = lambda p: np.sqrt((p**2).sum(1))-1.0\n >>> p, t = dm.distmeshnd(fd, dm.huniform, 0.2, (-1,-1,-1, 1,1,1))\n\n* Cylinder with hole::\n\n >>> import distmesh as dm\n >>> import numpy as np\n >>> def fd10(p):\n ... r, z = np.sqrt(p[:,0]**2 + p[:,1]**2), p[:,2]\n ... d1, d2, d3 = r-1.0, z-1.0, -z-1.0\n ... d4, d5 = np.sqrt(d1**2+d2**2), np.sqrt(d1**2+d3**2)\n ... d = dm.dintersect(dm.dintersect(d1, d2), d3)\n ... ix = (d1>0)*(d2>0); d[ix] = d4[ix]\n ... ix = (d1>0)*(d3>0); d[ix] = d5[ix]\n ... return dm.ddiff(d, dm.dsphere(p, 0,0,0, 0.5))\n >>> def fh10(p):\n ... h1 = 4*np.sqrt((p**2).sum(1))-1.0\n ... return np.minimum(h1, 2.0)\n >>> p, t = dm.distmeshnd(fd10, fh10, 0.1, (-1,-1,-1, 1,1,1))\n\nDemos\n-----\n\nFor a quick demonstration, run::\n\n $ python -m distmesh.demo2d\n\nor::\n\n $ python -m distmesh.demond\n\nDependencies\n------------\n\nPyDistMesh is compatible with both Python 2 and Python 3. (The author\nhas only tested it in Python 2.7 and Python 3.2). It requires several\ncommon Python packages:\n\n* NumPy_\n* SciPy_\n* matplotlib_ (optional)\n\nBuilding the package requires a C compiler and LAPACK_. Cython_, if\navailable, can be used to rebuild the extension module bindings.\n\n.. _NumPy: http://numpy.scipy.org/\n.. _SciPy: http://scipy.org/\n.. _matplotlib: http://matplotlib.sourceforge.net/\n.. _Cython: http://cython.org/\n.. _LAPACK: http://www.netlib.org/lapack/\n\nReferences\n----------\n\nThe DistMesh_ algorithm is described in the following two references.\nIf you use the algorithm in a program or publication, please\nacknowledge its authors by adding a reference to the first paper\nbelow.\n\n* P.-O. Persson, G. Strang, **A Simple Mesh Generator in MATLAB**.\n *SIAM Review*, Volume 46 (2), pp. 329-345, June 2004 (`PDF\n `__)\n\n* P.-O. Persson, **Mesh Generation for Implicit Geometries**.\n Ph.D. thesis, *Department of Mathematics, MIT*, Dec 2004 (`PDF\n `__)", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/bfroehle/pydistmesh", "keywords": "meshing", "license": "GPL", "maintainer": null, "maintainer_email": null, "name": "PyDistMesh", "package_url": "https://pypi.org/project/PyDistMesh/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/PyDistMesh/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/bfroehle/pydistmesh" }, "release_url": "https://pypi.org/project/PyDistMesh/1.2/", "requires_dist": null, "requires_python": null, "summary": "A Simple Mesh Generator in Python", "version": "1.2" }, "last_serial": 1107378, "releases": { "1.1": [ { "comment_text": "", "digests": { "md5": "f155509589ab0ba34a6d5a58e56a579c", "sha256": "f35546a0b60cb0ee8b3dbe7df9fb8a65b46c28ebe3f503c81311632e7c50e25f" }, "downloads": -1, "filename": "PyDistMesh-1.1.tar.gz", "has_sig": false, "md5_digest": "f155509589ab0ba34a6d5a58e56a579c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 55711, "upload_time": "2013-04-08T20:32:52", "url": "https://files.pythonhosted.org/packages/63/0d/3090c9c7f2bf16a62888a8910b8a4eef248700f2ac7adfad5dc6e5167e81/PyDistMesh-1.1.tar.gz" } ], "1.2": [ { "comment_text": "", "digests": { "md5": "c45719fdf1e545b55274cf04ba1082aa", "sha256": "f45010037c312f21f742ec83e640eda314455f4428a9c46567f128c82600d986" }, "downloads": -1, "filename": "PyDistMesh-1.2.tar.gz", "has_sig": false, "md5_digest": "c45719fdf1e545b55274cf04ba1082aa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 53914, "upload_time": "2014-05-29T02:53:36", "url": "https://files.pythonhosted.org/packages/39/3c/fef5c2f4882128e093ec308c2c0c29a37a1f5001a03423863728b0c8c000/PyDistMesh-1.2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c45719fdf1e545b55274cf04ba1082aa", "sha256": "f45010037c312f21f742ec83e640eda314455f4428a9c46567f128c82600d986" }, "downloads": -1, "filename": "PyDistMesh-1.2.tar.gz", "has_sig": false, "md5_digest": "c45719fdf1e545b55274cf04ba1082aa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 53914, "upload_time": "2014-05-29T02:53:36", "url": "https://files.pythonhosted.org/packages/39/3c/fef5c2f4882128e093ec308c2c0c29a37a1f5001a03423863728b0c8c000/PyDistMesh-1.2.tar.gz" } ] }