Questions tagged [design-patterns]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers

Why do BVP solvers' APIs only allow "unknown" parameters in the derivative and residual functions but not "known" parameters?

I recently needed to solve a second order boundary value problem and noticed that both scipy.integrate.solve_bvp and Matlab's ...
user9794's user avatar
  • 465
2 votes
1 answer

Solving Poisson equations as mixed Laplace using $RT_0-P_0$ pair

I'm trying to solve \begin{cases} - \Delta p=f \text{ in } \Omega\\ p=0 \text{ on } \partial \Omega \end{cases} with in $\Omega = [-1,1]^2$ by writing it as \begin{cases} u + \nabla p=0 \\ -\...
bob_bill's user avatar
1 vote
1 answer

Building blocks for solving a vector valued problem

This question is a follow-up of this previous one. I decided to solve the linear elasticity \begin{cases}- \nabla \sigma(u)=f \\ u=0 \text{ on } \partial \Omega\end{cases} with P1 Lagrangian finite ...
bob_bill's user avatar
1 vote
0 answers

Logging vs outputs in iterative optimisation

I'm coding an iterative algorithm of constrained continuous optimisation. An augmented Lagrangian algorithm (outer) calls a bound-constrained L-BFGS-B algorithm (inner), which calls a line search ...
schrödingcöder's user avatar
1 vote
0 answers

Understanding design patterns [closed]

I read some books and scoured the web about design pattern,but almost all ways of expressing design patterns are the same. They define what is it,draw UML and give an example,but what I want is to ...
Henok Tesfaye's user avatar
15 votes
2 answers

Design patterns in writing numerical software in C++

I'm looking for resources on design patterns and principles for numerical software, potentially but not necessarily with a focus on object-oriented approaches to numerical codes. I am aware of the ...
user1997744's user avatar
1 vote
2 answers

C++ template design pattern for groups (algebra)

Having both programmed my share of c++ and studied some beginners group theory some year ago, I got curious about this... Is there any particularly popular template based (object oriented) design ...
mathreadler's user avatar
11 votes
5 answers

How to deal with complexity in numerical code, for example, when dealing with large Jacobian matrices?

I am solving a non-linear system of coupled equations, and have calculated the Jacobian of the discretised system. The result is really complicated, below are (only!) the first 3 columns of a $3\times ...
boyfarrell's user avatar
  • 5,409