Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 89b2f2b1 authored by ALI Olivier's avatar ALI Olivier :monkey_face:
Browse files

Fixed a bit notation.

parent ef1a7bbc
No related branches found
No related tags found
No related merge requests found
Pipeline #239595 failed
...@@ -96,7 +96,7 @@ class BVP(object): ...@@ -96,7 +96,7 @@ class BVP(object):
self._dirichlet_class: list = [] self._dirichlet_class: list = []
self.neumannCondition: dict = {'constant': [], self.neumannCondition: dict = {'constant': [],
'variable': []} 'variable': []}
self.neumann_domain_id: list = {'constant': [], self._neumann_domain_id: list = {'constant': [],
'variable': []} 'variable': []}
self.solver: Union[LinearSolver, NonLinearSolver] = None self.solver: Union[LinearSolver, NonLinearSolver] = None
...@@ -303,11 +303,11 @@ class BVP(object): ...@@ -303,11 +303,11 @@ class BVP(object):
if isinstance(dir_class, (ConstantNeumann)): if isinstance(dir_class, (ConstantNeumann)):
self.neumannCondition['constant'].append(dir_class.apply(self.domain.bdata)) self.neumannCondition['constant'].append(dir_class.apply(self.domain.bdata))
self.neumann_domain_id['constant'].append(dir_class._id) self._neumann_domain_id['constant'].append(dir_class._id)
elif isinstance(dir_class, (VariableNeumann, NormalNeumann)): elif isinstance(dir_class, (VariableNeumann, NormalNeumann)):
self.neumannCondition['variable'].append(dir_class.apply(self.functionSpace, self.neumannCondition['variable'].append(dir_class.apply(self.functionSpace,
self.domain.bdata)) self.domain.bdata))
self.neumann_domain_id['variable'].append(dir_class._id) self._neumann_domain_id['variable'].append(dir_class._id)
def add_boundary_condition(self, bnd_cond, def add_boundary_condition(self, bnd_cond,
method='topological', method='topological',
...@@ -402,11 +402,11 @@ class BVP(object): ...@@ -402,11 +402,11 @@ class BVP(object):
if isinstance(self.vform.rhs, Zero): if isinstance(self.vform.rhs, Zero):
for neumann, domain_id in zip(self.neumannCondition['constant'], for neumann, domain_id in zip(self.neumannCondition['constant'],
self.neumann_domain_id['constant']): self._neumann_domain_id['constant']):
lhs -= fe.dot(neumann, #.apply(self.domain.bdata), lhs -= fe.dot(neumann, #.apply(self.domain.bdata),
self.testFunction)*self.domain.ds(domain_id) self.testFunction)*self.domain.ds(domain_id)
for neumann, domain_id in zip(self.neumannCondition['variable'], for neumann, domain_id in zip(self.neumannCondition['variable'],
self.neumann_domain_id['variable']): self._neumann_domain_id['variable']):
lhs -= fe.dot(neumann, #.apply(self.functionSpace, lhs -= fe.dot(neumann, #.apply(self.functionSpace,
# self.domain.bdata), # self.domain.bdata),
self.testFunction)*self.domain.ds(domain_id) self.testFunction)*self.domain.ds(domain_id)
...@@ -422,11 +422,11 @@ class BVP(object): ...@@ -422,11 +422,11 @@ class BVP(object):
else: else:
for neumann, domain_id in zip(self.neumannCondition['constant'], for neumann, domain_id in zip(self.neumannCondition['constant'],
self.neumann_domain_id['constant']): self._neumann_domain_id['constant']):
rhs += fe.dot(neumann, #.apply(self.domain.bdata), rhs += fe.dot(neumann, #.apply(self.domain.bdata),
self.testFunction)*self.domain.ds(domain_id) self.testFunction)*self.domain.ds(domain_id)
for neumann, domain_id in zip(self.neumannCondition['variable'], for neumann, domain_id in zip(self.neumannCondition['variable'],
self.neumann_domain_id['variable']): self._neumann_domain_id['variable']):
rhs += fe.dot(neumann, #.apply(self.functionSpace, rhs += fe.dot(neumann, #.apply(self.functionSpace,
# self.domain.bdata), # self.domain.bdata),
self.testFunction)*self.domain.ds(domain_id) self.testFunction)*self.domain.ds(domain_id)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment