Search found 37 matches

by Mary K
Wed May 10, 2017 11:37 am
Forum: Simbody: SimTK multibody dynamics API
Topic: Assertion failed in MultibodySystemRep.h
Replies: 0
Views: 191

Assertion failed in MultibodySystemRep.h

Hello, I am trying to visualize some contact forces and I follow the ExampleContactPlayground.cpp. In my case I try to assign my model's multibody system to appropriate classes but it fails. Here is what I am doing: ... SimTK::State& si = model.initSystem(); ... MultibodySystem& system = model.updMu...
by Mary K
Sun Mar 19, 2017 4:43 am
Forum: OpenSim
Topic: Add prescribed force - reference axis
Replies: 3
Views: 531

Re: Add prescribed force - reference axis

Tom, thanks for your response. I followed your advices and I simulated a simple senario with a ground and a block with different local axis and no gravity. I think I understood how the force is applied by observing the movement of the block. But still cannot visualize the force arrow properly, in th...
by Mary K
Wed Mar 15, 2017 4:44 am
Forum: OpenSim
Topic: Add prescribed force - reference axis
Replies: 3
Views: 531

Add prescribed force - reference axis

Hello, I want to add an external force to a body with these settings: The point of application should be in body frame, so that when the body moves, the force to 'follow' it. But the direction of the force should be constant in x-direction of global frame. Can someone help me how to do that using th...
by Mary K
Tue Dec 20, 2016 10:57 am
Forum: OpenSim
Topic: Access violation adding Controller
Replies: 6
Views: 764

Re: Access violation adding Controller

I finally solved this by creating the Controller with a pointer to the object and also creating different instances of Control Functions before assing them to the controller. Like this: // set controller PrescribedController* controller = new PrescribedController(); controller->setName( "flexion_con...
by Mary K
Tue Dec 20, 2016 3:39 am
Forum: OpenSim
Topic: Access violation adding Controller
Replies: 6
Views: 764

Re: Access violation adding Controller

I seem to solve this issue by adding a control function (even a zero-function) to the whole actuator set that was given to controller. Like this: Constant* ccf = new Constant(1); string muscle_name; for (int i=0; i<model.getActuators().getSize(); i++) { muscle_name = model.getActuators().get(i).getN...
by Mary K
Sun Dec 18, 2016 4:55 am
Forum: OpenSim
Topic: Access violation adding Controller
Replies: 6
Views: 764

Re: Access violation adding Controller

I did it like the example and still the same exception :| // set controller PrescribedController controller; controller.setName( "my_controller"); controller.setActuators( model.updActuators()); controller.prescribeControlForActuator( 0, new Constant( 100)); controller.setDisabled(false); model.addC...
by Mary K
Sat Dec 17, 2016 12:38 pm
Forum: OpenSim
Topic: Access violation adding Controller
Replies: 6
Views: 764

Access violation adding Controller

Hello, I am creating my first Controller to my model before doing a Forward Simulation like this: OpenSim::Model model("../mymodel.osim"); PrescribedController* controller = new PrescribedController(); controller->setName( "my_controller"); controller->setActuators( model.getActuators()); double con...
by Mary K
Tue Oct 11, 2016 8:01 am
Forum: OpenSim
Topic: Elastic Foundation Force properties
Replies: 3
Views: 611

Re: Elastic Foundation Force properties

Hi Dimitar, thanks for your reply, it was helpful. But I did not formulate my question properly. My question is, how to validate Elastic Foundation Force property values. Because in bibliography I can find only some of the properties or I find approximate values. Is something you validate with simul...
by Mary K
Sun Oct 09, 2016 1:03 pm
Forum: OpenSim
Topic: Elastic Foundation Force properties
Replies: 3
Views: 611

Elastic Foundation Force properties

Hello there, I have added contact meshes to my lower limb .osim model. And now I want to add contact forces on them. (On femur and meniscii). I figured out that Elastic Foundation Force is what OpenSim provides for this situation. But how can I define the properties (stiffness, dissipation, static f...
by Mary K
Sat Jun 04, 2016 7:49 am
Forum: OpenSim
Topic: segmentation fault while Storage::getData after SO
Replies: 1
Views: 179

segmentation fault while Storage::getData after SO

Hello, after implementing Static Optimization and trying to store activations to a vector, I get "Segmentation fault". Here is the loop where I get this error: vector<Vector> acts; // activations Storage *as = so.getActivationStorage(); int na = model.getActuators().getSize(); acts.resize(states.get...