SimVascular / SimVascular/svMultiPhysics
Spatial bounds on electrophysiology applied stimulus
@samibismar is already working on this.
Since Jun 29, 2026.
- Dominant language
- C++
- Stars
- 45
- Forks
- 61
- Avg merge
- 5d 23h
- Merged PRs (30d)
- 11
Description
Problem
Currently, when a stimulus current is applied, it is applied to the whole domain that contains it. This implies that changing the position, size or shape of the stimulus requires regenerating the domain labels, which might be cumbersome if this needs to be done repeatedly.
Solution
Add sub-tags to the <Stimulus> XML tag to constrain it within a certain subregion of the domain. Some examples might be:
- axis-aligned bounding box (only apply the stimulus if the point coordinates fall within user-defined minimum and maximum values);
- spherical stimulus (only apply the stimulus if the point falls within a sphere of user-defined center and radius).
This way the stimulus placement, size and shape will be changed by editing the XML file only. Adding other shapes as needed should be rather straightforward.
Additional context
- The choice of adding the spatial bounds within the domain is driven mostly by backwards compatibility. In principle, the stimulus could be entirely domain-independent, but I guess this might break some existing parameter files.
- It would also be nice to have this new structure support multiple stimuli in the same domain.
- I've asked Sami Bismar (@samibismar) to work on this as a first issue in
svMultiPhysics. Sami is collaborating with our group over the summer.
Code of Conduct
- I agree to follow this project's Code of Conduct and Contributing Guidelines
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.