Changeset dcfab7d in OpenModelica


Ignore:
Timestamp:
2016-04-06T13:21:35+02:00 (8 years ago)
Author:
Adeel Asghar <adeel.asghar@…>
Branches:
Added-citation-metadata, maintenance/v1.14, maintenance/v1.15, maintenance/v1.16, maintenance/v1.17, maintenance/v1.18, maintenance/v1.19, maintenance/v1.20, maintenance/v1.21, maintenance/v1.22, maintenance/v1.23, master, omlib-staging
Children:
c3b216c
Parents:
e3d9697 (diff), f06d1664 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge pull request #21 from robbr48/master

Fixed wrong index in rotation vector function.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • OMEdit/OMEditGUI/Editors/MetaModelEditor.cpp

    rd8c46e3 rf06d1664  
    541541    double phi[3];
    542542    phi[1] = (fabs(a13) < DBL_MIN)? 0.0 : asin((a13<-1.0) ? 1.0 : ((a13>1.0) ? -1.0 : -a13));
    543     double tmp = cos(phi[2]);
    544     double cosphi2 = tmp+sign(tmp)*1.0e-50;
    545 
    546     phi[0] = atan2(a23/cosphi2, a33/cosphi2);
    547     phi[2] = atan2(a12/cosphi2, a11/cosphi2);
     543    double tmp = cos(phi[1]);
     544    double cosphi1 = tmp+sign(tmp)*1.0e-50;
     545
     546    phi[0] = atan2(a23/cosphi1, a33/cosphi1);
     547    phi[2] = atan2(a12/cosphi1, a11/cosphi1);
    548548
    549549    return QGenericMatrix<3,1,double>(phi);
Note: See TracChangeset for help on using the changeset viewer.