最近学习机器学习 才发现以前数学没有学好 开始从线性代数开始学起 读完行列式一章写了些C#的代码学习一下. 直接上C#代码: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Runtime.InteropServices; using System.IO; namespace LYF.Math { /// <summary> /// 行列式 De…
<3D Math Primer for Graphics and Game Development>读书笔记2 上一篇得到了"矩阵等价于变换后的基向量"这一结论. 本篇只涉及两章,但容量已足够喝一壶了. 第8章 矩阵和线性变换 变换物体和变换坐标系是等价的,将物体变换一个量等价于将坐标系变换一个相反的量. 旋转rotation 2D中的旋转只有一个参数:角度θ,逆时针经常被认为是正方向. 在3D场景中,绕轴旋转而不是点.绕轴旋转θ°时,必须知道哪个方向被认为是正方向.在左手…
最近几天学习高等代数老师说要写个程序算行列式的结果,闲来无事就简单写了一下. 不多说了,上代码 using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Nrow_culmn { class Program { //计算行列式 计算复杂度为O(n的3次方) ; static void Main(string[] args) { //double[,] row_cu…
1.数学定义 n阶行列式定义如下: 2.算法实现 函数名: GetValue() 功能:返回一个行列式的值 Private Function GetValue() Dim gValue As Double Dim tempResultList As New List(Of Array) ) As Integer '要进行全排列的序列 tempNumArray(i) = i Next GetFullPerm(tempNumArray, , tempResultList) Dim temp As…
//Matrix ver1.0 //只支持矩阵内部(方阵)的运算 #include<iostream> #include<math.h> using namespace std; class matrix { double**num; int **e;//单位矩阵 int r; int c; unsigned int *array;//为全排序原矩阵列标提供初始顺序模板 unsigned int*arr;//为全排序伴随矩阵列标提供初始顺序模板 int**b;//存放原矩阵列标 i…