Exporting all solution variables from PDE Toolbox
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Jakub Checinski
am 2 Apr. 2018
Kommentiert: Jakub Checinski
am 2 Apr. 2018
I am solving a DC conductive media problem using the PDE Toolbox. The Plot menu allows me to see both the electric potential and the electric current density, but the Solve->Export Solution button always seem to export a 1D vector containing the electric potential only. How can I get a full solution (both variables) exported?
0 Kommentare
Akzeptierte Antwort
Alan Weiss
am 2 Apr. 2018
I'm afraid that you have to do some post-processing. If your exported solution is u, which is the potential at the nodes, then
[ux,uy] = pdegrad(p,t,u);
gives you the gradients at the triangle centers. To get the interpolated values of the potential at the triangle centers,
ut = pdeintrp(p,t,u);
I don't remember exactly how the gradient relates to the current density, but I think that it is proportional, and the constant of proportionality is related to the conductance, but I don't remember precisely what is the relationship.
Alan Weiss
MATLAB mathematical toolbox documentation
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!