# Model reaction diffusion brusselator 2d matlab

• RiseFox
In summary, the conversation discusses a project involving the model reaction diffusion brusselator 2d. The equations and initial conditions for the project are provided, and there is a discussion about issues with the MATLAB code. The expert advises using array operations and a different approach for handling border cases to improve efficiency. The conversation ends with a realization that it is difficult to find the error without having the code in front of them.
RiseFox
Moved from a technical forum, so homework template missing
Hello, I have a project (model reaction diffusion brusselator 2d)
∂u/∂t=A+u^2v-(B−1)u+D1((∂^2)u/∂(x^2)+(∂^2)u/∂(y^2))
∂v/∂t=Bu−u^2v+D2((∂^2)v/∂(x^2)+(∂^2)v/∂(y^2))

initial conditions:
u(x,y,0) = 0.5 + y,
v(x,y,0) = 1 + 5x.

boundary conditions:
∂u/∂n = 0, ∂v/∂t = 0

n-external normal to the boundary

for numerical experiment:
A=1;B=3.4; D1=D2=2*10-3

I attached .zip with MATLAB code, but it is not working properly for some reason (( pls help me with code (problems with initial conditions)

#### Attachments

• bruss.zip
1.9 KB · Views: 270
RiseFox said:
I attached .zip with MATLAB code, but it is not working properly for some reason (( pls help me with code (problems with initial conditions)
You'll have to describe the problem better than that.

ok, I already found one mistake there was to be no x, y and i, j
Code:
for i =1:n
for j =1:n
u(i,j) = 0.5 + i;
v(i,j) = 1 + 5*j;
end
end

at t = 0
is good,
but in other cases(t=0.25; t=0.75),
my u = NaN go in and I'm stuck at this point

Why is t_max = 0?

While not related to your problem, I must say that your program if not efficient. In the brusselator functions, you should use array operations, not for loops. In laplacian, you should not have a series of ifs for border cases. Use instead a main loop dealing with core points, and then treat the border values independently.

I realized now, even if I knew how to write, since I do not use matlab, and perform calculations have it

## 1. What is the Brusselator model?

The Brusselator model is a mathematical model that describes the dynamics of chemical reactions involving two reactants and two products. It was first proposed by Ilya Prigogine and Robert Lefever in 1959 and is often used as a simplified model for oscillating chemical reactions.

## 2. What is reaction diffusion?

Reaction diffusion is a process in which chemical reactions and diffusion (the movement of particles from areas of high concentration to areas of low concentration) occur simultaneously. This can result in the formation of spatial patterns, such as stripes or spots, in a system.

## 3. How is the Brusselator model used in 2D?

The Brusselator model can be extended to two-dimensional space by adding diffusion terms to the equations. This allows for the simulation of spatial patterns and the study of how they change over time. In 2D, the Brusselator model is often used to model biological systems, such as the development of animal coat patterns.

## 4. What is the role of MATLAB in simulating the Brusselator model?

MATLAB is a programming language and software environment that is commonly used in scientific and engineering applications. It is often used to simulate mathematical models, including the Brusselator model, by numerically solving the equations and visualizing the results.

## 5. What are the applications of the Brusselator model?

The Brusselator model has a wide range of applications in various fields, including chemistry, biology, and physics. It has been used to study pattern formation, chemical reactions, and self-organization in complex systems. It is also used as a teaching tool to demonstrate concepts in reaction kinetics and diffusion processes.

• Engineering and Comp Sci Homework Help
Replies
1
Views
1K
• Engineering and Comp Sci Homework Help
Replies
6
Views
1K
• Engineering and Comp Sci Homework Help
Replies
1
Views
1K
• Engineering and Comp Sci Homework Help
Replies
1
Views
1K
• Engineering and Comp Sci Homework Help
Replies
4
Views
1K
• MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
466
• Engineering and Comp Sci Homework Help
Replies
2
Views
977
• Differential Equations
Replies
13
Views
2K
• Engineering and Comp Sci Homework Help
Replies
1
Views
1K
• Engineering and Comp Sci Homework Help
Replies
1
Views
2K