New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

grid-mesh

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grid-mesh

Creates a simplicial complex for a plane.

latest
Source
npmnpm
Version
0.1.0
Version published
Maintainers
1
Created
Source

grid-mesh

Creates a triangulated orthogonal grid. This is not the same as grid-graph, since:

  • It only works for 2D meshes (though they can be embedded in arbitrary dimensional space)
  • It fills in the faces

Usage

Install using npm:

npm install grid-mesh

And use as follows:

console.log(require("grid-mesh")(100, 100))

require("grid-mesh")(nx, ny[, origin, dx, dy])

Creates an nx by ny sized grid mesh.

  • nx the number of subdivisions along the dx axis
  • ny the number of subdivisions along the dy axis
  • origin is the start coordinate for the mesh (Default: [0,0])
  • dx the step vector along the x direction (Default: [1,0])
  • dy the step vector along the y direction (Defulat: [0,1])

Returns A json object with the following properties:

  • cells the cells of the mesh
  • positions the positions of the mesh

Credits

(c) 2013 Mikola Lysenko. MIT License

Keywords

grid

FAQs

Package last updated on 10 Apr 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts