#include "math.h" #include "aquaterm/aquaterm.h" int main(void){ int i; int an_aqua_terminal; float *x,*y; an_aqua_terminal = aqtInit(); aqtOpenPlot(1); aqtSetPlotSize(400,200); aqtSetPlotTitle("test"); aqtSetBackgroundColor(1.0, 1.0, 1.0); aqtMoveTo(0.0, 0.0); aqtAddLineTo(100.0, 100.0); aqtRenderPlot(); aqtSetLinewidth(5); x = (float *) malloc (100 * sizeof(float)); y = (float *) malloc (100 * sizeof(float)); for (i = 0; i < 100; i++){ x[i] = 4.0 * (float)i; y[i] = 100.0 + 50.0 * sin(0.1 * (float)i); } aqtAddPolyline(x, y, 100); aqtRenderPlot(); return 1; }