Contact US

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

matlab PDE help needed

matlab PDE help needed

matlab PDE help needed

Need help !!

The partial differential equations to be solved in matlab are:

d(c1)/d(t) + u*d(c1)/dx = D1*(d/dx(d(c1)/d(x)))    (for x=0 to x=1mm)
d(c2)/d(t) + u*d(c2)/dx = D2*(d/dx(d(c2)/d(x)))    (for x=1mm to x=2mm)

the system is from x=0 to x=2 mm with an interface at x=1mm
So, there are two domains left domain(x=0 to x=1mm) and
right domain(x=1 to x=2mm)

C1 and C2 are concentration of the component in domain 1 and domain 2
In the left domain C1(t=0) = 500
In the right domain C2(t=0) = 0

As time starts the component starts to diffuse from domain 1 to 2 through the interface by diffusion

Boundary condition:
At the interface : D1*d(c1)/d(x) = D2*d(c2)/d(x)
At x=0mm : d(c1)/d(x)=0
At x=2mm : d(c2)/d(x)
The values of constants are:

D1=1e-6 (10 raised to the power -6)

Solve for t=0 to t=3or4 seconds

I m new to matlab and don't have much idea about the partial differential equations
i tried but the program had some errors. I need to do it for my project ..but i m stuck...Can someone plz give the code..

Plz help


RE: matlab PDE help needed

The built-in solvers work with ODE's.  PDE's are more challenging.

Is it a homework problem?

(2B)+(2B)'  ?

RE: matlab PDE help needed

your lucky, these equations are de-coupled and they have analytical solutiuons in each domain, subject to the matching conditions at the boundary.

suggest that you first solve the differential equation problem, i.e. set the d/dt terms to null, that will give you the equilibrium result. having done that you'll see your way forward,

as to the homework issue, if it involves solving pde's, most business managers start to roll their eyes and get interested in their cell phones, the common refrain is "gee this is like trigonometry..." oh well, what can you say

good luck  

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members! Already a Member? Login


Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close