Skip to content

non-plaid mesh #6

Description

@mlp6

This change was a little more involved (no MEX file unfortunately, just straight Matlab). Basically, there are 2 kinds of interpolant classes in matlab, griddedInterpolant and scatteredInterpolant. The gridded version is the one that interpn() uses and requires the matrix to be plaid, etc. The scattered version is the one that griddata() uses, which I think is confusingly named since you don’t need a grid. What’s nice with the scatteredInterpolant is that you just pass in XYZ coordinates and the value at each coordinate, and it figures out the interpolant from there. So basically, in the read_dot_dyn function, you can remove all that meshgrid stuff that happens after the textscan, and just pipe the 4 vectors (X,Y,Z, Val) directly into the interpolation function. I chose to implement this approach using the scatteredInterpolant() rather than griddata(), but either could work.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions