GridapROMs.TProduct

GridapROMs.TProduct.GenericRankTensorType
struct GenericRankTensor{D,K,A<:AbstractArray} <: AbstractRankTensor{D,K}
  decompositions::Vector{Rank1Tensor{D,A}}
end

Structure representing a generic rank-K tensor, i.e. assuming the form

$a = \sum\limits_{k=1}^K a_1^k \otimes \cdots \otimes a_D^k$

source
GridapROMs.TProduct.Rank1TensorType
struct Rank1Tensor{D,A<:AbstractArray} <: AbstractRankTensor{D,1}
  factors::Vector{A}
end

Structure representing rank-1 tensors, i.e. assuming the form

$a = a_1 \otimes \cdots \otimes a_D$

source
GridapROMs.TProduct.TProductDiscreteModelType
TProductDiscreteModel{D,A,B} <: DiscreteModel{D,D} end

Tensor product discrete model, storing a vector of 1-D models models_1d of length D, and the D-dimensional model model defined as their tensor product.

source
GridapROMs.TProduct.TProductFESpaceType
struct TProductFESpace{S} <: SingleFieldFESpace
  space::S
  spaces_1d::Vector{<:SingleFieldFESpace}
  trian::TProductTriangulation
end

Tensor product single field FESpace, storing a vector of 1-D FESpaces spaces_1d of length D, and the D-dimensional FESpace space defined as their tensor product. The tensor product triangulation trian is provided as a field to avoid incompatibility issues when passing to MultiField scenarios

source
GridapROMs.TProduct.TProductMeasureType
struct TProductMeasure{A,B} <: Measure
  measure::A
  measures_1d::B
end

Tensor product measure, storing a vector of 1-D measures measures_1d of length D, and the D-dimensional measure measure defined as their tensor product.

source
GridapROMs.TProduct.TProductTriangulationType
TProductTriangulation{Dt,Dp,A,B,C} <: Triangulation{Dt,Dp}

Tensor product triangulation, storing a tensor product model, a vector of 1-D triangulations trians_1d of length D, and the D-dimensional triangulation trian defined as their tensor product.

source
GridapROMs.TProduct.get_1d_tagsMethod
get_1d_tags(model::TProductDiscreteModel,tags) -> Vector{Vector{Int8}}

Fetches the tags of the tensor product 1D models corresponding to the tags of the D-dimensional model tags. The length of the output is D

source
GridapROMs.TProduct.get_decompositionMethod
get_decomposition(a::AbstractRankTensor,k::Integer) -> Vector{<:AbstractArray}

For a tensor a of dimension D and rank K assuming the form

$a = \sum\limits_{k=1}^K a_1^k \otimes \cdots \otimes a_D^k$

returns the decomposition relative to the kth rank:

$[a_1^k, \hdots , a_D^k]$

source
GridapROMs.TProduct.tproduct_arrayMethod
tproduct_array(arrays_1d::Vector{<:AbstractArray}) -> Rank1Tensor
tproduct_array(op,arrays_1d::Vector{<:AbstractArray},gradients_1d::Vector{<:AbstractArray},args...) -> GenericRankTensor

Returns a AbstractRankTensor storing the arrays arrays_1d (usually matrices) arising from an integration routine on D 1-d triangulations whose tensor product gives a D-dimensional triangulation. In the absence of the field gradients_1d, the output is a Rank1Tensor; when provided, the output is a GenericRankTensor

tproduct_array(arrays_1d::Vector{<:BlockArray}) -> BlockRankTensor
tproduct_array(op,arrays_1d::Vector{<:BlockArray},gradients_1d::Vector{<:BlockArray},args...) -> BlockRankTensor

Generalization of the previous functions to multi-field scenarios

source