On 2017-12-05 13:39-0000 W. Miah wrote:
Hello,
I am trying to draw a 3D contour plot using the following Fortran code:
call PLPARSEOPTS( PL_PARSE_FULL )
call PLSFNAM( 'main_heat.png' )
call PLSDEV( 'pngcairo' )
call PLINIT( )
call PLW3D( 1.0_rp, 1.0_rp, 1.0_rp, 0.0_rp, real( size, kind = rp ), &
0.0_rp, real( size, kind = rp ), &
0.0_rp, 100.0_rp, 90.0_rp, 0.0_rp )
call PLOT3D( x, y, A, DRAW_LINEXY, .true. )
call PLEND( )
However, when I execute my code, I get the following runtime error messages:
*** PLPLOT ERROR, ABORTING OPERATION ***
plw3d: Please set up 2-d window first, aborting operation
*** PLPLOT ERROR, ABORTING OPERATION ***
The documentation for PLW3D doesn't mention that I need to call other
subroutines. Any help will be greatly appreciated.
Hi Wadud:
As a general rule, our standard examples are the best demonstration of
how to combine PLplot subroutine calls together. So if you look in
examples/fortran/x*.f90 you will see that examples/fortran/x11f.f90
has a call to plot3d. In addition, after each call to pladv (which
advances to a new page), there are other important calls to plplot
routines such as plvpor, plwind, plw3d (which you did include above),
and plbox3, before it is possible to call plot3d. So using one page
of example 11 as a model, you should be able to soon get your own
example to work properly.
To see the plot results for example 11 + our code written in a number
of different languages including fortran to generate that plot, take
a look at <http://plplot.org/examples.php?demo=11>.
Documentation for all the PLplot routines I have mentioned can
be found at <http://plplot.org/docbook-manual/plplot-html-5.13.0/>.
Good luck, and let us know how it goes.
Alan
__________________________
Alan W. Irwin
Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).
Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__________________________
Linux-powered Science
__________________________
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Plplot-general mailing list
Plplot-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-general