Create a 2-D geometry and specify boundary conditions in the PDE
Modeler app, export them to the MATLAB® workspace, and then write the boundary conditions to a file.
Start the PDE Modeler app and draw a unit circle and a unit square.
pdecirc(0,0,1)
pderect([0 1 0 1])
Enter C1-SQ1 in the Set formula
field.
Use the default Dirichlet boundary condition u = 0 for all
boundaries. To verify the boundary condition, switch to boundary mode by selecting Boundary > Boundary Mode. Use Edit > Select all to select all boundaries. Select Boundary > Specify Boundary Conditions and verify that the boundary condition is the Dirichlet condition with
h = 1, r = 0.
Export the geometry and the boundary conditions to the MATLAB workspace by selecting the Export Decomposed Geometry,
Boundary Cond's option from the Boundary
menu.
Decompose the exported geometry into minimal regions. The result is one minimal
region with five edge segments: three circle edge segments and two line edge
segments.
Write the resulting boundary condition matrix to a file. Name the file
boundary.m.
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window.
Web browsers do not support MATLAB commands.
Website auswählen
Wählen Sie eine Website aus, um übersetzte Inhalte (sofern verfügbar) sowie lokale Veranstaltungen und Angebote anzuzeigen. Auf der Grundlage Ihres Standorts empfehlen wir Ihnen die folgende Auswahl: .
Sie können auch eine Website aus der folgenden Liste auswählen:
So erhalten Sie die bestmögliche Leistung auf der Website
Wählen Sie für die bestmögliche Website-Leistung die Website für China (auf Chinesisch oder Englisch). Andere landesspezifische Websites von MathWorks sind für Besuche von Ihrem Standort aus nicht optimiert.