For some reason, when I try to use this function it has a problem passing along the fname input.(adsbygoogle = window.adsbygoogle || []).push({});

For example, I'd type something like :

Field(S, 'names')

------------------------------

This returns an error:

??? Reference to non-existent field 'fname'.

Error in ==> CheckFieldConsistency at 4

[m n] = size(Q(1).fname);

---------------------------------

function output = Field(Q, fname)

k = 0;

[m n] = size(Q(1).fname);

dim = [m n];

Can someone please enlighten me on how I would go about passing this string along into the function to be utilized?

Thank you for your time.

**Physics Forums - The Fusion of Science and Community**

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Structure field *Matlab

Loading...

Similar Threads - Structure field *Matlab | Date |
---|---|

COMSOL - Plane Wave Radiation input not matching Pressure Field | Aug 12, 2014 |

COMSOL - Structural Mechanics - Membrane - vibration without input? | Aug 8, 2014 |

Structure Arrays (matlab) | Jul 30, 2014 |

What is a 3x3 subwindow structure in matlab? | Oct 7, 2011 |

Matlab: Problem with structures | Sep 2, 2011 |

**Physics Forums - The Fusion of Science and Community**