|
HOSTDEVICE Dscalar | Det2x2 (const Dscalar &x11, const Dscalar &x12, const Dscalar &x21, const Dscalar &x22) |
| Calculate the determinant of a 2x2 matrix.
|
|
HOSTDEVICE void | Circumcenter (const Dscalar2 &x1, const Dscalar2 &x2, Dscalar2 &xc) |
| Calculates the circumcenter of the circle passing through x1, x2 and the origin.
|
|
HOSTDEVICE void | Circumcenter (const Dscalar2 &x1, const Dscalar2 &x2, const Dscalar2 &x3, Dscalar2 &xc) |
| Calculates the circumcenter through x1,x2,x3.
|
|
template<typename T > |
| __attribute__ ((always_inline)) void removeDuplicateVectorElements(vector< T > &data) |
| remove duplicate elements from a vector, preserving the order, using sets More...
|
|
newData | resize (n-1) |
|
ArrayHandle< T > | h1 (newData, access_location::host, access_mode::overwrite) |
|
| for (int i=0;i< n;++i) = h.data[i] |
|
newData | resize (n-indices.size()) |
|
| __attribute__ ((always_inline)) void printDscalar2(Dscalar2 a) |
| print a Dscalar2 to screen
|
|
newData | resize (n+extraElements) |
|
ArrayHandle< T > | hnew (newData, access_location::host, access_mode::overwrite) |
|
data | swap (newData) |
|
| if (Nvector > Narray) copydata.resize(Nvector) |
|
ArrayHandle< T > | handle (copydata, access_location::host, access_mode::overwrite) |
|
ArrayHandle< T > | handle (data, access_location::host, access_mode::read) |
|
copydata | resize (n) |
|
HOSTDEVICE void | Circumcircle (const Dscalar2 &x1, const Dscalar2 &x2, Dscalar2 &xc, Dscalar &radius) |
| Get the circumcenter and radius, given one of the points on the circumcircle is the origin...
|
|
HOSTDEVICE void | Circumcircle (const Dscalar2 &x1, const Dscalar2 &x2, const Dscalar2 &x3, Dscalar2 &xc, Dscalar &radius) |
| Get the circumcenter and radius given three distinct points on the circumcirle.
|
|
HOSTDEVICE Dscalar | dot (const Dscalar2 &p1, const Dscalar2 &p2) |
| The dot product between two vectors of length two.
|
|
HOSTDEVICE Dscalar | norm (const Dscalar2 &p) |
| The norm of a 2-component vector.
|
|
HOSTDEVICE bool | inAnnulus (const Dscalar2 &p1, const Dscalar &rmin, const Dscalar &rmax) |
| test if a point lies in an annulus, given the inner and outer radii
|
|
HOSTDEVICE Dscalar | SignedPolygonAreaPart (const Dscalar2 &p1, const Dscalar2 &p2) |
| Calculate the area of a triangle with a vertex at the origin.
|
|
HOSTDEVICE Dscalar | TriangleArea (const Dscalar2 &p1, const Dscalar2 &p2) |
| Calculate the area of a triangle with a vertex at the origin.
|
|
HOSTDEVICE void | getdhdr (Matrix2x2 &dhdr, const Dscalar2 &rij, const Dscalar2 &rik) |
| Calculate matrix of derivatives needed in the 2D Voronoi model. More...
|
|
HOSTDEVICE void | getdhdgamma (Dscalar2 &dhdg, const Dscalar2 &rij, const Dscalar2 &rik) |
| Calculate the derivative of a Voronoi vertex w/r/t shear strain. More...
|
|
HOSTDEVICE int | computeSign (Dscalar x) |
| compute the sign of a Dscalar, and return zero if x = 0
|
|
HOSTDEVICE Dscalar | computeSignNoCast (Dscalar x) |
| compute the sign of a Dscalar, and return zero if x = 0...but return a Dscalar to avoid expensive casts on the GPU
|
|
HOSTDEVICE void | computeForceSetVertexModel (const Dscalar2 &vcur, const Dscalar2 &vlast, const Dscalar2 &vnext, const Dscalar &Adiff, const Dscalar &Pdiff, Dscalar2 &dEdv) |
| compute a force on a vertex from changing cell vertices More...
|
|
HOSTDEVICE int | Quadrant (Dscalar x, Dscalar y) |
| Calculate which quadrant the point (x,y) is in.
|
|