CoordinateConstraint

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Julie Iskander
Posts: 11
Joined: Thu Mar 10, 2016 9:25 pm

CoordinateConstraint

Post by Julie Iskander » Tue Sep 27, 2016 1:05 am

I need a coordinate constraint that takes 2 independent coordinates to calculate the dependent coordinate.

I created a Function class that inherets OpenSim::Function that takes 2 values and returns the calculated value.
But I couldn't create a class that works like the CoordinateCouplerConstraint but works with two coordinates.

Is this possible?

Whatever I tried, the model seemed to only use one coordinate value, the first one only!!!!

I hope someone can help me ASAP.

User avatar
Dimitar Stanev
Posts: 1096
Joined: Fri Jan 31, 2014 5:14 am

Re: CoordinateConstraint

Post by Dimitar Stanev » Tue Sep 27, 2016 9:58 am

Hi,

The problem is this line:

https://github.com/opensim-org/opensim- ... t.cpp#L227

and the internal implementation of CompoundFunction, which considers only a single variable dependency, despite the fact that you register multiple variables in the properties. Please report this as a bug

https://github.com/opensim-org/opensim-core/issues

and discuss possible solutions. Also, you can try to re-implement CoordinateCouplerConstraint with different name and change the CompoundFunction.

Best

User avatar
Julie Iskander
Posts: 11
Joined: Thu Mar 10, 2016 9:25 pm

Re: CoordinateConstraint

Post by Julie Iskander » Tue Sep 27, 2016 5:25 pm

Thanks a lot for your answer.

I have already created classes to inherit these and tried to change this issue but the problem is beyond that.
Can you point me to the class that sends the coordinate values to the CompoundFunction class???

Thanks again


POST REPLY