Home > General-Functions > SUGR > Point_2D > sugr_ghm_cg_Point_2D_from_Lines.m

sugr_ghm_cg_Point_2D_from_Lines

PURPOSE ^

% Determines residuals etc. for 2D point from passing lines

SYNOPSIS ^

function [lr,Cr,cg,atr,btr] = sugr_ghm_cg_Point_2D_from_Lines(l,le,xe,C)

DESCRIPTION ^

% Determines residuals etc. for 2D point from passing lines 
 
 [lr,Crrt,cg,atr,btr] = sugr_ghm_cg_Point_2D_from_Lines(l,le,xe,Crro)

 in spherical mode with minimal representation

 * l   = 3 x 1 vector, observed line
 * le  = 3 x 1 vector, approximated fitted line
 * xe  = 3 x 1 vector, approximated point
 * Crro = 2 x 2 matrix, reduced covariance matrix of observations

 * lr  = 2 x 1 vector, reduced observation
 * Crrt = 2 x 2 matrix, reduced covariance matrix of transformed observations
 * cg  = scalar, residual of constraint
 * atr  = 1 x 2 vector, transposed Jacobian for xe
 * btr  = 1 x 2 vector, transposed jacobian for le

 Wolfgang Förstner 09/2010, adapted for sugr 1/2011
 wfoerstn@uni-bonn.de

 See also sugr_Point_2D, sugr_Line_2D,  sugr_estimation_ml_Point_2D_from_Lines

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 %% Determines residuals etc. for 2D point from passing lines
0002 %
0003 % [lr,Crrt,cg,atr,btr] = sugr_ghm_cg_Point_2D_from_Lines(l,le,xe,Crro)
0004 %
0005 % in spherical mode with minimal representation
0006 %
0007 % * l   = 3 x 1 vector, observed line
0008 % * le  = 3 x 1 vector, approximated fitted line
0009 % * xe  = 3 x 1 vector, approximated point
0010 % * Crro = 2 x 2 matrix, reduced covariance matrix of observations
0011 %
0012 % * lr  = 2 x 1 vector, reduced observation
0013 % * Crrt = 2 x 2 matrix, reduced covariance matrix of transformed observations
0014 % * cg  = scalar, residual of constraint
0015 % * atr  = 1 x 2 vector, transposed Jacobian for xe
0016 % * btr  = 1 x 2 vector, transposed jacobian for le
0017 %
0018 % Wolfgang Förstner 09/2010, adapted for sugr 1/2011
0019 % wfoerstn@uni-bonn.de
0020 %
0021 % See also sugr_Point_2D, sugr_Line_2D,  sugr_estimation_ml_Point_2D_from_Lines
0022 
0023 
0024 function [lr,Cr,cg,atr,btr] = sugr_ghm_cg_Point_2D_from_Lines(l,le,xe,C)
0025 
0026 % Jacobian for observation
0027 Jle = null(le');
0028 
0029 % reduced observation
0030 lr  = Jle' * l;
0031 
0032 % Rotation from l to le
0033 R = calc_Rot_ab(le,l);
0034 
0035 % Jacobian for Cr
0036 JR = Jle' * R' * null(l');
0037 
0038 % reduced covariance matrix
0039 Cr = JR * C * JR';
0040 
0041 % Jacobian for x
0042 atr = le' *  null(xe'); % row 2-vector
0043 
0044 % Jacobain for l
0045 btr = xe' * Jle; % row 2-vector
0046  
0047 % residual of constraint
0048 %cg = - l' * xe ; % scalar
0049 cg = - le' * xe - btr * lr; 
0050

Generated on Sat 21-Jul-2018 20:56:10 by m2html © 2005