Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def createScene(rootNode):
bunny.addObject('UniformMass', totalMass=0.5)
bunny.addObject('TetrahedronFEMForceField', poissonRatio=0.3, youngModulus=18000)
bunny.addObject('BoxROI', name='boxROI', box=[-5, -6, -5, 5, -4.5, 5], drawBoxes=True)
bunny.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12)
bunny.addObject('FixedWeakConstraint', indices='@boxROI.indices', stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/constraints
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def createScene(rootNode):
finger.addObject('UniformMass', totalMass=0.075)
finger.addObject('TetrahedronFEMForceField', poissonRatio=0.3, youngModulus=600)
finger.addObject('BoxROI', name='ROI1', box=[-15, 0, 0, 5, 10, 15], drawBoxes=True)
finger.addObject('RestShapeSpringsForceField', points='@ROI1.indices', stiffness=1e12)
finger.addObject('FixedWeakConstraint', indices='@ROI1.indices', stiffness=1e12)
finger.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def createScene(rootNode):
model.addObject('TetrahedronFEMForceField', poissonRatio=0.3, youngModulus=200)
model.addObject('BoxROI', name='boxROI', box=[-5, 0, -20, 0, 30, 20], drawBoxes=True)
model.addObject('BoxROI', name='boxROISubTopo', box=[-175, 22.5, -8, -19, 28, 8], drawBoxes=False)
model.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e12)
model.addObject('FixedWeakConstraint', indices='@boxROI.indices', stiffness=1e12)
model.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def createScene(rootNode):
model.addObject('UniformMass', totalMass=0.1)
model.addObject('TetrahedronFEMForceField', poissonRatio=Const.PoissonRation, youngModulus=Const.YoungsModulus)
model.addObject('BoxROI', name='BoxROI1', box=Const.FixedBoxCoordsBack, drawBoxes=True)
model.addObject('RestShapeSpringsForceField', points='@BoxROI1.indices', stiffness=1e12)
model.addObject('FixedWeakConstraint', indices='@BoxROI1.indices', stiffness=1e12)
model.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def createScene(rootNode):
model.addObject('UniformMass', totalMass=0.1)
model.addObject('TetrahedronFEMForceField', poissonRatio=0.3, youngModulus=150)
model.addObject('BoxROI', name='boxROI', box=[-10, -15, 50, 10, 15, 90], drawBoxes=True)
model.addObject('RestShapeSpringsForceField', points='@boxROI.indices', stiffness=1e2)
model.addObject('FixedWeakConstraint', indices='@boxROI.indices', stiffness=1e2)
model.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def createScene(rootNode):
# Ex: if SlidingActuator simulates a single dof (e.g. translation along x),
# the other dofs must be fixed using this component
model.addObject('PartialFixedProjectiveConstraint', indices=0, fixedDirections=[0, 1, 1, 1, 1, 0])
model.addObject('RestShapeSpringsForceField', points=0, angularStiffness=1000, stiffness=1000)
model.addObject('FixedWeakConstraint', indices=0, angularStiffness=1000, stiffness=1000)

##########################################
# Actuator #
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def createScene(rootNode):
tetrahedra=model.container.tetrahedra.linkpath)
model.addObject('BoxROI', name='boxROISubTopo', box=[-175, 22.5, -8, -19, 28, 8], drawBoxes=False,
position="@tetras.rest_position", tetrahedra=model.container.tetrahedra.linkpath)
model.addObject('RestShapeSpringsForceField', points=model.boxROI.indices.linkpath, stiffness=1e12)
model.addObject('FixedWeakConstraint', indices=model.boxROI.indices.linkpath, stiffness=1e12)
model.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def createScene(rootNode):
bunny.addObject('UniformMass', totalMass=0.5)
bunny.addObject('TetrahedronFEMForceField', template='Vec3', poissonRatio=0.3, youngModulus=18000)
bunny.addObject('BoxROI', name='boxROI', box=[-5, -6, -5, 5, -4.5, 5], drawBoxes=True)
bunny.addObject('RestShapeSpringsForceField', points=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('FixedWeakConstraint', indices=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/effector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def createScene(rootNode):
bunny.addObject('UniformMass', totalMass=0.5)
bunny.addObject('TetrahedronFEMForceField', template='Vec3', poissonRatio=0.3, youngModulus=18000)
bunny.addObject('BoxROI', name='boxROI', box=[-5, -6, -5, 5, -4.5, 5], drawBoxes=True)
bunny.addObject('RestShapeSpringsForceField', points=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('FixedWeakConstraint', indices=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/effector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def createScene(rootNode):
model.addObject('TetrahedronFEMForceField',
poissonRatio=Const.PoissonRation, youngModulus=Const.YoungsModulus)
model.addObject('BoxROI', box=Const.FixedBoxCoords, drawBoxes=True)
model.addObject('RestShapeSpringsForceField', points=model.BoxROI.indices.linkpath, stiffness=1e12)
model.addObject('FixedWeakConstraint', indices=model.BoxROI.indices.linkpath, stiffness=1e12)
model.addObject('LinearSolverConstraintCorrection')

##########################################
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def createScene(rootNode):
bunny.addObject('UniformMass', totalMass=0.5)
bunny.addObject('TetrahedronFEMForceField', poissonRatio=0.45, youngModulus=60000)
bunny.addObject('BoxROI', name='boxROI', box=[-5, -5.5, -5, 5, -4.5, 5], drawBoxes=True)
bunny.addObject('RestShapeSpringsForceField', points=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('FixedWeakConstraint', indices=bunny.boxROI.indices.linkpath, stiffness=1e12)
bunny.addObject('LinearSolverConstraintCorrection')

# bunny/effector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def createScene(rootNode):
[-2, 2, -2, 1, 6, 1]], drawBoxes=True)
bunny.addObject('ComplementaryROI', name="outROI", template="Vec3", position="@loader.position", nbSet=1,
setIndices1="@boxROIFixed.indices")
bunny.addObject('RestShapeSpringsForceField', points='@outROI.indices', stiffness=1e12)
bunny.addObject('FixedWeakConstraint', indices='@outROI.indices', stiffness=1e12)
bunny.addObject('BoxROI', name='boxROI1', box=[-4.5, 2, -5, -2.5, 6, -1], drawBoxes=True)
bunny.addObject('BoxROI', name='boxROI2', box=[-2, 2, -2, 1, 6, 1], drawBoxes=True)
bunny.addObject('LinearSolverConstraintCorrection', linearSolver=bunny.SparseLDLSolver.getLinkPath())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<TetrahedronFEMForceField youngModulus="18000" poissonRatio='0.3' method='large'/>

<BoxROI name='ROI1' box='-5 -15 -5 5 -4.5 5' drawBoxes='true'/>
<RestShapeSpringsForceField points='@ROI1.indices' stiffness='1e12'/>
<RestShapeSpringsForceField indices='@ROI1.indices' stiffness='1e12'/>

<LinearSolverConstraintCorrection/>

Expand Down
4 changes: 2 additions & 2 deletions tests/component/solver/scenes/Finger.scn
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
<BoxROI name='ROI1' box='-15 0 0 5 10 15' drawBoxes='true'/>
<BoxROI name='ROI2' box='-15 0 0 5 10 15' drawBoxes='true'/>

<RestShapeSpringsForceField points='@ROI1.indices' stiffness='1e12'/>
<RestShapeSpringsForceField points='@ROI2.indices' stiffness='1e12'/>
<RestShapeSpringsForceField indices='@ROI1.indices' stiffness='1e12'/>
<RestShapeSpringsForceField indices='@ROI2.indices' stiffness='1e12'/>

<LinearSolverConstraintCorrection/>

Expand Down
Loading