资源简介
自己帮同学写的,C++求解矩阵AX = B,

代码片段和文件信息
/*
*File name: Complex.cpp
*Function purpose: To complate the mathematical operation of complex number.
*Author Date:2012-7-11
*Alter: No
*/
#include
#include
#include “Complex.h“
Complex::Complex(float re float im) {
real = re;
image = im;
}
void Complex::InitComplex() {
real = 0.0;
image = 0.0;
}
Complex Complex::operator+(const Complex &z) const {
return Complex(real+z.realimage+z.image);
}
/*
Complex Complex::operator-(const Complex &z) const {
return Complex(real-z.realimage-z.image);
}
*/
Complex Complex::operator*(const Complex &z) const {
return Complex(real*z.real-image*z.image real*z.image+image*z.real);
}
/*
Complex Complex::operator/(const Complex &z) const {
double delta = z.real*z.real + z.image*z.image;
return Complex((real*z.real + image*z.image)/delta
(z.real*image - real*z.image)/delta);
}
*/
float Complex::GetRealComplex()const {
return real;
}
float Complex::GetImageComplex()const {
return image;
}
/*
void Complex::PrintComplex() const {
if (image >= 0)
std::cout << std::left < else
std::cout << std::left << std::setw(12) << real << image << ‘i‘;
}*/
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 1289 2012-08-09 21:22 Complex.cpp
文件 685 2012-08-05 14:42 Complex.h
文件 17844 2012-06-16 09:42 ComplexMatrix.aps
文件 9113 2012-08-05 23:29 ComplexMatrix.cpp
文件 1589 2012-08-05 18:45 ComplexMatrix.h
文件 2470 2012-06-16 09:42 ComplexMatrix.rc
文件 892 2012-05-06 11:17 ComplexMatrix.sln
文件 4335 2012-07-11 22:27 ComplexMatrix.vcxproj
文件 1763 2012-07-11 22:27 ComplexMatrix.vcxproj.filters
文件 143 2012-05-06 11:17 ComplexMatrix.vcxproj.user
目录 0 2012-10-16 07:26 Debug\
目录 0 2012-10-16 07:25 ipch\
目录 0 2012-10-16 07:26 ipch\complexmatrix-51b46127\
文件 2178 2012-08-05 23:37 main.cpp
文件 18047 2012-08-05 22:15 RealMatrix.cpp
文件 2684 2012-08-05 22:09 RealMatrix.h
文件 392 2012-06-16 09:42 resource.h
相关资源
- C++中头文件与源文件的作用详解
- C++多线程网络编程Socket
- VC++ 多线程文件读写操作
- 利用C++哈希表的方法实现电话号码查
- 移木块游戏,可以自编自玩,vc6.0编写
- C++纯文字DOS超小RPG游戏
- VC++MFC小游戏实例教程(实例)+MFC类库
- 连铸温度场计算程序(C++)
- 6自由度机器人运动学正反解C++程序
- Em算法(使用C++编写)
- libstdc++-4.4.7-4.el6.i686.rpm
- VC++实现CMD命令执行与获得返回信息
- 白话C++(全)
- C++标准库第1、2
- 大数类c++大数类
- C++语言编写串口调试助手
- c++素数筛选法
- C++ mqtt 用法
- 商品库存管理系统 C++ MFC
- c++ 多功能计算器
- C++17 In Detail
- 嵌入式QtC++编程课件
- 颜色识别形状识别STM103嵌入式代码
- c++ 邮件多附件群发
- c++ 透明代理(hookproxy)
- mfc 调用redis
- FTP客户端源码(c++)
- c++ 画图(14Qt-XPS)
- c++多边形交并差运算
- VC++基于OpenGL模拟的一个3维空间模型
评论
共有 条评论