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
2 changes: 1 addition & 1 deletion python3/src/stlib3/communication/UDP_controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def createScene(rootNode):
rootNode.addObject(UDP)

Beam = rootNode.addChild('Beam')
Beam.addObject('EulerImplicitSolver', name="odesolver", rayleighStiffness=0.1, rayleighMass=0.1)
Beam.addObject('EulerImplicitIntegrationScheme', name="odesolver", rayleighStiffness=0.1, rayleighMass=0.1)
Beam.addObject('ShewchukPCGLinearSolver', iterations=1, name="linearsolver", tolerance=1e-5, preconditioners="preconditioner", use_precond=True)
Beam.addObject('RegularGridTopology', name="SoftBeam", nx=5, ny=2, nz=2, min=[-0.050, -0.010, -0.002], max=[0.050, 0.010, 0.0025])
Beam.addObject('MechanicalObject', name="meca", template="Vec3")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def init(self):
# Sofa.msg_info("Missing RequiredPlugin SofaSparseSolver in the scene, add it from Prefab ElasticMaterialObject.")

if self.solverName.value == '':
self.integration = self.addObject('EulerImplicitSolver', name='integration')
self.integration = self.addObject('EulerImplicitIntegrationScheme', name='integration')
self.solver = self.addObject('SparseLDLSolver', name="solver", template='CompressedRowSparseMatrixd')
# Eulalie: 01/21 a bit hard to debug... when uncommented, no warning or error shows up, yet all components won't just be created...
# self.solverName = 'solver'
Expand Down
2 changes: 1 addition & 1 deletion python3/src/stlib3/physics/mixedmaterial/rigidification.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ def createScene(rootNode):
o.RigidParts.addObject("FixedConstraint", indices=0)

simulationNode = rootNode.addChild("Simulation")
simulationNode.addObject("EulerImplicitSolver")
simulationNode.addObject("EulerImplicitIntegrationScheme")
simulationNode.addObject("CGLinearSolver", iterations=25, tolerance=1e-5, threshold=1e-5)
simulationNode.addChild(o)
return rootNode
2 changes: 1 addition & 1 deletion python3/src/stlib3/physics/rigid/RigidObject.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def RigidObject(name="RigidObject",


if not isAStaticObject:
object.addObject('EulerImplicitSolver')
object.addObject('EulerImplicitIntegrationScheme')
object.addObject('CGLinearSolver', iterations=25, tolerance=1e-5, threshold=1e-5)

def addCollisionModel(inputMesh=surfaceMeshFileName):
Expand Down
2 changes: 1 addition & 1 deletion python3/src/stlib3/scene/interaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class Interaction(object):

def __init__(self, parent, targets):
self.node = parent.addChild("Interaction")
self.node.addObject("EulerImplicitSolver")
self.node.addObject("EulerImplicitIntegrationScheme")
self.node.addObject("CGLinearSolver", iterations=25, tolerance=1e-5, threshold=1e-5)
for target in targets:
self.node.addChild(target)
6 changes: 3 additions & 3 deletions python3/src/stlib3/scene/scene.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ def addMainHeader(plugins=plugins, repositoryPaths=repositoryPaths, doDebug=Fals
if "SofaPython3" not in plugins:
plugins.append("SofaPython3")

if "Sofa.Component.ODESolver.Backward":
plugins.append("Sofa.Component.ODESolver.Backward")
if "Sofa.Component.IntegrationSchemes.Backward":
plugins.append("Sofa.Component.IntegrationSchemes.Backward")

if doDebug:
from splib3.debug import DebugManager
Expand All @@ -62,7 +62,7 @@ def addMainHeader(plugins=plugins, repositoryPaths=repositoryPaths, doDebug=Fals
addSimulation()

def addDefaultSolver(node):
node.addObject('EulerImplicitSolver', name='TimeIntegrationSchema')
node.addObject('EulerImplicitIntegrationScheme', name='TimeIntegrationSchema')
if iterative:
node.addObject('CGLinearSolver', name='LinearSolver', iterations=25, tolerance=1e-5, threshold=1e-5)
else:
Expand Down
4 changes: 2 additions & 2 deletions python3/src/stlib3/solver/defaultsolver.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ def DefaultSolver(node, iterative=True):
Adds EulerImplicit, CGLinearSolver

Components added:
EulerImplicitSolver
EulerImplicitIntegrationScheme
CGLinearSolver
'''
node.addObject('EulerImplicitSolver', name='TimeIntegrationSchema')
node.addObject('EulerImplicitIntegrationScheme', name='TimeIntegrationSchema')
if iterative:
return node.addObject('CGLinearSolver', name='LinearSolver', iterations=25, tolerance=1e-5, threshold=1e-5)

Expand Down
Loading