资源简介
This is a finite volume (toy) toolbox for chemical/petroleum engineers. Right now, it can solve a transient convection-diffusion equation with variable velocity field/diffusion coefficients.
代码片段和文件信息
%% Apparently it must be here!
% Copyright (c) 2012 2013 2014 2015; Ali Akbar Eftekhari
% All rights reserved.
%
% Redistribution and use in source and binary forms with or
% without modification are permitted provided that the following
% conditions are met:
%
% * Redistributions of source code must retain the above copyright notice
% this list of conditions and the following disclaimer.
% * Redistributions in binary form must reproduce the above
% copyright notice this list of conditions and the following
% disclaimer in the documentation and/or other materials provided
% with the distribution.
%
% THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS“
% AND ANY EXPRESS OR IMPLIED WARRANTIES INCLUDING BUT NOT LIMITED TO
% THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
% PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
% CONTRIBUTORS BE LIABLE FOR ANY DIRECT INDIRECT INCIDENTAL SPECIAL
% EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING BUT NOT LIMITED TO
% PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE DATA
% OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
% LIABILITY WHETHER IN CONTRACT STRICT LIABILITY OR TORT (INCLUDING
% NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
% SOFTWARE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
clc; clear; close all;
%% create a mesh and visualize it
% The first part of this demo shows you how to create a mesh and visualize
% it. The aim of the visualization is to introduce you to the mesh
% structure.
% Here we are going to create and visualize a 1D uniform equidistant mesh
% and show the cell centers with a ‘o‘ marker and the face of each cell
% with a ‘+‘ marker.
% We start by defining the length of the domain:
L = 1.0; % length of the domain
%%
% Then we define the number of cells in the domain:
%
Nx = 10; % number of cells in the domain
%%
% Now we call createMesh1D one of the functions from a group of createMesh*
% functions:
%
m = createMesh1D(Nx L);
%%
% This function generates a structure which keeps the domain and grid
% information which will be used by almost every other function in the
% FVMtool.
%
% In general 1D 2D 3D 1D radial (axial symetry) and 2D cylindrical
% grids can be constructed. For more information type
%%
%
% help createMesh2D
% help createMesh3D
% help createMeshCylindrical1D
% help createMeshCylindrical2D
%
%%
% Now let‘s have a look at the structure of the created mesh:
%
disp(m);
%%
% You can easily get more information about this structure by typing
%%
% help createMesh1D
%
%%
% As an example we use the position of the cell centers to visualize the
% domain the cells and the interfaces between them:
%
figure(2);
plot(m.cellcenters.x ones(size(m.cellcenters.x)) ‘or‘ ...
m.facecenters.x ones(size(m.facecenters.x)) ‘-+b‘);
legend(‘cell centers‘ ‘face centers‘);
tit
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-03-23 09:48 FVTool-master\
文件 16 2018-03-23 09:48 FVTool-master\.gitignore
目录 0 2018-03-23 09:48 FVTool-master\Boundary\
文件 1419 2018-03-23 09:48 FVTool-master\Boundary\boundaryCondition.m
文件 2224 2018-03-23 09:48 FVTool-master\Boundary\boundaryCondition1D.m
文件 4184 2018-03-23 09:48 FVTool-master\Boundary\boundaryCondition2D.m
文件 6508 2018-03-23 09:48 FVTool-master\Boundary\boundaryCondition3D.m
文件 7015 2018-03-23 09:48 FVTool-master\Boundary\boundaryConditionCylindrical3D.m
文件 4625 2018-03-23 09:48 FVTool-master\Boundary\boundaryConditionRadial2D.m
文件 658 2018-03-23 09:48 FVTool-master\Boundary\cellBoundary.m
文件 1161 2018-03-23 09:48 FVTool-master\Boundary\cellBoundary1D.m
文件 2343 2018-03-23 09:48 FVTool-master\Boundary\cellBoundary2D.m
文件 3217 2018-03-23 09:48 FVTool-master\Boundary\cellBoundary3D.m
文件 3372 2018-03-23 09:48 FVTool-master\Boundary\cellBoundaryCylindrical3D.m
文件 2511 2018-03-23 09:48 FVTool-master\Boundary\cellBoundaryRadial2D.m
文件 699 2018-03-23 09:48 FVTool-master\Boundary\combineBC.m
文件 1444 2018-03-23 09:48 FVTool-master\Boundary\combineBC1D.m
文件 2454 2018-03-23 09:48 FVTool-master\Boundary\combineBC2D.m
文件 662 2018-03-23 09:48 FVTool-master\Boundary\createBC.m
文件 771 2018-03-23 09:48 FVTool-master\Boundary\createBC1D.m
文件 1094 2018-03-23 09:48 FVTool-master\Boundary\createBC2D.m
文件 1309 2018-03-23 09:48 FVTool-master\Boundary\createBC3D.m
目录 0 2018-03-23 09:48 FVTool-master\Calculus\
文件 726 2018-03-23 09:48 FVTool-master\Calculus\ddtTerm.m
文件 800 2018-03-23 09:48 FVTool-master\Calculus\ddtTerm1D.m
文件 860 2018-03-23 09:48 FVTool-master\Calculus\ddtTerm2D.m
文件 770 2018-03-23 09:48 FVTool-master\Calculus\ddtTerm3D.m
文件 1031 2018-03-23 09:48 FVTool-master\Calculus\divergenceTerm.m
文件 742 2018-03-23 09:48 FVTool-master\Calculus\divergenceTerm1D.m
文件 1246 2018-03-23 09:48 FVTool-master\Calculus\divergenceTerm2D.m
文件 1733 2018-03-23 09:48 FVTool-master\Calculus\divergenceTerm3D.m
............此处省略313个文件信息
相关资源
- 用Matlab将坐标添加到地图上
- matlab 神经网络 遥感图像分类 可用程
-
Labview调用Matlab(用MATLAB sc
ript技术) - SPAMS 信号稀疏表示Matlab工具包windows版
- Matlab时频分析工具箱及仿真案例
- 基于matlab的运动目标检测源代码
- biot 双向介质正演模拟matlab程序
- 端元提取——顶点成分分析VCA的MATL
- 运动估计快速算法(TSSDS)matlab
- LSB信息隐藏实验 matlab代码及实验报告
- 含储能电池风电场并网可靠性评估.
- 基于栅格地图的蚁群算法路径规划
- matlab汉化补丁
- matlab基于BP神经网络的人脸识别13953
- SPAMS_matlab_v2.5
- matlab移动平均算法
- MATLAB雷达多普勒微动仿真
- 自适应全变分图像去噪模型及其快速
- 7个经典传感器网络WSN节点定位算法的
- matlab简单的统计硬币个数程序,包含
- 广义自回归神经网络预测代码含原始
- 用ZMNL对海杂波进行matlab仿真
- 聚类数指标matlab工具箱
- 基于MATLAB车牌识别系统设计--程序--字
- svpwm的matlab实现
- 基于MATLAB的回声状态网络,可用于趋
- MATLAB 6.5 辅助小波分析与应用 飞思科
- 《信号与系统》计算机练习+利用MAT
- 图像特征分类识别程序
- Zemax DDE toolbox for Matlab
评论
共有 条评论