Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

MatLab pdepe

  1. Jul 2, 2015 #1

    joshmccraney

    User Avatar
    Gold Member

    Hi PF!

    I am trying to solve a pde in matlab and started by using the generic code mathwork supplies and then augmenting for my purpose. After defining the function below and run the script, i can do anything to the ##f## and nothing changes. I can literally delete the line and still I receive the same plot. Any idea why?
    Code (Text):

    function [c,f,s] = pdex1pde(x,t,u,DuDx)
    c = 1;
    f = DuDx;%pdedu/dx
    s = u;
     
  2. jcsd
  3. Jul 3, 2015 #2

    FactChecker

    User Avatar
    Science Advisor
    Gold Member

    Sometimes when MATLAB compiles a function, it saves the compilation and will not recompile unless it knows the function has changed. Sometimes this goes wrong. I have had to remove compiled files from the directory to force MATLAB to recompile a new version. I forget what extension the compiled file had. I remember that I had a lot of problems when the files were on a network drive. Sometimes modification dates on network drive files do not get updated correctly to indicate a change.
     
  4. Jul 3, 2015 #3

    joshmccraney

    User Avatar
    Gold Member

    Do you know how to remove or where to look to remove compiled files from the directory to force MATLAB to recompile a new version?

    Thanks for taking interest to this!
     
  5. Jul 3, 2015 #4

    FactChecker

    User Avatar
    Science Advisor
    Gold Member

    My memory is vague on this. Look in the same directory with your .m file that defines the function. It will have the same function name but will have a different extension.
     
  6. Jul 5, 2015 #5

    joshmccraney

    User Avatar
    Gold Member

    Thanks a ton!
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: MatLab pdepe
  1. MATLAB problem (Replies: 1)

  2. MATLAB histogram (Replies: 3)

  3. Matlab intro (Replies: 1)

  4. MatLab Plot (Replies: 6)

  5. MATLAB book (Replies: 2)

Loading...