-
Notifications
You must be signed in to change notification settings - Fork 12
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Summary
The A and B matrix assembly in AngleBasedLSCM::Compute is a large block of nearly-identical per-vertex conditionals repeated three times per face (for e0, e1, e2). This is hard to read and maintain.
Proposed Fix
Extract a helper lambda inside Compute:
auto addContrib = [&](std::size_t row, const EdgePtr& e, T c, T s) {
if (e->vertex == p0) { /* push to tripletsB (fixed p0) */ }
else if (e->vertex == p1) { /* push to tripletsB (fixed p1) */ }
else {
auto freeIdx = freeIdxTable.at(e->vertex->idx);
/* push to tripletsA (free) */
}
};Replace the three repeated per-vertex blocks with calls to addContrib. Add comments linking the structure to the equations in Lévy et al. (2002).
Acceptance Criteria
- No behavioral change — all existing tests pass with bit-identical results
- Face loop body is visibly shorter
Conductor Track
Migrated from GitLab issue #2
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request