-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tensor type #81
base: ebourne_tensor_tools
Are you sure you want to change the base?
Add tensor type #81
Conversation
It seems like you haven't finished working on this PR so it has been put back into draft. Please remove the draft status when the PR can run tests without being interrupted. |
5ea707d
to
9e3bd05
Compare
a835ed8
to
9a77b48
Compare
{ | ||
tensor_tools::Vector<int, R_cov, Theta_cov> a; | ||
tensor_tools::Vector<int, R, Theta> b; | ||
ddcHelper::get<R_cov>(a) = -6; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You use the function get
to initialise the value ? I would have imagine a set
function ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can also use get
to have a write access.
- if
a
isconst
-qualified thenget
can only provide you a read access, soget<R_cov>(a) = -6
would not compile - if not then
get
can provide both read/write access
Add a type to describe tensor objects. Fixes #75 .
This PR is (almost) equivalent to https://gitlab.maisondelasimulation.fr/gysela-developpers/gyselalibxx/-/merge_requests/852
This PR is based off #77 and must be merged after #77