Comments (5)
Hi @AaronRapopot,
Yes, for this aim you can add EndpointForces on the rod. Just use the tangent argument of the rod to define the force direction. You need to make the force direction equal to the tangent of the last element.
from pyelastica.
Hi @ilianasiriziba
The direction of the Endpointforce should change continuously as the rod bending. Can I obtain the tangential direction of the rod's endpoint in real-time through a callback?Perhaps it needs to be calculated step by step?
For example:
for step in range(initial_step, final_step + 1):
tangent_direction = get_tangent_direction(step - 1) #Get the position information from the previous step through a callback
force_vector = tangent_direction * endpointforce
apply_force_to_rod(force_vector)
Not actual code, just to explain the logic. Thanks for your help!
from pyelastica.
Hi @AaronRapopot,
If you make the force direction equal to rod_name.tangents of the last element it will be updated step by step.
from pyelastica.
@AaronRapopot Has your issue been resolved? Please let us know, or else we shall close this issue due the inactivity in a few days.
from pyelastica.
@ilianasiriziba and @armantekinalp closing this issue due to inactivity, as mentioned above. Feel free to open if deemed necessary.
from pyelastica.
Related Issues (20)
- Reproducing snake diffraction results from your Nat Comm Paper HOT 7
- Failure for Helix under Gravity Case HOT 2
- Can PyElastica support GPU acceleration? HOT 3
- Do PyElastica support to simulate a rod containing two segments? HOT 3
- Question about base length HOT 8
- Replicating side-winding results from your Nat-comm snake paper HOT 29
- Instant controler and simulation HOT 6
- Small scale rod simulation HOT 11
- Updating muscle forces mid-simulation - how does it work? HOT 1
- Small-scale simulation problem 2 HOT 1
- OneEndFixedBC didn't work for applying a external torque HOT 4
- How to using PyElastica data to visualize in 3D models? HOT 1
- `FileNotFoundError` `python continuum_snake.py` HOT 1
- Bug and fix in 2_Slithering_Snake.ipynb HOT 1
- Task 1: Utilizing Python to clean and convert data from Elastica into a format recognizable by Blender. HOT 1
- Avoid having randomized unittest HOT 17
- [GSOC project 3] Binding PyElastica with Elastica++ HOT 1
- GSoC interest in Optimizing backend kernels in PyElastica HOT 1
- Examples not running due to modules not being found HOT 18
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyelastica.