I have a set of nonlinear equations (run by rk4 method). How can I compute the Jacobian for those?
조회 수: 4 (최근 30일)
이전 댓글 표시
The nonlinear equations give attitude quaternion and angular velocity of small satellite.
How may I compute the Jacobian matrices to use in a Kalman filter?
채택된 답변
Benjamin Großmann
2020년 2월 26일
Assume you have the set of nonlinear eqations
and the vector of independent variables defined in Matlab, then you can use the jacobian function to compute the jacobian matrices, e.g.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/273812/image.png)
clearvars, close all
clc
% the variables
x = sym('x',[3,1]);
% some random functions
f = [x(1)^2 + x(2); ...
sin(x(3)); ...
cos(x(1) + x(2))];
% jacobian calculation
J = jacobian(f,x);
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Reference Applications에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!