Define and draw the Cartesian vector field:
Initialize
|
•
|
Load the Student VectorCalculus package and execute the BasisFormat command.
|
|
|
Apply the VectorField command with the option "output=plot"
|
|
|
|
The
tutor can be used to draw the vector field in polar coordinates. If the launched tutor is carefully examined, it will be seen that the field is entered as a free vector whose components are those of the field in polar coordinates. The coordinates are then set to polar, with coordinate-variable names and a necessity. If the code at the bottom of the tutor is inspected, it will be seen that the ambient coordinates have to be set to the polar frame and the FlowLine command invoked to draw the field.
Getting the Vector Field tutor to launch on a vector field defined in polar coordinates requires use of the SetCoordinates command to change the ambient coordinates to polar, and the calling of the VectorFieldTutor command with a second argument, a point from which the FlowLine command can integrate a flow line. As yet, no provision has been made for a simple link via the Context Panel.
Define the vector field in polar coordinates
|
|
|
•
|
Use the MapToBasis command to change F to polar coordinates.
|
|
|
•
|
Use the SetCoordinates command to change to, and back from, polar coordinates.
|
|
|
|
|
The VectorFieldTutor command preceded by comment character (#) to prevent it from launching at this point, should the commands in these cells be executed. The tutor that launches with the
button will be in the state that the commands in these cells would provide if they were executed.