-
Notifications
You must be signed in to change notification settings - Fork 6
Connecting an exo skeleton to a human model
Please note that there are two steps in this modeling task, kinematics and kinetics:
First you will have to connect the EXO and the human kinematically. Here you need to make up your mind if you want this connection to be kinematically determined or not.
Determined kinematic: If you go for a kinematically determined solution you will need to add exactly the same amount of constraints between the EXO and the human as the dof in the EXO. So, for example, an EXO with two parts connected by a revolute joint would need exactly 7 constraints to the human for it to work.
Overdetermined kinematic: If you want to capture the sliding between the EXO and the human better, you may want to use an over determined approach. So, add more constraints between EXO and human but have these as soft. Then, the solver will make a compromise between them.
Make sure to have no reactions to be on when you create these drivers (Reaction.Type= {Off})
The following approach can be used to attach an exo to the human. It is important to keep a running model and not to attempt the full solution from the start. So the idea is to start with something that runs, then gradually work towards the human EXO connection wanted, always keeping a model that runs kinematically. The steps below will create a model which makes the EXO follow the human motion in sync, note that this is just the motion and you can control the applied EXO torques as desired.
- Make sure the human model runs kinematically
- Bring the EXO into the model
- Adjust r0 and Axes0 of EXO model to match human position (Note these do not need to be a 100% exact since r0 and Axes0 only serve as the initial guess for the kinematics and nothing else)
- Add drivers to ALL DOF in EXO (use e.g. these objects AnyKinLinear, AnyKinRotational, AnyKinEqSimpleDriver)
- Ensure the model runs kinematically, this model will not have any human EXO connection
- Create measures and drivers between pelvis and equivalent EXO segment (use e.g. these objects AnyKinLinear, AnyKinRotational AnyKinEqSimpleDriver), remove equivalent drivers from previous step, check that model runs. So if you add 6 constraints between EXO and human remove the equivalent 6 drivers added in step 4.
- Remove hip drivers from EXO model and replace them by connection to the human. Ensure the model is running.
- Continue this approach until EXO is driven by human motion, for each change ensure the model is running.
- Remove all reactions from the drivers/constraints added by setting Reaction.Type={Off}; (default is that they are "On"). Forces can be transmitted by contact elements.
It is possible to use overdetermined kinematics to define the connection between the human and the EXO. This can allow a motion between the EXO and the human to occur see Kinematic tutorial .
The process of doing this is the same as for determined kinematics, but there are these differences:
- The constraints in the drivers need to be made not "Hard" but "Soft" e.g.
CType = {Soft, Soft, Soft}
- The solver in the study needs to be changed to use the overdetermined solver.
InitialConditions.SolverType = KinSolOverDeterminate; Kinematics.SolverType = KinSolOverDeterminate;
- More constraints can be added to make it overdetermined, and the solver will then distribute the error between the drivers.
Ideally, it is desirable to record the motion of the human and EXO in a way that allows an independent reconstruction of the kinematics of both. This can allow the study of the relative motion between the human and EXO. However, it is possible that an EXO on the human prevents the placement of markers on anatomical landmarks of the human that are critical for the kinematics of the human. In such a scenario, the kinematics of the human can be difficult to estimate and therefore some assumptions must be made. Depending on the type of EXO, one or more of the following steps could be applied:
- Place sufficient markers on the EXO to capture the complete kinematics of the EXO and define the EXO markers in the MarkerProtocol file.
- As described previously, create drivers between the corresponding segments of the human and EXO.
- The constraints in these drivers should normally be soft. This would allow benefitting from the measured motion of the human when possible and in combination use soft drivers between human and EXO to compensate for the limited markers on the human.
- In some cases, hard constraints can be useful. For example, in a lower extremity EXO that prevents the application of markers on the knee, it could be useful to add a hard constraint ensuring alignment of the knee axis with the corresponding joint of the EXO.
- Please note that hard constraints do not allow relative motion between human and EXO. If hard constraints are added, please ensure that the model is not over-constrained.
A more advanced approach maybe possible if a reference trial can be recorded with enough markers to completely determine the kinematics of the human and EXO independently. This trial can then be used to identify parameters that will in turn drive soft drivers between human and EXO. The concept is exactly the same as in Parameter Identification of the AnyMocap Framework. The idea is to identify a known reference node on the EXO and define roughly a corresponding coincident node on the human segment by using AnyDesVar. Then, define a soft driver between these two nodes and set position to zero. The parameter identification study will optimize the AnyDesVar and consequently the position of the reference node on the human to be as close as possible to the corresponding EXO node. The steps to be followed are:
- Define a known reference node on the EXO, whose kinematics can be solved in all the trials using the marker data of the EXO.
- Define up to six variables per node (3 positions and 3 rotations) to include in the parameter identification study. Each variable must be defined individually using AnyDesVar, specifying an initial guess value and minimum and maximum values of the variable.
- Use these AnyDesVar from step 2 to define an AnyRefNode on the human segment that should be coincident to the known reference node on the EXO. Use relations such as
sRel = {0+DesVar0, 0+DesVar1, 0+DesVar2};
andARel = {{1,0,0},{0,1,0},{0,0,1}} * RotMat(DesVar3,x) * RotMat(DesVar4,y) * RotMat(DesVar5,z) ;
to define the node on the human segment. - Define an AnyKinEqSimpleDriver between the corresponding nodes on the EXO and human using AnyKinLinear and AnyKinRotational and drive these to zero position and velocity. Set
CType = {Soft,Soft,Soft,Soft,Soft,Soft};
andReaction.Type = {Off,Off,Off,Off,Off,Off};
so that the driver does not provide force. - Add a reference to the AnyDesVar(s) from step 2 in the parameter identification study of the mocap model (typically, Main.Studies.ParameterIdentification). Also, ensure that the reference to the folder containing the EXO model and the driver defined in step 4 is included in the “KinematicStudyForParameterIdentification” of the Parameter Identification study.
- Run the operation “RunParameterIdentification” to run the parameter optimization study and save the parameters. These parameters will be subsequently loaded every time before kinematic analysis.
Here you need to ensure forces are transmitted correctly
First you will need to supply a torque to the EXO. This can be supplied using e.g. AnyForce object applied on the EXO joint. You can create interpolation functions to represent any torque angle relation (AnyFunInterPol), this is a passive model.
Alternatively to adding an elastic passive force like above, you can also apply an optimal force/torque, this can be done by the use of an AnyReacForce object on the DOF in the EXO you would like to carry the loads. This will essentially create an optimal force with no cost in the muscle recruitment, you can see this an as optimal controlled engine. It will not change motion but carry all loads on the specific DOF. By examining the output from this object (Force/moment) and the motion in the DOF it was added on, you can get an idea on how if a passive spring can be created to do the same. See this webcast.
After having supplied the torque to the EXO contact between the EXO and the human need to be created.
Note than in AnyBody you can choose to separate reactions from your kinematic constraints, here we use the conditional contact elements to create the interface forces, and it is possible to have more contact forces than you have kinematic constraints, the reactions in the drivers has been disabled in previous step.
The best approach is to create conditional contact elements between the human and the exo, the best place to look for how this is done is in the SeatedHuman model in the file "Support.any" file. There is also a wiki entry on the subject please see Wiki on contact muscles
Instead of having rigid kinematic connections between the EXO and the human, you can also use force dependent motion (FDK) Tutorial on Force Dependent Motion to calculate the motion between EXO and human and the loads being transferred. This is a more advanced approach and it also a computationally more expensive than the approach outlined above, so it should only be used if the small motion between EXO and human is of particular interest and by experienced users since FDK adds significantly model complexity. It requires the combined stiffness of EXO/Human in contact areas to be estimated and applied in the model. Using this approach for all DOF between EXO and human removes the need for conditional contact muscles, the contact forces will eventually all be replaced by spring forces.
The steps 1-8 are the same as above but with additional steps towards the end so start with a kinematically determined model and make this run before trying to add FDK.
- Make sure the human model runs kinematically
- Bring the EXO into the model
- Adjust r0 and Axes0 of EXO model to match human position (Note these do not need to be a 100% exact since r0 and Axes0 only serve as the initial guess for the kinematics nothing else)
- Add drivers to ALL DOF in EXO (use e.g. these objects AnyKinLinear, AnyKinRotational, AnyKinEqSimpleDriver)
- Ensure the model runs kinematically, this model will not have any human EXO connection
- Create measures and drivers between pelvis and equivalent EXO segment (use e.g. these objects AnyKinLinear, AnyKinRotational AnyKinEqSimpleDriver), remove equivalent drivers from previous step, check that model runs. So if you add 6 constraints between EXO and human remove the equivalent 6 drivers added in step 4.
- Remove hip drivers from EXO model and replace them by connection to the human. Ensure the model is running.
- Continue this approach until EXO is driven by human motion, for each change ensure the model is running.
- Determine how many of the 7 DOF you would like to have determined by FDK, it does not need to be all of them.
- For the selected DOF change the Constraint.Type in the drivers from step 6 and 8 from "Hard" to "ForceDep"
- Create kinematic measures between EXO and Human in the EXO/human contact areas (AnyKinLinear) and supply AnyForce objects representing combined stiffness of EXO and human soft tissue in this region. This will essentially be springs in the model.
- In the AnyBodyStudy remember to set the ForceDepKinOnOff to "On", in the InverseDynamic folder, default is "Off".
- Introduce the ForceDep gradually,this will make it easier to understand and debug.