⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 getdp.texi

📁 cfd求解器使用与gmsh网格的求解
💻 TEXI
📖 第 1 页 / 共 5 页
字号:
GetDP as a mesh is a file containing a list of nodes (with theircoordinates) and a list of geometrical elements with, for each one, a numbercharacterizing its geometrical type (i.e., line, triangle, quadrangle,tetrahedron, hexahedron, prism, etc.), a number characterizing the physicalregion to which it belongs and the list of its nodes. This minimal input setshould be easy to extract from most of the classical mesh fileformats (@pxref{Input file format}, for a complete description of the meshfile format read by GetDP).Groups of geometrical entities of various types can be considered and areused in many objects. There are region groups, of which the entities areregions, and function groups, with nodes, edges, facets, volumes, groups ofnodes, edges of tree, facets of tree, @dots{} of regions.Amongst region groups, elementary and global groups can be distinguished:elementary groups are relative to single regions (e.g., physical regions inwhich piecewise defined functions or constraints can be defined) whileglobal groups are relative to sets of regions for which given treatmentshave to be performed (e.g., domain of integration, support of a functionspace, etc.).Groups of function type contain lists of entities built on some regiongroups (e.g., nodes for nodal elements, edges for edge elements, edges oftree for gauge conditions, groups of nodes for floating potentials, elementson one side of a surface for cuts, etc.).A definition of initially empty groups can be obtained thanks to a@code{DefineGroup} command, so that their identifiers exist and can bereferred to in other objects, even if these groups are not explicitlydefined. This procedure is similar to the @code{DefineConstant} procedureintroduced for constants in @ref{Constants}.The syntax for the definition of groups is:@exampleGroup @{  < DefineGroup [ @var{group-id} <@{@var{integer}@}> <,@dots{}> ]; > @dots{}  < @var{group-id} = @var{group-def}; > @dots{}  < @var{group-id} += @var{group-def}; > @dots{}  < @var{affectation} > @dots{}  < @var{loop} > @dots{}@}@end example@noindent with@example@var{group-id}:  @var{string} |  @var{string} ~ @{ @var{expression-cst} @}@var{group-def}:  @var{group-type} [ @var{group-list} <, @var{group-sub-type} @var{group-list} > ] |  @var{group-id} <@{<@var{integer}>@}> |  #@var{group-list}@var{group-type}:   Region | Global | NodesOf | EdgesOf | @var{etc}@var{group-list}:  All | @var{group-list-item} | @{ @var{group-list-item} <,@dots{}> @}@var{group-list-item}:  @var{integer} |   @var{integer} : @var{integer} |   @var{integer} : @var{integer} : @var{integer} |  @var{group-id} <@{<@var{integer}>@}>@var{group-sub-type}:   Not | StartingOn | OnOneSideOf | @var{etc}@end example@noindent Notes:@enumerate@item@var{integer} as a @var{group-list-item} is the only interface with themesh; with each element is associated a region number, being this@var{integer}, and a geometrical type (@pxref{Input file format}). Ranges ofintegers can be specified in the same way as ranges of constant expressionsin an @var{expression-cst-list-item} (@pxref{Constants}). For example,@code{@var{i}:@var{j}} replaces the list of consecutive integers @var{i},@var{i}+1, @dots{}, @var{j}-1, @var{j}.@itemArray of groups: @code{DefineGroup[@var{group-id}@{@var{n}@}]} definesthe empty groups @code{@var{group-id}@{@var{i}@}}, @var{i}=1, @dots{}, n.Such a definition is optional, i.e., each@code{@var{group-id}@{@var{i}@}} can be separately defined, in any order.@item@code{#@var{group-list}} is an abbreviation of @code{Region[@var{group-list}]}.@end enumerateSee @ref{Types for Group}, for the complete list of options and @ref{Groupexamples}, for some examples.@c -------------------------------------------------------------------------@c Function@c -------------------------------------------------------------------------@node Function, Constraint, Group, Objects@section @code{Function}: defining global and piecewise expressions@cindex Function, definition@cindex Piecewise functions@cindex User-defined functions@tindex Function@tindex DefineFunction@tindex =@vindex @var{function-id}A user-defined function can be global in space or piecewise defined inregion groups. A physical characteristic is an example of a piecewisedefined function (e.g., magnetic permeability, electric conductivity, etc.)and can be simply a constant, for linear materials, or a function of one orseveral arguments for nonlinear materials. Such functions can of coursedepend on space coordinates or time, which can be needed to express complexconstraints.A definition of initially empty functions can be made thanks to the@code{DefineFunction} command so that their identifiers exist and can bereferred to (but cannot be used) in other objects. The syntax for thedefinition of functions is:@exampleFunction @{  < DefineFunction [ @var{function-id} <,@dots{}> ]; > @dots{}  < @var{function-id} [ < @var{group-def} > ] = @var{expression}; > @dots{}  < @var{affectation} > @dots{}  < @var{loop} > @dots{}@}@end example@noindent with@example@var{function-id}:  @var{string}@end example@noindent Note:@enumerate@itemThe optional @var{group-def} in brackets must be of @code{Region} type, andindicates on which region the (piecewise) function is defined. Warning: itis incorrect to write @code{f[reg1]=1; g[reg2]=f[]+1;} since the domains ofdefinition of @code{f[]} and @code{g[]} don't match.@end enumerateSee @ref{Types for Function}, for the complete list of built-in functionsand @ref{Function examples}, for some examples.@c -------------------------------------------------------------------------@c Constraint@c -------------------------------------------------------------------------@node Constraint, FunctionSpace, Function, Objects@section @code{Constraint}: specifying constraints on function spaces and formulations@cindex Constraint, definition@cindex Circuit equations@cindex Boundary conditions@cindex Networks@tindex Constraint@tindex Name@tindex Type@tindex Case@tindex Region@tindex SubRegion@tindex TimeFunction@vindex @var{constraint-id}@vindex @var{constraint-type}@vindex @var{constraint-val}@vindex @var{constraint-case-id}@vindex @var{constraint-case-val}Constraints can be referred to in @code{FunctionSpace} objects to beused for boundary conditions, to impose global quantities or toinitialize quantities.  These constraints can be expressed withfunctions or be imposed by the pre-resolution of another discreteproblem. Other constraints can also be defined, e.g., constraints ofnetwork type for the definition of circuit connections, to be used in @code{Formulation} objects.The syntax for the definition of constraints is:@exampleConstraint @{  @{ Name @var{constraint-id}; Type @var{constraint-type};    Case @{      @{ Region @var{group-def}; < Type @var{constraint-type}; >        < SubRegion @var{group-def}; > < TimeFunction @var{expression}; >         < RegionRef @var{group-def}; > < SubRegionRef @var{group-def}; >         < Coefficient @var{expression}; > < Function @var{expression}; >        < Filter @var{expression}; >         @var{constraint-val}; @} @dots{}      < @var{loop} > @dots{}    @}   | Case @var{constraint-case-id} @{       @{ Region @var{group-def}; < Type @var{constraint-type}; >        @var{constraint-case-val}; @} @dots{}      < @var{loop} > @dots{}    @} @dots{}  @} @dots{}  < @var{affectation} > @dots{}  < @var{loop} > @dots{}@}@end example@noindent with@example@var{constraint-id}:@var{constraint-case-id}:  @var{string} |  @var{string} ~ @{ @var{expression-cst} @}@var{constraint-type}:   Assign | Init | Network | Link | @var{etc}@var{constraint-val}:  Value @var{expression} | NameOfResolution @var{resolution-id} | @var{etc}@var{constraint-case-val}:  Branch @{ @var{integer}, @var{integer} @} | @var{etc}@end example@noindent Notes:@enumerate@itemThe constraint type @var{constraint-type} defined outside the @code{Case}fields is applied to all the cases of the constraint, unless other types areexplicitly given in these cases.  The default type is @code{Assign}.@itemThe region type @code{Region @var{group-def}} will be the main@var{group-list} argument of the @var{group-def} to be built for theconstraints of @code{FunctionSpace}s. The optional region type@code{SubRegion @var{group-def}} will be the argument of the associated@var{group-sub-type}.@item@var{expression} in @code{Value} of @var{constraint-val} cannot be timedependent (@code{$Time}) because it is evaluated only once during thepre-processing (for efficiency reasons).  Time dependences must be definedin @code{TimeFunction @var{expression}}.@end enumerateSee @ref{Types for Constraint}, for the complete list of options and@ref{Constraint examples}, for some examples.@c -------------------------------------------------------------------------@c FunctionSpace@c -------------------------------------------------------------------------@node FunctionSpace, Jacobian, Constraint, Objects@section @code{FunctionSpace}: building function spaces@cindex Function space, definition@cindex Discrete function spaces@cindex Spaces, discrete@cindex Approximation spaces@cindex Basis Functions@cindex Interpolation@cindex Hierarchical basis functions@tindex FunctionSpace@tindex Name@tindex Type@tindex BasisFunction@tindex NameOfCoef@tindex Function@tindex Quantity@tindex Formulation@tindex Group@tindex Resolution@tindex Support@tindex Entity@tindex SubSpace@tindex NameOfBasisFunction@tindex GlobalQuantity@tindex Constraint@tindex EntityType@tindex EntitySubType@tindex NameOfConstraint@vindex @var{function-space-id}@vindex @var{function-space-type}@vindex @var{basis-function-id}@vindex @var{basis-function-type}@vindex @var{coef-id}@vindex @var{sub-space-id}@vindex @var{basis-function-list}@vindex @var{global-quantity-id}@vindex @var{global-quantity-type}A @code{FunctionSpace} is characterized by the type of its interpolatedfields, one or several basis functions and optional constraints (inspace and time). Subspaces of a function space can be defined (e.g.,for the use with hierarchical elements), as well as direct associations ofglobal quantities (e.g., floating potential, electric charge, current,voltage, magnetomotive force, etc.).A key point is that basis functions are defined by any number of subsets offunctions, being added. Each subset is characterized by associated built-infunctions for evaluation, a support of definition and a set of associatedsupporting geometrical entities (e.g., nodes, edges, facets, volumes,groups of nodes, edges incident to a node, etc.). The freedom in definingvarious kinds of basis functions associated with different geometricalentities to interpolate a field permits to build made-to-measure functionspaces adapted to a wide variety of field approximations(@pxref{FunctionSpace examples}).The syntax for the definition of function spaces is:@exampleFunctionSpace @{  @{ Name @var{function-space-id};    Type @var{function-space-type};    BasisFunction @{      @{ Name @var{basis-function-id}; NameOfCoef @var{coef-id};        Function @var{basis-function-type}         < @{ Quantity @var{quantity-id};             Formulation @var{formulation-id} @{#@var{integer}@};              Group @var{group-def}; Resolution @var{resolution-id} @{@} @} >;       Support @var{group-def}; Entity @var{group-def}; @} @dots{}    @}  < SubSpace @{      @{ Name @var{sub-space-id};        NameOfBasisFunction @var{basis-function-list}; @} @dots{}    @} >  < GlobalQuantity @{      @{ Name @var{global-quantity-id}; Type @var{global-quantity-type};        NameOfCoef @var{coef-id}; @} @dots{}    @} >  < Constraint @{      @{ NameOfCoef @var{coef-id};       EntityType @var{group-type}; < EntitySubType @var{group-sub-type}; >       NameOfConstraint @var{constraint-id} <@{@}>; @} @dots{}    @} >  @} @dots{}  < @var{affectation} > @dots{}  < @var{loop} > @dots{}@}@end example@noindent with@example@var{function-space-id}: @var{formulation-id}:@var{resolution-id}:  @var{string} |  @var{string} ~ @{ @var{expression-cst} @}@var{basis-function-id}:@var{coef-id}:@var{sub-space-id}:@var{global-quantity-id}:   @var{string}@var{function-space-type}:     Scalar | Vector | Form0 | Form1 | @var{etc} @var{basis-function-type}:  BF_Node | BF_Edge | @var{etc} @var{basis-function-list}:  @var{basis-function-id} | @{ @var{basis-function-id} <,@dots{}> @} @var{global-quantity-type}:  AliasOf | AssociatedWith@end example@noindent Notes:@enumerate@itemWhen the definition region of a function type group used as an @code{Entity} of a @code{BasisFunction} is the same as that of the associated @code{Support}, it is replaced by @code{All} for more efficient t

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -