上一页 1 ··· 7 8 9 10 11 12 13 下一页
摘要: 贝塞尔曲线绘图方法:```%Program 3.7 Freehand Draw Program Using Bezier Splines%Click in Matlab figure window to locate first point, and click% three more times ... 阅读全文
posted @ 2015-07-10 00:08 Wsine 阅读(1073) 评论(0) 推荐(0) 编辑
摘要: 如题:```function X = IsStrictDiagMatrix(A)% input: A matrix% output: The matrix after transformation % if the matrix is not a square matrix, return e... 阅读全文
posted @ 2015-07-10 00:00 Wsine 阅读(1797) 评论(0) 推荐(0) 编辑
摘要: 复合梯形法则:```function int_f = CompoundEchelon( f, a, b, m )% input : f : function handler% a : the lower limit of integral% b : the... 阅读全文
posted @ 2015-07-09 23:57 Wsine 阅读(2740) 评论(0) 推荐(0) 编辑
摘要: 高斯牛顿法:```function [ x_ans ] = GaussNewton( xi, yi, ri)% input : x = the x vector of 3 points% y = the y vector of 3 points% r = the ra... 阅读全文
posted @ 2015-07-09 23:51 Wsine 阅读(3279) 评论(0) 推荐(0) 编辑
摘要: 插值法实现sin函数:```%calculate and print the sine function%input: x%output: sin(x) similarfunction y = sin2(x)%save a copy of xx_temp = x;%calculate the int... 阅读全文
posted @ 2015-07-09 23:44 Wsine 阅读(1739) 评论(0) 推荐(0) 编辑
摘要: 共轭梯度法:```function [ x, r, k ] = CorGrant( x0, A, b ) x = x0; r = b - A * x0; d = r; X = ones(length(x), 1); k = 0; while 1 if... 阅读全文
posted @ 2015-07-09 23:30 Wsine 阅读(5520) 评论(0) 推荐(0) 编辑
摘要: 稀疏矩阵生成:```function [a, b] = aparsesetup(n) e = ones(n, 1); n2 = n / 2; a = spdiags([-e 3*e -e], -1:1, n, n); a(n2+1, n2) = -1; a(n2, n2+... 阅读全文
posted @ 2015-07-09 23:23 Wsine 阅读(1031) 评论(0) 推荐(0) 编辑
摘要: 朴素高斯消去法:```function x = GauElim(n, A, b) if nargin < 2 for i = 1 : 1 : n for j = 1 : 1 : n A(i, j) = 1 / (i + j - ... 阅读全文
posted @ 2015-07-09 23:17 Wsine 阅读(3399) 评论(0) 推荐(1) 编辑
摘要: 不动点迭代 牛顿法: 割线法: Stewart平台运动学问题求解: test our function at theta = pi / 4 and theta = pi / 4 阅读全文
posted @ 2015-07-09 23:13 Wsine 阅读(5441) 评论(0) 推荐(0) 编辑
摘要: 嵌套乘法的计算:$$ P(x) = 1 - x + x^2 - x^3 + ...+ x ^ {98} - x^{99} $$```function y = nest( d, c, x, b ) if nargin = 0 error('f(a)f(b) tol c =... 阅读全文
posted @ 2015-07-09 23:04 Wsine 阅读(1161) 评论(0) 推荐(0) 编辑
上一页 1 ··· 7 8 9 10 11 12 13 下一页