24 #ifndef SHEAF_DLL_SPEC_H 25 #include "SheafSystem/sheaf_dll_spec.h" 29 #include "SheafSystem/atp.h" 42 template <
typename T0,
typename T1>
43 typename tensor_traits<static_cast<int>(T0::P) - static_cast<int>(T1::P),
typename T0::vector_space_type>::atp_type*
44 hook(
const T0& x0,
const T1& x1)
48 require(precondition_of(
hook(x0, x1, *result)));
52 typedef typename T0::vector_space_type VST;
61 hook(x0, x1, *result);
66 ensure(postcondition_of(
hook(x0, x1, *result)));
70 return reinterpret_cast<return_type*
>(result);
74 template <
typename T0,
typename T1>
76 wedge(
const T0& x0,
const T1& x1)
80 require(precondition_of(
wedge(x0, x1, *result)));
84 typedef typename T0::vector_space_type VST;
93 wedge(x0, x1, *result);
98 ensure(postcondition_of(
wedge(x0, x1, *result)));
102 return reinterpret_cast<return_type*
>(result);
105 template <
typename T0,
typename T1>
107 hook(
const T0& x0,
const T1& x1,
bool xauto_access)
111 require(precondition_of(
hook(x0, x1, *result, xauto_access)));
115 typedef typename T0::vector_space_type VST;
118 return_type* result =
119 reinterpret_cast<return_type*
>(x0.new_atp(x0.p(xauto_access) - x1.p(xauto_access),
122 hook(x0, x1, *result, xauto_access);
127 ensure(postcondition_of(
hook(x0, x1, *result, xauto_access)));
134 template <
typename T0,
typename T1>
136 wedge(
const T0& x0,
const T1& x1,
bool xauto_access)
140 require(precondition_of(
wedge(x0, x1, *result, xauto_access)));
144 typedef typename T0::vector_space_type VST;
147 return_type* result =
148 reinterpret_cast<return_type*
>(x0.new_atp(x0.p(xauto_access) + x1.p(xauto_access), xauto_access));
150 wedge(x0, x1, *result, xauto_access);
155 ensure(postcondition_of(
wedge(x0, x1, *result, xauto_access)));
166 #endif // ifndef ATP_IMPL_H An antisymmetric tensor of degree p over an abstract vector space (volatile version).
SHEAF_DLL_SPEC void wedge(const e2 &x0, const e2 &x1, at2_e2 &xresult, bool xauto_access)
The exterior (wedge) product of two antisymmetric tensors (pre-allocated version for persistent types...
Tensor types of degree P over VECTOR_TYPE. No generic implementation defined, must be specialized for...
SHEAF_DLL_SPEC void hook(const e2 &x0, const e2 &x1, at0 &xresult, bool xauto_access)
The interior (hook) product of two antisymmetric tensors (pre-allocated version for persistent types)...
virtual const atp_lite & atp_prototype(int xp) const
Prototype for antisymmetric tensors of degree xp over this vector space.
Namespace for the fiber_bundles component of the sheaf system.