This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//forward differencing method for rendering curve points | |
int t=20; | |
double space=0.05; | |
double fx,fy,f1x,f2x,f3x,f1y,f2y,f3y; | |
fx=ansMat[3][0]; | |
fy=ansMat[3][1]; | |
f1x= ansMat[0][0]*pow(space,3)+ ansMat[1][0]*pow(space,2)+ansMat[2][0]*space; | |
f2x=6*ansMat[0][0]*pow(space,3)+ 2*ansMat[1][0]*pow(space,2); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
""" | |
Created on Sun Nov 18 23:42:40 2018 | |
@author: yeaseen | |
""" | |
import numpy as np | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
void AddrSpace::loadIntoFreePage(int vpn){ | |
int physicalPageNo=memoryManager->AllocPage(); | |
pageTable[vpn].physicalPage = physicalPageNo; | |
pageTable[vpn].valid = true; | |
bzero(&machine -> mainMemory[(pageTable[vpn].physicalPage) * PageSize], PageSize); | |
NewerOlder