Added or adjusted documentation to match toolbox requirements

parent 9d7e4523
...@@ -4,6 +4,16 @@ classdef (Abstract)itaAbstract3DModelVisualizer < handle ...@@ -4,6 +4,16 @@ classdef (Abstract)itaAbstract3DModelVisualizer < handle
% Parameters for the plot are defined using class properties. % Parameters for the plot are defined using class properties.
% Adjusting these leads to a real-time update the plot (if % Adjusting these leads to a real-time update the plot (if
% autoRefresh is set to true). % autoRefresh is set to true).
%
% See also itaAc3dVisualizer, itaComsolModelVisualizer
%
% Reference page in Help browser
% <a href="matlab:doc itaAbstract3DModelVisualizer">doc itaAbstract3DModelVisualizer</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = protected) properties(Access = protected)
mModel; %Stores the model which is to be visualized mModel; %Stores the model which is to be visualized
......
classdef itaAc3dVisualizer < itaAbstract3DModelVisualizer classdef itaAc3dVisualizer < itaAbstract3DModelVisualizer
%itaAc3dVisualizer This class is used to visualize an AC3D model. %itaAc3dVisualizer This class is used to visualize an itaAc3dModel.
% Parameters for the plot are defined using class properties. % Parameters for the plot are defined using class properties.
% Adjusting these leads to a real-time update the plot (if % Adjusting these leads to a real-time update the plot (if
% autoRefresh is set to true). % autoRefresh is set to true).
%
% See also itaAc3dVisualizer, itaAc3dModel
%
% Reference page in Help browser
% <a href="matlab:doc itaAc3dVisualizer">doc itaAc3dVisualizer</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Hidden = true) properties(Hidden = true)
axesMapping = [1 -3 2]; %Maps data from .ac3d file to fit to the plot (default is no transform) axesMapping = [1 -3 2]; %Maps data from .ac3d file to fit to the plot (default is no transform)
......
classdef itaComsolModelVisualizer < itaAbstract3DModelVisualizer classdef itaComsolModelVisualizer < itaAbstract3DModelVisualizer
%itaComsolModelVisualizer Summary of this class goes here %itaComsolModelVisualizer This class is used to visualize an itaComsolModel.
% Detailed explanation goes here % Parameters for the plot are defined using class properties.
% Adjusting these leads to a real-time update the plot (if
% autoRefresh is set to true).
%
%
% See also itaAc3dVisualizer, itaComsolModel, itaComsolServer
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolModelVisualizer">doc itaComsolModelVisualizer</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
mMeshPlotHandles; mMeshPlotHandles;
......
...@@ -6,6 +6,17 @@ classdef itaComsolImpedance < handle ...@@ -6,6 +6,17 @@ classdef itaComsolImpedance < handle
% itaMaterial or itaSuper.Therefore. suitable physics and interpolation % itaMaterial or itaSuper.Therefore. suitable physics and interpolation
% nodes are created and linked apropriately. All comsol nodes % nodes are created and linked apropriately. All comsol nodes
% representing this impedance are stored for later modification. % representing this impedance are stored for later modification.
%
% See also itaComsolModel, itaComsolServer, itaComsolSource,
% itaComsolReceiver
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolImpedance">doc itaComsolImpedance</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
mModel; mModel;
......
classdef itaComsolModel < handle classdef itaComsolModel < handle
%itaComsolModel Interface to adjust work with comsol model %itaComsolModel Interface to adjust and work with Comsol models
% This class takes an existing comsol model and provides interfaces % This class represents a model tree similar to the one within
% to adjust certain parameters such as boundary conditions % Comsol. Each child node of a model is represented by a particular
% (impedances) and sources. Also provides the function to run a % class (e.g. the physics node is represented by itaComsolPhysics).
% simulation and gather results in ita-formats. % Through these sub-classes it provides interfaces to adjust certain
% % parameters or access data. An overview is given below. More details
% can be found in the documentation of the respective classes.
%
% Note, that it is crucial to define the basis of the comsol model in % Note, that it is crucial to define the basis of the comsol model in
% Comsol itself. This includes: % Comsol itself. This includes:
% -Geometry % -Geometry
...@@ -15,7 +17,7 @@ classdef itaComsolModel < handle ...@@ -15,7 +17,7 @@ classdef itaComsolModel < handle
% -Mesh % -Mesh
% -Study % -Study
% %
% This class is able to create/adjust: % Using an itaComsolModel and its related classes, it is possible to create/adjust:
% -Global Definitions % -Global Definitions
% -Interpolations % -Interpolations
% -Geometry % -Geometry
...@@ -26,11 +28,22 @@ classdef itaComsolModel < handle ...@@ -26,11 +28,22 @@ classdef itaComsolModel < handle
% -frequency dependent values for boundary impedances % -frequency dependent values for boundary impedances
% -frequency dependent source parameters (velocity / pressure) % -frequency dependent source parameters (velocity / pressure)
% -Mesh % -Mesh
% -... () % -mesh size
% -Result
% -retrieve results in ita-formats
% -Study % -Study
% -frequency vector % -frequency vector
% -run simulation
% -Batch % -Batch
% -... % -create batch commands to run simulation
%
% See also itaComsolServer, itaComsolBatch, itaComsolExport,
% itaComsolFunction, itaComsolGeometry, itaComsolMaterial,
% itaComsolMesh, itaComsolParameters, itaComsolPhysics,
% itaComsolResult, itaComsolSelection, itaComsolStudy
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolModel">doc itaComsolModel</a>
% <ITA-Toolbox> % <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved. % This file is part of the ITA-Toolbox. Some rights reserved.
......
...@@ -4,6 +4,17 @@ classdef itaComsolReceiver < handle ...@@ -4,6 +4,17 @@ classdef itaComsolReceiver < handle
% for a given itaComsolModel using an itaReceiver. Therefore depending % for a given itaComsolModel using an itaReceiver. Therefore depending
% on the receiver type, suitable geometry nodes are created. All comsol % on the receiver type, suitable geometry nodes are created. All comsol
% nodes representing this receiver are stored for later modification. % nodes representing this receiver are stored for later modification.
%
% See also itaComsolModel, itaComsolServer, itaComsolSource,
% itaComsolImpedance
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolReceiver">doc itaComsolReceiver</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
mModel; mModel;
......
classdef itaComsolServer < handle classdef itaComsolServer < handle
%itaComsolServer Interface to start/stop and connect/disconnect %itaComsolServer Interface to start/stop and connect/disconnect
%Comsol Server via Matlab LiveLink %Comsol Server via Matlab LiveLink
% Also allows to remove comsol models from the server % Also allows to remove comsol models from the server.
%
% Information on the server and LiveLink path are stored in an ini-file.
% This file is created the first time a connection is established.
%
% See also itaComsolModel
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolServer">doc itaComsolServer</a>
% <ITA-Toolbox> % <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved. % This file is part of the ITA-Toolbox. Some rights reserved.
......
...@@ -5,6 +5,17 @@ classdef itaComsolSource < handle ...@@ -5,6 +5,17 @@ classdef itaComsolSource < handle
% on the source type, suitable physics, geometry and interpolation % on the source type, suitable physics, geometry and interpolation
% nodes are created and linked apropriately. All comsol nodes % nodes are created and linked apropriately. All comsol nodes
% representing this source are stored for later modification. % representing this source are stored for later modification.
%
% See also itaComsolModel, itaComsolServer, itaComsolReceiver,
% itaComsolImpedance
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolSource">doc itaComsolSource</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
mModel; mModel;
......
...@@ -3,6 +3,16 @@ classdef itaComsolBatch < itaComsolNode ...@@ -3,6 +3,16 @@ classdef itaComsolBatch < itaComsolNode
%to run models in batch mode %to run models in batch mode
% Note, that this class also provides static functions to create and % Note, that this class also provides static functions to create and
% execute windows command lines to simulate Comsol models from batch. % execute windows command lines to simulate Comsol models from batch.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolBatch">doc itaComsolBatch</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolExport < itaComsolNode classdef itaComsolExport < itaComsolNode
%itaComsolExport Interface to the result.export nodes of an itaComsolModel %itaComsolExport Interface to the result.export nodes of an itaComsolModel
% ... % Can run child nodes to export Comsol data to files (e.g. csv)
%
% See also itaComsolModel, itaComsolNode, ita_read_comsol_csv
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolExport">doc itaComsolExport</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolFunction < itaComsolNode classdef itaComsolFunction < itaComsolNode
%itaComsolFunction Interface to the func (=function) nodes of an itaComsolModel %itaComsolFunction Interface to the func (=function) nodes of an itaComsolModel
% ... % Can be used to create interpolation nodes in Comsol that represent
% frequency dependent functions. Can also represent complex-valued
% functions using one interpolation for the real and one for the
% imaginary part.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolFunction">doc itaComsolFunction</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
...@@ -86,6 +99,9 @@ classdef itaComsolFunction < itaComsolNode ...@@ -86,6 +99,9 @@ classdef itaComsolFunction < itaComsolNode
end end
methods(Static = true) methods(Static = true)
function expression = GetComplexFunctionExpression(realInterpolationNode, imagInterpolationNode) function expression = GetComplexFunctionExpression(realInterpolationNode, imagInterpolationNode)
%Returns a function expression giving two interpolation nodes
% The expression will look like this:
% tagReal(freq) + i*tagImag(freq)
realFuncName = char(realInterpolationNode.tag); realFuncName = char(realInterpolationNode.tag);
imagFuncName = char(imagInterpolationNode.tag); imagFuncName = char(imagInterpolationNode.tag);
expression = [realFuncName '(freq) + i*' imagFuncName '(freq)']; expression = [realFuncName '(freq) + i*' imagFuncName '(freq)'];
......
classdef itaComsolGeometry < itaComsolNode classdef itaComsolGeometry < itaComsolNode
%itaComsolGeometry Interface to the geom (=geometry) nodes of an itaComsolModel %itaComsolGeometry Interface to the geom (=geometry) nodes of an itaComsolModel
% ... % Can be used to create certain types of geometry that refer to
% objects such as itaSource or itaReceiver. This is done using the
% Create...-functions of this class.
% These functions are given a unique tag. Existing geometries can be
% adjusted by the same function that created them using the same tag.
%
% See also itaComsolModel, itaComsolNode, itaComsolSource,
% itaComsolReceiver
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolGeometry">doc itaComsolGeometry</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolMaterial < itaComsolNode classdef itaComsolMaterial < itaComsolNode
%itaComsolMaterial Interface to the material nodes of an itaComsolModel %itaComsolMaterial Interface to the material nodes of an itaComsolModel
% ... % This class is just a place-holder so far and has no functionality.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolMaterial">doc itaComsolMaterial</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolMesh < itaComsolNode classdef itaComsolMesh < itaComsolNode
%itaComsolMesh Interface to the mesh nodes of an itaComsolModel %itaComsolMesh Interface to the mesh nodes of an itaComsolModel
% ... % Can be used to access and adjust the size nodes of a mesh.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolMesh">doc itaComsolMesh</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
...@@ -15,6 +15,16 @@ classdef (Abstract)itaComsolNode < handle ...@@ -15,6 +15,16 @@ classdef (Abstract)itaComsolNode < handle
% -Batch % -Batch
% -Results % -Results
% Use mphnavigator() on a comsol model for more information % Use mphnavigator() on a comsol model for more information
%
% See also itaComsolModel
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolNode">doc itaComsolNode</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = protected) properties(Access = protected)
mModel; %itaComsolModel object mModel; %itaComsolModel object
......
classdef itaComsolParameters < itaComsolNode classdef itaComsolParameters < itaComsolNode
%itaComsolParameters Interface to the param (=parameter) nodes of an itaComsolModel %itaComsolParameters Interface to the param (=parameter) nodes of an itaComsolModel
% ... % Allows to list the parameters of the Comsol model and adjust their
% values.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolParameters">doc itaComsolParameters</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
......
classdef itaComsolPhysics < itaComsolNode classdef itaComsolPhysics < itaComsolNode
%itaComsolPhysics Interface to the physics node of an itaComsolModel %itaComsolPhysics Interface to the physics node of an itaComsolModel
% ... % Allows to adjust parameters of a comsol physics node. Also allows
% to create new nodes that represent certain acoustic properties
% (e.g. for sources or boundaries).
% This is done using the Create...-functions of this class. These
% functions are given a unique tag. Existing physic nodes can be
% adjusted by the same function that created them using the same tag.
%
% See also itaComsolModel, itaComsolNode, itaComsolSource,
% itaComsolImpedance
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolPhysics">doc itaComsolPhysics</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolResult < handle classdef itaComsolResult < handle
%itaComsolResult Interface to access simulation results of an %itaComsolResult Interface to access simulation results of an
%itaComsolModel object %itaComsolModel object
% Detailed explanation goes here % Allows to evaluate the results of a study at the mesh nodes or
% given coordintas. The result are then returned as an itaResult
% object with one channel per given coordinate.
%
% Note:
% The direct data import only works for FEM simulation. For BEM,
% simulations data has to be exported to .csv files and before being
% imported into Matlab (see itaComsolExport & ita_read_comsol_csv).
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolResult">doc itaComsolResult</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
mModel; mModel;
......
classdef itaComsolSelection < itaComsolNode classdef itaComsolSelection < itaComsolNode
%itaComsolSelection Interface to the selection nodes of an itaComsolModel %itaComsolSelection Interface to the selection nodes of an itaComsolModel
% ... % Can be used to quickly access all Comsol selection nodes of certain
% dimension (0D, 1D, ..., 3D). Furthermore, it allows to use filters
% to further specify which selections are to be returned (see
% itaComsolSelection.filters). Also allows to access a selection node
% using its name.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolSelection">doc itaComsolSelection</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
classdef itaComsolStudy < itaComsolNode classdef itaComsolStudy < itaComsolNode
%itaComsolStudy Interface to the study nodes of an itaComsolModel %itaComsolStudy Interface to the study nodes of an itaComsolModel
% ... % Allows to run simulations from Matlab and adjust certain study
% parameters such as the frequency vector.
%
% Furthermore it is possible to run a parametric sweep from Matlab:
% Therefore, a series of simulations where a Comsol parameter is a
% changed for each simulation is executed independently. The results
% are stored in different files. This reduces the amount of memory
% compared to running a parametric sweep from Comsol.
%
% See also itaComsolModel, itaComsolNode
%
% Reference page in Help browser
% <a href="matlab:doc itaComsolStudy">doc itaComsolStudy</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
%% Constructor %% Constructor
methods methods
......
...@@ -3,6 +3,11 @@ classdef itaMaterial < itaSimulationInputItem ...@@ -3,6 +3,11 @@ classdef itaMaterial < itaSimulationInputItem
%used for GA-based and wave-based simulations %used for GA-based and wave-based simulations
% Properties: % Properties:
% Impedance, absorption, scattering % Impedance, absorption, scattering
%
% See also itaSimulationInputItem, ImpedanceType, ScatteringType
%
% Reference page in Help browser
% <a href="matlab:doc itaMaterial">doc itaMaterial</a>
% <ITA-Toolbox> % <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved. % This file is part of the ITA-Toolbox. Some rights reserved.
......
...@@ -4,8 +4,11 @@ classdef itaMaterialVisualizer < handle ...@@ -4,8 +4,11 @@ classdef itaMaterialVisualizer < handle
% This class can plot the impedance, absorption or scattering of all % This class can plot the impedance, absorption or scattering of all
% given materials in a single plot. Plotting is based on ita_plot_freq() % given materials in a single plot. Plotting is based on ita_plot_freq()
% function and uses same syntax for input arguments. % function and uses same syntax for input arguments.
% %
% See also ita_plot_freq. % See also itaMaterial, ita_plot_freq
%
% Reference page in Help browser
% <a href="matlab:doc itaMaterialVisualizer">doc itaMaterialVisualizer</a>
% <ITA-Toolbox> % <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved. % This file is part of the ITA-Toolbox. Some rights reserved.
......
classdef itaReceiver < itaSpatialSimulationInputItem classdef itaReceiver < itaSpatialSimulationInputItem
%itaReceiver Summary of this class goes here %itaReceiver represents a receiver and its acoustic properties which are
% Detailed explanation goes here %used for GA-based and wave-based simulations
% Properties:
% Receiver-type, position, orientation, left and right ear position
%
% See also itaSpatialSimulationInputItem, ReceiverType
%
% Reference page in Help browser
% <a href="matlab:doc itaReceiver">doc itaReceiver</a>
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
% You can find the license for this m-file in the license.txt file in the ITA-Toolbox folder.
% </ITA-Toolbox>
properties(Access = private) properties(Access = private)
%mFemGroup; %mFemGroup;
......
classdef (Abstract) itaSimulationInputItem classdef (Abstract) itaSimulationInputItem
%itaSimulationInputItem An abstract item that is used in a database for %itaSimulationInputItem An abstract item that is used to represent
%acoustic simulations (wave-based and GA-based) %input data for sound field simulations (wave-based and GA-based)
%
% See also itaMaterial, itaSource, itaReceiver
%
% Reference page in Help browser
% <a href="matlab:doc itaSimulationInputItem">doc itaSimulationInputItem</a>
% <ITA-Toolbox> % <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved. % This file is part of the ITA-Toolbox. Some rights reserved.
......
...@@ -7,6 +7,11 @@ classdef itaSource < itaSpatialSimulationInputItem ...@@ -7,6 +7,11 @@ classdef itaSource < itaSpatialSimulationInputItem
% The wave TF can either represent a point source, a piston or a % The wave TF can either represent a point source, a piston or a
% distribution over a surface and is specified in one itaSource's % distribution over a surface and is specified in one itaSource's
% subclasses. % subclasses.
%
% See also itaSpatialSimulationInputItem, SourceType, SensitivityType
%