12
A smoothed particle hydrodynamics algorithm for haptic rendering of dental filling materials Conference or Workshop Item Accepted Version Tse, B., Barrow, A., Quinn, B. and Harwin, W. S. (2015) A smoothed particle hydrodynamics algorithm for haptic rendering of dental filling materials. In: IEEE World Haptics Conference, 22-26 Jun 2015, Chicago, pp. 321-326. doi: https://doi.org/10.1109/WHC.2015.7177732 Available at http://centaur.reading.ac.uk/67693/ It is advisable to refer to the publisher’s version if you intend to cite from the work.  See Guidance on citing  . Published version at: http://dx.doi.org/10.1109/WHC.2015.7177732 To link to this article DOI: http://dx.doi.org/10.1109/WHC.2015.7177732 All outputs in CentAUR are protected by Intellectual Property Rights law, including copyright law. Copyright and IPR is retained by the creators or other copyright holders. Terms and conditions for use of this material are defined in the End User Agreement  www.reading.ac.uk/centaur   

A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

  • Upload
    others

  • View
    8

  • Download
    0

Embed Size (px)

Citation preview

Page 1: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

A smoothed particle hydrodynamics algorithm for haptic rendering of dental filling materials Conference or Workshop Item 

Accepted Version 

Tse, B., Barrow, A., Quinn, B. and Harwin, W. S. (2015) A smoothed particle hydrodynamics algorithm for haptic rendering of dental filling materials. In: IEEE World Haptics Conference, 22­26 Jun 2015, Chicago, pp. 321­326. doi: https://doi.org/10.1109/WHC.2015.7177732 Available at http://centaur.reading.ac.uk/67693/ 

It is advisable to refer to the publisher’s version if you intend to cite from the work.  See Guidance on citing  .Published version at: http://dx.doi.org/10.1109/WHC.2015.7177732 

To link to this article DOI: http://dx.doi.org/10.1109/WHC.2015.7177732 

All outputs in CentAUR are protected by Intellectual Property Rights law, including copyright law. Copyright and IPR is retained by the creators or other copyright holders. Terms and conditions for use of this material are defined in the End User Agreement  . 

www.reading.ac.uk/centaur   

Page 2: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

CentAUR 

Central Archive at the University of Reading 

Reading’s research outputs online

Page 3: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

A Smoothed Particle Hydrodynamics Algorithm for HapticRendering of Dental filling materials

Brian Tse1, Alaistair Barrow2, Barry Quinn3 and William S. Harwin4∗†‡§

June 2015¶

Abstract

Using haptic interfaces to assist the training of skillswithin the curriculum of undergraduate dentists pro-vides a unique opportunity to advance rendering al-gorithms and engineering of haptic devices. In thispaper we use the dental context to explore a render-ing technique called smoothed particle hydrodynam-ics (SPH) as a potential method to train students onappropriate techniques for insertion of filling mate-rial into a previously prepared (virtual) dental cav-ity. The paper also considers how problems of hap-tic rendering might be implemented on a GraphicalProcessing Unit (GPU) that operates in the hapticscontrol loop. The filling simulation used 3000 parti-cles to represent the cavity boundary (approx. 1400particles), tool (approx. 42 particles) and filling ma-terial (approx. 1600 particles), running at an averageof 447Hz. Novel smoothing function in SPH was de-veloped and its flexibility is presented.

1 Introduction

Haptic interfaces have a good history of use as a skilltraining aid, in particular for medical, veterinary and

∗1Brian Tse ([email protected]) receivevd hisPhD from The University of Reading, UK†2Alaistair Barrow is a director of Generic Robotics Ltd,

UK‡3Barry Quinnis is with Kings College Dental School, Lon-

don§4William Harwin ([email protected]) is with

The University of Reading, UK¶Published in IEEE World Haptics Conference (WHC)

(June 2015).

dental education. King’s College London requiresstudents to gain practical experience of cavity prepa-ration and restoration in support of their theoreticaleducation at the early stages of dental training andnow use a haptic simulator as a viable method to sup-port this teaching with a suite of workstations in usesince 2009[11, 2].

Removing material is a relatively well explored pro-cess in haptic rendering, however tooth restorationalso requires filling and curing of the cavity. In thispaper we consider smoothed particle hydrodynamics(SPH) as a framework for applying soft body hapticrendering to the simulation of dental filling. A newadhesion model in SPH is used to replicate the softbody dynamics of dental materials. Finally the ben-efits of using GPU hardware for haptic rendering ofSPH are evaluated.

Smoothed particle hydrodynamics facilitates theneed to change the properties of the filling materialduring operation, thus enabling simulation of char-acteristics such as work hardening and curing of thefilling material with ultraviolet light.

2 Background to smoothedparticle hydrodynamics

Smoothed particle hydrodynamics (SPH) providea useful framework for rendering fluids. Accord-ing to Liu[7], Smoothed particle hydrodynamicswas originally developed by Lucy [8], Gingold andMonaghan[4] as a mesh-free particle method for as-trophysical analysis. The work was subsequentlyused for simulating fluids and is now widely used

Page 4: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

in computer animation. Cirio et al.[1] have imple-mented SPH in a realistic haptic simulation of fluidswhere they demonstrate stable rendering of fluid flow(pancake batter) using a 6DoF Virtuose from Hap-tion. Several authors give a general background toSPH[7, 3, 6, 9, 10].

Smoothed particle hydrodynamics provides amethod for solving systems of differential equationssuch as the Navier Stokes equation. Kernels1 are usedto interpolate the value of a field variable and a wellchosen Kernel allows the calculation to be confinedlocally to a particle. Differentiable kernels allow easycalculation of the gradient or Laplacian vial the ker-nel rather than on the fields associated with each par-ticle. Any particle j in a collection of N particles areattributed with a position rj , velocity vj , mass mj ,and density ρj . The value of a field fj such as pres-sure can be also be attributed to each particle thusallowing interpolation of the field across all particlesin the system (< f(r) >) to be computed using thefollowing equation

< f(r) >=

N∑j

mjfjρjW (r− rj , h) (1)

Where : W (r−rj , h) is a kernel described below (8, 9and 10). Taking the gradient of the field can be doneby noting that the only term dependent on position inequation 1 is the kernel W (r− rj , h). However somecare is needed since numerical problems can lead tonon symmetrical solutions or a non zero differentialvalue in a constant field so the variation suggestedby Muller[10] is usually considered where an averagefield is used for the interpolation.

< ∇f(r) >=∑j 6=i

fi + fj2

mj

ρj∇W (r− rj , h)

According to[7], there are several properties forconstructing the smoothing function:

1. The integral of the smoothing function over thesupport domain must be equal to 1, satisfyingthe Dirac delta function.

1Since both the SPH algorithm and CUDA use the termKernel the latter will be prefaced as CUDA kernels althoughit should be evident from context

2. Compact support (non zero in a limited space)and kernel symmetry.

3. Positive support domain of centered particle.

4. The effect of neighbour particles should decaysmoothly as the distance increases.

3 Methods

We have adapted smoothed particle hydrodynamicsalgorithms to simulate dental filling. The demonstra-tion hardware ran the SPH algorithm on a GPU witha second GPU for the visual rendering. Additionalproperties included adhesion/cohesion forces betweenthe particles well as a modified kernel to allow effi-cient implementation.

3.1 Particle Interaction Forces

Four particle interaction forces were considered.These were gravity, pressure, viscosity and the forcesdue to cohesion and adhesion2 (eqn 3). The forceper unit volume due to pressure is Fpress = −∇P (r),where P is the pressure. The SPH formulation ofFpress (eqn 5). In the case of viscosity Fvis =µ∇2V(r), where V is the velocity. The Laplacianof this vector field is also calculated on the Lapla-cian of the kernel. The viscous force is shown ineqn 4. Both the pressure and viscous force and theirsmoothing function used in this research were basedon Muller[10] and Cirio[1] as it produces symmetricalforces and reduces numerical errors.

Ftotal = FLJ + Fvis + Fgravity (2)

where the FLJ is the Lennard-Jones force consistsof pressure and adhesion:

FLJ = Fadh + Fpress (3)

Fvis =∑ µi + µj

2mj

Vj − Viρj

∇2Wvis(−→rij , h) (4)

2Cohesion and adhesion refer to the attraction between sim-ilar or dissimilar particles respectively. The term adhesion isused when describing situations that would also include cohe-sion

Page 5: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

Fpress = −∑ Pi + Pj

2

mj

ρj∇Wspike(

−→rij , h) (5)

where:

µi, µj : Viscosity associated with particlei and j

mj : Particle j massVi, Vj : Velocity of particle i and jPi, Pj : Pressure of i and jWspike,Wvis : Smoothing function used in pres-

sure and viscosity force, shownin (9) and (10).

The particle mass density and pressure are shownin (6) and (7).

ρi = −∑

mjWpoly6(−→rij , h) (6)

Pi = KP (i)(ρi − ρinit) (7)

where:

Wpoly6 : Smoothing function used in mass den-sity calculation, shown in (8)

KP (i) : Mass density recovery constant of par-ticle i.

Different smoothing functions facilitate field calcu-lations, and Muller based the pressure smoothing onDebrun’s Spiky kernel and designed new smoothingkernels for mass density and viscosity. (See eqns 8,9and 10)

Wpoly6(−→rij , h) = Ca

{(h2 − |−→rij |2)3 0 ≤ |−→rij | ≤ h0 |−→rij | > h

(8)

∇Wspiky(−→rij , h) = Cb

−→rij|−→rij |

{(h− |−→rij |)2 0 ≤ |−→rij | ≤ h0 |−→rij | > h

(9)

∇2Wvis = Cc

{(h− |−→rij |) 0 ≤ |−→rij | ≤ h0 |−→rij | > h

(10)

Where Ca, Cb and Cc are normalization factor thatdepend on the dimension of the problem domain.

Dental filling material includes adhesion and co-hesion properties. The SPH method in[3] also con-sidered these attraction properties and proposed theSpiky Smoothing Kernel. Muller and Circio also em-ployed this kernel for liquid based simulation. Thissmoothing kernel allowed the particle interaction toproduce a force and displacement characteristic simi-lar to the Lennard-Jones model of particle potential.Their cohesion properties were described as a func-tion of low fluid pressure, which was modified from agas pressure function. The cohesion was achieved byadjusting the mass density recovery constant (KP (i))and the resting density (ρinit) in (7). However, thismethod lacked the ability to control attraction andrepulsion independently. Any changes to KP (i) andρinit would result in a change in both attraction andrepulsion force. For material such as dental filling,this method required some modification.

In this research, a new adhesion/cohesion methodmodel was developed within the SPH framework,based on Desbrun and Muller methods. The cohesionforce here is described as a material physical connec-tion rather than pressure gradient force. Instead ofmodelling the Lennard-Jones model in a single pres-sure function, the pressure and the adhesion forceboth have individual smoothing function to replicatethe shape of particle repulsion and attraction. Thesetwo forces are modelled separately in order to achieveindependent control. Care is needed to blend pres-sure and adhesion into a single kernel to ensure cor-rect adjustable Lennard-Jones behaviour.

The pressure force equation in this work used theSpiky kernel to produce a pure repulsive force. Thiswas achieved by setting the mass and resting densitycondition to ρi ≥ ρinit. ρinit is a predefined initialdensity constant.

The adhesion force calculation only needs to beactivated when two particles are in within a prede-fined distance. The adhesion force should then beblended with the pressure force to provide a contin-ued motion for the particle. As the two particlesmove towards each other, the effect of pressure forcedominates. If the adhesion force is activated, whentwo particle moved apart, the adhesion force would

Page 6: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

−0.1 0 0.1 0.2 0.3 0.4 0.5

−2000

−1000

0

1000

2000

3000

4000

Particle Distance

Part

icle

fo

rce p

rod

uced

by S

PH

(Red) Force produced by both adhesion and pressure smoothing function only

Particle follow this path when adhesion activated

Adhesion smoothing function end point,Adhesion deactivated when particle

distance by pass this point

BhA

(Black) Force produced by both adhesion smoothing function only

Adhesion smoothing function start point, blending function start point and

adhesion activated point

Pressure smoothing function start point (Particle initial contact)

(Blue) Force produced by pressure smoothing function only

Symmetrical axis of both kernel

Figure 1: The combined pressure gradient (∇Wspiky)and adhesion kernel Wadh. Shows the smoothingfunction of the adhesion force, pressure force and theblending function of both forces. Note: the kernelaxis symmetry as shown.

attract them towards each other. Fig. 1 demonstratesthe pressure and adhesion smoothing function as wellas the resulted blending force. The adhesion smooth-ing function is inverted to map the force direction forclearer presentation purposes. The loading and un-loading of the particle interaction path are shown inFig. 2 and the calculation of the adhesion force isgiven in eqn 11.

FAdh =∑ Ka(j) +Ka(i)

2

mj

ρjWAdh(−→rij , ha) (11)

where:

Ka(i),Ka(j) : Adhesion parameters for particle i andj

WAdh : Adhesion smoothing function

The calculation of adhesion smoothing function isshown in eqn 12 and design to be effect between sup-port domain A and B from the particle, see Fig. 1.

WAdh(−→rij , ha) = Cd

0 |−→rij | < A

(−→raQ )ε − (

−→raQ )ζ A ≤ |−→rij | ≤ B

0 |−→rij | > B(12)

where: ε > ζ, Q = (B −A), −→ra = (rj −A) and,A : Adhesion smoothing function starting

point (activation distance).B : Adhesion smoothing function end point.ε, ζ : User adjustable adhesion behaviour. In

this application ε = 3 and ζ = 2If the adhesion is activated, the blending force oc-

curs between the adhesion smoothing function start-ing point and the pressure smoothing function sup-port domain (h). The blending of the pressure andadhesion force are shown in (13).

FLJ =

Fpress = 0 |−→rij | > hFpress + Fadh A ≤ |−→rij | ≤ hFadh = 0 |−→rij | < A

(13)

3.2 Algorithmic Implementation

The SPH algorithmic structure used to render thedental the filling simulation was based on the Nvidiaparticle simulation structure[5]. This research ex-tended the CUDA particle algorithm to include SPHand achieve loop times compatible with haptic ren-dering. We also implemented a less efficient algo-rithm where every inter particle distance is consid-ered and used in the force calculations.

The structure of the GPU requires a different ap-proach to programming. The concept of broad andnarrow phase collision detection is well suited to com-putation on GPU hardware, where particles likely tocollide are first identified in broad phase. During nar-row phase processing properties relevant to SPH arecalculated including mass density and pressure. Theoptimised SPH implementation used 6 steps. Thesewere:

1. Broad phase collision detection. Based on theNvidia grid method.

2. Reorganize particles and cell.

Page 7: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

3. First pass narrow phase collision detection. Cal-culation of mass density.

4. Calculation of particle pressure field.

5. Second pass narrow phase collision detection.Calculation of adhesion, viscous and pressureforces.

6. Use sum of forces from previous simulation loopto compute particle acceleration and integrationfor new particle velocity and position.

The concept of broad and narrow phase collisiondetection reduces the read/write operation time andglobal memory space on GPU, maximized the com-putation efficiency in terms of particles number. Themass density computation must be done first as thevalues are required in the second pass calculations.

Different particles are needed to represent the tool,filling material and cavity. We employed the ghostparticle methods[7] to implement cavity walls and thehaptic tool. The cavity walls remained static duringthe simulation whereas the tool particles were up-dated based on the position of the haptic device.

Step 1. Broad phase collision detection,and

Step 2. Rearrange and organize parti-cle and cell information

The broad phase collision detection was based onthe particle simulation by Nvidia[5] using the Par-allel Radix Sort algorithm (provided in the CUDAThrust Library). This provided fast data access forthe narrow phase collision detection.

Step 3. First pass narrow phase colli-sion detection and calculation of massdensity and

Step 4. Calculate particle pressure

Each particle can only interact with other particles inthe 27 neighbouring cells (including the Home Cell).The narrow phase collision detection uses the sorted

Home Cell/Particle ID list to identify other particleswithin these neighbouring cells. It first calculatedthe mass density and then used it to calculation thepressure value.

3.3 Step 5. Second pass narrow phasecollision detection and calculationof adhesion, viscous and pressureforce

The second pass narrow phase collision detection isthen performed to once again retrieve neighbouringparticle information for the calculation of the par-ticle forces. The second pass was required so as tocompute adhesion. This includes activation and de-activation of adhesion status, based on the relativeposition between two particles.

Once a neighbouring particle has been identified,the distance to that particle is computed and if lessthan the smoothing length, the value for the viscousand pressure smoothing function can be calculated. Ifthe distance between the two particles is closer thanan adhesion threshold (A), the adhesion computationis activated.

Step 6. Integrate force to output newposition

The force on the particles can now be calculated using(3). The forces acting on those particles represent-ing the tool were summed up and sent to the hapticdevices. The resultant forces of the filling materialparticles were then used in the Euler integration toupdate all their velocity and position. An updatedposition received from the haptic interface is usedto update the position of all the tool particles viatheir fixed homogeneous transform. To ensure cav-ity boundary and fill material stiffness is modulatedcorrectly the particles associated with the tool andboundaries should be evenly spaced.

Page 8: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

−0.4 −0.3 −0.2 −0.1 0 0.1 0.2 0.3 0.4 0.5 0.6−2

−1

0

1

2

3

4

5

6x 10

4

Particle Distance

Part

icle

fo

rce p

rod

uced

by S

PH

5. Relaxation

1. No contact

3. Adhesion activated

6. Particle pulling apart, Force dominated byadhesion

7. Decay force by adhesion

4. Dominated by pressure force

3, 421 5 6 7

2. Initial contact

Figure 2: Interaction between two particles, fromnon-adhesive state to adhesion state separation

3.4 Explanation of SPH interactionforce

Fig. 1 shows the forces produced by the adhesion andpressure smoothing function as well as the blendingforces between when combined 3. Fig. 2 demonstrates7 key stages of particle interaction. When the par-ticles are not in contact (1), no adhesion or pres-sure force arises. During initial contact, only pres-sure force is produced (2). When the particle passesthe predefined adhesion threshold, adhesion activates(3). As the particles get closer together, pressureforce dominates (4). The tool particle is then re-laxed (5) and blending force occurs. As two particlesseparates, adhesion force occurs (6) and got strongerbefore decay (7).

4 Implementation

Two GPUs were used in this research, the first GPU(a Nvidia GTX560) was responsible for graphical ren-dering output, the second GPU (a Nvidia GTX580)was solely responsible for filling material interaction,which included all the computation of the haptic ren-dering forces and all the inter particle force calcula-

3The smoothing function are symmetrical, only half of thesmoothing function are shown for presentation purposes.

tions. This computational architecture reduced thework load on the CPU to being primarily a methodto manage the data flow between GPUs, the haptichardware and long term memory storage.

The computer CPU was then managed in threethreads. A haptic interface thread was responsiblefor communicating forces and positions with the de-vices (Novint Falcon 4 or Force Dimension Omega5). A Haptic GPU thread managed the stability ofthe SPH calculation and the CUDA kernel calls. Al-though the SPH calculation was done entirely on theGPU (GTX580), the calling of the GPU function hadto be done by CPU. This thread was also responsi-ble for copying memory data between the GPU andCPU. The particle positions were then passed on toa graphic rendering thread for display via the secondGPU (GTX560).

5 Result

In order to approximate the algorithm performanceaccurately the particle were setup so that each par-ticle has to naturally collide with as many particlesas possible. These results are shown in Fig. 3. Theresults show that on the test hardware, loop times of400 to 600 hertz are possible.

5.1 Dental Filling Simulation

A desktop based dental filling simulation was devel-oped, shown in Fig. 4. The tooth triangle mesh modelwas generated via high resolution CT scan. A totalof 3000 particles were used, about 1400 represent-ing the cavity boundary, 42 the tool, and 1600 thefill material. New material dropped into the cavitywhen user requested. The user compacted materiallayer by layer until the cavity was filled. The fillingprocess is illustrated in Fig. 5. A video also showsthe SPH algorithm in operation and a haptic deviceused to simulate the cavity filling process.

4http://www.novint.com/5http://www.forcedimension.com/

Page 9: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

103

104

10−3

10−2

Number of particles

Loop tim

e (

s)

Non−Optimised Configuration 1

Non−Optimised Configuration 2

Optimised Configuration 1

Optimised Configuration 2

Figure 3: Algorithm Performance showing an efficientand inefficient implementation. Configuration 1 usesa GTX 560 for the haptic SPH, configuration 2 usesa GT580 for the haptic SPH.

Figure 4: Haptic dental filling simulation setup. Sim-ulation ran on both the Novint Falcon and the ForceDimension Omega.

6 Discussion

Tooth restoration training using haptics has primar-ily focused on dental drilling and cavity preparation.There are a number of possible reasons for this, in-

Figure 5: Haptic dental filling simulation - compact-ing material layer by layer. The tool is representedby the orange ball of particles and is controlled bythe haptic device. The filling material is shown asblue particles, and the static cavity wall particles areshown in orange.

cluding: the algorithms for rigid body deformationare less computationally expensive than those, forexample, for filling; arguably there is greater man-ual skill and procedural knowledge required in thepreparation of the cavity thus potentially a greaterbenefit to training; and also, drilling is particularlyassociated with dentistry for non-dental professionalsand simulation developers may simply unaware of therole played by different parts of the tooth restorationprocedure. However the quality of the applicationand compaction of the material in the cavity remainsa vital part of tooth restoration. As with any simu-lated procedure, dental students using a haptic fillingtrainer can repeat, practice and perfect their tech-nique.

6.1 Algorithm Performance

The algorithm was implemented using GPU paralleltoolkit. The Parallel Radix Sort requires the numberof GPU threads launched to be the same as the num-ber of grid cells. The numbers of threads launchedfor other operations in section (implementation), areproportional to the number of particles in the sys-

Page 10: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

tem. This makes the algorithm to be adaptable fordifferent GPU platform. The performance remainedstabled at around 450Hz between 3000 to 7000 parti-cles. The regression of the lines gives the exponent ofthe performance result to be about 0.25. Graphicallyrendering of the scene graph was running at 30fps,which is above the acceptable level.

6.2 Haptic Rendering and MaterialRepresentation

The haptic device interfacing thread and the GPUSPH calculation thread ran at 1.5kHz and 447Hz re-spectively. The SPH thread sent forces via commu-nication class object to the haptic interface as soonthese were available. The simulation testing showsthat haptic interaction between the tool, boundaryand the material were stable and the decay propertiesof the smoothing function aided this contact stability.

The material in this SPH simulation was weaklycompressible. When two particles moved toward eachother, the pressure force increased as predicted. How-ever, if the particles continue and overlap completely,no further pressure increase will occur. As the mo-tions carry on, the particle positions swap and willexperience a sudden surge of pressure which can re-sult in instability. This was overcome by the fast SPHcalculation speed and high pressure gain value. Thenew algorithm presented here gives the ability to con-trol adhesion and pressure force independently whichallows greater flexibility in the design of the interac-tion. The blending function of the two forces allowsparticle motions to be continuous. The particle in-teraction path from contact, activation of adhesion toseparation includes a hysteresis effect based on dis-placement to emphasise the adhesion properties ofthe material.

It is important to understand that SPH particlesare interacting with each other via a force field, notthe physical particle contact. In this algorithm, h wasset to the particle radius, making the force field thesame as particle volume. The h can be extended de-pending on the application. Consideration in graph-ical rendering is needed to ensure the surface of theparticle volume is represented correctly. Therefore,the users do not interact the surface particle force

field without surface contact.

6.2.1 Representation of Filling Material,Cavity and Tool Using SPH

The associated video shows that SPH is suitable forrepresenting dental filling material. The forces due topressure, adhesion and viscous force can be simulatedas a visco-plastic fluid that emulates the behaviour ofthe filling material and allows simulation of the hapticinteraction with user.

Particles were used to represent the cavity andtool boundary vertices. The location of these ver-tices required careful consideration, even distributionwas preferred. Boundary particles were intention-ally overlapped slightly to prevent the filling particlesleaking through. The particles of the cavity, tool andfilling each had different properties in operation. Incomparison to filling material particles, the pressureparameters associated with the cavity and tool par-ticles were higher, but the adhesion was not present.Therefore, no adhesion occurs when the tool was incontact with the cavity. However, adhesion wouldstill occur between tool/material or cavity/materialinteraction.

Thus far there has been no formal calibration of theparameters in the simulation to any practical dentalmaterial other than via the collective experience ofdental tutors and engineers within the Haptel con-sortium. A further process is needed to determinea set parameters appropriate to teaching the task ofcavity restoration with additional validation neededto ensure that learning via simulation transfers topractice. Likewise there has been no effort to presentthe haptic simulation in a visually appropriate wayand methods such as those described by[12] shouldbe used to present a better visual form.

7 Conclusion

This paper discusses haptic rendering in dental fill-ing. This is an aspect of the tooth restoration train-ing that had not been explored in the field of haptic.Smoothed particle hydrodynamics was selected as themodelling method and this work demonstrated that

Page 11: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

smoothed particle hydrodynamics is an appropriatemethod for representing filling materials in haptic in-teraction. Physical properties such as pressure, vis-cosity and gravity forces were included in the model.A novel adhesion/cohesion model was developed toextend the traditional smoothed particle hydrody-namics framework to simulate the mechanical con-nection between material particles. The results showthat the algorithm can simulate the properties of fill-ing material and has the flexibility to model other softmatter. Parallel programming using multiple GPUswas employed as the computational platform in orderto achieve real-time stable haptic rendering. In thiscase 3000 particles were rendered at about 447 Hz forhaptic display.

Although focused on dental filling the techniquesdiscussed in this paper should allow rendering ofother material interactions. It may be possible toextend the method to include the hardening processof the material to be achieved simply through a pa-rameter change. The use of GPU processing in hap-tic rendering is not wide spread, but this hardwareis highly suited to real-time computations over largenumbers of particles and polygons. This along withthe tools, availability and cost make it an attractivesolution, however there is an additional burden toadapt the algorithms to run efficiently on the GPUarchitecture.

Acknowledgements

The Authors are grateful to the ESRC and the ES-PRC for the funding for the HapTEL project. Weare also pleased to acknowledge the support of Mar-garet Cox, Mark Woolford, Jonathan San Diego, andall the HapTEL researchers.

References

[1] G. Cirio, M. Marchal, S. Hillaire, andA. Lecuyer. Six degrees-of-freedom haptic inter-action with fluids. Visualization and ComputerGraphics, IEEE Transactions on, 17(11):1714 –1727, nov. 2011.

[2] Mathieu Desbrun and Marie-paule Gascuel.Smoothed Particles: A new paradigm for ani-mating highly deformable bodies. In In Com-puter Animation and Simulation 96 (Proceedingsof EG Workshop on Animation and Simulation,pages 61–76. Springer-Verlag, 1996.

[3] R. A Gingold and J. J. Monaghan. Smoothedparticle hydrodynamics - Theory and applica-tion to non-spherical stars. Monthly Noticesof the Royal Astronomical Society, 181:375–389,1977.

[4] Simon Green. Particle simulations usingcuda. Technical report, Nvidia.com, July 2012.http://docs.nvidia.com/cuda/samples/5_

Simulations/particles/doc/particles.pdf.

[5] Micky Kelager. Lagrangian fluid dynamics usingsmoothed particle hydrodynamics, 2006.

[6] G. R. Liu and Liu M. B. Smoothed Particle Hy-drodynamics - a meshfree particle method. WorldScientific Publishing Co. Pte. Ltd., 2003.

[7] L. B Lucy. A numerical approach to the testingof the fission hypothesis. Astronomical Journal,82:1013–1024, 1977.

[8] J.J. Monaghan. Notes [on] smoothed particle hy-drodynamics IPAM. Technical report, IPAM In-stitute for Pure & Applied Mathematics, UCLA,March 2005.

[9] Matthias Muller, David Charypar, and MarkusGross. Particle-based fluid simulation for inter-active applications. In Proceedings of the 2003ACM SIGGRAPH/Eurographics symposium onComputer animation, SCA ’03, pages 154–159,Aire-la-Ville, Switzerland, Switzerland, 2003.Eurographics Association.

[10] Brian Tse, William Harwin, Alastair Barrow,Barry Quinn, Jonathan San Diego, and Mar-garet Cox. Design and development of a hapticdental training system: haptel. In Proceedingsof the 2010 international conference on Haptics- generating and perceiving tangible sensations:

Page 12: A smoothed particle hydrodynamics algorithm for …centaur.reading.ac.uk/67693/2/TseWH15_authorFM.pdfA smoothed particle hydrodynamics algorithm for haptic rendering of dental filling

Part II, EuroHaptics’10, pages 101–108, Berlin,Heidelberg, 2010. Springer-Verlag.