• Aucun résultat trouvé

Jacobians and Hessians of Mean Value Coordinates for Closed Triangular Meshes

N/A
N/A
Protected

Academic year: 2021

Partager "Jacobians and Hessians of Mean Value Coordinates for Closed Triangular Meshes"

Copied!
4
0
0

Texte intégral

(1)

HAL Id: hal-00619214

https://hal.archives-ouvertes.fr/hal-00619214v2

Submitted on 22 Oct 2011

HAL is a multi-disciplinary open access

archive for the deposit and dissemination of

sci-entific research documents, whether they are

pub-lished or not. The documents may come from

teaching and research institutions in France or

abroad, or from public or private research centers.

L’archive ouverte pluridisciplinaire HAL, est

destinée au dépôt et à la diffusion de documents

scientifiques de niveau recherche, publiés ou non,

émanant des établissements d’enseignement et de

recherche français ou étrangers, des laboratoires

publics ou privés.

Jacobians and Hessians of Mean Value Coordinates for

Closed Triangular Meshes

Jean-Marc Thiery, Julien Tierny, Tamy Boubekeur

To cite this version:

Jean-Marc Thiery, Julien Tierny, Tamy Boubekeur. Jacobians and Hessians of Mean Value

Coordi-nates for Closed Triangular Meshes. 2011. �hal-00619214v2�

(2)

1

Jacobians and Hessians of Mean Value Coordinates

for Closed Triangular Meshes

Jean-Marc Thiery

Julien Tierny

Tamy Boubekeur

T´el´ecom ParisTech – CNRS – LTCI

Abstract—In this technical note, we present the formulae of the derivatives of the Mean Value Coordinates [2] based transformations using an enclosing triangle mesh, acting as a cage for the deformation of an interior object.

I. BACKGROUND

A. Mean Value Coordinates for Closed Triangular Meshes Mean Value Coordinates for closed triangular meshes were introduced in [2]. In this section, we briefly review this work and describe the notations we will use in the rest of this note. As written in [2], a 3D point η can be expressed as a linear sum of the 3D positions piof the vertices of a triangular mesh

M by: η = P iwi·pi P iwi = P iλi· pi.

For a point x onto the surface (a two-dimensional param-eter), we note as usual φi[x] the linear function on M that

takes value 1 on vertex i and 0 on other vertices, and p[x] its 3D position. The definition of the weights λishould guarantee

linear precision (i.e. η =P

iλi(η)pi).

Since RB

η(M )

p[x]−η

|p[x]−η|dSη(x) = 0 (the integral of the unit

outward normal onto the unit sphere is 0), we have η = R Bη(M ) p[x] |p[x]−η|dSη(x) R Bη(M ) 1 |p[x]−η|dSη(x) (1) Bη(M ) being the projection of the manifold M onto the unit

sphere centered in η. Writing that ∀x p[x] =P iφi[x]pi, withPiφi[x] = 1, we obtain η = P i R Bη(M ) φi[x] |p[x]−η|dSη(x)pi R Bη(M ) 1 |p[x]−η|dSη(x) (2) The weights λi are given by

λi= R Bη(M ) φi[x] |p[x]−η|dSη(x) R Bη(M ) 1 |p[x]−η|dSη(x) (3) And the weights wi such that λi =Pwi

jwj are given by wi= Z Bη(M ) φi[x] |p[x] − η|dSη(x) (4) This definition guarantees linear precision; it gives a linear interpolation of the function onto the triangles of the cage; and it extends it in a regular way to the entire 3D space.

Computing the weightswi: The support of the function

φi[x] is only composed of the adjacent triangles to the vertex

i. Then, we can rewrite Eq. 4 as wi=PT ∈N 1(i)w T i, with wiT = Z Bη(T ) φi[x] |p[x] − η|· dT (5) Given a triangle T with vertices t1, t2, t3, we see that

X j wTt j · (ptj − η) = Z Bη(T ) P jφtj[x] · (ptj− η) |p[x] − η| · dT = Z Bη(T ) p[x] − η |p[x] − η|· dT , m T (6)

This last integral is simply the integral of the unit outward normal on the spherical triangle T .

By noting nT i = NiT |NT i| , with NT i , (pti+1− η) ∧ (pti+2− η)

(see Fig.1), it can be easily expressed as mT =X i 1 2θ T i n T i (7)

This comes from the fact that the integral of the unit outward normal on a closed surface is always 0.

Finally, we obtain X j wtT j · (ptj − η) = m T (8) This point was discussed in [2]. As the authors pointed out, by noting AT the 3 by 3 matrix {pt1− η, pt2 − η, pt3− η},

we can derive the weights wtTj by

{wT t1, w T t2, w T t3} t= AT −1· mT (9) Since NT i t

· (ptj− η) = 0 ∀i 6= j, we have from Eq. 8 that

wTt i = NT i t · mT NT i t · (pti− η) =N T i t · mT det(AT) ∀η /∈ Support(T ) (10)

(3)

2

II. MVC DERIVATIVES

We now present the derivatives of the Mean Value Coordinates. Deforming the cage mesh with f (pi) = pi

induces a deformation of the 3D space by f = P

iλi· pi.

In the rest of the document, for any function h : E → F , we note ∂xh, ∂yh, ∂zh its derivative by x, y, and z,

− → 5h its gradient, J h its jacobian, and Hh its hessian.

The deformation function f as defined acts now on R3

entirely. The derivatives of f can be expressed as a linear sum of positions pi= {xi, yi, zi}:        J f =P ipi· − → 5λit H(fx) =Pixi· Hλi H(fy) =Piyi· Hλi H(fz) =Pizi· Hλi (11)

Consequently, it allows to specify implicit equations on the cage in a linear system by giving specified rotations and scales on 3D locations, or to minimize the norm of the hessian to force rigidity, as done in the case of Green Coordinates in [1].

Since λi=Pwi jwj, − → 5λi= − → 5wi P jwj −wi· P j − → 5wj (P jwj)2 (12) We also have ∀c = x, y, z ∂c( − → 5λi) = ∂c( − → 5wi) P jwj − − → 5wi·Pj∂c(wj) (P jwj)2 −∂c(wi) · P j − → 5wj+ wi·Pj∂c( − → 5wj) (P jwj)2 +2wi· ( P j − → 5wj) · (Pk∂c(wk)) (P jwj)3 (13) or Hλi= Hwi P jwj −wi P jHwj (P jwj)2 − − → 5wi·Pj − → 5(wj)t+Pj − → 5(wj) · − → 5wit (P jwj)2 +2wi( P j − → 5wj) · (Pj − → 5wj)t (P jwj)3 (14)

From these expressions, we see that, in order to get−→5λi(η)

and Hλi(η), we first need to obtain

− →

5wi(η) and Hwi(η) for

each vertex i of the cage.

Special case:η lies on the surface of the cage

Mean Value Coordinates define an interpolation process. The function represented onto the vertices of the cage (in our case, a space transformation) is extended to the interior of the triangles with linear interpolation on each triangle. Then it is extended to the space by means of a surfacic integration of the function (see Eq. 1).

Since we represent the cage as triangle mesh in the 3D case, the deformation function cannot be anything more

than continuous onto the edges of the cage in 3D. Therefore Jacobians and Hessians of the deformation cannot be evaluated everywhere on the surface of the cage, and we do not provide any formula for Jacobians and Hessians of the deformation onto the surface of the cage.

A. Expression of the Jacobians

In the general case where det(AT) = (p ei− η) t· NT i 6= 0, we have − → 5wT ti = BT t·NT i det(AT) with BT =X j eq1(θjT)NjT· NjT t · J NT j 2(|ptj+2− η||ptj+1− η|) 3 −X j NT j · (2η − ptj+1− ptj+2) t 2(|ptj+2− η||ptj+1− η|) 2 +X j eq2(θjT)J NjT 2|ptj+2− η||ptj+1− η| +X j wtTj· I3

and eq1(x) = cos(x) sin(x)−xsin(x)3 and eq2(x) = sin(x)x two well

defined functions on ]0, π[ that admit well controlled Taylor expansion around 0, J NT

j = (ptj+2− ptj+1)[∧], k[∧] being the

skew 3 by 3 matrix (i.e. k[∧] t

= −k[∧]) such that k[∧]· u =

k ∧ u ∀k, u ∈ R3.

Special case:η ∈ Support(T ), /∈ T : −2|T |−→5wTi = X j eq2(θTj)(pti+2− pti+1) t· (p tj+2− ptj+1) 2|ptj+2− η||ptj+1− η| nT +X j eq1(θTj)|ptj+2− ptj+1| 2NT i t · NT j 4(|ptj+2− η||ptj+1− η|) 3 nT +X j cos(θT j)eq3(θjT)NiT t · NT j 2(|ptj+2− η||ptj+1− η|) 2nT (15) with eq2(x) = sin(x)x , eq1(x) = cos(x) sin(x)−xsin(x)3 , and

eq3(x) =

cos(x)−1

sin(x)2 being functions well defined on ]0, π[ and

that admit controlable Taylor expansion around 0.

B. Expression of the Hessians We note δx=   1 0 0  , δy =   0 1 0  , δz=   0 0 1  . HwiT = 1 det(AT)    NT i t · ∂x(J mT) NiTt· ∂y(J mT) NT i t · ∂z(J mT)    + 1 det(AT)(N T i · ( X j − → 5wT j) t+X j − → 5wT j · N T i t ) (16)

(4)

3 with ∂c(J mT) = X j eq6(θjT)(J NjT t · NT j )(c)NjT · NjT t · J NT j 2(|ptj+2− η||ptj+1− η|) 5 −X j eq7(θTj)(2η − ptj+1− ptj+2)(c)N T j · N T j t · J NT j 2(|ptj+2− η||ptj+1− η|) 4 +X j eq1(θTj)∂c(NjT) · NjT t · J NT j 2(|ptj+2− η||ptj+1− η|) 3 +X j eq1(θTj)NjT · ∂c(NjT) t · J NT j 2(|ptj+2− η||ptj+1− η|) 3 −X j 3eq1(θTj)(η − ptj+1)(c)N T j · N T j t · J NT j 2|ptj+2− η| 3|p tj+1− η| 5 −X j 3eq1(θTj)(η − ptj+2)(c)N T j · NjT t · J NT j 2|ptj+2− η| 5|p tj+1− η| 3 −X j ∂c(NjT) · (2η − ptj+1− ptj+2) t 2(|ptj+2− η||ptj+1− η|) 2 +X j (η − ptj+1)(c)N T j · (2η − ptj+1− ptj+2) t |ptj+2− η| 2|p tj+1− η| 4 +X j (η − ptj+2)(c)N T j · (2η − ptj+1− ptj+2) t |ptj+2− η| 4|p tj+1− η| 2 +X j eq8(θTj)(J NjT t · NT j )(c)J NjT 2(|ptj+2− η||ptj+1− η|) 3 −X j eq9(θTj)(2η − ptj+1− ptj+2)(c)J N T j 2(|ptj+2− η||ptj+1− η|) 2 −X j (η − ptj+1)(c)eq2(θ T j)J NjT 2|ptj+2− η||ptj+1− η| 3 −X j (η − ptj+2)(c)eq2(θ T j)J NjT 2|ptj+2− η| 3|p tj+1− η| −X j NT j · δct |ptj+2− η| 2|p tj+1− η| 2 (17) and eq6(x) = d(eq1) dx (x)cos(x)/sin(x), eq7(x) = d(eq1) dx (x)sin(x), eq8(x) = d(eq2) dx (x)cos(x)/sin(x), and

eq9(x) = d(eqdx2)(x)sin(x) being functions well defined on

]0, π[ and that admit controllable Taylor expansion around 0. Special case:η ∈ Support(T ), /∈ T :

H(wiT)(η) =−→5dwT i (η) · n t T (18) with − 2|T |−→5dwT i = −X j ((pti+2− pti+1) t· (p tj+2− ptj+1))(2η − ptj+2− ptj+1) (|ptj+2− η||ptj+1− η|) 2 +X j eq1(θjT)((pti+2− pti+1) t· (p tj+2− ptj+1))J N T j t · NT j 2(|ptj+2− η||ptj+1− η|) 3 +X j |ptj+2− ptj+1| 2(NT i t · NT j )(2η − ptj+2− ptj+1) 2(|ptj+2− η||ptj+1− η|) 4 +X j eq1(θjT)|ptj+2− ptj+1| 2(J NT j t · NT i + J NiT t · NT j ) 4(|ptj+2− η||ptj+1− η|) 3 −X j eq4(θjT)|ptj+2− ptj+1| 2(NT i t · NT j )J NjT t · NT j 2(|ptj+2− η||ptj+1− η|) 5 +X j cos(θTj)eq3(θTj)(J N T j t · NT i + J N T i t · NT j ) 2(|ptj+2− η||ptj+1− η|) 2 −X j (1 − 2 cos(θT j))(NiT t · NT j )(2η − ptj+2− ptj+1) 2(|ptj+2− η||ptj+1− η|) 3 +X j eq5(θjT)(NiT t · NT j )J NjT t · NT j 2(|ptj+2− η||ptj+1− η|) 4 (19) and eq1(x) = cos(x) sin(x)−x sin(x)3 , eq4(x) = 2 cos(x) sin(x)3+3(sin(x) cos(x)−x)

sin(x)5 , eq3(x) =

cos(x)−1 sin(x)2 , and

eq5(x) = cos(x) sin(x)

2(1−2 cos(x))−2 cos(x)2+2 cos(x)

sin(x)4 being

functions well defined on ]0, π[ and that admit controllable Taylor expansion formula around 0.

REFERENCES

[1] M. Ben-Chen, O. Weber, and C. Gotsman, Variational harmonic maps for space deformation, ACM Transactions on Graphics (Proc. of ACM SIGGRAPH) (2009), 1–11.

[2] T. Ju, S. Schaefer, and J. Warren, Mean value coordinates for closed triangular meshes, ACM Transactions on Graphics (Proc. of ACM SIGGRAPH) 24 (2005), no. 3, 561–566.

Figure

Fig. 1. Triangle T projected on the spherical triangle ¯ T.

Références

Documents relatifs

Recently, the authors of [15, 4] show that the pseudopolynomial procedures in [18, 13, 12] can be used to design (fully) polynomial value approximation schemes for certain classes

† Laboratoire de Math´ ematiques et Physique Th´ eorique CNRS-UMR 7350, Universit´ e de Tours, Campus de Grandmont, 37200 Tours, FRANCE and Universit´ e de Tunis El Manar, Facult´

A mean value criterion for plurisubharmonic functions Karim Rakhimov and Shomurod

The différences between the asymptotic distribution of the bootstrap sample mean for infinitesimal arrays and for sequences of independent identically distributed

Smooth boundaries will be in fact considered in [17], where we applyformula (11) to derive a recursive algorithm for the computation of the complete asymptotic series of the

Toute utilisa- tion commerciale ou impression systématique est constitutive d’une in- fraction pénale.. Toute copie ou impression de ce fichier doit conte- nir la présente mention

Toute utili- sation commerciale ou impression systématique est constitutive d’une infraction pénale.. Toute copie ou impression de ce fichier doit conte- nir la présente mention

The mean value estimate supplied by our new bounds for J s,k (X) via Theorem 8.5 may be utilised to derive improvements in our understanding of the asymptotic formula in