nnopinf.operators.LinearAffineSkewTensorOperator#
- class nnopinf.operators.LinearAffineSkewTensorOperator(acts_on, depends_on, skew=True, name='LinearAffineSkewTensorOperator')[source]#
Bases:
Module\(f: (v,x) \mapsto [S_{ijk} - S_{jik}] x_k v_k\)
Constructs a linear affine skew-symmetric tensor operator
- Parameters:
acts_on (nnopinf.Variable) – The state the operators acts on, i.e., the \(x\)
depends_on (tuple of nnopinf.Variable) – The affine variables the operator depends on, i.e., the \(v\)
- skewbool
Constructs a skew-symmetric operator if true, constructs a symmetric operator if false
- namestring
Operator name. Used when saving to file
- forward(inputs, return_jacobian=False)[source]#
Forward pass of operator
Warning
return_jacobian is currently not implemented
- Parameters:
inputs (dict(str, np.array)) – Dictionary of input data in the form of arrays referenced by the variable name, i.e., inputs[‘x’] = np.ones(3)
return_jacobian (bool, optional) – If True, return the (approximate) Jacobian in addition to the output.