static void PlotAll (Scene& scene, Plotter& plotter) { Vector x(1,steps), Pot(1,steps); for (int i = 1; i <= steps; i++) { x(i) = xmin + (i-1)*(xmax-xmin)/(steps-1); Pot(i) = V(x(i)); } plotter.clear(); double ymin = -1, ymax = min(6.0,max(1.0,Max(Pot))); // betwwen 1 and 6 !! plotter.axisframe(xmin,xmax,ymin,ymax, "x","V(x), Psi(x)"); plotter.style(plotter.LINES); plotter.plot(x,Pot); // potential scene.Line(xmin,ymin,xmin,ymax); scene.Line(xmax,ymin,xmax,ymax); scene.SetColor(ColorB(255,0,0)); // wave function plotter.plot(x,Psi); scene.SetColor(ColorB(0,0,255)); // eigen energy scene.Line(xmin,E,xmax,E); scene.SetTextStyle(Standard); char label[60]; sprintf(label,"E=%.8g",E); scene.Write(xmin+0.01,E+0.05,label); }
//Function that prints names bool backgroundIntro() { ifstream data; POINT p; Plotter screen; /* HWND consoleWnd = GetConsoleWindow();*/ Sleep(100); //PlaySound("C:\Users\Abril Resendiz\SkyDrive\Documents\ProjectFinal\ProjectFinal\357mag.wav", NULL, SND_ASYNC); screen.setColor(yellow); screen.move(30,23); cout<<"Created By:"; Sleep(2000); Sleep(100); //PlaySound("C:\Users\Abril Resendiz\SkyDrive\Documents\ProjectFinal\ProjectFinal\357mag.wav", NULL, SND_ASYNC); screen.setColor(green); screen.move(30,25); cout<<"Abril Resendiz"; Sleep(2000); // PlaySound("C:\Users\Abril Resendiz\SkyDrive\Documents\ProjectFinal\ProjectFinal\357mag.wav", NULL, SND_ASYNC); screen.setColor(yellow); screen.move(30,27); cout<<"Daniel Holt"; Sleep(2000); // PlaySound("C:\\Users\\Alex\\Desktop\\CB\\ProjectFinal\\357mag.wav", NULL, SND_ASYNC); screen.setColor(green); screen.move(30,29); cout<<"Maggie Schmeltekopf"; Sleep(2000); // PlaySound("C:\\Users\\Alex\\Desktop\\CB\\ProjectFinal\\357mag.wav", NULL, SND_ASYNC); screen.setColor(yellow); screen.move(30,31); cout<<"Victoria Robinson"; Sleep(2000); // PlaySound("C:\Users\Abril Resendiz\SkyDrive\Documents\ProjectFinal\ProjectFinal\\357mag.wav", NULL, SND_ASYNC); screen.setColor(green); screen.move(30,33); cout<<"Emily Peirce"; Sleep(2000); screen.clear(); return exit; }