blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
2
247
content_id
stringlengths
40
40
detected_licenses
listlengths
0
57
license_type
stringclasses
2 values
repo_name
stringlengths
4
111
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
58
visit_date
timestamp[ns]date
2015-07-25 18:16:41
2023-09-06 10:45:08
revision_date
timestamp[ns]date
1970-01-14 14:03:36
2023-09-06 06:22:19
committer_date
timestamp[ns]date
1970-01-14 14:03:36
2023-09-06 06:22:19
github_id
int64
3.89k
689M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
25 values
gha_event_created_at
timestamp[ns]date
2012-06-07 00:51:45
2023-09-14 21:58:52
gha_created_at
timestamp[ns]date
2008-03-27 23:40:48
2023-08-24 19:49:39
gha_language
stringclasses
159 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
7
10.5M
extension
stringclasses
111 values
filename
stringlengths
1
195
text
stringlengths
7
10.5M
cc80e9d3511f73375cb2c4bda2dfd7f7e66eb8d5
6b78e5377558d715386382064bdb77cc71cb8025
/Tree_Expr.cpp
f5e08ce906e9aa5c0462452157911f314f40c79b
[]
no_license
nkahile/Tree-Based-Evaluator
1034f5780a2d677be62257e2a698968d76d8ef5f
4077d5088e8b399735887031d9fe56f5f8c5e894
refs/heads/main
2023-05-04T13:23:43.016533
2021-05-24T19:04:57
2021-05-24T19:04:57
365,877,865
1
0
null
null
null
null
UTF-8
C++
false
false
572
cpp
Tree_Expr.cpp
// // Tree_Expr // #include "Tree_Expr.h" // // Tree_Expr // Tree_Expr::Tree_Expr(Expr_Node* root) : root_(root) { } // // ~Tree_Expr // Tree_Expr::~Tree_Expr(void) { } // // Eval // int Tree_Expr::eval(void) { if (nullptr == this->root_) throw std::runtime_error("There is no expression!\n"); root_->accept(evaluateTree_); return evaluateTree_.getResult(); } // // getRoot // Expr_Node* Tree_Expr::getRoot(void) { return root_; } // // setRoot // void Tree_Expr::setRoot(Expr_Node* root) { root_ = root; }
2a77e884070a119524c3d1c43e0b9c9f7f094ced
944f417bcc13e95191b48a62177e4cdab89f675e
/Floor.h
12545d25af5a99973e8dbdd6229dd24e18ab0bd0
[]
no_license
LeonAbi/PAD2
604022c9f16e0c59720416f8f996e6ae38be9ddd
621a9e4d339c4129d79e171cf058098e889335d0
refs/heads/master
2021-01-25T11:39:43.932949
2017-06-28T09:17:25
2017-06-28T09:17:25
93,938,773
1
0
null
null
null
null
UTF-8
C++
false
false
893
h
Floor.h
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ /* * File: Floor.h * Author: stud * * Created on 14. Mai 2017, 17:00 */ #include "Tile.h" #include "Item.h" #include "Active.h" #include "Passive.h" #include "Door.h" #include "Lever.h" #include "Switch.h" #include "Trap.h" #ifndef FLOOR_H #define FLOOR_H class Floor : public Tile { public: Floor(); Floor(Item* item); void onLeave(Tile* toTile) override; void onEnter(Character* c, Tile* fromTile) override; void setItem(Item* item); void setActive(Active* active); void setPassive(Passive* passive); bool isTransparent() override; void print() override; private: Item* m_item; Active* m_active; Passive* m_passive; }; #endif /* FLOOR_H */
802438198a68e1ad781504135209caecafeb70eb
3097f84736cb3f9ee2b7038ead75d258056efcfb
/Engine/engine.cpp
a3291881612852560635fb6ac1a7556f90dc20af
[ "MIT" ]
permissive
patrickvanreck/BAS
b72cef9ac0de961dffd2399829a3f5a9c8d75ccf
2f00806c912e1633f27b6fec3ad0a55b84f1896c
refs/heads/master
2021-05-01T23:43:36.695001
2021-02-12T13:27:25
2021-02-12T13:27:25
77,854,198
0
0
MIT
2021-02-12T13:27:26
2017-01-02T18:41:24
C++
UTF-8
C++
false
false
67
cpp
engine.cpp
#include "engine.h" #include "every_cpp.h" Engine::Engine() { }
5f36af1594d6f352eaa8533b82d9209653295408
5a1c6608e13a4df5c28007be8a21f4de48f42b92
/MP2/SolarSystem/Code/Game/Game.hpp
07f5ae32f070fca5b6f7400adcea902281c7975d
[]
no_license
RollerSimmer/Guildhall-Projects
8bcf52ceb23a0a7f05b06f0613201dcb89c80708
79f59a4d16726cf415eac214d3b4ff280facba08
refs/heads/master
2021-01-19T12:35:03.010982
2017-02-17T23:34:22
2017-02-17T23:34:22
82,342,157
0
0
null
null
null
null
UTF-8
C++
false
false
1,936
hpp
Game.hpp
#pragma once #include "Engine/Renderer/Camera3D.hpp" #include "Engine/Renderer/SpriteSheet.hpp" #include "Game/SceneGraph.hpp" #include "Game/CelestialNode.hpp" const int CURRENT_GAME_VERSION = 0; const float SCREEN_SHAKE_AMOUNT=10.f; const float SCREEN_SHAKE_TIME_SPAN = 0.5f; const float ISOMETRIC_BLOCK_WIDTH_PADDING_FACTOR = 1.2f; const float ISOMETRIC_BLOCK_WIDTH = 50.f; struct SettingsFileData { unsigned int m_version; unsigned int m_seed; Camera3D m_camera; }; class Game { public: Game(); void init(); ~Game(); Camera3D& getCamera() { return m_cam; } void update(float deltaSeconds); void updateScreenShakeTimer(float deltaSeconds); void updateInput(float deltaSeconds); void updateRotationInput(float deltaSeconds); void updatePositionInput(float deltaSeconds); void updateCameraFromMouse(); void updateCamera(); void render(); void doScreenShake(); void goIntoSceneRenderMode(); void goIntoTextRenderMode(); void displayGameDebugInfo(); std::string makeDebugLines(); void displayHUD(); void drawDebugDots(); void startScreenShake(); void toggleDebugGraphics(); void togglePause(); bool isQuitting(); void addDebugDotAt(const Vector3& pos); void initSolarSystem(); void jumpToNextPlanet(); void cycleFocusPlanet(); void lockCameraPositionToPlanet(); bool lookAtFocus(); void updateCurrentFocusBodyMessage(); private: public: private: void doUnitTests(); private: int m_timescale; bool m_isPaused; bool m_isQuittingGame; float m_currentShakeAmount; float m_currentShakeTimeLeft; int m_targetIndex; CelestialNode* m_targetNode; int m_focusIndex; CelestialNode* m_focusNode; SceneGraph m_solarSystem; std::vector<CelestialNode*> m_nodeList; Camera3D m_cam; std::vector<Vector3> m_debugDotPoints; };
8aead6c7604f7d5163bd96b3b02c377a89d75731
eae9f2549574159366947210ddcaf8d049712cb5
/Source/Engine/Render/VertexType.h
7537d109f4ea5a10bcb96b487773de92dd1fce38
[]
no_license
terryjsmith/eternity
899ba87796eb30e12e554a1b62bf38274c221317
cc03ccbcabf574ee3ff9f938b825858f03c7915d
refs/heads/master
2021-01-09T20:18:47.255013
2018-09-11T00:56:47
2018-09-11T00:56:47
124,821,773
3
0
null
null
null
null
UTF-8
C++
false
false
1,263
h
VertexType.h
#ifndef vertextype_h #define vertextype_h #include <eternity.h> enum GIGA_API { VERTEXTYPE_ATTRIB_POSITION = 1, VERTEXTYPE_ATTRIB_COLOR = 1 << 1, VERTEXTYPE_ATTRIB_NORMAL = 1 << 2, VERTEXTYPE_ATTRIB_TEXCOORD0 = 1 << 3, VERTEXTYPE_ATTRIB_TEXCOORD1 = 1 << 4, VERTEXTYPE_ATTRIB_BONES = 1 << 5, VERTEXTYPE_ATTRIB_BONEWEIGHTS = 1 << 6, }; class GIGA_API VertexType { public: VertexType() = default; virtual ~VertexType(); virtual void Initialize() { } virtual void Destroy() { } /** * Add/remove/check for vertex attribute */ void AddVertexAttrib(int attrib, int size, int offset); void RemoveVertexAttrib(int attrib); bool HasVertexAttrib(int attrib); int GetVertexSize() { return m_vertexSize; } /** * Enable a particular vertex attribute (if this vertex type has it) */ virtual void EnableAttribute(int index, int attrib) { } virtual void DisableAttribute(int index) { } /** * Bind/unbind this vertex type */ virtual void Bind() { } virtual void Unbind() { } // Internal vertex attribute layout struct VertexAttrib { int attrib; int size; int offset; }; protected: int m_vertexSize; int m_attribBitmask; std::map<int, VertexAttrib*> m_attribs; }; #endif
590a941beacb6eae5d53ec4b2fa68a6e7540735e
90749adb2756d8ba2fb914cc3acc06b1ac6fa50b
/Auction.cpp
5458c1377a9427b3d991e3b236d5bdba4c2f4d00
[]
no_license
mzhao98/SOCA_code
1dd60c81d939b1e70bdc7dfe8b3cea867f2dd79e
dc6346449d07fb6bd1e069267d8e6ceb3a05f42b
refs/heads/master
2021-07-12T22:04:21.488077
2017-10-19T17:39:26
2017-10-19T17:39:26
107,577,894
0
0
null
null
null
null
UTF-8
C++
false
false
3,018
cpp
Auction.cpp
#include <stdio.h> #include <stdlib.h> #include <math.h> #include <iostream> #include <cmath> using namespace std; struct AA_param_struct{ double N; double R_comm; double max_comm_iter; }; int getEuclideanNorm(int input[], int size){ int sum = 0; int i; for (i = 0; i < size; i++){ sum += (input[i] * input[i]); } return sqrt(sum); } int* auction(double *current_pos, double *xf, int xf_cols, int xf_rows, int *m, double *p, int *j, AA_param_struct AA_param){ double N = AA_param.N; double R_comm = AA_param.R_comm; double max_comm_iter = AA_param.max_comm_iter; int M = xf_cols; int i; int k; if(p == NULL){ p = new int[N][M]; p_old = new int[N][M]; for (i = 0; i < N; i++){ for (k = 0; i < M; i++){ p[i][k] = 0; p_old[i][k] = -1; } } } else{ p_old = p; } if(j == NULL){ j = new int[N]; for (i = 0; i < N; i++){ j[i] = 1; } } c = new int[N][M]; p_temp = new int[N][M]; done = new int[N]; count = new int[N]; m_new = new int[N]; for (i = 0; i < N; i++){ done[i] = 0; count[i] = 0; m_new[i] = 0; for (k = 0; i < M; i++){ c[i][k] = 0; p_temp[i][k] = -1; } } int norm_input[2]; int l; for (i = 0; i < N; i++){ for (k = 0; i < M; i++){ for(l = 0; l < xf_rows; l++){ norm_input[l] = current_pos[l][i] - xf[l][k]; } c[i][k] = pow(getEuclideanNorm(norm_input),2); } } int done[3] = {0, 0, 0}; while(1){ int anyNotDone = 0; for (i = 0; i < 3; i++){ if (done[i]==0){ anyNotDone = 1; break; } } if(anyNotDone == 0){ break; } for(i = 0; i < N; i++){ if (done[i]==0){ int p_input[N] = p[i]; int c_input[N] = c[i]; int p_old_input[N] = c[i]; int j_input = j[i]; int m_input = m[i]; int m_new_input = m_new[i]; int count_input = count[i]; AA_bid(c_input, p_input, p_old_input, j_input, m_input, m_new_input, count_input); p[i] = p_input[N]; j[i] = j_input; m[i] = m_input; m_new[i] = m_new_input; count[i] = count_input; p_old[i] = p[i]; done[i] = (count[i]>max_comm_iter); } } for(i = 0; i < N; i++){ int r; int Neighbors[N] = new int[N]; for (r = 0; r < N; r++){ Neighbors[r] = pow((current_pos[1][i] - current_pos[1][r]),2); } } } return xf; } int main(){ //double* current_pos = malloc(sizeof(double)*2*3); double current_pos[2][3] = {1, 2, 3}, {2, 3, 4}; double xf[2][3] = {2, 3, 4}, {3, 4, 5}; int m[3] = {2, 2, 2}; double p[3][3] = {0.003, 0.005, -0.001}, {0.003, 0.005, -0.001}, {0.003, 0.005, -0.001}; int j[3] = {1, 1, 1}; AA_param_struct AA_param; AA_param.N = 3; AA_param.R_comm = 10; AA_param.max_comm_iter = 5; double* final_pos = Auction(current_pos,xf, 3, 2, m,p,j,AA_param); int i; int j; for(i = 0; i < 2; i++){ for(j = 0; j < 3; i++){ printf("final_pos %d: %f\n", i, final_pos[i][j]); } } for(i = 0; i < 3; i++){ printf("m %d: %f\n", i, m[i]); } for(i = 0; i < 3; i++){ for(j = 0; j < 3; i++){ printf("p %d: %f\n", i, p[i][j]); } } }
b859f1b93b5b5d22a8ee45f0bdfd5a27271ee58e
bd3c003756e4122bf677f3550a6ddb4888828550
/programs/2_3Tree/Node.h
5dbaed4acd01bdf7e416e8d27e4aa1cbef46bc20
[]
no_license
flacopaco/CS014-Introduction-to-Data-Structures-and-Algorithms
ff5ae0f3730c354bfd211c0142a8fee75b38cf14
badde76d4ba78bad2ad7c54039780bdba5fc8729
refs/heads/master
2022-07-01T11:15:31.447788
2020-05-13T10:01:12
2020-05-13T10:01:12
263,590,875
0
0
null
null
null
null
UTF-8
C++
false
false
856
h
Node.h
#ifndef __NODE_H #define __NODE_H #include <string> using namespace std; class Node { friend class Tree; private: string small; string large; int counter; Node *left; Node *middle; Node *right; Node *parent; public: Node(); Node(string, Node *); Node(string, string, Node *); bool isFull() const; bool isLeaf() const; bool maxChildren() const; void changeCounter(int count); void addValue(string add); void addChild(Node *); Node * swapSuccessor(const string &); bool empty() const; Node * rightSibling() const; Node * leftSibling() const; void removeValue(const string &); void transferChildren(Node *); Node * findSuccessor() const; string validToRedistribute() const; // Add additional functions/variables here. Remember, you may not add any // Node * or string variables. }; #endif
505962feb2a05d877a674888547e1319980daf27
6cf018e10e98a675651b3d2688618ed137483155
/woj/woj1288.cpp
c3ded0080dab6790468bbc64bfec5cd43d4f3c73
[]
no_license
GonewithGt/woj
41e29837fe755b6da0bfdcc67017b49f8eb85fce
e955371ab5b5ba5b7a938ae4895d84bc13926a10
refs/heads/master
2021-01-10T16:42:33.656851
2017-03-17T14:22:40
2017-03-17T14:22:40
52,983,297
2
0
null
null
null
null
UTF-8
C++
false
false
599
cpp
woj1288.cpp
#include<iostream> #include<algorithm> #include<cstdlib> using namespace std; int main(){ int gt=0,j=0; cin >> gt; for(j=0;j<gt;j++) { string a,b; int k; cin >> a >> b >> k; int l = a.length(); int s[l]; long int res = 0; for (int i=0; i<l; i++) { s[i] = abs(a[i]-b[i]); res += s[i]; } sort(s,s+l); for(int i=l-1; i>(l-1-k); --i){ res -= (s[i]==0) ? -1 :s[i] ; } cout << res <<endl; } return 0; }
9a14010cc3b5effd47a62effa09807472391a902
71c4bb0b40c5e2366e4291073189858e8bc4f979
/relasi.cpp
b86584c04b8996176927a3e5609c9521729c6a33
[]
no_license
Bagasarfiansyah007/Tugas-Besar-Struktur-Data
79ce3c306c2473f5db31ea859be505afdbcd9dc5
8b3fef294930c411f84fd74941ddd390628147b9
refs/heads/master
2021-05-19T17:22:00.534178
2017-04-14T11:43:28
2017-04-14T11:43:28
null
0
0
null
null
null
null
UTF-8
C++
false
false
20,283
cpp
relasi.cpp
#include "relasi.h" void createList_relasi(List_relasi &L){ first_relasi(L)=NULL; } address_relasi alokasi_relasi(address_maba PM, address_jurusan PJ){ address_relasi P = new elmList_relasi; kejurusan(P)= PJ; kemaba(P)=PM; next_relasi(P)= NULL; return P; } void dealokasi_relasi(address_relasi &P){ delete P; } void insertFirst_relasi(List_relasi &L, address_relasi P){ if(first_relasi(L)==NULL){ first_relasi(L)=P; next_relasi(first_relasi(L))=first_relasi(L); prev_relasi(first_relasi(L))=first_relasi(L); } else{ address_relasi Q=prev_relasi(first_relasi(L)); if(next_relasi(first_relasi(L))==first_relasi(L)){ next_relasi(P)=first_relasi(L); prev_relasi(P)=Q; next_relasi(Q)=P; prev_relasi(Q)=P; first_relasi(L)=P; } else{ next_relasi(P)=first_relasi(L); prev_relasi(P)=Q; prev_relasi(first_relasi(L))=P; next_relasi(Q)=P; first_relasi(L)=P; } } } void insertLast_relasi(List_relasi &L, address_relasi P){ if(first_relasi(L)==NULL){ first_relasi(L)=P; next_relasi(first_relasi(L))=first_relasi(L); prev_relasi(first_relasi(L))=first_relasi(L); } else{ address_relasi Q=prev_relasi(first_relasi(L)); prev_relasi(P)=Q; prev_relasi(first_relasi(L))=P; next_relasi(P)=first_relasi(L); next_relasi(Q)=P; } } address_relasi findElm_relasi(List_relasi L, address_maba PM, address_jurusan PJ){ address_relasi P = first_relasi(L); bool found = false; if (first_relasi(L) != NULL){ while ((next_relasi(P)!=NULL)&&(found == false)){ if (kemaba(P) == PM&& kejurusan(P) == PJ){ found = true; return P; }else{ P=next_relasi(P); } } } else{ P=NULL; } return P; } void deleteFirst_relasi(List_relasi &L, address_relasi &P){ if(first_relasi(L)!=NULL){ P=first_relasi(L); if(next_relasi(first_relasi(L))==first_relasi(L)){ first_relasi(L)=NULL; } else{ address_relasi Q=prev_relasi(first_relasi(L)); first_relasi(L)=next_relasi(P); prev_relasi(first_relasi(L))=Q; next_relasi(Q)=first_relasi(L); next_relasi(P)=NULL; prev_relasi(P)=NULL; } } else{ cout<<"Data kosong"<<endl; } } void deleteLast_relasi(List_relasi &L, address_relasi &P){ if(first_relasi(L)!=NULL){ if(next_relasi(first_relasi(L))==first_relasi(L)){ P=first_relasi(L); createList_relasi(L); } else{ address_relasi Q=prev_relasi(prev_relasi(first_relasi(L))); P=next_relasi(Q); next_relasi(Q)=first_relasi(L); prev_relasi(first_relasi(L))=Q; next_relasi(P)=NULL; prev_relasi(P)=NULL; } } else{ cout<<"Data kosong"<<endl; } } void print_relasi(List_relasi L){ address_relasi P; if (first_relasi(L) == NULL){ cout << "=========================================================================" << endl; cout << "\t\t Daftar Jurusan yang dipilih Mahasiswa" << endl; cout << "=========================================================================" << endl; cout<<endl; cout<<"\t Belum Ada Mahasiswa Baru yang Memilih Jurusan\n"<<endl; } else{ cout << "=========================================================================" << endl; cout << "\t\t Daftar Jurusan yang dipilih Mahasiswa" << endl; cout << "=========================================================================" << endl; cout << "Nama Mahasiswa \t\t| Asal SMA \t\t| Jurusan \t\t|" << endl; cout << "=========================================================================" << endl; P = first_relasi(L); while (next_relasi(P) != first_relasi(L)){ cout<<info_maba(kemaba(P)).nama<<" \t\t| "<<info_maba(kemaba(P)).asal_sma<<" "<<info_maba(kemaba(P)).alamat<<"\t| "<<info_jurusan(kejurusan(P)).jurusan_kul<<"\t|"; cout<<endl; P = next_relasi(P); } cout<<info_maba(kemaba(P)).nama<<" \t\t| "<<info_maba(kemaba(P)).asal_sma<<" "<<info_maba(kemaba(P)).alamat<<"\t| "<<info_jurusan(kejurusan(P)).jurusan_kul<<"\t|"; cout<<endl; } } void insertAfter_relasi(List_relasi &L, address_relasi prec, address_relasi &P){ if (first_relasi(L) == NULL){ first_relasi(L) = P; } else{ next_relasi(P) = next_relasi(prec); next_relasi(prec) = P; } } void deleteAfter_relasi(address_relasi Prec, address_relasi &P){ P=next_relasi(Prec); prev_relasi(next_relasi(P))=prev_relasi(P); next_relasi(Prec)=next_relasi(P); next_relasi(P)=NULL; prev_relasi(P)=NULL; } void delete_relasi(List_relasi &L, address_relasi &P){ address_relasi Q, Prec; if(P!=NULL){ Q=first_relasi(L); do{ Q=next_relasi(Q); }while (next_relasi(Q)!= first_relasi(L)); //Q=next_relasi(Q); if(P==first_relasi(L)){ if(next_relasi(P)==first_relasi(L)){ first_relasi(L)=NULL; } else{ deleteFirst_relasi(L, P); //P=first_relasi(L); } } else if(P==Q){ deleteLast_relasi(L, P); //P=Q; } else{ Prec = prev_relasi(P); deleteAfter_relasi(Prec, P); //P=Prec; } //dealokasi_relasi(P); } } void deleteSearch_relasi(List_relasi &L, address_relasi &P){ address_relasi Q, Prec; if(P!=NULL){ Q=first_relasi(L); while (next_relasi(Q)!= first_relasi(L)){ Q=next_relasi(Q); } Q=next_relasi(Q); if(P==first_relasi(L)){ if(next_relasi(P)==first_relasi(L)){ first_relasi(L)=NULL; } else{ deleteFirst_relasi(L, P); P=first_relasi(L); } } else if(P==Q){ deleteLast_relasi(L, P); P=Q; } else{ Prec = prev_relasi(P); deleteAfter_relasi(Prec, P); P=Prec; } //dealokasi_relasi(P); } } void delete_maba(List_relasi &LR, List_maba &LM, address_maba &PM){ address_relasi P=first_relasi(LR); if(first_relasi(LR)!=NULL){ do{ if(kemaba(P)==PM){ deleteSearch_relasi(LR, P); } P=next_relasi(P); } while(next_relasi(P)!=first_relasi(LR)); if(kemaba(P)==PM){ deleteSearch_relasi(LR, P); } } deleteSearch_maba(LM, PM); } void delete_jurusan(List_relasi &LR, List_jurusan &LJ, address_jurusan &PJ){ address_relasi P=first_relasi(LR); if(first_relasi(LR)!=NULL){ do{ if(kejurusan(P)==PJ){ deleteSearch_relasi(LR, P); } P=next_relasi(P); }while(next_relasi(P)!=first_relasi(LR)); if(kejurusan(P)==PJ){ deleteSearch_relasi(LR, P); } } deleteSearch_jurusan(LJ, PJ); } void input_relasi(List_maba LM, List_jurusan LJ, List_relasi &LR){ address_maba PM; address_jurusan PJ; address_relasi PR; maba mdicari; jurusan jdicari; printInfo_maba(LM); cout<<"Nama Mahasiswa : "; cin.ignore(); getline(cin,mdicari.nama); PM=findElm_maba(LM,mdicari.nama); if (PM!=NULL){ system("cls"); printInfo_jurusan(LJ); cout<<"Nama Mahasiswa : "<<mdicari.nama<<endl; cout<<"Jurusan yang ingin dipilih : "; getline(cin, jdicari.jurusan_kul); PJ=findElm_jurusan(LJ, jdicari.jurusan_kul); if (PJ!=NULL){ PR=alokasi_relasi(PM,PJ); insertLast_relasi(LR,PR); cout<<endl; cout<<"Mahasiswa Baru Berhasil Memilih Jurusan"<<endl; } else{ cout<<endl; cout<<"Jurusan tersebut tidak tersedia dalam pilihan"<<endl; } } else{ cout<<"Data Mahasiswa Baru tidak ditemukan"<<endl; } } address_relasi find_relasi(List_relasi L, string x, string y){ bool cek; address_relasi P; if(first_relasi(L)!=NULL){ cek=false; P=first_relasi(L); while((cek==false)&&(next_relasi(P)!=first_relasi(L))){ if(info_maba(kemaba(P)).nama == x){ if(info_jurusan(kejurusan(P)).jurusan_kul == y){ cek=true; return P; } } else{ P=next_relasi(P); } } if (cek == false){ if(info_maba(kemaba(P)).nama == x){ if(info_jurusan(kejurusan(P)).jurusan_kul == y){ cek=true; } } } } if(cek!=true){ return P=NULL; } return P; } void menu (List_maba LM, List_jurusan LJ, List_relasi LR) { int pil; maba mdicari; jurusan jdicari; address_maba PM; address_jurusan PJ; address_relasi PR; data_maba (LM); data_jurusan (LJ); data_relasi(LR, LM, LJ); do { system("cls"); cout << "==================================================" << endl; cout << "\tAplikasi Penerimaan Mahasiswa Baru" << endl; cout << "==================================================" << endl; cout << " -- INPUT -- " << endl; cout << "1. Pendaftaran Mahasiswa Baru" << endl; cout << "2. Tambah Jurusan Baru" << endl; cout << "3. Pemilihan Jurusan Mahasiswa Baru" << endl; cout << " -- EDIT -- " << endl; cout << "4. Ubah Data Mahasiswa" << endl; cout << "5. Ubah Profile Jurusan" << endl; cout << " -- VIEW -- " << endl; cout << "6. Lihat Mahasiswa yang telah terdaftar" << endl; cout << "7. Lihat Jurusan" << endl; cout << "8. Lihat Jurusan yang dipilih Mahasiswa Baru" << endl; cout << " -- DELETE -- " << endl; cout << "9. Hapus Data Mahasiswa" << endl; cout << "10. Hapus Profile Jurusan" << endl; cout << "11. Hapus Pilihan Jurusan Mahasiswa" << endl; cout << " -- SEARCHING -- " << endl; cout << "12. Cari Data Mahasiswa" << endl; cout << "13. Cari Profile Jurusan" << endl; cout<<endl; cout << "0. Exit " << endl; cout<<endl; cout << "Masukkan Pilihan : "; cin >> pil; switch(pil){ case 1: system("CLS"); cout << "==================================================" << endl; cout << "\tPendaftaran Mahasiswa Baru" << endl; cout << "==================================================" << endl; PM=input_maba(); insertLast_maba(LM,PM); cout<<endl; cout<<"Mahasiswa Baru Berhasil terdaftar"<<endl; cout<<endl; system("pause"); break; case 2: system("CLS"); cout << "==================================================" << endl; cout << "\t\tTambah Jurusan Baru" << endl; cout << "==================================================" << endl; PJ=input_jurusan(); insertLast_jurusan(LJ,PJ); cout<<endl; cout<<"Jurusan Berhasil ditambahkan"<<endl; cout<<endl; system("pause"); break; case 3: system("cls"); input_relasi(LM,LJ,LR); cout<<endl; system("pause"); break; case 4: system("Cls"); printInfo_maba(LM); cout<<"Masukkan Nama Mahasiswa yang ingin diubah: "; cin.ignore(); getline(cin,mdicari.nama); PM=findElm_maba(LM,mdicari.nama); if(PM!=NULL){ cout<<"Data Mahasiswa ditemukan"<<endl; system("PAUSE"); system("CLS"); editInfo_maba(LM,PM); cout<<"Data Mahasiswa Berhasil diubah"<<endl; } else{ cout<<"Data Mahasiswa tidak ditemukan"<<endl; } system("PAUSE"); break; case 5: system("cls"); printInfo_jurusan(LJ); cout<<"Masukkan Jurusan yang ingin diubah: "; cin.ignore(); getline(cin,jdicari.jurusan_kul); PJ=findElm_jurusan(LJ,jdicari.jurusan_kul); if(PM!=NULL){ cout<<"Profile Jurusan ditemukan"<<endl; system("cls"); editInfo_jurusan(LJ,PJ); cout<<"Profile Jurusan Berhasil diubah"<<endl; } else{ cout<<"Tidak ada data jurusan tersebut"<<endl; } system("pause"); break; case 6: system("CLS"); printInfo_maba(LM); system("PAUSE"); break; case 7: system("CLS"); printInfo_jurusan(LJ); system("PAUSE"); break; case 8: system("cls"); print_relasi(LR); system("PAUSE"); break; case 9: system("Cls"); printInfo_maba(LM); cout<<"Masukkan Nama Mahasiswa yang ingin dihapus: "; cin.ignore(); getline(cin,mdicari.nama); PM=findElm_maba(LM,mdicari.nama); if(PM!=NULL){ delete_maba(LR, LM, PM); cout<<endl; cout<<"Data Mahasiswa Berhasil dihapus"<<endl; cout<<endl; } else{ cout<<endl; cout<<"Data Mahasiswa tidak ditemukan"<<endl; cout<<endl; } system("PAUSE"); break; case 10: system("cls"); printInfo_jurusan(LJ); cout<<"Masukkan Jurusan yang ingin dihapus: "; cin.ignore(); getline(cin,jdicari.jurusan_kul); PJ=findElm_jurusan(LJ,jdicari.jurusan_kul); if(PJ!=NULL){ delete_jurusan(LR,LJ, PJ); cout<<endl; cout<<"Profile Jurusan Berhasil dihapus"<<endl; cout<<endl; } else{ cout<<endl; cout<<"Profile Jurusan tidak ditemukan"<<endl; cout<<endl; } system("PAUSE"); break; case 11: system("cls"); print_relasi(LR); cout<<"Masukkan Nama Mahasiswa yang ingin dihapus: "; cin.ignore(); getline(cin,mdicari.nama); cout<<"Masukkan Jurusan yang ingin dihapus: "; getline(cin,jdicari.jurusan_kul); PR = find_relasi(LR, mdicari.nama, jdicari.jurusan_kul); if(PR != NULL){ delete_relasi(LR, PR); cout<<"Data berhasil dihapus"<<endl; } else{ cout<<"Data tidak ditemukan"<<endl; } system("pause"); break; case 12: system("cls"); printInfo_maba(LM); cout<<"Masukkan Nama Mahasiswa yang dicari: "; cin.ignore(); getline(cin,mdicari.nama); PM=findElm_maba(LM, mdicari.nama); if(PM!=NULL){ cout<<endl; search_maba(LM, LR, PM); cout<<endl; } else{ cout<<"\nMahasiswa Baru tidak ditemukan\n"<<endl; } system("pause"); break; case 13: system("cls"); printInfo_jurusan(LJ); cout<<"Masukkan Jurusan yang dicari: "; cin.ignore(); getline(cin,jdicari.jurusan_kul); PJ=findElm_jurusan(LJ, jdicari.jurusan_kul); if(PM!=NULL){ cout<<endl; cout<<"Mahasiswa Yang Memilih Jurusan "<<jdicari.jurusan_kul<<" : "<<endl; search_jurusan(LJ, LR, PJ); cout<<endl; } else{ cout<<"\nJurusan tidak ditemukan\n"<<endl; } system("pause"); break; case 0: cout<<"\nTerima Kasih Telah Menggunakan Aplikasi Penerimaan Mahasiswa Baru\n"<<endl; system("PAUSE"); break; default: cout<<endl; cout << "Angka yang anda masukkan salah, silakan masukkan angka dari 0 - 13" << endl; cout<<endl; system("PAUSE"); break; } }while (pil!=0); } void search_maba(List_maba LM, List_relasi LR, address_maba PM){ address_relasi PR=first_relasi(LR); int i=0; while (next_relasi(PR) != first_relasi(LR)){ if(info_maba(PM).nama == info_maba(kemaba(PR)).nama){ i++; cout<<"Pilihan ke-"<<i<<" : "<<info_jurusan(kejurusan(PR)).jurusan_kul<<endl; } PR = next_relasi(PR); } if(info_maba(PM).nama == info_maba(kemaba(PR)).nama){ i++; cout<<"Pilihan ke-"<<i<<" : "<<info_jurusan(kejurusan(PR)).jurusan_kul<<endl; } if(i==0){ cout<<"Mahasiswa Ini Belum Memilih Jurusan"<<endl; } } void search_jurusan(List_jurusan LJ, List_relasi LR, address_jurusan PJ){ address_relasi PR=first_relasi(LR); int i=0; while (next_relasi(PR) != first_relasi(LR)){ if(info_jurusan(PJ).jurusan_kul == info_jurusan(kejurusan(PR)).jurusan_kul){ i++; cout<<i<<". "<<info_maba(kemaba(PR)).nama<<endl; } PR = next_relasi(PR); } if(info_jurusan(PJ).jurusan_kul == info_jurusan(kejurusan(PR)).jurusan_kul){ i++; cout<<i<<". "<<info_maba(kemaba(PR)).nama<<endl; } if(i==0){ cout<<"Belum Ada Mahasiswa yang Memilih Jurusan Ini"<<endl; } } void data_relasi (List_relasi &L, List_maba LM, List_jurusan LJ){ address_relasi P; address_maba PM; address_jurusan PJ; PM=findElm_maba(LM, "ANDREA HIRATA"); PJ=findElm_jurusan(LJ, "S1 MANAJEMEN BISNIS"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "JOKO WIDODO"); PJ=findElm_jurusan(LJ, "S1 TEKNIK INFORMATIKA"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "RADITYA DIKA"); PJ=findElm_jurusan(LJ, "S1 ILMU KOMUNIKASI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "TERE LIYE"); PJ=findElm_jurusan(LJ, "S1 ILMU KOMUNIKASI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "PIDI BAIQ"); PJ=findElm_jurusan(LJ, "S1 TEKNIK ELEKTRO"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "OKI SETIANA"); PJ=findElm_jurusan(LJ, "S1 SISTEM INFORMASI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "RADITYA DIKA"); PJ=findElm_jurusan(LJ, "S1 DESAIN PRODUK"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "JOKO WIDODO"); PJ=findElm_jurusan(LJ, "S1 TEK TELEKOMUNIKASI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "ASMA NADIA"); PJ=findElm_jurusan(LJ, "S1 SISTEM INFORMASI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "JOKO WIDODO"); PJ=findElm_jurusan(LJ, "S1 TEKNIK INDUSTRI"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "NADIM MAKARIM"); PJ=findElm_jurusan(LJ, "S1 MANAJEMEN BISNIS"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); PM=findElm_maba(LM, "TERE LIYE"); PJ=findElm_jurusan(LJ, "S1 TEKNIK INFORMATIKA"); P=alokasi_relasi(PM,PJ); insertLast_relasi(L,P); }
2fb84e77f868497de39c6472bdbe53d4d4b6af12
09980c070c09f633dde5d2c681b978ac1ac42b45
/addIntToStartOfList.cpp
624862f8d909ffe86652be65a4b62de3df2390ba
[]
no_license
adiltruong/lab06_adiltruong_syang1297
2ef2731584b5e39cc215c5bac3da438a88aa41e2
dad9e1c5dc15f7820c5ae3a1f86d6994ce033e43
refs/heads/master
2021-01-21T09:07:03.374177
2017-02-23T01:44:38
2017-02-23T01:44:38
82,865,115
0
0
null
null
null
null
UTF-8
C++
false
false
410
cpp
addIntToStartOfList.cpp
//addIntToEndOfList.cpp //Date: February 22, 2017 //Authors: A Truong & S Yang //addIntToEndOfList.cpp takes an integer and adds it to the end of a linked list #include "linkedListFuncs.h" #include "tddFuncs.h" #include <iostream> using namespace std; int main () { struct Node { int data; Node *next; }; Node n1; n1*data= 10; n1*next= NULL; Node * head= new Node; head-> data= 20; head-> next= NULL;
b8bded46a5bf4bee35cc3b9e1bd50fd4dcf62a8b
d33b232ae41dcca316c590f35d59209176ab185d
/Sources/Internal/Platform/TemplateAndroid/JniExtensions.cpp
5689aa06acb587ba81a7520e546e7a30f64803d8
[]
no_license
dominik111/dava.framework
fd10e75cb76090301dd765de3885fe7f62570e75
3650cb7541bad8188d0ac043a804f3eea99b972b
refs/heads/master
2021-01-17T22:59:46.358803
2013-10-11T14:20:14
2013-10-11T14:20:14
null
0
0
null
null
null
null
UTF-8
C++
false
false
3,601
cpp
JniExtensions.cpp
/*================================================================================== Copyright (c) 2008, DAVA, INC All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the DAVA, INC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE DAVA, INC AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL DAVA, INC BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. =====================================================================================*/ #include "JniExtensions.h" #include "Platform/TemplateAndroid/CorePlatformAndroid.h" namespace DAVA { JniExtension::JniExtension() { //Logger::Debug("JniExtension::JniExtension(%s)", GetJavaClassName()); CorePlatformAndroid *core = (CorePlatformAndroid *)Core::Instance(); AndroidSystemDelegate* delegate = core->GetAndroidSystemDelegate(); vm = delegate->GetVM(); jint res = JNI_OK; if (Thread::IsMainThread()) { res = vm->GetEnv((void **)&env,JNI_VERSION_1_6); } else { res = vm->AttachCurrentThread(&env, NULL); if (res != JNI_OK) { Logger::Error("Failed to AttachCurrentThread: res:%d", res); } } if (res != JNI_OK) { Logger::Error("Failed to get the environment using GetEnv()"); env = NULL; } } JniExtension::~JniExtension() { //Logger::Debug("JniExtension::~JniExtension(%s)", GetJavaClassName()); if (!Thread::IsMainThread()) { jint res = vm->DetachCurrentThread(); Logger::Error("Failed to DetachCurrentThread: res:%d", res); } } void JniExtension::SetJavaClass(JNIEnv* env, const char* className, jclass* gJavaClass, const char** gJavaClassName) { *gJavaClass = (jclass) env->NewGlobalRef(env->FindClass(className)); if (gJavaClassName) *gJavaClassName = className; } jmethodID JniExtension::GetMethodID(const char *methodName, const char *paramCode) const { jclass javaClass = GetJavaClass(); DVASSERT(javaClass && "Not initialized Java class"); if (!javaClass) return 0; jmethodID mid = env->GetStaticMethodID(javaClass, methodName, paramCode); if (!mid) { Logger::Error("get method id of %s.%s error ", GetJavaClassName(), methodName); } return mid; } Rect JniExtension::V2P(const Rect& srcRect) const { Vector2 offset = Core::Instance()->GetPhysicalDrawOffset(); float32 v2p = Core::Instance()->GetVirtualToPhysicalFactor(); Rect rect = srcRect; rect.x *= v2p; rect.y *= v2p; rect.dx *= v2p; rect.dy *= v2p; rect += offset; return rect; } }//namespace DAVA
02323f2cad277d2614d3b562f90d29f21b4afcbb
aa0a6e0c4c4a12ee2bf19b96207f5ae83f91bdd1
/tools/tiling_test/tiling_test.cc
430edee6b1af27a89fedcbf3c8ed3f1c8fad8203
[ "MIT" ]
permissive
nicuveo/MML
9ba661db25753d93fe45e47317daee1dba803fbf
b877a65abb61ea2fe6d8407b50f44fd170fb748d
refs/heads/master
2021-01-10T19:32:42.725957
2015-10-04T07:48:08
2015-10-04T07:48:08
3,950,730
0
0
null
null
null
null
UTF-8
C++
false
false
5,978
cc
tiling_test.cc
// // Copyright Antoine Leblanc 2010 - 2015 // Distributed under the MIT license. // // http://nauths.fr // http://github.com/nicuveo // mailto://antoine.jp.leblanc@gmail.com // //HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH // Includes #include <fstream> #include <iomanip> #include <iostream> #include "nauths/mml/mml.hh" #include "img/io/tga.hh" //HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH // Local code namespace { // types typedef mml::shapes<int>::Shape Shape; typedef mml::shapes<int>::Point Point; typedef mml::shapes<int>::Rect Rect; typedef mml::Tessellation<int> Tessellation; typedef tools::Bitmap Bitmap; typedef tools::Color Color; typedef tools::Bitmap::size_type size_type; // constants const int IMW = 1200; const int IMH = 900; const int DIA = 280; const int REF_SIZE = 380; const int MOT_SIZE = 100; const int FACT = 4; const int AA = 1; const char* OUT = "out/tess.tga"; //const Shape REF = Shape::reg_heptagon(FACT * IMW / 2, FACT * IMH / 2, FACT * DIA, mml::pi() / 2); const Shape REF = Shape::circle(FACT * IMW / 2, FACT * IMH / 2, FACT * REF_SIZE); const Tessellation TESS = Tessellation(mml::tiling::RHOMBITRIHEXAGONAL, REF, 150 * FACT, 240 * FACT, FACT * MOT_SIZE, 0.); // scale // scales a bitmap, blending colours Bitmap scale(Bitmap const& in) { assert(in.width() % FACT == 0); assert(in.height() % FACT == 0); assert(in.width() == FACT * IMW); assert(in.height() == FACT * IMH); Bitmap res(IMW, IMH); const int r_min = -AA; const int r_max = FACT + AA; const float k = 1.f / std::pow(FACT + 2 * AA, 2); for (size_type y = 0; y < size_type(IMH); y += 1) for (size_type x = 0; x < size_type(IMW); x += 1) { float c[3] = { 0, 0, 0 }; for (int dy = r_min; dy < r_max; ++dy) for (int dx = r_min; dx < r_max; ++dx) { size_type rx = std::max<size_type>(std::min<size_type>(FACT * x + dx, in.width() - 1), 0); size_type ry = std::max<size_type>(std::min<size_type>(FACT * y + dy, in.height() - 1), 0); const Color& color = in.at(rx, ry); c[0] += color.rf() * k; c[1] += color.gf() * k; c[2] += color.bf() * k; } res(x, y) = Color::rgbf(c[0], c[1], c[2]); // Color color = Color::rgbf(c[0], c[1], c[2]); // std::cout << "res[" // << std::dec << std::setfill(' ') << std::setw(4) << x // << ", " // << std::dec << std::setfill(' ') << std::setw(4) << y // << "]: <- #" // << std::hex << std::setfill('0') << std::setw(2) << int(color.r()) // << std::hex << std::setfill('0') << std::setw(2) << int(color.g()) // << std::hex << std::setfill('0') << std::setw(2) << int(color.b()) // << std::endl; } return res; } // add // add two rgb colors Color add(const Color& c1, const Color& c2) { return Color::rgb( std::min(int(c1.r()) + int(c2.r()), 255), std::min(int(c1.g()) + int(c2.g()), 255), std::min(int(c1.b()) + int(c2.b()), 255)); } // draw_shape // draws a shape on the bitmap void draw_shape(Bitmap& b, const Shape& s, const Color& c) { const Rect bb = s.bounding_rect(); const size_type xmin = std::max<size_type>(bb.x_min(), 0); const size_type ymin = std::max<size_type>(bb.y_min(), 0); const size_type xmax = std::min<size_type>(bb.x_max(), b.width() - 1); const size_type ymax = std::min<size_type>(bb.y_max(), b.height() - 1); for (size_type y = ymin; y <= ymax; ++y) for (size_type x = xmin; x <= xmax; ++x) if (mml::contains(s, Point(x, y))) b(x, y) = add(b(x, y), c); } // draw_point // draws a point on the bitmap void draw_point(Bitmap& b, const Point& p, const Color& c) { const int d = 1 * FACT; draw_shape(b, Shape::rect(p - Point(d, d), p + Point(d, d)), c); } // populate // populates teh bitmap Bitmap populate() { Bitmap res(IMW * FACT, IMH * FACT, Color::black); for (Tessellation::iterator it = TESS.begin(false, false); it != TESS.end(); ++it) { Shape const& s = *it; Color c; switch (it.index() % TESS.pattern().size() % 18) { case 0: c = Color::rgb( 0, 0, 200); break; case 1: c = Color::rgb( 0, 200, 0); break; case 2: c = Color::rgb( 0, 200, 200); break; case 3: c = Color::rgb(200, 0, 0); break; case 4: c = Color::rgb(200, 0, 200); break; case 5: c = Color::rgb(200, 200, 0); break; case 6: c = Color::rgb( 0, 100, 200); break; case 7: c = Color::rgb( 0, 200, 100); break; case 8: c = Color::rgb(100, 0, 200); break; case 9: c = Color::rgb(100, 200, 0); break; case 10: c = Color::rgb(200, 0, 100); break; case 11: c = Color::rgb(200, 100, 0); break; case 12: c = Color::rgb( 0, 0, 100); break; case 13: c = Color::rgb( 0, 100, 0); break; case 14: c = Color::rgb( 0, 100, 100); break; case 15: c = Color::rgb(100, 0, 0); break; case 16: c = Color::rgb(100, 0, 100); break; case 17: c = Color::rgb(100, 100, 0); break; } draw_shape(res, s, c); } return res; } } //HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH // Implementation int main() { Shape draw(REF.circle().polygonize(1024 * FACT)); Bitmap res = populate(); for (const Point& p : draw.polygon().points_data()) draw_point(res, p, Color::white); draw_point(res, REF.center(), Color::white); std::ofstream res_file(OUT); if (not res_file.is_open()) return 1; res_file << tools::tga(scale(res)); res_file.close(); }
de7d136c0be887b9f785bd9cb0a5f7f2b8b87aeb
76ce016fb54e0947885304ecee05eaa6d2f95356
/ProjectNope/ProjectNope/LinkContainer.h
a8e0141944101839f394a697b0f4dc3cacb4f358
[]
no_license
raysloks/ProjectRPG
d8cdfd7e40744597cc14efa83f40e4f4add78e76
035f700889ce4e60978d072a7eb395fad2fd2359
refs/heads/master
2021-03-22T02:15:12.456332
2019-07-08T12:48:20
2019-07-08T12:48:20
69,451,090
0
0
null
null
null
null
UTF-8
C++
false
false
325
h
LinkContainer.h
#ifndef LINK_CONTAINER_H #define LINK_CONTAINER_H #include <vector> #include <stack> class LinkContainer { public: LinkContainer(void); ~LinkContainer(void); size_t add(const std::pair<size_t, size_t>& ref); void remove(size_t lid); std::vector<std::pair<size_t, size_t>> oref; std::stack<size_t> alloc; }; #endif
4308f7502e2c133995b73ded8c059e939d31640b
8a50b610a76c02642c9357245c6f17a1d99be39a
/pigbank.cpp
da18c48b0d413fa9571015e98f4e613092a64b0b
[]
no_license
sheeraznarejo/SPOJ
d3ec9ba31337beb578b49441aaa7881795b1c257
9e715c0f7b9fa8e89ec01febf98da0bfed59aa54
refs/heads/master
2021-01-25T03:19:59.485646
2015-04-16T21:31:59
2015-04-16T21:31:59
34,078,815
0
0
null
null
null
null
UTF-8
C++
false
false
1,417
cpp
pigbank.cpp
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <limits.h> #include <fstream> #include <iostream> using namespace std; int P[505]; int W[505]; int dp[505][10005]; int min(int a, int b) { return (a < b) ? a : b; } int main() { int T; scanf("%d", &T); while(T--) { ofstream myfile; myfile.open("test.txt"); int a, b; scanf("%d %d", &a, &b); int weight = b - a; int N; scanf("%d", &N); for(int i=0; i<= N; i++) for(int j=0; j<=weight; j++) dp[i][j] = INT_MAX; for(int i=0; i<N; i++) { scanf("%d %d", &P[i], &W[i]); dp[i][W[i]] = P[i]; } dp[0][0] = 0; for(int i = 1; i<= N; i++) { dp[i][0] = 0; for(int j = 1; j<= weight; j++) { if(j >= W[i-1]) { int a; int b = dp[i][j-W[i-1]] + P[i-1]; if( b >= 0) { a = min(dp[i-1][j], b); dp[i][j] = min(a, dp[i][j]); } else dp[i][j] = min(dp[i-1][j], dp[i][j]); } else dp[i][j] = dp[i-1][j]; } } if(dp[N][weight] == INT_MAX) printf("This is impossible.\n"); else printf("The minimum amount of money in the piggy-bank is %d.\n", dp[N][weight]); /*for(int i=1; i<= N; i++) { for(int j=1; j<= weight; j++) printf("%d ", dp[i][j]); printf("\n"); } */ } }
cf280234626085ad9baabab7706eeacf767e31b1
506cca8bfdb50d588b03c1ac41ac680f8998e7e7
/myOldSchoolProjects/C/COUN_L_D.CPP
efac4d568980925a8f1adc9580838e08f291fee7
[]
no_license
merimsoi/merimsoi.github.io
8ae63d77182b99e0b70a17aaa49df433c0c54fbb
3906d90ff11f35b80b95236ac75b1ba7d55f4ee0
refs/heads/master
2023-01-13T19:56:41.581763
2021-01-28T04:08:47
2021-01-28T04:08:47
70,628,194
0
0
null
2023-01-05T20:54:41
2016-10-11T19:30:04
C++
UTF-8
C++
false
false
514
cpp
COUN_L_D.CPP
#include<stdio.h> #include<string.h> main() { char str[256]; int a[26]; int b[9]; int i,k; for(i=0;i<=26;i++) a[i]=0; for(i=0;i<=9;i++) b[i]=0; printf("\nenter a string "); gets(str); for(i=0;i<=(strlen(str));i++) if ((str[i]>='0' && str[i]<='9')?1:0) { k=str[i]-'0'; b[k]++;} else if ((str[i]>='a' && str[i]<='z')?1:0) a[str[i]-97]++; for(i=0;i<26;i++) if (a[i]!=0) printf("\n%d of occurances of %c",a[i],i+97); for(i=0;i<9;i++) if (b[i]!=0) printf("\n%d of occurances of %d",b[i],i); }
daeaf413ce49d2310d29e6cb2f4f2305c7b69883
0eff74b05b60098333ad66cf801bdd93becc9ea4
/second/download/CMake/CMake-gumtree/Kitware_CMake_old_new_old_log_579.cpp
b83862675fc71f17babb4936e5e6cae727c3e79d
[]
no_license
niuxu18/logTracker-old
97543445ea7e414ed40bdc681239365d33418975
f2b060f13a0295387fe02187543db124916eb446
refs/heads/master
2021-09-13T21:39:37.686481
2017-12-11T03:36:34
2017-12-11T03:36:34
null
0
0
null
null
null
null
UTF-8
C++
false
false
66
cpp
Kitware_CMake_old_new_old_log_579.cpp
snprintf(ftpc->newhost, NEWHOST_BUFSIZE, "%s", conn->ip_addr_str);
32511d303466969b21ed563c98c339ff4da88476
f28782d02a8fa301be9e08496c7341762462bc2c
/DataStruct/栈与队列/杨辉三角(队列实现).cpp
09666bd29b0977d8662b8da98c5eb5470a8ffa97
[]
no_license
BUCTdarkness/JiyiShen-s-Coding
4dcd265c9e65d6c7dee21d87bb76420f39ace3b2
9957c10e222f15686459e5a7c909404e7e7ff536
refs/heads/master
2016-09-06T16:50:31.586323
2015-03-22T01:44:56
2015-03-22T01:44:56
32,655,388
2
0
null
null
null
null
UTF-8
C++
false
false
1,026
cpp
杨辉三角(队列实现).cpp
#include<iostream> #include<conio.h> #define MAX_LEN 100 using namespace std; template <class T> class queue { private: T data[MAX_LEN]; int head; int rear; public: queue() { head=0; rear=0; } void push(T t) { data[rear++]=t; } T front() { return data[head]; } void pop() { head++; } bool isEmpty() { if(head==rear) return true; else return false; } void clear() { while(!isEmpty()) { this->pop(); } } void printQueue() { for(int i=this->head;i<this->rear;i++) { if(this->data[i]!=0) { cout<<data[i]; if(i!=rear-1) cout<<" "; } } } }; void printYH(int n) { queue<int> q; q.push(0); q.push(1); q.push(0); int s,t,i; for(i=2;i<=n;i++) { do { s=q.front(); q.pop(); t=q.front(); q.push(s+t); }while(t!=0); q.push(0); } q.printQueue(); cout<<endl; } int main() { int n; while(cin>>n) { for(int i=1;i<=n;i++) { printYH(i); } } return 0; }
8a1ec3e90fa1b1f3b1fb6b8df2f11300ae198e29
6d4ed4934c4758c6e0a573336031f4f95e7bcf28
/SP1Framework/game.cpp
e705d81b16dc0711c74eeb9688bde0d2001ab877
[]
no_license
namkz/sp1-group19
de3ef84b39d454de53427bfd27d7e16cf408439e
4beeace3284949ac0c7910d5a9b0ff98c1995cff
refs/heads/master
2020-03-25T09:28:07.021785
2018-08-30T13:57:41
2018-08-30T13:57:41
143,672,262
0
0
null
2018-08-29T01:56:05
2018-08-06T03:34:09
C++
UTF-8
C++
false
false
41,702
cpp
game.cpp
// This is the main file for the game logic and function // // #include "game.h" #include "spell.h" #include "Framework\console.h" #include "effect.h" #include <iostream> #include <iomanip> #include <sstream> #include <fstream> double g_dElapsedTime; double g_dDeltaTime; double g_dNextRegen = 0; bool g_abKeyPressed[K_COUNT]; // Game specific variables here SGameChar g_sChar; SMessage* g_psMessages; ESpellComponents g_aeSpell[4] = {SC_NONE, SC_NONE, SC_NONE, SC_NONE}; SSpellNode* g_sSpells; SDungeonLevel * g_sLevel; SRenderedEffectList* g_sEffects; EGAMESTATES g_eGameState = S_SPLASHSCREEN; SVisibilityMap * g_sVisible; wchar_t * g_sBGM; char g_cSpellSlot = 0; bool g_bPlayerMoved = true; bool g_bPlayerMovedLastTurn = false; double g_adBounceTime[K_COUNT] = {}; // this is to prevent key bouncing, so we won't trigger keypresses more than once bool g_bifOver = false; bool g_bFirst = true; bool g_bSecond = false; bool g_bThird = false; std::string* g_asInventoryScreen[35]; std::string* g_asWinScreen[35]; std::string* g_asLeaderboard[35]; std::string* g_asGameOverscreen[35]; std::string* g_asTitle[35]; std::string* g_asHighscore[35]; std::string* g_asHowtoPlay[35]; // Console object Console g_Console(80, 35, "Slash"); //-------------------------------------------------------------- // Purpose : Initialisation function // Initialize variables, allocate memory, load data from file, etc. // This is called once before entering into your main loop // Input : void // Output : void //-------------------------------------------------------------- void init( void ) { srand(time(0)); g_sLevel = new SDungeonLevel ("Level.txt", 1); // Set precision for floating point output g_dElapsedTime = 0.0; g_dNextRegen = 0.0; setBGM(L"title.wav"); // sets the initial state for the game g_eGameState = S_SPLASHSCREEN; g_sChar.m_cLocation.X = 32; g_sChar.m_cLocation.Y = 12; g_sChar.m_bActive = true; g_sChar.m_iLevel = 1; g_sChar.m_iMaxEXP = 100; g_sChar.m_iExperience = 0; g_sChar.m_iMaxPlayerHealth = 100; g_sChar.m_iMaxPlayerMana = 100; g_sChar.m_iMaxPlayerAttack = 10; g_sChar.m_iMaxPlayerDefense = 10; g_sChar.m_iHealth = 100; g_sChar.m_iMana = 100; g_sChar.m_iAttack = 10; g_sChar.m_iDefense = 10; g_sChar.m_iInventoryIndex = 6; g_sChar.m_iInventoryPage = 1; g_sChar.m_iScore = 0; g_sChar.m_sInventory = new SInventory(); g_sEffects = new SRenderedEffectList(); g_sVisible = new SVisibilityMap(); g_bPlayerMoved = true; SItem * temp = new SItemIntellectualWizardHat(); g_sChar.m_sInventory->addItem(temp); //Test spell updateSpells(); std::fstream instructGameFile; instructGameFile.open("instructions.txt"); for (short i = 0; i < 35; i++) { g_asHowtoPlay[i] = new std::string; std::getline(instructGameFile, *g_asHowtoPlay[i]); } instructGameFile.close(); std::fstream winGameFile; winGameFile.open("Win.txt"); for (short i = 0; i < 35; i++) { g_asWinScreen[i] = new std::string; std::getline(winGameFile, *g_asWinScreen[i]); } winGameFile.close(); std::fstream leaderboardFile; leaderboardFile.open("leaderboard.dat"); for (short i = 0; i < 35; i++) { g_asLeaderboard[i] = new std::string; std::getline(leaderboardFile, *g_asLeaderboard[i]); } leaderboardFile.close(); std::fstream inventoryFile; inventoryFile.open("inventory.txt"); for (short i = 0; i < 35; i++) { g_asInventoryScreen[i] = new std::string; std::getline(inventoryFile, *g_asInventoryScreen[i]); } inventoryFile.close(); std::fstream titleFile; titleFile.open("title.txt"); for (short i = 0; i < 35; i++) { g_asTitle[i] = new std::string; std::getline(titleFile, *g_asTitle[i]); } titleFile.close(); std::fstream GameOverFile; GameOverFile.open("GameOver.txt"); for (short i = 0; i < 35; i++) { g_asGameOverscreen[i] = new std::string; std::getline(GameOverFile, *g_asGameOverscreen[i]); } GameOverFile.close(); // sets the width, height and the font name to use in the console g_Console.setConsoleFont(0, 16, L"Consolas"); } void updateSpells() { delete g_sSpells; g_sSpells = new SSpellNode(); //Test Spell /*{ESpellComponents aeTemp[4] = {SC_FIRE, SC_NONE}; SSpell * psSpell = new SSpellElementalBasic(100000, E_FIRE, 0, "rekt bolt", 0x0F); g_sSpells->addSpellToTree(psSpell, aeTemp);}*/ //Basic Fire {ESpellComponents aeTemp[4] = { SC_FIRE, SC_NONE };//Input SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_FIRE, 4, "fireball", 0x0C);//In order Attack,Element,Mana,String,Color of visuals g_sSpells->addSpellToTree(psSpell, aeTemp);} //Basic Water {ESpellComponents aeTemp[4] = { SC_WATER, SC_NONE }; SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_WATER, 4, "waterbolt", 0x09); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Basic Earth {ESpellComponents aeTemp[4] = { SC_EARTH, SC_NONE }; SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_EARTH, 4, "dirt", 0x06); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Basic Wind {ESpellComponents aeTemp[4] = { SC_AIR, SC_NONE }; SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_AIR, 4, "piercing wind", 0x0F); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Basic Lightning {ESpellComponents aeTemp[4] = { SC_LIGHTNING, SC_NONE }; SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_LIGHTNING, 4, "spark", 0x0E); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Basic Ice {ESpellComponents aeTemp[4] = { SC_ICE, SC_NONE }; SSpell * psSpell = new SSpellElementalBasic(g_sChar.m_iAttack, E_ICE, 4, "snowball of death", 0x0A); g_sSpells->addSpellToTree(psSpell, aeTemp);} //DragonFlame {ESpellComponents aeTemp[4] = { SC_FIRE, SC_FIRE, SC_NONE }; g_sSpells->addSpellToTree(new SSpellElementalDragonFlame((double)g_sChar.m_iAttack * 1.5, E_FIRE, 15 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 1.5), aeTemp); //void executeSpell(); } //Steamed Hams {ESpellComponents aeTemp[4] = { SC_FIRE, SC_WATER, SC_NONE }; SSpell * psSpell = new SSpellElementalSteamedHams((double)g_sChar.m_iAttack * 8, E_WATER, 20 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 2); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Firestorm {ESpellComponents aeTemp[4] = { SC_FIRE, SC_AIR, SC_NONE }; SSpell * psSpell = new SSpellElementalFireStorm((double)g_sChar.m_iAttack * (1.5), E_FIRE, 40 + ((double)g_sChar.m_iMaxPlayerMana / 100) *4); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Blazing Lightning {ESpellComponents aeTemp[4] = { SC_FIRE, SC_LIGHTNING, SC_NONE }; SSpell * psSpell = new SSpellElementalBlazingLightning((double)g_sChar.m_iAttack*4, E_LIGHTNING, 30 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 3); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Frostfire {ESpellComponents aeTemp[4] = { SC_FIRE, SC_ICE, SC_NONE }; SSpell * psSpell = new SSpellElementalFrostFire((double)g_sChar.m_iAttack*4, E_FIRE, 35+ ((double)g_sChar.m_iMaxPlayerMana / 100) * 3.5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Water Tree //Water Wave {ESpellComponents aeTemp[4] = { SC_WATER, SC_WATER, SC_NONE }; SSpell * psSpell = new SSpellElementalWaterWave((double)g_sChar.m_iAttack*2, E_WATER, 30+ ((double)g_sChar.m_iMaxPlayerMana / 100) * 3); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Quagmire {ESpellComponents aeTemp[4] = { SC_WATER, SC_EARTH, SC_NONE }; SSpell * psSpell = new SSpellElementalQuagmire((double)g_sChar.m_iAttack, E_WATER, 40+ ((double)g_sChar.m_iMaxPlayerMana / 100) * 4); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Hurricane {ESpellComponents aeTemp[4] = { SC_WATER, SC_AIR, SC_NONE}; SSpell * psSpell = new SSpellElementalHurricane((double)g_sChar.m_iAttack*2, E_AIR, 40 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 3); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Shockwave {ESpellComponents aeTemp[4] = { SC_WATER, SC_LIGHTNING,SC_NONE }; SSpell * psSpell = new SSpellElementalShockwave((double)g_sChar.m_iAttack*1.5, E_LIGHTNING, 25 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 2.5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Ice Tomb {ESpellComponents aeTemp[4] = { SC_WATER, SC_ICE,SC_NONE}; SSpell * psSpell = new SSpellElementalIceTomb((double)g_sChar.m_iAttack*3, E_WATER, 50 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Earth Tree //Rock Armor // Buff {ESpellComponents aeTemp[4] = { SC_EARTH, SC_EARTH,SC_NONE }; SSpell * psSpell = new SSpellElementalRockArmour(0, E_EARTH ,20 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 2); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Meteor Storm {ESpellComponents aeTemp[4] = { SC_EARTH, SC_AIR,SC_NONE }; SSpell * psSpell = new SSpellElementalMeteorStorm((double)g_sChar.m_iAttack*1.5, E_EARTH, 40 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 4); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Effect Negation //Debuff {ESpellComponents aeTemp[4] = { SC_EARTH, SC_LIGHTNING,SC_NONE }; SSpell * psSpell = new SSpellElementalEffectNegation(0, E_EARTH , 20 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 2); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Pitfall {ESpellComponents aeTemp[4] = { SC_EARTH, SC_ICE,SC_NONE }; SSpell * psSpell = new SSpellElementalEffectNegation((double)g_sChar.m_iAttack*5, E_EARTH, 30 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 3); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Wind Tree //Deflective Barrier // Buff {ESpellComponents aeTemp[4] = { SC_AIR, SC_AIR,SC_NONE }; SSpell * psSpell = new SSpellElementalEffectNegation(0, E_AIR, 20 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 2); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Lightning Storm {ESpellComponents aeTemp[4] = { SC_AIR, SC_LIGHTNING,SC_NONE }; SSpell * psSpell = new SSpellElementalEffectNegation((double)g_sChar.m_iAttack*2, E_AIR, 50 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Icicle Barrage {ESpellComponents aeTemp[4] = { SC_AIR, SC_LIGHTNING,SC_NONE }; SSpell * psSpell = new SSpellElementalIcicleBarrage((double)g_sChar.m_iAttack * 2, E_AIR, 40 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 4); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Chain Lightning {ESpellComponents aeTemp[4] = { SC_LIGHTNING, SC_LIGHTNING,SC_NONE }; SSpell * psSpell = new SSpellElementalChainLightning((double)g_sChar.m_iAttack * 2.5, E_LIGHTNING, 35 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 3.5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Everlasting Paralysis // Debuff {ESpellComponents aeTemp[4] = { SC_LIGHTNING, SC_ICE,SC_NONE }; SSpell * psSpell = new SSpellElementalEverlastingParalysis((double)g_sChar.m_iAttack * 1.5, E_LIGHTNING, 50 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Ice Tree //Ice Wall {ESpellComponents aeTemp[4] = { SC_LIGHTNING, SC_ICE,SC_NONE }; SSpell * psSpell = new SSpellElementalIceWall((double)g_sChar.m_iAttack * 1.5, E_ICE, 50 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Ultimate Spell Tree //Sun God Fury {ESpellComponents aeTemp[4] = { SC_FIRE, SC_FIRE,SC_FIRE,SC_NONE }; SSpell * psSpell = new SSpellElementalSunGodFury((double)g_sChar.m_iAttack * 15, E_FIRE, 500 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 80); g_sSpells->addSpellToTree(psSpell, aeTemp);} //LandSlide {ESpellComponents aeTemp[4] = { SC_EARTH, SC_WATER,SC_AIR,SC_NONE }; SSpell * psSpell = new SSpellElementalLandSlide((double)g_sChar.m_iAttack * 10, E_EARTH, 50 + ((double)g_sChar.m_iMaxPlayerMana / 100) * 5); g_sSpells->addSpellToTree(psSpell, aeTemp);} //Ritual of Madness //Debuff {ESpellComponents aeTemp[4] = { SC_FIRE, SC_ICE,SC_EARTH,SC_NONE }; SSpell * psSpell = new SSpellElementalRitualofMadness(0, E_FIRE, g_sChar.m_iMaxPlayerMana); g_sSpells->addSpellToTree(psSpell, aeTemp);} } //-------------------------------------------------------------- // Purpose : Reset before exiting the program // Do your clean up of memory here // This is called once just before the game exits // Input : Void // Output : void //-------------------------------------------------------------- void shutdown( void ) { // Reset to white text on black background colour(FOREGROUND_BLUE | FOREGROUND_GREEN | FOREGROUND_RED); g_Console.clearBuffer(); } //-------------------------------------------------------------- // Purpose : Getting all the key press states // This function checks if any key had been pressed since the last time we checked // If a key is pressed, the value for that particular key will be true // // Add more keys to the enum in game.h if you need to detect more keys // To get other VK key defines, right click on the VK define (e.g. VK_UP) and choose "Go To Definition" // For Alphanumeric keys, the values are their ascii values (uppercase). // Input : Void // Output : void //-------------------------------------------------------------- void getInput( void ) { g_abKeyPressed[K_SPACE] = isKeyPressed(VK_SPACE); g_abKeyPressed[K_ESCAPE] = isKeyPressed(VK_ESCAPE); g_abKeyPressed[K_W] = isKeyPressed('W') || isKeyPressed(VK_UP); g_abKeyPressed[K_A] = isKeyPressed('A') || isKeyPressed(VK_LEFT); g_abKeyPressed[K_S] = isKeyPressed('S') || isKeyPressed(VK_DOWN); g_abKeyPressed[K_D] = isKeyPressed('D') || isKeyPressed(VK_RIGHT); g_abKeyPressed[K_E] = isKeyPressed('E'); g_abKeyPressed[K_U] = isKeyPressed('U'); g_abKeyPressed[K_I] = isKeyPressed('I'); g_abKeyPressed[K_O] = isKeyPressed('O'); g_abKeyPressed[K_J] = isKeyPressed('J'); g_abKeyPressed[K_K] = isKeyPressed('K'); g_abKeyPressed[K_L] = isKeyPressed('L'); g_abKeyPressed[K_SHIFT] = isKeyPressed(VK_SHIFT); g_abKeyPressed[K_ENTER] = isKeyPressed(VK_RETURN); g_abKeyPressed[K_ESCAPE] = isKeyPressed(VK_ESCAPE); } void setBGM(wchar_t * eBGM) { if(g_sBGM != eBGM) { PlaySound(eBGM, NULL, SND_LOOP | SND_ASYNC); g_sBGM = eBGM; } } //-------------------------------------------------------------- // Purpose : Update function // This is the update function // double dt - This is the amount of time in seconds since the previous call was made // // Game logic should be done here. // Such as collision checks, determining the position of your game characters, status updates, etc // If there are any calls to write to the console here, then you are doing it wrong. // // If your game has multiple states, you should determine the current state, and call the relevant function here. // // Input : dt = deltatime // Output : void //-------------------------------------------------------------- void update(double dt) { // get the delta time g_dElapsedTime += dt; g_dDeltaTime = dt; switch (g_eGameState) { case S_SPLASHSCREEN : splashScreenWait(); // game logic for the splash screen break; case S_GAME: gameplay(); // gameplay logic when we are in the game break; case S_INVENTORY: gameplayInventory(); // gameplay logic when we are in the inventory break; case S_GAMEEND: case S_GAMEWIN: gameEnd(); // Spacebar ends program break; case S_GAMEINSTRUCT:resetMain(); break; } } //-------------------------------------------------------------- // Purpose : Render function is to update the console screen // At this point, you should know exactly what to draw onto the screen. // Just draw it! // To get an idea of the values for colours, look at console.h and the URL listed there // Input : void // Output : void //-------------------------------------------------------------- void render() { clearScreen(); // clears the current screen and draw from scratch switch (g_eGameState) { case S_SPLASHSCREEN: renderSplashScreen(); break; case S_GAME: renderGame(); break; case S_INVENTORY: renderInventory(); break; case S_GAMEEND: renderGameOver(); break; case S_GAMEWIN: renderWin(); break; case S_GAMEINSTRUCT: renderInstruct(); break; } renderFramerate(); // renders debug information, frame rate, elapsed time, etc renderToScreen(); // dump the contents of the buffer to the screen, one frame worth of game } void splashScreenWait() // waits for time to pass in splash screen { /*if (g_abKeyPressed[K_SPACE]) { g_eGameState = S_GAME; g_adBounceTime[K_SPACE] = g_dElapsedTime + 0.4; }*/ } void gameplay() // gameplay logic { if(g_sChar.m_iHealth < g_sChar.m_iMaxPlayerHealth / 3) setBGM(L"creepy_low.wav"); else setBGM(L"creepy.wav"); processUserInput(); // checks if you should change states or do something else with the game, e.g. pause, exit if(g_eGameState != S_INVENTORY) moveCharacter(); // moves the character, collision detection, physics, etc if(g_bPlayerMoved) { g_sVisible = g_sLevel->tilesWithLineOfSight(g_sChar.m_cLocation); g_sLevel->m_sExplored->assimilate(g_sVisible); g_bPlayerMoved = false; } if(g_eGameState != S_INVENTORY) { entityTurns(); regen(); } if (g_sChar.m_iHealth <= 0)//If health is 0 transition to end game screen. { g_eGameState = S_GAMEEND; } } void gameEnd()//Function when game ends { if (g_abKeyPressed[K_ENTER] && g_dElapsedTime > g_adBounceTime[K_ENTER])//When user presses Enter { g_bQuitGame = true; // quits the game } } void resetMain() //Reset to main menu during instruction page { if (g_abKeyPressed[K_SPACE] && g_dElapsedTime > g_adBounceTime[K_SPACE])//if space bar is pressed { if (g_eGameState == S_GAMEINSTRUCT) // and gamestate is instruct { g_eGameState = S_SPLASHSCREEN;//set to the main menu } } } void regen() { if(g_dNextRegen > g_dElapsedTime) return; g_sChar.m_iMana += (g_sChar.m_iMana * 3 + g_sChar.m_iMaxPlayerMana * 5) / 100; g_sChar.m_iHealth += (g_sChar.m_iMaxPlayerHealth * 2) / 100; if(g_sChar.m_iMana > g_sChar.m_iMaxPlayerMana) g_sChar.m_iMana = g_sChar.m_iMaxPlayerMana; if(g_sChar.m_iHealth > g_sChar.m_iMaxPlayerHealth) g_sChar.m_iHealth = g_sChar.m_iMaxPlayerHealth; g_dNextRegen = g_dElapsedTime + 0.8; } void gameplayInventory() { processUserInput(); processEquipment(g_sChar.m_iInventoryIndex); g_Console.writeToBuffer({ 26,16 }, std::to_string(g_sChar.m_iInventoryPage), 0x0f); g_Console.writeToBuffer(moveInventoryCursor(), ">", 0x0f); } void mainMenuCursor() { g_Console.writeToBuffer(moveMainMenuCursor(), ">", 0x0f); } COORD moveMainMenuCursor()//Cursor for main menu { COORD cCursorPos; //Var for COORD cursor bool b_input = true; if (g_bFirst == true) { cCursorPos = { 37, 15 }; // set starting coord for cursor if (g_adBounceTime[K_ENTER] < g_dElapsedTime && g_abKeyPressed[K_ENTER])//if enter key is pressed at the curren coordinate { g_eGameState = S_GAME;//Goes into gameplay } } if (g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S] && g_bFirst == true)//Moving the cursor down from First option { cCursorPos = { 34, 18 }; // cursor COORDS for 2nd option g_bFirst = false;//Checks First as false to prevent it from going back up g_bSecond = true;//Sets Check for 2nd option b_input = true;//checks for bouncetime } else if (g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S] && g_bSecond == true)//Moving cursor down from second option { cCursorPos = { 37,21 };//COORDS for 3rd option g_bSecond = false;//sets second as false to prevent it from going back up g_bThird = true;//sets third as true b_input = true; // Checks for bouncetime } else if (g_adBounceTime[K_W] < g_dElapsedTime && g_abKeyPressed[K_W] && g_bThird == true)// moving to 2nd option from 3rd { cCursorPos = { 34,18 }; //sets coords to 2nd option g_bThird = false;//Third as false to prevent it from automatically going back down g_bSecond = true;//set second as true } else if (g_adBounceTime[K_W] < g_dElapsedTime && g_abKeyPressed[K_W] && g_bSecond == true)//Moving to 1st option from 2nd { cCursorPos = { 37,15 };//sets coords to 1st Option b_input = true;//Checks for bouncetime g_bFirst = true;//Sets first to true g_bSecond = false;//Sets second to false to prevent it to automatically go back to 2nd option } if (g_bSecond == true)//if second option is true { if (g_adBounceTime[K_ENTER] < g_dElapsedTime && g_abKeyPressed[K_ENTER])//If user presses Enter { g_eGameState = S_GAMEINSTRUCT;//User goes into How to play Menu } b_input = true;//Checks for bouncetime cCursorPos = { 34, 18 };//Cursor Coords for 2nd option } if ( g_bThird == true)//if third option is true { if (g_adBounceTime[K_ENTER] < g_dElapsedTime && g_abKeyPressed[K_ENTER])//user presses enter { exit(1);//Exits game } b_input = true;//bounce time cCursorPos = { 37, 21 };//sets coords to third } if (b_input = true) { // set the bounce time to some time in the future to prevent accidental triggers for (int i = 0; i < K_COUNT; i++) { if (g_abKeyPressed[i]) g_adBounceTime[i] = g_dElapsedTime + (i >= K_U ? 1 / 8.0 : 1 / 15.0); } } return cCursorPos; } COORD moveInventoryCursor() { bool bInput = false; short sEquipCalculationNumber = 64; COORD cCursorPos; // Moving the cursor position when user input is detected if (g_sChar.m_iInventoryIndex >= 0 && g_sChar.m_iInventoryIndex <= 5) { cCursorPos = { 9, 11 }; if (g_adBounceTime[K_A] < g_dElapsedTime && g_abKeyPressed[K_A] && g_sChar.m_iInventoryIndex != 5) { ++g_sChar.m_iInventoryIndex; bInput = true; } if (g_adBounceTime[K_D] < g_dElapsedTime && g_abKeyPressed[K_D] && g_sChar.m_iInventoryIndex != 0) { --g_sChar.m_iInventoryIndex; bInput = true; } cCursorPos.X = (sEquipCalculationNumber - g_sChar.m_iInventoryIndex * 11); if (g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S]) { cCursorPos = { 7, 17 }; g_sChar.m_iInventoryIndex = (g_sChar.m_iInventoryPage * 8) - 2; bInput = true; } } else if (g_sChar.m_iInventoryIndex >= 6 && g_sChar.m_iInventoryIndex <= 38) { cCursorPos = { 7, 17 }; if (g_adBounceTime[K_W] < g_dElapsedTime && g_abKeyPressed[K_W]) { if ((g_sChar.m_iInventoryIndex + 2) % 8 == 0) { cCursorPos = { 9, 11 }; g_sChar.m_iInventoryIndex = 5; bInput = true; } else { --g_sChar.m_iInventoryIndex; bInput = true; } } if (g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S]) { if ((g_sChar.m_iInventoryIndex - 5) % 8 != 0) { ++g_sChar.m_iInventoryIndex; bInput = true; } } if (g_adBounceTime[K_A] < g_dElapsedTime && g_abKeyPressed[K_A]) { if (g_sChar.m_iInventoryPage != 1) { g_sChar.m_iInventoryPage -= 1; g_sChar.m_iInventoryIndex -= 8; bInput = true; } } if (g_adBounceTime[K_D] < g_dElapsedTime && g_abKeyPressed[K_D]) { if (g_sChar.m_iInventoryPage != 4) { g_sChar.m_iInventoryPage += 1; g_sChar.m_iInventoryIndex += 8; bInput = true; } } if (g_sChar.m_iInventoryIndex >= 6) { cCursorPos.Y += ((g_sChar.m_iInventoryIndex + 2) - g_sChar.m_iInventoryPage * 8) * 2; } } if (bInput) { // set the bounce time to some time in the future to prevent accidental triggers for (int i = 0; i < K_COUNT; i++) { if (g_abKeyPressed[i]) g_adBounceTime[i] = g_dElapsedTime + (i >= K_U ? 1 / 8.0 : 1 / 15.0); } } return cCursorPos; } void processEquipment(short sIndex) { if (sIndex < 6 && g_adBounceTime[K_ENTER] < g_dElapsedTime && g_abKeyPressed[K_ENTER]) { g_sChar.m_sInventory->unequipItemFromSlot(sIndex); } else if (g_adBounceTime[K_ENTER] < g_dElapsedTime && g_abKeyPressed[K_ENTER]) { g_sChar.m_sInventory->equipItemToSlot(sIndex); } } void resetPlayerMaxStats() { g_sChar.m_iMaxPlayerAttack = ((pow(g_sChar.m_iLevel, 2) / 2) + (g_sChar.m_iLevel * 5) + 5); g_sChar.m_iMaxPlayerDefense = (g_sChar.m_iMaxPlayerAttack - 10) / 1.5 + 10; g_sChar.m_iMaxPlayerMana = (5 * pow((g_sChar.m_iLevel), 2) + 95); g_sChar.m_iMaxPlayerHealth = g_sChar.m_iMaxPlayerMana; } void updateEquipmentStats() { resetPlayerMaxStats(); int health = g_sChar.m_iMaxPlayerHealth; int mana = g_sChar.m_iMaxPlayerMana; int attack = g_sChar.m_iMaxPlayerAttack; int defense = g_sChar.m_iMaxPlayerDefense; for (int i = 0; i < 6; i++) { if (g_sChar.m_sInventory->m_asContents[i] == nullptr) { continue; } else { health += g_sChar.m_sInventory->m_asContents[i]->processHealth(g_sChar.m_iMaxPlayerHealth); mana += g_sChar.m_sInventory->m_asContents[i]->processMana(g_sChar.m_iMaxPlayerMana); attack += g_sChar.m_sInventory->m_asContents[i]->processAttack(g_sChar.m_iMaxPlayerAttack); defense += g_sChar.m_sInventory->m_asContents[i]->processDefense(g_sChar.m_iMaxPlayerDefense); } } g_sChar.m_iMaxPlayerHealth = health; g_sChar.m_iMaxPlayerMana = mana; g_sChar.m_iMaxPlayerAttack = attack; g_sChar.m_iMaxPlayerDefense = defense; g_sChar.m_iAttack = g_sChar.m_iMaxPlayerAttack; g_sChar.m_iDefense = g_sChar.m_iMaxPlayerDefense; } void entityTurns() { g_sLevel->m_sEnemies.cleanDeadEntities(); for(SEntity *ppsCurrent : g_sLevel->m_sEnemies) { if(ppsCurrent == nullptr) continue; if(ppsCurrent->m_dNextTurn > g_dElapsedTime) continue; if(ppsCurrent) ppsCurrent->takeTurn(); } } bool playerMove(COORD *cNewLocation) { if((!g_sLevel->hasEnemy(*cNewLocation) || g_sLevel->canPlayerSeeEnemy(*cNewLocation)) && g_sLevel->getFeatureAt(cNewLocation)->onMovedInto()) { g_sChar.m_cLocation = *cNewLocation; g_bPlayerMoved = true; return true; } return false; } void moveCharacter() { bool bSomethingHappened = false; if (g_adBounceTime[K_W] < g_dElapsedTime && g_abKeyPressed[K_W] || g_adBounceTime[K_A] < g_dElapsedTime && g_abKeyPressed[K_A] || g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S] || g_adBounceTime[K_D] < g_dElapsedTime && g_abKeyPressed[K_D]) { g_sChar.m_sFacingX = 0; g_sChar.m_sFacingY = 0; g_bPlayerMoved = true; } // Updating the location of the character based on the key press // providing a beep sound whenver we shift the character if (g_adBounceTime[K_W] < g_dElapsedTime && g_abKeyPressed[K_W] && g_sChar.m_cLocation.Y > 0) { bSomethingHappened = true; g_sChar.m_sFacingY = -1; } if (g_adBounceTime[K_A] < g_dElapsedTime && g_abKeyPressed[K_A] && g_sChar.m_cLocation.X > 0) { bSomethingHappened = true; g_sChar.m_sFacingX = -1; } if (g_adBounceTime[K_S] < g_dElapsedTime && g_abKeyPressed[K_S] && g_sChar.m_cLocation.Y < 27) { bSomethingHappened = true; g_sChar.m_sFacingY = 1; } if (g_adBounceTime[K_D] < g_dElapsedTime && g_abKeyPressed[K_D] && g_sChar.m_cLocation.X < 79) { bSomethingHappened = true; g_sChar.m_sFacingX = 1; } if (g_adBounceTime[K_U] < g_dElapsedTime && g_abKeyPressed[K_U] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_FIRE; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_I] < g_dElapsedTime && g_abKeyPressed[K_I] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_LIGHTNING; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_O] < g_dElapsedTime && g_abKeyPressed[K_O] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_AIR; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_J] < g_dElapsedTime && g_abKeyPressed[K_J] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_WATER; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_K] < g_dElapsedTime && g_abKeyPressed[K_K] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_EARTH; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_L] < g_dElapsedTime && g_abKeyPressed[K_L] && g_cSpellSlot <= 2) { g_aeSpell[g_cSpellSlot] = SC_ICE; g_cSpellSlot++; bSomethingHappened = true; } if (g_adBounceTime[K_SPACE] < g_dElapsedTime && g_abKeyPressed[K_SPACE]) { if(g_aeSpell[0] != SC_NONE) { SSpell *sSpell = g_sSpells->lookupSpell(g_aeSpell); if(sSpell == nullptr) { sendMessage("Your spell fizzles into nothing."); _PLAY_SOUND(L"hiss.wav") } else { sSpell->executeSpell(); } g_aeSpell[0] = SC_NONE; g_aeSpell[1] = SC_NONE; g_aeSpell[2] = SC_NONE; g_aeSpell[3] = SC_NONE; g_cSpellSlot = 0; bSomethingHappened = true; } } if (bSomethingHappened) { if (g_bPlayerMoved && (g_sChar.m_sFacingX || g_sChar.m_sFacingY)) { COORD cNewLocation = {g_sChar.m_cLocation.X, g_sChar.m_cLocation.Y}; cNewLocation.X += g_sChar.m_sFacingX; cNewLocation.Y += g_sChar.m_sFacingY; if(!playerMove(&cNewLocation) && g_bPlayerMovedLastTurn) { COORD cNewLocationX = {g_sChar.m_cLocation.X, g_sChar.m_cLocation.Y}; COORD cNewLocationY = {g_sChar.m_cLocation.X, g_sChar.m_cLocation.Y}; cNewLocationY.Y += g_sChar.m_sFacingY; playerMove(&cNewLocationY); cNewLocationX.X += g_sChar.m_sFacingX; playerMove(&cNewLocationX); } } // set the bounce time to some time in the future to prevent accidental triggers for(int i = 0; i < K_COUNT; i++) { if(g_abKeyPressed[i]) g_adBounceTime[i] = g_dElapsedTime + (i >= K_U?1/8.0:1/15.0); } g_bPlayerMovedLastTurn = g_bPlayerMoved; } } void processUserInput() { bool bSomethingHappened = false ; // quits the game if player hits the escape key if (g_abKeyPressed[K_ESCAPE]) g_bQuitGame = true; if (g_abKeyPressed[K_E] && g_dElapsedTime > g_adBounceTime[K_E])//If user presses E and bouncetime check { if (g_eGameState == S_INVENTORY)//If the menu is in inventory { updateEquipmentStats(); g_eGameState = S_GAME;//Set gamestate to Gameplay } else if (g_eGameState == S_GAME)//else if gamestate is at Gameplay { g_eGameState = S_INVENTORY; //Set it to inventory menu } g_adBounceTime[K_E] = g_dElapsedTime + 0.2; // Bouncetime } } void clearScreen() { // Clears the buffer with this colour attribute g_Console.clearBuffer(0x0F); } void renderSplashScreen() // renders the splash screen { COORD c = g_Console.getConsoleSize(); c.Y /= 3; c.X /= 2; for (short s = 0; s < 35; s++) { if (s < 10) { g_Console.writeToBuffer(COORD{ 0, s }, *(g_asTitle[s]), 0x0C); } else { g_Console.writeToBuffer(COORD{ 0, s }, *(g_asTitle[s]), 0x09); } } g_Console.writeToBuffer(COORD{ 38, 15 }, "START", 0x0F); g_Console.writeToBuffer(COORD{ 35, 18 }, "HOW TO PLAY", 0x0F); g_Console.writeToBuffer(COORD{ 38,21 }, "EXIT", 0x0F); mainMenuCursor(); } void renderItems() { } void renderEnemies() { for(SEntity *ppsCurrent : g_sLevel->m_sEnemies) { if(ppsCurrent == nullptr) continue; if(g_sVisible->getTileVisibility(ppsCurrent->m_cLocation)) g_Console.writeToBuffer(ppsCurrent->m_cLocation, ppsCurrent->m_cMonsterClass, ppsCurrent->m_cColor); } } unsigned char getSpellColor(ESpellComponents eComponent) { switch(eComponent) { case SC_FIRE: return 0xC0; case SC_LIGHTNING: return 0xE0; case SC_WATER: return 0x90; case SC_EARTH: return 0xA0; case SC_AIR: return 0xF0; case SC_ICE: return 0xB0; default: return 0x00; } } void renderSpell() { g_Console.writeToBuffer(COORD {0, 28}, "Spell:", 0x07); g_Console.writeToBuffer(COORD {7, 28}, "O", getSpellColor(g_aeSpell[0])); g_Console.writeToBuffer(COORD {8, 28}, "O", getSpellColor(g_aeSpell[1])); g_Console.writeToBuffer(COORD {9, 28}, "O", getSpellColor(g_aeSpell[2])); } void writeToBuffer(COORD sA, char cChar, unsigned char cColor) { g_Console.writeToBuffer(sA, cChar, cColor); } void renderEffects(int i) { g_sEffects->renderAllEffects(i); g_sEffects->clearExpiredEffects(); } void renderNonVisibility() { for(short i = 0; i < 80 * 28; i++) { if(!(g_sLevel->m_sExplored->getTileVisibility(COORD{i%80, i/80}))) writeToBuffer(COORD{i % 80, i / 80}, ' ', 0x08); } } void renderGame() { renderMap(); // renders the map to the buffer first renderEffects(-1); renderItems(); // then overwrites item locations to buffer next renderEffects(0); renderEnemies(); // then renders enemies renderEffects(1); renderCharacter(); // then renders the character into the buffer renderEffects(2); renderMessages(); // then renders messages renderSpell(); renderNonVisibility(); renderStatus(); // then renders the status } char messageColourFromTime(double dTimeDiff) { if(dTimeDiff <= 0) return 0x00; if(dTimeDiff < 2.5) return 0x08; if(dTimeDiff < 5.0) return 0x07; return 0x0F; } void sendMessage(std::string sStringMessage) { if(g_psMessages == nullptr) g_psMessages = new SMessage(sStringMessage, 10.0); else g_psMessages = g_psMessages->addNewMessage(sStringMessage, 10.0); } void renderMessages() { SMessage *psCurrentMessage = g_psMessages; for(unsigned char i = 0; i < 6; i++) { if(psCurrentMessage == nullptr) return; g_Console.writeToBuffer(COORD{0, 34-i}, psCurrentMessage->m_sStringMessage, messageColourFromTime(psCurrentMessage->m_dExpiryTime - g_dElapsedTime)); psCurrentMessage = psCurrentMessage->m_psNext; } } void renderStatus() { // [!] NICE TO HAVE: a health BAR std::stringstream ss; g_Console.writeToBuffer(COORD{45, 28}, "Level:"); ss << g_sChar.m_iLevel; g_Console.writeToBuffer(COORD{55, 28}, ss.str()); ss.str(""); g_Console.writeToBuffer(COORD{55, 27}, "EXP:"); ss << g_sChar.m_iExperience << " / " << g_sChar.m_iMaxEXP; g_Console.writeToBuffer(COORD{60, 27}, ss.str()); ss.str(""); //Health g_Console.writeToBuffer(COORD{13, 27}, "Health:"); std::string sTemp; sTemp = ""; ss.str(""); ss << g_sChar.m_iHealth << " / " << g_sChar.m_iMaxPlayerHealth; sTemp = ss.str(); ss.str(""); ss << std::left<< std::setw(10) << sTemp; g_Console.writeToBuffer(COORD{ 21 , 27 }, ss.str(), 0x0F); g_Console.writeToBuffer(COORD{ 21 , 27 }, ss.str().substr(0, (10 * g_sChar.m_iHealth / g_sChar.m_iMaxPlayerHealth)), 0xCF);//Draws the health bar on the players health string ss.str(""); //Mana g_Console.writeToBuffer(COORD{35, 27}, "Mana:"); std::string sManaT; sManaT = ""; ss.str(""); ss << g_sChar.m_iMana << " / " << g_sChar.m_iMaxPlayerMana; sManaT = ss.str(); ss.str(""); ss << std::left << std::setw(10) << sManaT; g_Console.writeToBuffer(COORD{41, 27}, ss.str(),0x0F); g_Console.writeToBuffer(COORD{ 41 , 27 }, ss.str().substr(0, (10 * g_sChar.m_iMana/ g_sChar.m_iMaxPlayerMana)), 0x1F);//Draws the players mana bar ontop of the string ss.str(""); g_Console.writeToBuffer(COORD{45, 29}, "Attack:"); ss << g_sChar.m_iAttack << " (Base: " << g_sChar.m_iMaxPlayerAttack << ")"; g_Console.writeToBuffer(COORD{55, 29}, ss.str()); ss.str(""); g_Console.writeToBuffer(COORD{45, 30}, "Defense:"); ss << g_sChar.m_iDefense << " (Base: " << g_sChar.m_iMaxPlayerDefense << ")"; g_Console.writeToBuffer(COORD{55, 30}, ss.str()); ss.str(""); g_Console.writeToBuffer(COORD{ 45,31 }, "Score:"); ss << g_sChar.m_iScore; g_Console.writeToBuffer(COORD{ 55,31 }, ss.str()); ss.str(""); } void renderInstruct() { for (short s = 0;s < 35;s++) { g_Console.writeToBuffer(COORD{ 0,s }, *(g_asHowtoPlay[s]), 0x0F); } } void renderGameOver() { if (g_bifOver == false) { leaderboard(g_sChar.m_iScore); g_bifOver = true; } for (short s = 0; s < 35; s++) { g_Console.writeToBuffer(COORD{ 10,s + 3 }, *(g_asGameOverscreen[s]), 0x0C); } g_Console.writeToBuffer(COORD{ 33, 10 }, "LEADERBOARD", 0x0C); for (short i = 0; i < 10; i++) { g_Console.writeToBuffer(COORD{ i==9?9:10,i*2 + 11 }, std::to_string(i+1), 0x0C); g_Console.writeToBuffer(COORD{ 60,i*2 + 11 }, std::to_string(g_iHighscore[i]), 0x0C); } g_Console.writeToBuffer(COORD{ 30,32 }, "PRESS ENTER TO EXIT", 0x0C); } void renderWin() { for (short s = 0; s < 35; s++) { g_Console.writeToBuffer(COORD{ 10,s + 3 }, *(g_asWinScreen[s]), 0x0A); } g_Console.writeToBuffer(COORD{ 33,10 }, "LEADERBOARD", 0X0A); for (short i = 0; i < 10; i++) { g_Console.writeToBuffer(COORD{ i == 9 ? 9 : 10,i * 2 + 11 }, std::to_string(i + 1), 0x0A); g_Console.writeToBuffer(COORD{ 60,i * 2 + 11 }, std::to_string(g_iHighscore[i]), 0x0A); } g_Console.writeToBuffer(COORD{ 30,32 }, "PRESS ENTER TO EXIT", 0x0A); } void renderMap() { for(SHORT i = 0; i < 80 * 28; i++) { g_Console.writeToBuffer(COORD{i%80, i/80}, g_sLevel->getFeatureAt(i%80,i/80)->getMapChar(), g_sVisible->getTileVisibility(COORD{i%80,i/80})?g_sLevel->getFeatureAt(i%80,i/80)->getMapColor():(g_sLevel->getFeatureAt(i%80,i/80)->getMapColor()%16 != 0?0x08:0x80)); } } void renderCharacter() { // Draw the location of the character g_Console.writeToBuffer(g_sChar.m_cLocation, '@', 0x0F); } void renderInventory() { for (short s = 0; s < 35; s++) { g_Console.writeToBuffer({ 0,s }, *(g_asInventoryScreen[s]), 0x0F); } COORD c = { 11, 17 }; for (int i = ((g_sChar.m_iInventoryPage - 1) * 8) + 6; i < g_sChar.m_iInventoryPage * 8 + 6; i++) { if (g_sChar.m_sInventory->m_asContents[i] == nullptr) continue; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[i]->m_cDroppedIcon, g_sChar.m_sInventory->m_asContents[i]->m_cDroppedColour); c.X++; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[i]->m_sName); c.Y += 2; c.X--; } for (int i = 0; i < 6; i++) { if (g_sChar.m_sInventory->m_asContents[i] == nullptr) { continue; } else { COORD c = { 67, 12 }; g_Console.writeToBuffer({ (SHORT)(c.X - (i * 11) - (g_sChar.m_sInventory->m_asContents[i]->m_sEquippedName1.length() / 2)), c.Y }, g_sChar.m_sInventory->m_asContents[i]->m_sEquippedName1); g_Console.writeToBuffer({ (SHORT)(c.X - (i * 11) - (g_sChar.m_sInventory->m_asContents[i]->m_sEquippedName2.length() / 2)), c.Y + 1 }, g_sChar.m_sInventory->m_asContents[i]->m_sEquippedName2); } } for (int i = (((g_sChar.m_iInventoryPage - 1) * 8)+1); i < (g_sChar.m_iInventoryPage * 8)+1; i++) { COORD c = { 9, 17 }; std::string sInventoryNumber = std::to_string(i) + "."; c.Y += ((i-1)%8)*2; if (i < 10) { g_Console.writeToBuffer(c, sInventoryNumber, 0x0f); } else { g_Console.writeToBuffer(c.X - 1, c.Y, sInventoryNumber, 0x0f); } } if (g_sChar.m_sInventory->m_asContents[g_sChar.m_iInventoryIndex] != nullptr) { renderItemStats(g_sChar.m_iInventoryIndex); } gameplayInventory(); } void renderItemStats(int itemIndex) { COORD c = { 52, 19 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sHealth.length() / 2; // Centering the text under the stats g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sHealth); // Writes health modifier of the currently selected equipment in the inventory c.X = 68; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sMana.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sMana); c = { 52, 21 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sAttack.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sAttack); c.X = 68; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDefense.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDefense); c = { 59, 23 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial1.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial1); c = { 59, 24 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial2.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial2); c = { 59, 25 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial3.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial3); c = { 59, 26 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial4.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sSpecial4); c = { 60, 28 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription1.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription1); c = { 60, 29 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription2.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription2); c = { 60, 30 }; c.X = c.X - g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription3.length() / 2; g_Console.writeToBuffer(c, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sDescription3); if (itemIndex <= 5) { g_Console.writeToBuffer({ (SHORT)(40 - (g_sChar.m_sInventory->m_asContents[itemIndex]->m_sName.length() / 2)), 3 }, g_sChar.m_sInventory->m_asContents[itemIndex]->m_sName); } } void renderFramerate() { COORD c; // displays the framerate std::ostringstream ss; ss << std::fixed << std::setprecision(3); ss << 1.0 / g_dDeltaTime << "fps"; c.X = g_Console.getConsoleSize().X - 9; c.Y = 0; g_Console.writeToBuffer(c, ss.str()); // displays the elapsed time ss.str(""); ss << g_dElapsedTime << "secs"; c.X = 0; c.Y = 0; g_Console.writeToBuffer(c, ss.str(), 0x59); } void renderToScreen() { // Writes the buffer to the console, hence you will see what you have written g_Console.flushBufferToConsole(); } SGameChar::~SGameChar() { if (this->m_sInventory != nullptr) { delete this->m_sInventory; } } void SGameChar::takeDamage(SDamagePacket * sDamage) { m_iHealth -= sDamage->m_iDamage; sDamage->printHitMessage(); if(m_iHealth <= 0) die(); _PLAY_SOUND(L"hit.wav") }
0b5a08fe6e45e8e15da2f3121078e64b7b551ff5
934e9946d94f584da218798ae4e386d4ffcd68fc
/main_memory.h
666bfd6873cce1809d76f85e0bc43e0593e56664
[]
no_license
rh16238/arch
2f7671ec1e81f5d6b4c78e064eca227e9b6a3646
42cf94b7819a0527c7ec53bfc591d4251f41f0bf
refs/heads/master
2020-09-30T23:10:05.509957
2020-01-24T08:37:29
2020-01-24T08:37:29
227,396,433
0
0
null
null
null
null
UTF-8
C++
false
false
457
h
main_memory.h
#pragma once #include "math_utils.h" class main_memory { public: const static int time_cost = 20; main_memory(const std::vector<int64_t>& memory_bank); main_memory(); int64_t access_location(int64_t memory_location); void set_location(int64_t memory_location, int64_t value); void clock_tick(); const std::vector<int64_t>& return_memory(); private: const static int mem_size = 1024; std::vector<int64_t> memory_bank{ 1024,0 }; };
96feea8e9516a21a5cc9d9d58da9b25755f1b849
792f2ee67210556f224daf88ef0b9785becadc9b
/atcoder/Other/CF2017A-B.cpp
3ab32552955c168046ba450c621002499cc17e9c
[]
no_license
firiexp/contest_log
e5b345286e7d69ebf2a599d4a81bdb19243ca18d
6474a7127d3a2fed768ebb62031d5ff30eeeef86
refs/heads/master
2021-07-20T01:16:47.869936
2020-04-30T03:27:51
2020-04-30T03:27:51
150,196,219
0
0
null
null
null
null
UTF-8
C++
false
false
532
cpp
CF2017A-B.cpp
#include <iostream> #include <algorithm> #include <vector> #include <iomanip> #include <map> #include <queue> static const int INF = 1000000007; using ll = long long; using u32 = unsigned; using namespace std; int main() { int n, m, k; cin >> n >> m >> k; for (int i = 0; i <= n; ++i) { for (int j = 0; j <= m; ++j) { if(i*m + n*j - 2*i*j == k) { cout << "Yes\n"; return 0; } } } cout << "No\n"; return 0; }
3919e5f40421b190fdc3772d402f1779eee31288
38b15ffd75dc2b44c644c72e7012bbd240533775
/tests/spotty_network_failure_test.cpp
d3468bad4e3cbed9b11804b85a5e46a5590e15e2
[ "BSD-3-Clause", "BSD-2-Clause" ]
permissive
brettdh/libcmm
8ef3bb1302badb28622fc0b18a4b6de33d3a4c0c
66745da7ff64261713dda7de7e6d3d3eae4a98d9
refs/heads/master
2021-01-19T20:15:55.702155
2015-09-16T18:01:09
2015-09-16T18:01:09
25,616,631
0
1
null
null
null
null
UTF-8
C++
false
false
8,860
cpp
spotty_network_failure_test.cpp
#include <cppunit/extensions/HelperMacros.h> #include "spotty_network_failure_test.h" #include <errno.h> #include <stdlib.h> #include <unistd.h> #include <sys/types.h> #include <sys/stat.h> #include <limits.h> #include <fcntl.h> #include <sys/wait.h> #include <sys/socket.h> #include <netdb.h> #include <netinet/in.h> #include <arpa/inet.h> #include <assert.h> #include <string.h> #include <libcmm.h> #include <libcmm_irob.h> #include "net_interface.h" #include "test_common.h" #include "cmm_socket_control.h" #include "libcmm_ipc.h" #include "timeops.h" #include <string> #include <vector> using std::string; using std::vector; #include "proxy_socket.h" CPPUNIT_TEST_SUITE_REGISTRATION(SpottyNetworkFailureTest); /* In the process of revising this test as follows. * * What this test currently does: * 1) Fake a multisocket on the server end. * 2) Connect a real multisocket to the fake one. * 3) Shut down one of the TCP sockets. * 4) Try to send/receive data. * * The trouble with this approach is that the multisocket can * detect the TCP connection being shut down and react to it. * I really want to test what happens when the TCP connection * just stops receiving any messages (including FIN, for example). * * What the revised test will do: * 1) Create a real multisocket on the server end. * 2) Create proxy sockets: * a) Between the IntNW listen socket and the client * b) Between the multisocket's internal listen socket * and the client's connecting csockets * 3) Rewrite the necessary messages to keep the multisocket * endpoints unaware of the proxy: * a) The listener port in the initial HELLO response * 4) Snoop on the csocket setup messages to determine which * one should be considered FG * 5) Stop proxying data on that csocket. * 6) Try to send/receive FG data. */ const in_port_t SpottyNetworkFailureTest::PROXY_PORT = 4243; const in_port_t SpottyNetworkFailureTest::INTNW_LISTEN_PORT = 42424; bool process_chunk(int to_sock, char *chunk, size_t len, SpottyNetworkFailureTest *test, SpottyNetworkFailureTest::chunk_proc_method_t processMethod) { return (test->*processMethod)(to_sock, chunk, len); } bool process_bootstrap(int to_sock, char *chunk, size_t len, SpottyNetworkFailureTest *test) { return process_chunk(to_sock, chunk, len, test, &SpottyNetworkFailureTest::processBootstrap); } bool process_data(int to_sock, char *chunk, size_t len, SpottyNetworkFailureTest *test) { return process_chunk(to_sock, chunk, len, test, &SpottyNetworkFailureTest::processData); } void SpottyNetworkFailureTest::setupReceiver() { bootstrap_done = false; fg_socket_rtt = INT_MAX; fg_proxy_thread = (pthread_t) -1; pthread_mutex_init(&proxy_threads_lock, NULL); setListenPort(PROXY_PORT); start_proxy_thread(&bootstrap_proxy_thread, TEST_PORT, PROXY_PORT, (chunk_proc_fn_t) process_bootstrap, this); start_proxy_thread(&internal_data_proxy_thread, INTNW_LISTEN_PORT + 1, INTNW_LISTEN_PORT, (chunk_proc_fn_t) process_data, this); EndToEndTestsBase::setupReceiver(); } bool SpottyNetworkFailureTest::processBootstrap(int to_sock, char *chunk, size_t len) { // overwrite internal-listener port with the proxy's port struct sockaddr_in addr; memset(&addr, 0, sizeof(addr)); socklen_t addrlen = sizeof(addr); if (!bootstrap_done && getsockname(to_sock, (struct sockaddr *) &addr, &addrlen) == 0 && ntohs(addr.sin_port) == TEST_PORT) { // only modify the hello response, not the request struct CMMSocketControlHdr *hdr = (struct CMMSocketControlHdr *) chunk; if (ntohs(hdr->type) == CMM_CONTROL_MSG_HELLO) { in_port_t listener_port = ntohs(hdr->op.hello.listen_port); printf("Overwriting listener port %hu in hello response with proxy port %hu\n", listener_port, INTNW_LISTEN_PORT + 1); hdr->op.hello.listen_port = htons(INTNW_LISTEN_PORT + 1); bootstrap_done = true; } } return true; } bool SpottyNetworkFailureTest::processData(int to_sock, char *chunk, size_t len) { struct sockaddr_in addr; memset(&addr, 0, sizeof(addr)); socklen_t addrlen = sizeof(addr); int rc = getpeername(to_sock, (struct sockaddr *) &addr, &addrlen); if (rc != 0) { fprintf(stderr, "Error: getpeername failed: %s\n", strerror(errno)); } else { printf("In processData: checking message heading for %s:%hu\n", inet_ntoa(addr.sin_addr), ntohs(addr.sin_port)); } pthread_mutex_lock(&proxy_threads_lock); if (proxy_threads.size() < 2 && ntohs(addr.sin_port) == INTNW_LISTEN_PORT) { printf("Looking for new_interface message\n"); struct CMMSocketControlHdr *hdr = (struct CMMSocketControlHdr *) chunk; // XXX: make sure this is in fact the new_interface message for the new csocket // XXX: (probably not strictly necessary, since that message // XXX: is the first message on the csocket, but still // XXX: a good sanity check.) if (ntohs(hdr->type) == CMM_CONTROL_MSG_NEW_INTERFACE) { if (ntohl(hdr->op.new_interface.RTT) < fg_socket_rtt) { fg_socket_rtt = ntohl(hdr->op.new_interface.RTT); fg_proxy_thread = pthread_self(); TIME(fg_proxy_start_time); printf("Now treating iface with RTT %d (%s) as FG\n", (int) fg_socket_rtt, inet_ntoa(hdr->op.new_interface.ip_addr)); } proxy_threads.insert(pthread_self()); } } bool ret = true; if (fg_proxy_thread == pthread_self()) { struct timeval now, diff; TIME(now); TIMEDIFF(fg_proxy_start_time, now, diff); pthread_mutex_unlock(&proxy_threads_lock); if (diff.tv_sec >= 1) { ret = false; } else { ret = true; } } else { pthread_mutex_unlock(&proxy_threads_lock); ret = true; } printf("%s a %d-byte message to %s:%hu\n", ret ? "Proxying" : "Suppressing", (int) len, inet_ntoa(addr.sin_addr), ntohs(addr.sin_port)); return ret; } void SpottyNetworkFailureTest::tearDown() { if (isReceiver()) { EndToEndTestsBase::tearDown(); stop_proxy_thread(internal_data_proxy_thread); stop_proxy_thread(bootstrap_proxy_thread); } else { EndToEndTestsBase::tearDown(); } } int connect_to_scout_control() { int sock = socket(PF_INET, SOCK_STREAM, 0); handle_error(sock < 0, "creating scout control socket"); struct sockaddr_in addr; memset(&addr, 0, sizeof(addr)); addr.sin_family = AF_INET; addr.sin_addr.s_addr = htonl(INADDR_LOOPBACK); addr.sin_port = htons(CONTROL_SOCKET_PORT); socklen_t addrlen = sizeof(addr); int rc = connect(sock, (struct sockaddr *)&addr, addrlen); handle_error(rc < 0, "connecting scout control socket"); return sock; } void SpottyNetworkFailureTest::testOneNetworkFails() { const char expected_str[] = "ABCDEFGHIJ"; const size_t len = strlen(expected_str); char buf[len + 1]; memset(buf, 0, sizeof(buf)); if (isReceiver()) { fd_set readable; FD_ZERO(&readable); FD_SET(data_sock, &readable); struct timeval timeout = {4, 0}; int rc = cmm_select(data_sock + 1, &readable, NULL, NULL, &timeout); CPPUNIT_ASSERT_EQUAL(1, rc); rc = cmm_read(data_sock, buf, len, NULL); CPPUNIT_ASSERT_EQUAL((int)len, rc); CPPUNIT_ASSERT_EQUAL(string(expected_str), string(buf)); rc = cmm_write(data_sock, expected_str, len, CMM_LABEL_ONDEMAND, NULL, NULL); CPPUNIT_ASSERT_EQUAL((int) len, rc); } else { int scout_control_sock = connect_to_scout_control(); sleep(1); int rc = cmm_write(data_sock, expected_str, len, CMM_LABEL_ONDEMAND, NULL, NULL); CPPUNIT_ASSERT_EQUAL((int)len, rc); // succeeds immediately without waiting for bytes to be sent sleep(5); char cmd[] = "bg_down\n"; rc = write(scout_control_sock, cmd, strlen(cmd)); CPPUNIT_ASSERT_EQUAL((int) strlen(cmd), rc); sleep(1); memset(buf, 0, sizeof(buf)); rc = cmm_recv(data_sock, buf, len, MSG_WAITALL, NULL); CPPUNIT_ASSERT_EQUAL((int) len, rc); CPPUNIT_ASSERT_EQUAL(string(expected_str), string(buf)); close(scout_control_sock); } }
2a6471a9f8d880917bd6390a1dcb908da6865816
c460942da15f6c487041623300372302f09cff09
/VirtualLCD.cpp
67e59d9413c6cd6dfc8cbdd6ccd0d15c75a828ed
[]
no_license
MajenkoLibraries/VirtualLCD
c3c2935a93ef6e467ec8f5420df339e0523daa5b
57742a2e01a5e2b1ecb36f13f1f8f21192c4ac2d
refs/heads/master
2020-12-25T18:18:57.041760
2020-04-25T19:38:08
2020-04-25T19:38:08
28,677,200
0
0
null
null
null
null
UTF-8
C++
false
false
2,082
cpp
VirtualLCD.cpp
#include <VirtualLCD.h> static const uint8_t CMD_PUSH = 129; static const uint8_t CMD_SET_DIM = 130; static const uint8_t CMD_SET_BG = 131; static const uint8_t CMD_SET_FG = 132; static const uint8_t CMD_SET_PIX = 133; static const uint8_t CMD_CLR_PIX = 134; static const uint8_t CMD_SET_LINE = 135; static const uint8_t CMD_CLR_LINE = 136; void _VirtualLCD::begin() { begin(Serial); } void _VirtualLCD::begin(Stream &s) { _ser = &s; _width = 64; _height = 64; } void _VirtualLCD::push(uint8_t v) { _ser->write(CMD_PUSH); _ser->write('a' + (v & 0x0F)); _ser->write('a' + ((v >> 4) & 0x0F)); } void _VirtualLCD::setPixel(uint8_t x, uint8_t y) { push(x); push(y); _ser->write(CMD_SET_PIX); } void _VirtualLCD::clearPixel(uint8_t x, uint8_t y) { push(x); push(y); _ser->write(CMD_CLR_PIX); } void _VirtualLCD::drawLine(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, boolean col) { push(x0); push(y0); push(x1); push(y1); if (col) { _ser->write(CMD_SET_LINE); } else { _ser->write(CMD_CLR_LINE); } } void _VirtualLCD::setSize(uint8_t x, uint8_t y) { push(x); push(y); _ser->write(CMD_SET_DIM); _width = x; _height = y; } void _VirtualLCD::setBackground(uint8_t r, uint8_t g, uint8_t b) { push(r); push(g); push(b); _ser->write(CMD_SET_BG); } void _VirtualLCD::setForeground(uint8_t r, uint8_t g, uint8_t b) { push(r); push(g); push(b); _ser->write(CMD_SET_FG); } void _VirtualLCD::sendData(uint8_t *data) { boolean first = true; uint32_t pos = 0; for (int y = 0; y < _height; y++) { for (int x = 0; x < _width / 8; x++) { sendByte(data[pos++], first); first = false; } } } void _VirtualLCD::sendByte(uint8_t v, boolean startbit) { uint8_t b1 = v >> 4; uint8_t b2 = v & 0x0F; if (startbit) { b1 += 'A'; b2 += 'a'; } else { b1 += 'a'; b2 += 'a'; } _ser->write(b1); _ser->write(b2); } _VirtualLCD VirtualLCD;
e3843c3bbd5ea5ac45e2e74107948927d042d3d8
54bfb2e571688b860fb3e84efd3ac50d20e86878
/dia6/1524_cafeteria_uri.cpp
951323049132fc6031df287ad67715eda1f164e1
[]
no_license
msclar/tc-chaco-2016
4252c4001ef44c096d06c2dee9334c5a758f99eb
aa3d28f518f30734afa4b875f140f590b9d875df
refs/heads/master
2021-01-20T19:27:15.072343
2016-07-29T18:00:38
2016-07-29T18:00:38
64,238,343
0
0
null
null
null
null
UTF-8
C++
false
false
391
cpp
1524_cafeteria_uri.cpp
#include <iostream> #include <algorithm> using namespace std; int main () { int dif[1001], pos[1001], n, k, res; while (cin >> n >> k) { pos[0] = 0; for (int i = 1; i < n; i++) { cin >> pos[i]; dif[i-1] = - pos[i] + pos[i-1]; } sort(dif, dif+n-1); res = pos[n-1] - pos[0]; for (int i = 0; i < k-1; i++) { res += dif[i]; } cout << res << endl; } return 0; }
27ee96b367ebdffa2eb3f66f7f66e813f8072360
440fe9bc55a3d9fc44410d1748f47fbc74e30506
/anycloud39ev300/SDK/component/NetCamera/IPCamera_ViewTool/Anyka IP CameraDlg.h
05ac5e6a25cb95656324d299864c36302d3ba396
[]
no_license
haihoang1219931/qiwen
5def7764f48e70a8c4fbb9692f5fd0714dcb5a20
6c86facd09a5c2efe5314a669f653fa90acbc999
refs/heads/main
2023-07-10T17:37:18.512888
2021-08-22T07:01:43
2021-08-22T07:01:43
null
0
0
null
null
null
null
GB18030
C++
false
false
7,979
h
Anyka IP CameraDlg.h
// Anyka IP CameraDlg.h : 头文件 // #pragma once #include "NetTalk.h" #include "ImageToolBar.h" #include "afxcmn.h" #include "PreviewDialog.h" #include "Aimer39RTSPClient.h" #include "FfmpegEnvoy.h" #include "VideoRender.h" #include "ServerSearch.h" #include "afxwin.h" #include "PrivacyDialog.h" #include "MotionDetectDlg.h" #include "RecordPlayDlg.h" #include "AutoLock.h" #include "AudioRender.h" #include "ClientSocket.h" #define PREVIEW_WINDOWS 2 #define SUPPORT_STREAM_CNT 2 #define SUPPORT_AUDIO_STREAM_CNT 1 #define ONLY_AUDIO_STREAM_START_IDX 2 #define AP_ADDRESS_LEN (MAX_PATH + 24) #pragma pack(1) typedef struct { short len; char commad_type; BOOL auto_test_flag; char *file_name; //len+name char *data_param; short check_sum; }T_NET_INFO; #pragma pack() typedef enum VideoFunction_en { VF_PRIVACY_AREA, VF_MOTION_DETECT, VF_PLAY, VF_MAX }VIDEOFUNCTION; typedef struct tag_KickOutMessageWParam_st { unsigned long ulIpAddr; unsigned long ulPort; }KickOutMessageWParam; enum { TEST_COMMAND = 1, TEST_RESPONSE, TEST_HEARTBEAT, TEST_COMMAND_FINISH, TEST_COMMAND_START }; // CAnykaIPCameraDlg 对话框 class CAnykaIPCameraDlg : public CDialog { // 构造 public: CAnykaIPCameraDlg(CWnd* pParent = NULL); // 标准构造函数 virtual ~CAnykaIPCameraDlg(){} // 对话框数据 enum { IDD = IDD_ANYKAIPCAMERA_DIALOG }; protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持 static void __stdcall OnClientFinish(void * pLParam, void * pRParam); static void __stdcall OnClientDisConnect(void * pLParam, void * pRParam); static void __stdcall OnFullScreenMessage(UINT message, WPARAM wParam, LPARAM lParam, void * pClassParam); static void __stdcall OnTalkKickOut(IServer * pIServer, unsigned long ulIpAddr, unsigned short usPort, void * pClassParam); static void __stdcall OnServerReturnInfo(IServer * pIServer, RETINFO * pstRetInfo, void * pClassParam); // 实现 protected: HICON m_hIcon; void InitToolBar(); void InitStatusBar(); void InitTreeCtrlPosition(); void InitPreviewWindows(BOOL bNeedCreate = TRUE, BOOL bfull_flag = TRUE); void InitComboBox(); void UpdateCombo(); void InitPrivacyDialog(); // 生成的消息映射函数 virtual BOOL OnInitDialog(); virtual BOOL PreTranslateMessage(MSG * pMsg); afx_msg void OnSysCommand(UINT nID, LPARAM lParam); afx_msg void OnPaint(); afx_msg HCURSOR OnQueryDragIcon(); DECLARE_MESSAGE_MAP() char * MakeRTSPUrl(); int CloseTheStream(int iSelect, BOOL bNeedCloseAudio = FALSE); int OpenTheStream(int iSelect, const char * strURL = NULL, BOOL bNeedENotify = TRUE); afx_msg void OnPrivacyArea(); afx_msg void OnMotionDetect(); afx_msg void OnPicture(); afx_msg void OnRecord(); afx_msg void OnPlay(); afx_msg void OnZoomIn(); afx_msg void OnZoomOut(); afx_msg void OnVolumeMinus(); afx_msg void OnVolumePlus(); afx_msg void OnStopRecord(); int OnAudioInOpen(int nAudioClientIndex); int OnAudioInClose(int nAudioClientIndex); afx_msg void OnTvnSelchangedTree1(NMHDR *pNMHDR, LRESULT *pResult); afx_msg void OnNMRClickTree1(NMHDR *pNMHDR, LRESULT *pResult); afx_msg void OnClose(); afx_msg void OnSearchDevice(); afx_msg void OnTimer(UINT_PTR nIDEvent); afx_msg void OnPreviewchoose1(); afx_msg void OnPreviewchoose2(); BOOL OnPreviewchoose_test(); void MakeAndSendImageSet(); afx_msg void OnCbnSelchangeContrastCombo(); afx_msg void OnCbnSelchangeBrightnessCombo(); afx_msg void OnCbnSelchangeSaturationCombo(); afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point); afx_msg void OnLButtonDown(UINT nFlags, CPoint point); afx_msg void OnLButtonUp(UINT nFlags, CPoint point); afx_msg void OnRButtonDblClk(UINT nFlags, CPoint point); afx_msg void OnRButtonDown(UINT nFlags, CPoint point); afx_msg void OnMouseMove(UINT nFlags, CPoint point); afx_msg void OnBnClickedButtonLeft(); afx_msg void OnBnClickedButtonUp(); afx_msg void OnBnClickedButtonRight(); afx_msg void OnBnClickedButtonDown(); afx_msg void OnBnClickedButtonLeftRight(); afx_msg void OnBnClickedButtonUpDown(); afx_msg void OnBnClickedButtonRepositionSet(); afx_msg void OnBnClickedButtonReposition(); afx_msg void OnPreviewdlgchooseTalkOpen(); afx_msg void OnPreviewdlgchooseTalkClose(); afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags); afx_msg void OnSysKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags); afx_msg void OnSize(UINT nType, int cx, int cy); afx_msg LRESULT OnTalkKickOutMessage(WPARAM wParam, LPARAM lParam); afx_msg LRESULT OnServerDisconnect(WPARAM wParam, LPARAM lParam); afx_msg LRESULT OnServerRetInfo(WPARAM wParam, LPARAM lParam); afx_msg void OnPreviewdlgchoose1ClosePreview(); afx_msg void OnPreviewdlgchooseClosePreview(); BOOL CanDoTheJob(); int RegisterThePreviewServer(IServer * pIServer, int iSelect, const char * strURL); int UnregisterThePreviewServer(int iSelect); int ShutDownTheStream(int iSelect); static unsigned int WINAPI thread_begin( void * pParam ); void UpdateTreeNode(IServer * UpdateServer); int ServerDisConnect(int iSelect); void Monitor(); void VideoFunctionOpenProcess(VIDEOFUNCTION enVFun); void FullScreenProcess(BOOL bIsFullScreen, int iSelect); void CameraMovement(CAMERAMOVEMENT movement); void TempCloseTalk(int iIndex); void RepositionWidget(); void PositionTheButton(); void PositionTheImageCombo(); void WiatForMonitorThreadEnd(); BOOL read_config(LPCTSTR file_path); TCHAR *ConvertAbsolutePath(LPCTSTR path); private: CTreeCtrl m_TreeCtrl; CImageToolBar m_ToolBar; CStatusBar m_StatusBar; CMenu m_menuTalk; CNetTalk m_NetTalk; CAimer39RTSPClient * m_pClient[SUPPORT_STREAM_CNT]; CFfmpegEnvoy * m_videoDecoder[SUPPORT_STREAM_CNT]; CFfmpegEnvoy * m_AudioDecoder[SUPPORT_STREAM_CNT]; CVideoRender * m_videoRender[SUPPORT_STREAM_CNT]; CAudioRender * m_AudioRender[SUPPORT_STREAM_CNT]; CClock m_SyncClock[PREVIEW_WINDOWS]; CPreviewDialog m_Preview[PREVIEW_WINDOWS]; IServer * m_pServerPreviews[PREVIEW_WINDOWS]; string m_strURL[PREVIEW_WINDOWS]; volatile int m_nRBChoosePrevIndex; volatile int m_nAudioClientIndex; volatile int m_nVideoFullScreenIndex; int m_nLongPressButtonID; CServerSearch m_Search; HTREEITEM m_hCurrentSelectItem; CComboBox m_ContrastCombo, m_SaturationCombo, m_BrightnessCombo; CComboBox m_acutanceCom; CPrivacyDialog m_PrivacyDialog; CMotionDetectDlg m_MotionDetectDlg; CRecordPlayDlg m_RecordPlayDlg; KickOutMessageWParam m_stKickOutParam; RETINFO m_stRetInfo; HANDLE m_MonitorThread; BOOL m_runThreadFlag, m_bNeedJudgeDisConnWork, m_bIsInit, m_bPicture, m_bIsLongPress, m_bIsLongPressDone, m_bIsSearch; CriticalSection m_csForServerConnect, m_csForOpenCloseStream, m_csForTalkOpen, m_csForKickOut, m_csForRet; public: CClientSocket m_ClientSocket; TCHAR m_path[MAX_PATH+1]; CString m_username; CString m_password; char m_ircut_flag; afx_msg void OnCbnSelchangeCombo4(); BOOL Creat_Anyka_Test_thread() ; void Close_Anyka_Test_thread() ; BOOL Anyka_Test_thread(); afx_msg void OnBnClickedRadioIrcutOn(); afx_msg void OnBnClickedButtonSet(); afx_msg void OnBnClickedRadioIrcutOff(); BOOL ConnetServer(LPCTSTR addr, UINT idex); BOOL Connet_FTPServer(LPCTSTR addr, UINT idex); BOOL decode_command(char *lpBuf, char *commad_type, char *file_name, char *param); BOOL create_thread_rev_data(UINT idex); void close_thread_rev_data() ; BOOL Send_cmd(char commad_type, BOOL auto_test_flag, char *file_name, char *param); BOOL Anyka_Test_check_info(void); void CloseServer(void); BOOL OnSend_data(void); BOOL Anyka_connet(void); BOOL find_file_indir(TCHAR *file_name, UINT *name_len); afx_msg void OnBnClickedButtonRecoverDev(); };
ba4c1f36db0ef23a6d0610ff70958a6b1ff23039
554868ca307bc4bd42bd1cc7675c95acfb525a69
/trunk/src/gui/mi/stateterminate.cpp
4a46a3ea1d83a8d7cc235863c311d35f20d58499
[]
no_license
Lins5682/program
9f38ad9a2ce0fba6f8ceb7351f36270ff1041d50
342dad28f9c99e9e7a5517e186cdf01d85a7a364
refs/heads/master
2021-07-23T08:33:44.166981
2017-11-01T06:17:22
2017-11-01T06:17:22
109,094,895
0
0
null
null
null
null
UTF-8
C++
false
false
294
cpp
stateterminate.cpp
#include "state.h" TerminateState::TerminateState(QWidget *w,QObject *parent) { terminate = new Terminate(w); currPage = terminate; } TerminateState::~TerminateState() { DELETE(terminate); } void TerminateState::entered() { terminate->show(); terminate->showWaiting(); }
e304df45fe96c6e815dcdd8d489a0ed6c4d64ea0
58f884716c972f360a2abbadd7bc614dffab5b85
/TimeBubblePrototypes/TimeBubbleLib/SoundManager.h
35d771e25fbca21f13653801ed42aeefac49b1f8
[]
no_license
janoldsen/Time-Bubble
6dbe4732121f4fec9d1c62d23ab6a8a47c9ed05e
536e3700a5d61590cfa5d4ceaf79e52f375a9c41
refs/heads/master
2016-09-05T10:32:26.420330
2015-07-19T20:29:11
2015-07-19T20:29:11
39,346,712
0
0
null
null
null
null
UTF-8
C++
false
false
505
h
SoundManager.h
#ifndef SOUND_MANAGER_H #define SOUND_MANAGER_H #include <SFML\Audio.hpp> #include <map> class SoundManager { public: sf::SoundBuffer& getSound(std::string fileName); void load(std::string fileName); void unLoad(std::string fileName); static SoundManager* getInstance(); private: static SoundManager instance; SoundManager() {}; SoundManager(SoundManager& SoundManager); SoundManager& operator=(const SoundManager& soundManager); std::map<std::string, sf::SoundBuffer> mSounds; }; #endif
b1637cd4a79c06a60bcd12e5e7b0e98fc51d32b5
6bcdb9e8836cd60e972be865beb50fbfefdfa650
/libs/options/include/fcppt/options/detail/concrete_decl.hpp
a08a8ea3d854df1c5ad6f730a93648f5dc33ccb7
[ "BSL-1.0" ]
permissive
pmiddend/fcppt
4dbba03f7386c1e0d35c21aa0e88e96ed824957f
9f437acbb10258e6df6982a550213a05815eb2be
refs/heads/master
2020-09-22T08:54:49.438518
2019-11-30T14:14:04
2019-11-30T14:14:04
225,129,546
0
0
BSL-1.0
2019-12-01T08:31:12
2019-12-01T08:31:11
null
UTF-8
C++
false
false
1,437
hpp
concrete_decl.hpp
// Copyright Carl Philipp Reh 2009 - 2018. // Distributed under the Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) #ifndef FCPPT_OPTIONS_DETAIL_CONCRETE_DECL_HPP_INCLUDED #define FCPPT_OPTIONS_DETAIL_CONCRETE_DECL_HPP_INCLUDED #include <fcppt/noncopyable.hpp> #include <fcppt/string.hpp> #include <fcppt/options/base_decl.hpp> #include <fcppt/options/flag_name_set.hpp> #include <fcppt/options/option_name_set.hpp> #include <fcppt/options/parse_context_fwd.hpp> #include <fcppt/options/parse_result_fwd.hpp> #include <fcppt/options/state_fwd.hpp> #include <fcppt/options/detail/concrete_fwd.hpp> namespace fcppt { namespace options { namespace detail { template< typename Result, typename Parser > class concrete : public fcppt::options::base< Result > { typedef fcppt::options::base< Result > base_type; FCPPT_NONCOPYABLE( concrete ); public: explicit concrete( Parser && ); ~concrete() override; typedef Result result_type; fcppt::options::parse_result< result_type > parse( fcppt::options::state &&, fcppt::options::parse_context const & ) const override; fcppt::options::flag_name_set flag_names() const override; fcppt::options::option_name_set option_names() const override; fcppt::string usage() const override; private: Parser const parser_; }; } } } #endif
efaef483e7448b9003cf66d1e905943c679ff316
60aa54a3969a506a275ac033471f3d15b8c4ae68
/database/table/TableStaticAnalyzer.cpp
1424ac9d2bdcff421b58cb441a6e8665413d10f0
[]
no_license
IRETD/TestSystemServer
5e9cf9bb7a3d6825523dfe52d435fca3d8876cdb
78ec19579c363d99dae9ecd36f01483d05335fcc
refs/heads/master
2021-09-10T02:36:31.703918
2018-03-20T18:47:24
2018-03-20T18:47:24
126,066,409
0
0
null
null
null
null
UTF-8
C++
false
false
2,560
cpp
TableStaticAnalyzer.cpp
#include "TableStaticAnalyzer.h" quint32 TableStaticAnalyzer::insert( quint32 idAboutHistory, TestResult idResult, OurQueryInfo &queryInfo ) { m_Db.startTransaction(); QSqlQuery query( QSqlDatabase::database( m_Db.getConnectionName() ) ); query.prepare( "INSERT INTO static_analyzer(id_about_history, id_result) " "VALUES(:id_about_history, :id_result)" ); query.bindValue( ":id_about_history", idAboutHistory ); query.bindValue( ":id_result", static_cast < int > ( idResult ) ); if ( query.exec() ) { query.prepare( "SELECT LAST_INSERT_ID();" ); if ( query.exec() ) { QSqlRecord rec = query.record(); if ( query.first() && query.isValid() ) { quint32 idStaticAnalyzer = query.value( rec.indexOf( "LAST_INSERT_ID()" ) ).toInt(); queryInfo.setResult( true ); query.finish(); m_Db.commit(); queryInfo.setTypeError( query.lastError().type() ); queryInfo.setNumberError( query.lastError().number() ); queryInfo.setDescription( query.lastError().text() ); return idStaticAnalyzer; } } } queryInfo.setTypeError( query.lastError().type() ); queryInfo.setNumberError( query.lastError().number() ); queryInfo.setDescription( query.lastError().text() ); m_Db.rollback(); return QUERY_ERROR; } quint32 TableStaticAnalyzer::getIdStaticAnalyzer( quint32 idAboutHistory, OurQueryInfo &queryInfo ) { QSqlQuery query( QSqlDatabase::database( m_Db.getConnectionName() ) ); query.prepare( "SELECT id_static_analyzer FROM static_analyzer WHERE id_about_history = :id_about_history" ); query.bindValue( ":id_about_history", idAboutHistory ); query.exec(); int idStaticAnalyzer; if ( query.size() > 0 ) { QSqlRecord rec = query.record(); if ( query.first() && query.isValid() ) { queryInfo.setResult( true ); idStaticAnalyzer = query.value( rec.indexOf( "id_static_analyzer" ) ).toInt(); } } queryInfo.setTypeError( query.lastError().type() ); queryInfo.setNumberError( query.lastError().number() ); queryInfo.setDescription( query.lastError().text() ); return idStaticAnalyzer; } TableStaticAnalyzer::TableStaticAnalyzer( const OurDataBase &db ) { m_Db = db; }
36fe0cb3ebc49e288d9979d8262180067948e6a2
a33aac97878b2cb15677be26e308cbc46e2862d2
/program_data/PKU_raw/31/234.c
03940491e1099911eb3cf4e8e95e4a68d87976a0
[]
no_license
GabeOchieng/ggnn.tensorflow
f5d7d0bca52258336fc12c9de6ae38223f28f786
7c62c0e8427bea6c8bec2cebf157b6f1ea70a213
refs/heads/master
2022-05-30T11:17:42.278048
2020-05-02T11:33:31
2020-05-02T11:33:31
null
0
0
null
null
null
null
UTF-8
C++
false
false
667
c
234.c
struct student { char num[15]; char name[20]; char sex; int age; char score[10]; char add[30]; struct student *next; }; int main() { int n,i; struct student *head,*p1,*p2; n=0; p1=p2=(struct student *)malloc(LEN); p1->next=NULL; scanf("%s ",p1->num); while(strcmp(p1->num,"end")!=0) { n++; scanf("%s %c %d %s %s\n",p1->name,&p1->sex,&p1->age,p1->score,p1->add); p2=(struct student *)malloc(LEN); p2->next=p1; p1=p2; scanf("%s ",p1->num); } head=p1->next; p1=p2=head; for(i=0;i<n;i++) { printf("%s %s %c %d %s %s\n",p1->num,p1->name,p1->sex,p1->age,p1->score,p1->add); p1=p2->next; p2=p1; } }
2d5668fe3332ee9fb1fef6febf5416efa70fbe5c
ddd22d154509a39ec61bf660a264a4f6e6fbeee9
/Trabalho3/curso.h
6e12d985b68de7f082bc019a3cfdda11c7376aeb
[]
no_license
areamluersen/univali
e2b91d697b56976aaa22d24874c3560b3286090a
2f22f6adcc2dcc2c573270c23c8296f82dbe46f1
refs/heads/master
2020-06-16T07:29:16.167326
2017-03-23T22:08:59
2017-03-23T22:08:59
75,233,880
0
0
null
null
null
null
UTF-8
C++
false
false
507
h
curso.h
#ifndef CURSO_H #define CURSO_H #include <string> #include <iostream> #include "windows.h" #include "tela.h" using namespace std; class Curso { int codigo; string descricao,coordenador; static int contC; public: Curso(); virtual ~Curso(); void cadastrar (); int getCodigo (); string getCoordenador(); void setCoordenador(string); static int getCont(); static void addCont(); }; #endif // CURSO_H
dee4334e1c728e514441fbc97e08b5e11b84d268
3b92fb0292ab80c822fcbfdd3485770f96e7a59e
/CPE_301L/lab6/arduinoPiano/arduinoPiano.ino
56c25ebe44169e0d84f68e20328fbdaad9c4f682
[]
no_license
frankolson/classWork
e6433cd535de6587d22ae46900f04462a26f0579
e2f71ee3fbf427e6986045fb1097055c44451fe9
refs/heads/master
2021-01-10T00:53:16.286095
2015-04-16T03:16:10
2015-04-16T03:16:10
24,739,426
0
0
null
null
null
null
UTF-8
C++
false
false
4,489
ino
arduinoPiano.ino
/* Arduino Piano Frank Olson V.1 10 March 2014 Arduino Mega 2560 R3 Last Update: 11 March 2014 Simple Serial ECHO script : Written by ScottC 03/07/2012 This program is for lab 6. Using the new delay function created and the simple serial connection code cited above create a program that takes computer input and outputs tones like a piano on portB.6 on the Arduino Mega with a 50% duty cycle. */ // Define hardware pointers volatile unsigned char *portB; // Port B volatile unsigned char *myTCCR1A; // Timer/Counter 1 Control Register A volatile unsigned char *myTCCR1B; // Timer/Counter 1 Control Register B volatile unsigned char *myTCCR1C; // Timer/Counter 1 Control Register C volatile unsigned char *myTIMSK1; // Timer/Counter 1 Interupt Mask Register volatile unsigned char *myTIFR1; // Timer/Counter 1 Interupt Flag Register volatile unsigned int *myTCNT1; // Timer/Counter 1 16-bit Counter Register // Define Frequency Tones (lowercase stands fo sharpnote): // Note Tone Frequency volatile unsigned long A = 2272; // 440 Hz volatile unsigned long a = 2146; // 466 Hz volatile unsigned long B = 2024; // 494 Hz volatile unsigned long C = 1912; // 523 Hz volatile unsigned long c = 1805; // 554 Hz volatile unsigned long D = 1704; // 587 Hz volatile unsigned long d = 1603; // 624 Hz volatile unsigned long E = 1517; // 659 Hz volatile unsigned long F = 1433; // 698 Hz volatile unsigned long f = 1351; // 740 Hz volatile unsigned long G = 1276; // 784 Hz volatile unsigned long g = 1203; // 831 Hz // Define functions void newDelay(unsigned long mSeconds); long convertInput(byte value); // Use a variable called byteRead to store the data coming // from the computer. Use as tone and defualt to 440Hz // Note: 0b01000001 is 'A' in binary byte byteRead = 0b01000001; void setup() { // Turn the Serial Protocol ON Serial.begin(9600); // Initialize timer1 pointers myTCCR1A = (unsigned char *) 0x80; myTCCR1B = (unsigned char *) 0x81; myTCCR1C = (unsigned char *) 0x82; myTIMSK1 = (unsigned char *) 0x6F; myTIFR1 = (unsigned char *) 0x36; myTCNT1 = (unsigned int *) 0x84; // Initialize NORMAL mode, off, and no interupts for timer1 *myTCCR1A = 0; *myTCCR1B = 0; *myTCCR1C = 0; *myTIMSK1 = 0; // Initialize GPIO portB volatile unsigned char *portDDRB; portDDRB = (unsigned char *) 0x24; *portDDRB |= 0x40; Serial.println("Notes are A, A#, B, C, C#, D, D#, E, F, F#, G, G#."); Serial.println("Arduino will default at A. Write sharp notes lower case."); Serial.println("Please Enter the note you would like to play: "); } void loop() { // Check if data has been sent from the computer: if (Serial.available()) { // Read the most recent byte byteRead = Serial.read(); // ECHO the value that was read, back to the serial port Serial.write(byteRead); Serial.println(); Serial.println(); // Message to user/prompt Serial.println("Notes are A, A#, B, C, C#, D, D#, E, F, F#, G, G#."); Serial.println("Arduino will default at A. Write sharp notes lower case"); Serial.println("Please Enter the note you would like to play: "); } portB = (unsigned char *) 0x25; // Flip portB then use byteRead/2 to define pulses *portB ^= 0x40; newDelay(convertInput(byteRead)/2); } // Delay Function void newDelay(unsigned long mSeconds) { // used a prescaler of 64 with mSeconds/4 scaling converting to microseconds *myTCNT1 = (unsigned int) (65536 - (long) (mSeconds/4)); *myTCCR1B = 0b00000011; // Prescalar of 1024 applied to timer1 // loop through timer; while((*myTIFR1 & 0x01) == 0); // Turn off the timer and clear the flag bit for next use *myTCCR1B = 0; *myTIFR1 &= 0x01; } // Convert input to tone long convertInput(byte value) { if(value == 'A'){ return A; } else if(value == 'a'){ return a; } else if(value == 'B'){ return B; } else if(value == 'C'){ return C; } else if(value == 'c'){ return c; } else if(value == 'D'){ return D; } else if(value == 'd'){ return d; } else if(value == 'E'){ return E; } else if(value == 'F'){ return F; } else if(value == 'f'){ return f; } else if(value == 'G'){ return G; } else if(value == 'g'){ return g; } }
1e179ead8b216369b95256ced000b75fcd35c46d
a3d6556180e74af7b555f8d47d3fea55b94bcbda
/device/fido/u2f_register_operation_unittest.cc
92229561521f5868a5a13f6b5950492b050c46fc
[ "BSD-3-Clause" ]
permissive
chromium/chromium
aaa9eda10115b50b0616d2f1aed5ef35d1d779d6
a401d6cf4f7bf0e2d2e964c512ebb923c3d8832c
refs/heads/main
2023-08-24T00:35:12.585945
2023-08-23T22:01:11
2023-08-23T22:01:11
120,360,765
17,408
7,102
BSD-3-Clause
2023-09-10T23:44:27
2018-02-05T20:55:32
null
UTF-8
C++
false
false
11,488
cc
u2f_register_operation_unittest.cc
// Copyright 2018 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "device/fido/u2f_register_operation.h" #include <memory> #include <utility> #include "base/test/task_environment.h" #include "device/fido/authenticator_make_credential_response.h" #include "device/fido/ctap_make_credential_request.h" #include "device/fido/fido_constants.h" #include "device/fido/fido_parsing_utils.h" #include "device/fido/fido_test_data.h" #include "device/fido/mock_fido_device.h" #include "device/fido/test_callback_receiver.h" #include "device/fido/virtual_u2f_device.h" #include "testing/gmock/include/gmock/gmock.h" #include "testing/gtest/include/gtest/gtest.h" namespace device { using ::testing::_; namespace { // Creates a CtapMakeCredentialRequest with given |registered_keys| as // exclude list. CtapMakeCredentialRequest CreateRegisterRequestWithRegisteredKeys( std::vector<PublicKeyCredentialDescriptor> registered_keys, bool is_individual_attestation = false) { PublicKeyCredentialRpEntity rp(test_data::kRelyingPartyId); PublicKeyCredentialUserEntity user( fido_parsing_utils::Materialize(test_data::kUserId)); CtapMakeCredentialRequest request( test_data::kClientDataJson, std::move(rp), std::move(user), PublicKeyCredentialParams( std::vector<PublicKeyCredentialParams::CredentialInfo>(1))); request.exclude_list = std::move(registered_keys); if (is_individual_attestation) { request.attestation_preference = AttestationConveyancePreference::kEnterpriseApprovedByBrowser; } return request; } // Creates a CtapMakeCredentialRequest with an empty exclude list. CtapMakeCredentialRequest CreateRegisterRequest( bool is_individual_attestation = false) { return CreateRegisterRequestWithRegisteredKeys( std::vector<PublicKeyCredentialDescriptor>(), is_individual_attestation); } using TestRegisterCallback = ::device::test::StatusAndValueCallbackReceiver< CtapDeviceResponseCode, absl::optional<AuthenticatorMakeCredentialResponse>>; } // namespace class U2fRegisterOperationTest : public ::testing::Test { public: TestRegisterCallback& register_callback_receiver() { return register_callback_receiver_; } private: base::test::TaskEnvironment task_environment_; TestRegisterCallback register_callback_receiver_; }; TEST_F(U2fRegisterOperationTest, TestRegisterSuccess) { auto request = CreateRegisterRequest(); auto device = std::make_unique<MockFidoDevice>(); EXPECT_CALL(*device, GetId()).WillRepeatedly(testing::Return("device")); device->ExpectWinkedAtLeastOnce(); device->ExpectRequestAndRespondWith( test_data::kU2fRegisterCommandApdu, test_data::kApduEncodedNoErrorRegisterResponse); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), register_callback_receiver().callback()); u2f_register->Start(); register_callback_receiver().WaitForCallback(); EXPECT_EQ(CtapDeviceResponseCode::kSuccess, register_callback_receiver().status()); ASSERT_TRUE(register_callback_receiver().value()); EXPECT_THAT(register_callback_receiver() .value() ->attestation_object.GetCredentialId(), ::testing::ElementsAreArray(test_data::kU2fSignKeyHandle)); } TEST_F(U2fRegisterOperationTest, TestRegisterSuccessWithFake) { auto request = CreateRegisterRequest(); auto device = std::make_unique<VirtualU2fDevice>(); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), register_callback_receiver().callback()); u2f_register->Start(); register_callback_receiver().WaitForCallback(); EXPECT_EQ(CtapDeviceResponseCode::kSuccess, register_callback_receiver().status()); // We don't verify the response from the fake, but do a quick sanity check. ASSERT_TRUE(register_callback_receiver().value()); EXPECT_EQ(32ul, register_callback_receiver() .value() ->attestation_object.GetCredentialId() .size()); } TEST_F(U2fRegisterOperationTest, TestDelayedSuccess) { auto request = CreateRegisterRequest(); auto device = std::make_unique<MockFidoDevice>(); EXPECT_CALL(*device, GetId()).WillRepeatedly(testing::Return("device")); device->ExpectWinkedAtLeastOnce(); // Device error out once waiting for user presence before retrying. ::testing::InSequence s; device->ExpectRequestAndRespondWith( test_data::kU2fRegisterCommandApdu, test_data::kU2fConditionNotSatisfiedApduResponse); device->ExpectRequestAndRespondWith( test_data::kU2fRegisterCommandApdu, test_data::kApduEncodedNoErrorRegisterResponse); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), register_callback_receiver().callback()); u2f_register->Start(); register_callback_receiver().WaitForCallback(); EXPECT_EQ(CtapDeviceResponseCode::kSuccess, register_callback_receiver().status()); ASSERT_TRUE(register_callback_receiver().value()); EXPECT_THAT(register_callback_receiver() .value() ->attestation_object.GetCredentialId(), ::testing::ElementsAreArray(test_data::kU2fSignKeyHandle)); } // Tests a scenario where a single device is connected and registration call // is received with two unknown key handles. We expect that two check // only sign-in calls be processed before registration. TEST_F(U2fRegisterOperationTest, TestRegistrationWithExclusionList) { auto request = CreateRegisterRequestWithRegisteredKeys( {PublicKeyCredentialDescriptor( CredentialType::kPublicKey, fido_parsing_utils::Materialize(test_data::kKeyHandleAlpha)), PublicKeyCredentialDescriptor( CredentialType::kPublicKey, fido_parsing_utils::Materialize(test_data::kKeyHandleBeta))}); auto device = std::make_unique<MockFidoDevice>(); EXPECT_CALL(*device, GetId()).WillRepeatedly(::testing::Return("device")); device->ExpectWinkedAtLeastOnce(); // DeviceTransact() will be called three times including two sign-in calls // with bogus challenges and one registration call. For the first two calls, // device will invoke MockFidoDevice::WrongData/WrongLength as the // authenticator did not create the two key handles provided in the exclude // list. At the third call, MockFidoDevice::NoErrorRegister will be invoked // after registration. ::testing::InSequence s; device->ExpectRequestAndRespondWith( test_data::kU2fSignCommandApduWithKeyAlphaAndBogusChallenge, test_data::kU2fWrongDataApduResponse); device->ExpectRequestAndRespondWith( test_data::kU2fSignCommandApduWithKeyBetaAndBogusChallenge, test_data::kU2fWrongLengthApduResponse); device->ExpectRequestAndRespondWith( test_data::kU2fRegisterCommandApdu, test_data::kApduEncodedNoErrorRegisterResponse); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), register_callback_receiver().callback()); u2f_register->Start(); register_callback_receiver().WaitForCallback(); ASSERT_TRUE(register_callback_receiver().value()); EXPECT_EQ(CtapDeviceResponseCode::kSuccess, register_callback_receiver().status()); EXPECT_THAT(register_callback_receiver() .value() ->attestation_object.GetCredentialId(), ::testing::ElementsAreArray(test_data::kU2fSignKeyHandle)); } // Tests a scenario where single device is connected and registration is // called with a key in the exclude list that was created by this device. We // assume that the duplicate key is the last key handle in the exclude list. // Therefore, after duplicate key handle is found, the process is expected to // terminate after calling bogus registration which checks for user presence. TEST_F(U2fRegisterOperationTest, TestRegistrationWithDuplicateHandle) { // Simulate two unknown key handles followed by a duplicate key. auto request = CreateRegisterRequestWithRegisteredKeys( {PublicKeyCredentialDescriptor( CredentialType::kPublicKey, fido_parsing_utils::Materialize(test_data::kKeyHandleAlpha)), PublicKeyCredentialDescriptor( CredentialType::kPublicKey, fido_parsing_utils::Materialize(test_data::kKeyHandleBeta)), PublicKeyCredentialDescriptor( CredentialType::kPublicKey, fido_parsing_utils::Materialize(test_data::kKeyHandleGamma))}); auto device = std::make_unique<MockFidoDevice>(); EXPECT_CALL(*device, GetId()).WillRepeatedly(::testing::Return("device")); device->ExpectWinkedAtLeastOnce(); // For three keys in exclude list, the first two keys will return // SW_WRONG_DATA and the final duplicate key handle will invoke // SW_NO_ERROR. This means user presence has already been collected, so the // request is concluded with Ctap2ErrCredentialExcluded. ::testing::InSequence s; device->ExpectRequestAndRespondWith( test_data::kU2fSignCommandApduWithKeyAlphaAndBogusChallenge, test_data::kU2fWrongDataApduResponse); device->ExpectRequestAndRespondWith( test_data::kU2fSignCommandApduWithKeyBetaAndBogusChallenge, test_data::kU2fWrongDataApduResponse); // The signature in the response is intentionally incorrect since nothing // should depend on it being correct. device->ExpectRequestAndRespondWith( test_data::kU2fSignCommandApduWithKeyGammaAndBogusChallenge, test_data::kApduEncodedNoErrorSignResponse); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), register_callback_receiver().callback()); u2f_register->Start(); register_callback_receiver().WaitForCallback(); EXPECT_EQ(CtapDeviceResponseCode::kCtap2ErrCredentialExcluded, register_callback_receiver().status()); EXPECT_FALSE(register_callback_receiver().value()); } MATCHER_P(IndicatesIndividualAttestation, expected, "") { return arg.size() > 2 && ((arg[2] & 0x80) == 0x80) == expected; } TEST_F(U2fRegisterOperationTest, TestIndividualAttestation) { // Test that the individual attestation flag is correctly reflected in the // resulting registration APDU. for (const auto& individual_attestation : {false, true}) { SCOPED_TRACE(individual_attestation); TestRegisterCallback cb; auto request = CreateRegisterRequest(individual_attestation); auto device = std::make_unique<MockFidoDevice>(); EXPECT_CALL(*device, GetId()).WillRepeatedly(::testing::Return("device")); device->ExpectWinkedAtLeastOnce(); device->ExpectRequestAndRespondWith( individual_attestation ? test_data::kU2fRegisterCommandApduWithIndividualAttestation : test_data::kU2fRegisterCommandApdu, test_data::kApduEncodedNoErrorRegisterResponse); auto u2f_register = std::make_unique<U2fRegisterOperation>( device.get(), std::move(request), cb.callback()); u2f_register->Start(); cb.WaitForCallback(); EXPECT_EQ(CtapDeviceResponseCode::kSuccess, cb.status()); ASSERT_TRUE(cb.value()); EXPECT_THAT(cb.value()->attestation_object.GetCredentialId(), ::testing::ElementsAreArray(test_data::kU2fSignKeyHandle)); } } } // namespace device
71062327065c5ac3ad3c8243b7ccc747bb1198fd
03d0ce8a4bd34de35f654a568b6004aa321d3ab8
/DemoDirectX/PlayScence.cpp
997077c03a199c7e1c58be3339098c96bff9af5e
[]
no_license
minhnhatkool123/CASTLENEW
7a202a3a4e3eb14dd9d7e6c2e347f8f69535b165
c7de8dc774678f3a3b3503b43fb2113463ab472b
refs/heads/master
2022-11-24T12:40:28.200321
2020-07-28T11:59:30
2020-07-28T11:59:30
257,939,088
0
1
null
null
null
null
UTF-8
C++
false
false
50,815
cpp
PlayScence.cpp
#include <iostream> #include <fstream> #include "PlayScence.h" #include "Utils.h" #include "Textures.h" #include "Sprites.h" #define map1 1 #define map2 2 #define map3 3 #define map4 4 #define map5 5 #define map6 6 #define SCENE_SECTION_UNKNOWN -1 #define SCENE_SECTION_TEXTURES 2 #define SCENE_SECTION_SPRITES 3 #define SCENE_SECTION_ANIMATIONS 4 #define SCENE_SECTION_ANIMATION_SETS 5 #define SCENE_SECTION_OBJECTS 6 #define SCENE_SECTION_START 7 #define SCENE_SECTION_LINKMAP 8 #define SCENE_SECTION_SCENEOBJECT 9 #define SCENE_SECTION_INFOMAP 10 #define SCENE_SECTION_CLEARTEXT 11 #define SCENE_SECTION_CLEARSP 12 #define SCENE_SECTION_CLEARANI 13 #define SCENE_SECTION_CLEARANISET 14 #define OBJECT_TYPE_SIMON 0 #define OBJECT_TYPE_GROUND 1 #define OBJECT_TYPE_CANDLE 2 #define OBJECT_TYPE_GATE 3 #define OBJECT_TYPE_STAIR 4 #define OBJECT_TYPE_GROUNDMOVING 5 #define OBJECT_TYPE_KNIGHT 6 #define OBJECT_TYPE_BAT 7 #define OBJECT_TYPE_MONKEY 8 #define OBJECT_TYPE_SKELETON 9 #define OBJECT_TYPE_FROG 10 #define OBJECT_TYPE_DRAVEN 11 #define OBJECT_TYPE_BREAKWALL 12 #define OBJECT_TYPE_SMALLCANDLE 13 #define OBJECT_TYPE_ZOMBIE 14 #define OBJECT_TYPE_BOSS 15 #define OBJECT_TYPE_PORTAL 50 #define MAX_SCENE_LINE 1024 using namespace std; CPlayScene::CPlayScene() : CScene() { key_handler = new CPlayScenceKeyHandler(this); //sceneFilePath = L"Scenes\\Castlevania.txt"; Load(L"Scenes\\Castlevania.txt");//load ani sprites texture LoadBaseObject(); SwitchScene(current_scene); } void CPlayScene::LoadBaseObject() { if (simon == NULL) { simon = new Simon(); DebugOut(L"[INFO]SIMON CREATED \n"); } //boss = new Boss(simon); board = new Board(simon->GetHealth(), /*boss->hp*/boss_max_hp); tilemap = new TileMap(); //grid = new Grid(); //grididle = new Grid(); } void CPlayScene::SwitchScene(int idmap) { Unload(); grid = new Grid(); grididle = new Grid(); if (simon->beforescene >= 1) ClearAll(ToLPCWSTR(linkmap[simon->beforescene-1/*idmap - 2*/])); CGame::GetInstance()->SetKeyHandler(this->GetKeyEventHandler()); LPCWSTR a = ToLPCWSTR(linkmap[idmap - 1]); Load(a); LoadMap(a); LoadObject(); //grid->PushGrid(listpush); //grididle->PushGrid(listidle); CGame::GetInstance()->SetCamPos(CGame::GetInstance()->GetCamPosX(), 0.0f); simon->currentscene=simon->beforescene = idmap; } Items* CPlayScene::DropItem(float x, float y,int id) { Items *a = new Items(); a->SetPosition(x, y); a->idItems = id; a->SetState(id); //listitems.push_back(a); return a; } void CPlayScene::_ParseSection_CLEARTEXTURES(string line) { vector<string> tokens = split(line); for (int i = 0; i < tokens.size(); i++) CTextures::GetInstance()->Clear(atoi(tokens[i].c_str())); } void CPlayScene::_ParseSection_CLEARSPRITES(string line) { vector<string> tokens = split(line); for (int i = 0; i < tokens.size(); i++) CSprites::GetInstance()->Clear(atoi(tokens[i].c_str())); } void CPlayScene::_ParseSection_CLERANIMATIONS(string line) { vector<string> tokens = split(line); for (int i = 0; i < tokens.size(); i++) CAnimations::GetInstance()->Clear(atoi(tokens[i].c_str())); } void CPlayScene::_ParseSection_CLERANIMATIONSSET(string line) { vector<string> tokens = split(line); for (int i = 0; i < tokens.size(); i++) CAnimationSets::GetInstance()->Clear(atoi(tokens[i].c_str())); } void CPlayScene::_ParseSection_LINKOBJECTS(string line) { vector<string> tokens = split(line); if (tokens.size() < 1) return; sceneObject= ToLPCWSTR(tokens[0]); } void CPlayScene::ClearAll(LPCWSTR a) { ifstream f; f.open(a); int section = SCENE_SECTION_UNKNOWN; char str[MAX_SCENE_LINE]; while (f.getline(str, MAX_SCENE_LINE)) { string line(str); if (line[0] == '#') continue; if (line == "[CLEARTEXT]") { section = SCENE_SECTION_CLEARTEXT; continue; } if (line == "[CLEARSP]") { section = SCENE_SECTION_CLEARSP; continue; } if (line == "[CLEARANI]") { section = SCENE_SECTION_CLEARANI; continue; } if (line == "[CLEARANISET]") { section = SCENE_SECTION_CLEARANISET; continue; } if (line[0] == '[') { section = SCENE_SECTION_UNKNOWN; continue; } switch (section) { case SCENE_SECTION_CLEARTEXT:_ParseSection_CLEARTEXTURES(line); break; case SCENE_SECTION_CLEARSP:_ParseSection_CLEARSPRITES(line); break; case SCENE_SECTION_CLEARANI:_ParseSection_CLERANIMATIONS(line); break; case SCENE_SECTION_CLEARANISET:_ParseSection_CLERANIMATIONSSET(line); break; } } f.close(); } void CPlayScene::_ParseSection_INFOMAP(string line) { vector<string> tokens = split(line); if (tokens.size() < 10) return; int IDmap = atoi(tokens[0].c_str()); wstring pathpic = ToWSTR(tokens[1]); wstring pathtxt = ToWSTR(tokens[2]); int num_row = atoi(tokens[3].c_str()); int num_col = atoi(tokens[4].c_str()); int num_row_read = atoi(tokens[5].c_str()); int num_col_read = atoi(tokens[6].c_str()); int tile_width = atoi(tokens[7].c_str()); int tile_height = atoi(tokens[8].c_str()); idstage = atoi(tokens[9].c_str()); int r = atoi(tokens[14].c_str()); int g = atoi(tokens[15].c_str()); int b = atoi(tokens[16].c_str()); tilemap->LoadMap(IDmap, pathpic.c_str(), pathtxt.c_str(), num_row, num_col, num_row_read, num_col_read, tile_width, tile_height, r, g, b); if(simon->currentscene<=simon->nextscene) CGame::GetInstance()->SetCamPosX(atof(tokens[10].c_str())); else CGame::GetInstance()->SetCamPosX(atof(tokens[11].c_str())); grid->Resize(atoi(tokens[12].c_str()), atoi(tokens[13].c_str())); grididle->Resize(atoi(tokens[12].c_str()), atoi(tokens[13].c_str())); } void CPlayScene::_ParseSection_LINKMAP(string line) { vector<string> tokens = split(line); if (tokens.size() < 1) return; linkmap.push_back(tokens[0].c_str()); } void CPlayScene::_ParseSection_SETTINGS(string line) { vector<string> tokens = split(line); if (tokens.size() < 2) return; if (tokens[0] == "start") current_scene = atoi(tokens[1].c_str()); else DebugOut(L"[ERROR] Unknown game setting %s\n", ToWSTR(tokens[0]).c_str()); } void CPlayScene::_ParseSection_TEXTURES(string line) { vector<string> tokens = split(line); if (tokens.size() < 5) return; // skip invalid lines int texID = atoi(tokens[0].c_str()); wstring path = ToWSTR(tokens[1]); int R = atoi(tokens[2].c_str()); int G = atoi(tokens[3].c_str()); int B = atoi(tokens[4].c_str()); CTextures::GetInstance()->Add(texID, path.c_str(), D3DCOLOR_XRGB(R, G, B)); } void CPlayScene::_ParseSection_SPRITES(string line) { vector<string> tokens = split(line); if (tokens.size() < 6) return; // skip invalid lines int ID = atoi(tokens[0].c_str()); int l = atoi(tokens[1].c_str()); int t = atoi(tokens[2].c_str()); int r = atoi(tokens[3].c_str()); int b = atoi(tokens[4].c_str()); int texID = atoi(tokens[5].c_str()); LPDIRECT3DTEXTURE9 tex = CTextures::GetInstance()->Get(texID); if (tex == NULL) { DebugOut(L"[ERROR] Texture ID %d not found!\n", texID); return; } CSprites::GetInstance()->Add(ID, l, t, r, b, tex); } void CPlayScene::_ParseSection_ANIMATIONS(string line) { vector<string> tokens = split(line); if (tokens.size() < 3) return; // skip invalid lines - an animation must at least has 1 frame and 1 frame time //DebugOut(L"--> %s\n",ToWSTR(line).c_str()); LPANIMATION ani = new CAnimation(); int ani_id = atoi(tokens[0].c_str()); for (int i = 1; i < tokens.size(); i += 2) // why i+=2 ? sprite_id | frame_time { int sprite_id = atoi(tokens[i].c_str()); int frame_time = atoi(tokens[i + 1].c_str()); ani->Add(sprite_id, frame_time); } CAnimations::GetInstance()->Add(ani_id, ani); } void CPlayScene::_ParseSection_ANIMATION_SETS(string line) { vector<string> tokens = split(line); if (tokens.size() < 2) return; // skip invalid lines - an animation set must at least id and one animation id int ani_set_id = atoi(tokens[0].c_str()); LPANIMATION_SET s = new CAnimationSet(); CAnimations *animations = CAnimations::GetInstance(); for (int i = 1; i < tokens.size(); i++) { int ani_id = atoi(tokens[i].c_str()); LPANIMATION ani = animations->Get(ani_id); s->push_back(ani); } CAnimationSets::GetInstance()->Add(ani_set_id, s); } /* Parse a line in section [OBJECTS] */ void CPlayScene::_ParseSection_OBJECTS(string line) { vector<string> tokens = split(line); //DebugOut(L"--> %s\n",ToWSTR(line).c_str()); if (tokens.size() < 3) return; // skip invalid lines - an object set must have at least id, x, y int object_type = atoi(tokens[0].c_str()); float x = atof(tokens[1].c_str()); float y = atof(tokens[2].c_str()); int ani_set_id = atoi(tokens[3].c_str()); CAnimationSets * animation_sets = CAnimationSets::GetInstance(); CGameObject *obj = NULL; switch (object_type) { case OBJECT_TYPE_SIMON: { int nx1= atof(tokens[3].c_str()); int state1= atof(tokens[4].c_str()); float x2= atof(tokens[5].c_str()); float y2 = atof(tokens[6].c_str()); int nx2= atof(tokens[7].c_str()); int state2 = atof(tokens[8].c_str()); if (simon->currentscene <= simon->nextscene) { simon->SetNx(nx1); simon->SetPosition(x, y); simon->SetState(state1); } else /*if (simon->currentscene > simon->nextscene)*/ { simon->SetPosition(x2, y2); simon->SetNx(nx2); simon->SetState(state2); } break; } case OBJECT_TYPE_GROUND: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Ground(); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listidle.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grididle->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_CANDLE: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int id = atof(tokens[4].c_str()); int top = atoi(tokens[5].c_str()); int bot = atoi(tokens[6].c_str()); int left = atoi(tokens[7].c_str()); int right = atoi(tokens[8].c_str()); obj = new Candle(); obj->idItems = id; obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_GATE: { int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Gate(); obj->nextscene = atof(tokens[3].c_str()); /*current_scene = NEXTMAP;*/ obj->SetPosition(x, y); listidle.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grididle->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_STAIR: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[5].c_str()); int bot = atoi(tokens[6].c_str()); int left = atoi(tokens[7].c_str()); int right = atoi(tokens[8].c_str()); obj = new Stair(); int stairnx = atof(tokens[4].c_str()); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); obj->stairdir = stairnx; listidle.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grididle->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_GROUNDMOVING: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new GroundMoving(); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_KNIGHT: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Knight(); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_BAT: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Bat(simon); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_MONKEY: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Monkey(simon); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_SKELETON: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Skeleton(simon); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_FROG: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Frog(simon); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_DRAVEN: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); obj = new Raven(simon); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_BREAKWALL: { int id = atoi(tokens[4].c_str()); int top = atoi(tokens[5].c_str()); int bot = atoi(tokens[6].c_str()); int left = atoi(tokens[7].c_str()); int right = atoi(tokens[8].c_str()); LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); obj = new BreakWall(); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); obj->idItems = id; listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_SMALLCANDLE: { int id = atoi(tokens[4].c_str()); int top = atoi(tokens[5].c_str()); int bot = atoi(tokens[6].c_str()); int left = atoi(tokens[7].c_str()); int right = atoi(tokens[8].c_str()); LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); obj = new SmallCandle(); obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); obj->idItems = id; listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_ZOMBIE: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int nx = atoi(tokens[4].c_str()); int top = atoi(tokens[5].c_str()); int bot = atoi(tokens[6].c_str()); int left = atoi(tokens[7].c_str()); int right = atoi(tokens[8].c_str()); obj = new Zombie(); obj->nx = nx; obj->SetAnimationSet(ani_set); obj->SetPosition(x, y); listpush.push_back(obj); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(obj, row, col); } break; } case OBJECT_TYPE_BOSS: { LPANIMATION_SET ani_set = animation_sets->Get(ani_set_id); int top = atoi(tokens[4].c_str()); int bot = atoi(tokens[5].c_str()); int left = atoi(tokens[6].c_str()); int right = atoi(tokens[7].c_str()); boss = new Boss(simon); boss->SetAnimationSet(ani_set); boss->SetPosition(x, y); listpush.push_back(boss); for (int row = top; row < bot; row++) { for (int col = left; col < right; col++) grid->PushGridStart(/*obj*/boss, row, col); } break; } default: DebugOut(L"[ERR] Invalid object type: %d\n", object_type); return; break; } } void CPlayScene::GetObjectGrid() { objects.clear(); liststairleft.clear(); liststairright.clear(); listget.clear(); grididle->GetGrid(listget); grid->GetGrid(listget); //DebugOut(L" SO PHAN TU TRONG LIST TĨNH %d \n", listidle.size()); //DebugOut(L" SO PHAN TU TRONG LIST ĐỘNG %d \n", listpush.size()); //DebugOut(L" SO PHAN TU TRONG LIST %d \n", listget.size()); for (UINT i = 0; i < listget.size(); i++) { if (dynamic_cast<Stair*>(listget[i])) { if(listget[i]->stairdir==-1) liststairright.push_back(listget[i]); else liststairleft.push_back(listget[i]); } else objects.push_back(listget[i]); } } void CPlayScene::LoadMap(LPCWSTR map) { ifstream f; f.open(map); int section = SCENE_SECTION_UNKNOWN; char str[MAX_SCENE_LINE]; while (f.getline(str, MAX_SCENE_LINE)) { string line(str); if (line[0] == '#') continue; if (line == "[SCENEOBJECT]") { section = SCENE_SECTION_SCENEOBJECT; continue; } if (line == "[TILEMAP]") { section = SCENE_SECTION_INFOMAP; continue; } if (line[0] == '[') { section = SCENE_SECTION_UNKNOWN; continue; } switch (section) { case SCENE_SECTION_SCENEOBJECT: _ParseSection_LINKOBJECTS(line); break; case SCENE_SECTION_INFOMAP:_ParseSection_INFOMAP(line); break; } } f.close(); } void CPlayScene::LoadObject() { DebugOut(L"[INFO] StartLOAD OBJECT resources from : %s \n", sceneObject); ifstream f; f.open(sceneObject); /*if (f.fail()) { DebugOut(L"[ERROR] LOAD OBJECT FAIL : %s \n", sceneObject); f.close(); return; }*/ int section = SCENE_SECTION_UNKNOWN; char str[MAX_SCENE_LINE]; while (f.getline(str, MAX_SCENE_LINE)) { string line(str); if (line[0] == '#') continue; if (line == "[OBJECTS]") { section = SCENE_SECTION_OBJECTS; continue; } if (line[0] == '[') { section = SCENE_SECTION_UNKNOWN; continue; } switch (section) { case SCENE_SECTION_OBJECTS: _ParseSection_OBJECTS(line); break; } } f.close(); DebugOut(L"[INFO] Done LOAD OBJECT resources from %s\n", sceneObject); } void CPlayScene::Load(LPCWSTR sceneFilePath) { DebugOut(L"[INFO] Start loading scene resources from : %s \n", sceneFilePath); ifstream f; f.open(sceneFilePath); /*if (f.fail()) { DebugOut(L"[ERROR] LOAD ANISPRITETEXT FAIL : %s \n", sceneFilePath); f.close(); return; }*/ // current resource section flag int section = SCENE_SECTION_UNKNOWN; char str[MAX_SCENE_LINE]; while (f.getline(str, MAX_SCENE_LINE)) { string line(str); if (line[0] == '#') continue; // skip comment lines if (line == "[TEXTURES]") { section = SCENE_SECTION_TEXTURES; continue; } if (line == "[SPRITES]") { section = SCENE_SECTION_SPRITES; continue; } if (line == "[ANIMATIONS]") { section = SCENE_SECTION_ANIMATIONS; continue; } if (line == "[ANIMATION_SETS]") { section = SCENE_SECTION_ANIMATION_SETS; continue; } if (line == "[SETTINGS]") { section = SCENE_SECTION_START; continue; } if (line == "[LINKMAP]") { section = SCENE_SECTION_LINKMAP; continue; } if (line[0] == '[') { section = SCENE_SECTION_UNKNOWN; continue; } // // data section // switch (section) { case SCENE_SECTION_TEXTURES: _ParseSection_TEXTURES(line); break; case SCENE_SECTION_SPRITES: _ParseSection_SPRITES(line); break; case SCENE_SECTION_ANIMATIONS: _ParseSection_ANIMATIONS(line); break; case SCENE_SECTION_ANIMATION_SETS: _ParseSection_ANIMATION_SETS(line); break; case SCENE_SECTION_START: _ParseSection_SETTINGS(line); break; case SCENE_SECTION_LINKMAP: _ParseSection_LINKMAP(line); break; } } f.close(); CTextures::GetInstance()->Add(ID_TEX_BBOX, L"textures\\bbox.png", D3DCOLOR_XRGB(255, 255, 255)); DebugOut(L"[INFO] Done loading scene resources %s\n", sceneFilePath); } int CPlayScene::RandomItems() { int a = rand() % rand_items_max; if (min_rand_1 < a &&a <= max_rand_2) return items_small_heart; else if (max_rand_2 < a && a <= max_rand_3) return items_big_heart; //else if (max_rand_3 < a&&a <= max_rand_5 && simon->GetWhip()->GetState() < whip_lv3) //return items_for_whip; else if (max_rand_5 < a &&a <= max_rand_6&&simon->currentWeapon==-1) return items_knife; else if (max_rand_6 < a&&a <= max_rand_7 && simon->currentWeapon == -1) return items_axe; else if (max_rand_7 < a&&a <= max_rand_8 && simon->currentWeapon == -1) return items_boom; else if (max_rand_8 < a &&a <= max_rand_9 && simon->currentWeapon == -1) return items_holywater; else if (max_rand_9 < a &&a <= max_rand_10) return items_watterbottle; else if (max_rand_10 < a&&a <= max_rand_11) return items_corss; else if (max_rand_12 < a &&a <= max_rand_13) return items_double; else if (max_rand_13 < a&&a <= max_rand_14) return items_triple; else if (max_rand_14 < a&&a <= max_rand_15) return items_meat; else if (max_rand_15 < a&&a <= max_rand_16) return items_bluemoney; else if (max_rand_16 < a&&a <= max_rand_4) return items_redmoney; else return items_whitemoney; } bool CPlayScene::CheckInCam(LPGAMEOBJECT a) { CGame* game = CGame::GetInstance(); return (a->GetPositionX() >= game->GetCamPosX()) && (a->GetPositionX() < (game->GetCamPosX() + SCREEN_WIDTH)) && (a->GetPositionY() >= game->GetCamPosY()) && (a->GetPositionY() < game->GetCamPosY() + SCREEN_HEIGHT); } void CPlayScene::UseCross() { if (simon->isCross) { simon->isCross = false; timecross->Start(); for (UINT i = 0; i < objects.size();i++) { if (!CheckInCam(objects[i])) continue; if (dynamic_cast<Knight*>(objects[i])) { Knight* knight = dynamic_cast<Knight*>(objects[i]); knight->SetState(knight_ani_die); } else if (dynamic_cast<Bat*>(objects[i])) { Bat* bat = dynamic_cast<Bat*>(objects[i]); bat->SetState(bat_ani_die); } else if (dynamic_cast<Monkey*>(objects[i])) { Monkey* monkey = dynamic_cast<Monkey*>(objects[i]); monkey->SetState(monkey_ani_die); } else if (dynamic_cast<Frog*>(objects[i])) { Frog *frog = dynamic_cast<Frog*>(objects[i]); frog->SetState(frog_ani_die); } else if (dynamic_cast<Skeleton*>(objects[i])) { Skeleton *skele = dynamic_cast<Skeleton*>(objects[i]); skele->SetState(skeleton_ani_die); } else if (dynamic_cast<Raven*>(objects[i])) { Raven *raven = dynamic_cast<Raven*>(objects[i]); raven->SetState(raven_ani_die); } else if (dynamic_cast<Zombie*>(objects[i])) { Zombie *zombie = dynamic_cast<Zombie*>(objects[i]); zombie->colliwhip = true; zombie->SetState(zombie_ani_die); } } } } void CPlayScene::ResetGame() { if (simon->bossdie) { if (!checkreset) { reset->Start(); checkreset = true; } if (simon->GetHealth() < simon_max_health) { if (delayaddhp->IsTimeUp()) { delayaddhp->Start(); simon->addHp(1); } } if (simon->getmana() > 0) { simon->usemana(1); simon->addScore(add_score_time_up); } if (board->gettimemax() > 0) { board->subtimemax(1); simon->addScore(add_score_time); } } if (simon->bossdie&&reset->IsTimeUp()) { reset->Stop(); simon->bossdie = false; board->setCheckTime(false); checkreset = false; board->settimeremain(def_time_max); simon->isDead = false; simon->isWalkStair = false; simon->GetWhip()->SetState(whip_lv1); simon->setHealth(max_heal); simon->setMana(simon_mana); simon->setLife(simon_life); simon->currentWeapon = -1; simon->hitDoubleTriple = -1; SwitchScene(map1); simon->setScore(simon_score); } } void CPlayScene::Revival() { if (!simon->bossdie) { CGame* game = CGame::GetInstance(); if ((simon->GetPositionY() >= (game->GetCamPosY() + SCREEN_HEIGHT/*+ 200*/))) simon->SetState(simon_ani_dead); if (board->getCheckTime() /*&& !simon->bossdie*/) { simon->SetState(simon_ani_dead); board->setCheckTime(false); } if ((simon->isDead && timedeadsimon->IsTimeUp()) || (board->getCheckTime() == true)) { timedeadsimon->Stop(); board->settimeremain(def_time_max); simon->isDead = false; simon->GetWhip()->SetState(whip_lv1); simon->setHealth(max_heal); simon->setMana(simon_mana); simon->isWalkStair = false; if (simon->getlife() > 0) { //board->settimeremain(300); simon->setLife(simon->getlife() - 1); SwitchScene(simon->currentscene); } else //if (simon->getlife() == 0) { simon->setLife(simon_life); SwitchScene(map1); simon->setScore(simon_score); } } if (simon->GetState() == simon_ani_dead) { if (!simon->isDead) { simon->isDead = true; timedeadsimon->Start(); } } } //CGame* game = CGame::GetInstance(); //if ((simon->GetPositionY() >= (game->GetCamPosY() + SCREEN_HEIGHT /*+ 200*/))) // simon->SetState(simon_ani_dead); //if (board->getCheckTime()&&!simon->bossdie) //{ // simon->SetState(simon_ani_dead); // board->setCheckTime(false); //} //if ((simon->isDead && timedeadsimon->IsTimeUp()) || (board->getCheckTime() == true)) //{ // timedeadsimon->Stop(); // board->settimeremain(def_time_max); // simon->isDead = false; // simon->GetWhip()->SetState(whip_lv1); // simon->setHealth(max_heal); // simon->setMana(simon_mana); // if (simon->getlife() > 0) // { // //board->settimeremain(300); // simon->setLife(simon->getlife() - 1); // SwitchScene(simon->currentscene); // } // else //if (simon->getlife() == 0) // { // simon->setLife(simon_life); // SwitchScene(map1); // simon->setScore(simon_score); // } //} //if (simon->GetState() == simon_ani_dead) //{ // if (!simon->isDead) // { // simon->isDead = true; // timedeadsimon->Start(); // } //} } void CPlayScene::Update(DWORD dt) { grid->CheckCamGrid(listpush); grididle->CheckCamGrid(listidle); GetObjectGrid(); if (timerclk->IsTimeUp()) timerclk->Stop(); if (timecross->IsTimeUp()) timecross->Stop(); UseCross(); vector<LPGAMEOBJECT> coObjects; for (int i = 0; i < objects.size(); i++) { if (dynamic_cast<Skeleton*>(objects[i])) { Skeleton* skele = dynamic_cast<Skeleton*>(objects[i]); for(int i=0;i< max_bone;i++) coObjects.push_back(skele->getBone()[i]); } if (dynamic_cast<Boss*>(objects[i])) { Boss *boss = dynamic_cast<Boss*>(objects[i]); coObjects.push_back(boss->getFireBall()); } coObjects.push_back(objects[i]); } for (int i = 0; i < listpiece.size(); i++) listpiece[i]->Update(dt); if (simon->animation_set->at(simon_ani_stand_hit)->GetcurrentFrame() == 2 && simon->GetState() == simon_ani_stand_hit || (simon->animation_set->at(simon_ani_sit_hit)->GetcurrentFrame() == 2 && simon->GetState() == simon_ani_sit_hit) || (simon->animation_set->at(simon_ani_stair_up_hit)->GetcurrentFrame() == 2 && simon->GetState() == simon_ani_stair_up_hit)|| (simon->animation_set->at(simon_ani_stair_down_hit)->GetcurrentFrame() == 2 && simon->GetState() == simon_ani_stair_down_hit)) { if(!simon->isHitSubWeapon) simon->GetWhip()->Update(dt, &objects); } for (int i = 0; i < simon->GetWhip()->listHit.size(); i++) { if (simon->GetWhip()->listHit[i]->timedestroy()) simon->GetWhip()->listHit.erase(simon->GetWhip()->listHit.begin() + i); } //DebugOut(L" SO PHAN TU TRONG LISTHIT %d \n", simon->GetWhip()->listHit.size()); for (UINT i = 0; i < objects.size(); i++) { LPGAMEOBJECT obj = objects[i]/*allobject[i]*/; if (dynamic_cast<Candle*>(obj) && obj->GetState() == break_candle && !(obj->isDone)&&!(obj->isFire)) { if (obj->animation_set->at(break_candle)->RenderOver(time_render_fire))//để khi render xong lửa thì mới rới đồ { obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), obj->idItems)); } } if (dynamic_cast<Knight*>(obj) && obj->GetState() == knight_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(knight_ani_die)->RenderOver(knight_ani_die_time)) { Knight* e = dynamic_cast<Knight*>(obj); simon->addScore(e->getScore()); obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), RandomItems())); } } if (dynamic_cast<Bat*>(obj) && obj->GetState() == bat_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(bat_ani_die)->RenderOver(bat_time)) { Bat* e = dynamic_cast<Bat*>(obj); e->isFire = true; if (!e->Getcollisimon()) { simon->addScore(e->getScore()); listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), RandomItems())); } /*simon->batdie = false;*/ e->Setcollisimon(false); } } if(dynamic_cast<Frog*>(obj) && obj->GetState() == frog_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(frog_ani_die)->RenderOver(frog_time)) { Frog* e = dynamic_cast<Frog *>(obj); simon->addScore(e->getScore()); obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), RandomItems())); } } if (dynamic_cast<Monkey*>(obj) && obj->GetState() == monkey_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(monkey_ani_die)->RenderOver(monkey_time)) { Monkey* e = dynamic_cast<Monkey *>(obj); simon->addScore(e->getScore()); obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY()- monkey_drop_item_y, RandomItems())); } } if (dynamic_cast<Skeleton*>(obj) && obj->GetState() == skeleton_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(skeleton_ani_die)->RenderOver(skeleton_time)) { Skeleton* e = dynamic_cast<Skeleton *>(obj); simon->addScore(e->getScore()); obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX() + skele_drop_item_x, obj->GetPositionY(), RandomItems())); } } if (dynamic_cast<Raven*>(obj) && obj->GetState() == raven_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(raven_ani_die)->RenderOver(raven_time)) { Raven* e = dynamic_cast<Raven*>(obj); e->isFire = true; /*obj->isFire = true;*/ if (/*!simon->ravendie*/!e->Getcollisimon()) { simon->addScore(e->getScore()); listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), RandomItems())); } //simon->ravendie = false; e->Setcollisimon(false); } } if (dynamic_cast<BreakWall*>(obj) && (obj->isDone) && !(obj->isFire)) { obj->isFire = true; listpiece.push_back(CreatePiece(obj->x+ piece_0_x, obj->y, piece_type_0)); listpiece.push_back(CreatePiece(obj->x+ piece_1_x_y, obj->y+ piece_1_x_y, piece_type_1)); listpiece.push_back(CreatePiece(obj->x + piece_2_x, obj->y - piece_2_y, piece_type_2)); listpiece.push_back(CreatePiece(obj->x- piece_3_x, obj->y- piece_3_y, piece_type_3)); if (obj->idItems == items_crown) { listitems.push_back(DropItem(CGame::GetInstance()->GetCamPosX() + SCREEN_WIDTH / 2, CGame::GetInstance()->GetCamPosY() + SCREEN_HEIGHT - breakwall_drop_item_y_crown, obj->idItems)); } else listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY() - breakwall_drop_item_y, obj->idItems)); } if (dynamic_cast<SmallCandle*>(obj) && obj->GetState() == break_candle && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(break_candle)->RenderOver(smallcandle_time))//để khi render xong lửa thì mới rới đồ { obj->isFire = true; listitems.push_back(DropItem(obj->GetPositionX(), obj->GetPositionY(), obj->idItems)); } } if (dynamic_cast<Zombie*>(obj) && obj->GetState() == zombie_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(zombie_ani_die)->RenderOver(zombie_time)) { Zombie* e = dynamic_cast<Zombie *>(obj); obj->isFire = true; if (e->colliwhip) { simon->addScore(e->getScore()); listitems.push_back(DropItem(obj->GetPositionX() + zombie_drop_item_x, obj->GetPositionY(), RandomItems())); } e->colliwhip = false; } } if (dynamic_cast<Boss*>(obj) && obj->GetState() == boss_ani_die && !(obj->isDone) && !(obj->isFire)) { if (obj->animation_set->at(boss_ani_die)->RenderOver(boss_time)) { Boss* e = dynamic_cast<Boss*>(obj); simon->addScore(e->getScore()); obj->isFire = true; listitems.push_back(DropItem(CGame::GetInstance()->GetCamPosX() + (SCREEN_WIDTH / 2), CGame::GetInstance()->GetCamPosY() + ((SCREEN_HEIGHT - boss_drop_item_y) / 2), items_boss)); } } } simon->SimonColliWithItems(&listitems); for (int i = 0; i < listitems.size(); i++) listitems[i]->Update(dt, &coObjects); for (int i = 0; i < objects.size(); i++) { objects[i]->Update(dt, &coObjects,!timerclk->IsTimeUp()); } simon->Update(dt, &coObjects); if (simon->GetState() == simon_ani_sit_hit) simon->GetWhip()->SetPosWhip(D3DXVECTOR3(simon->GetPositionX(), simon->GetPositionY(), 0), false);//false là ngồi else simon->GetWhip()->SetPosWhip(D3DXVECTOR3(simon->GetPositionX(), simon->GetPositionY(), 0), true);//true là đứng if (simon->currentWeapon != weapon_watch) { for (int i = 0; i < max_sub; i++) { if (simon->currentWeapon != -1 && !simon->GetListSubWeapon()[i]->isDone) simon->GetListSubWeapon()[i]->Update(dt, &objects); } } float cx, cy; simon->GetPosition(cx, cy); CGame *game = CGame::GetInstance(); if (simon->isChangeScene) { SwitchScene(simon->nextscene); simon->isChangeScene = false; } if (boss == nullptr) { if (simon->GetPositionX() > (SCREEN_WIDTH / 2) && simon->GetPositionX() + (SCREEN_WIDTH / 2) < tilemap->getwidthmap()) { cx = simon->GetPositionX() - (SCREEN_WIDTH / 2); CGame::GetInstance()->SetCamPos(cx, 0.0f); } } else { if (simon->GetPositionX() > (SCREEN_WIDTH / 2) && simon->GetPositionX() + (SCREEN_WIDTH / 2) < tilemap->getwidthmap() && !boss->checkactive) { cx = simon->GetPositionX() - (SCREEN_WIDTH / 2); CGame::GetInstance()->SetCamPos(cx, 0.0f); } if (boss->checkactive) if (simon->x < CGame::GetInstance()->GetCamPosX() - sub_dis_cam_boss) simon->x = CGame::GetInstance()->GetCamPosX() - sub_dis_cam_boss; } grid->ResetGrid(listpush); if (boss == nullptr) board->Update(dt, simon->GetHealth(), boss_max_hp); else board->Update(dt, simon->GetHealth(), boss->hp); Revival(); //DebugOut(L" SO PHAN TU TRONG LISTPIECE %d \n", listpiece.size()); /*if (simon->bossdie) { if (!checkreset) { reset->Start(); checkreset = true; } if (simon->GetHealth() < simon_max_health) { if (delayaddhp->IsTimeUp()) { delayaddhp->Start(); simon->addHp(1); } } if (simon->getmana() > 0) { simon->usemana(1); simon->addScore(add_score_time_up); } if (board->gettimemax() > 0) { board->subtimemax(1); simon->addScore(10); } }*/ ResetGame(); } void CPlayScene::Render() { tilemap->Draw(); board->Render(idstage, CGame::GetInstance()->GetCamPosX(), 0, simon); /*for (int i = 0; i < liststairleft.size(); i++) liststairleft[i]->Render(); for (int i = 0; i < liststairright.size(); i++) liststairright[i]->Render(); */ for (int i = 0; i < listitems.size(); i++) listitems[i]->Render(); for (int i = 0; i < objects.size(); i++) if(objects[i]!=dynamic_cast<Ground*>(objects[i])) objects[i]->Render(); for (int i = 0; i < listpiece.size(); i++) listpiece[i]->Render(); simon->Render(); if (simon->Getnx() > 0) simon->GetWhip()->SetNx(1); else simon->GetWhip()->SetNx(-1); if ((simon->GetState() == simon_ani_stand_hit || simon->GetState() == simon_ani_sit_hit || simon->GetState() == simon_ani_stair_down_hit || simon->GetState() == simon_ani_stair_up_hit) && !simon->isHitSubWeapon || (simon->isHitSubWeapon&&simon->currentWeapon == -1)) { simon->GetWhip()->Render(simon->animation_set->at(simon->GetState())->GetcurrentFrame()); } else simon->GetWhip()->Render(-1); if (simon->currentWeapon != 1) { for (int i = 0; i < max_sub; i++) { if (simon->currentWeapon != -1) { simon->GetListSubWeapon()[i]->Render(); } } } //if(simon->isHitSubWeapon&&simon->currentWeapon!=-1) //simon->GetKnife()->Render(); } /* Unload current scene */ void CPlayScene::Unload() { for (int i = 0; i < objects.size(); i++) delete objects[i]; objects.clear(); for (int i = 0; i < listitems.size(); i++) delete listitems[i]; listitems.clear(); for (int i = 0; i < liststairleft.size(); i++) delete liststairleft[i]; liststairleft.clear(); for (int i = 0; i < liststairright.size(); i++) delete liststairright[i]; liststairright.clear(); for (int i = 0; i < listpiece.size(); i++) delete listpiece[i]; listpiece.clear(); listpush.clear(); listidle.clear(); delete grid; delete grididle; grid = NULL; grididle = NULL; boss = nullptr; } void CPlayScenceKeyHandler::RunRight() { Simon *simon = ((CPlayScene*)scence)->simon; simon->SetNx(1); simon->SetState(simon_ani_run); } void CPlayScenceKeyHandler::RunLeft() { Simon *simon = ((CPlayScene*)scence)->simon; simon->SetNx(-1); simon->SetState(simon_ani_run); } // , void CPlayScenceKeyHandler::Jump() { Simon *simon = ((CPlayScene*)scence)->simon; if (simon->GetState() == simon_ani_stand_hit || simon->GetState() == simon_ani_sit_hit || simon->GetState() == simon_ani_sit || simon->GetState() == simon_ani_led) return; if (simon->isGrounded) simon->SetState(simon_ani_jump); } void CPlayScenceKeyHandler::Idle() { Simon *simon = ((CPlayScene*)scence)->simon; if (simon->isGrounded) simon->SetState(simon_ani_idle); } void CPlayScenceKeyHandler::Hit() { Simon *simon = ((CPlayScene*)scence)->simon; if (simon->isWalkStair) return; if ((simon->GetState() == simon_ani_idle || simon->GetState() == simon_ani_jump || simon->GetState() == simon_ani_run)) { if (simon->isGrounded) { simon->SetState(simon_ani_stand_hit); simon->SetVx(0); } else { simon->SetState(simon_ani_stand_hit); } } else if (simon->GetState() == simon_ani_sit) simon->SetState(simon_ani_sit_hit); else if (simon->GetState() == simon_ani_stair_up) simon->SetState(simon_ani_stair_up_hit); else if (simon->GetState() == simon_ani_stair_down) simon->SetState(simon_ani_stair_down_hit); } void CPlayScenceKeyHandler::Sit() { Simon *simon = ((CPlayScene*)scence)->simon; simon->SetState(simon_ani_sit); } void CPlayScenceKeyHandler::Hit_SubWeapon() { Simon *simon = ((CPlayScene*)scence)->simon; CPlayScene *playscene = ((CPlayScene*)scence); SubWeapon * subweaponlist = NULL; if (simon->currentWeapon == weapon_watch) { subweaponlist = simon->GetListSubWeapon()[first_sub]; if (simon->getmana() < mana_use) return; if (!playscene->timerclk->IsTimeUp()) return; } if (simon->currentWeapon != -1 && simon->currentWeapon != 1) { if (!simon->GetListSubWeapon()[first_sub]->isFire) subweaponlist = simon->GetListSubWeapon()[first_sub]; else if (!simon->GetListSubWeapon()[sec_sub]->isFire && (simon->hitDoubleTriple == 0 || simon->hitDoubleTriple == 1)) subweaponlist = simon->GetListSubWeapon()[sec_sub]; else if (!simon->GetListSubWeapon()[last_sub]->isFire && simon->hitDoubleTriple == 1) subweaponlist = simon->GetListSubWeapon()[last_sub]; else return; } if (simon->currentWeapon == -1||simon->getmana()==0) { Hit(); return; //return để không bị đánh khi không có vũ khí phụ } if (simon->currentWeapon == weapon_watch) { simon->usemana(mana_use); playscene->timerclk->Start(); } if (!subweaponlist->isDone) //để cho vũ khí phụ ko thể đánh quá nhiều return; simon->isHitSubWeapon = true; if (simon->getcurrentweapon() != -1 && simon->currentWeapon != weapon_watch) { subweaponlist->SetNx(simon->Getnx()); if (simon->GetState() == simon_ani_sit) subweaponlist->SetPosSubWeapon(D3DXVECTOR3(simon->GetPositionX(), simon->GetPositionY(), 0), false); else subweaponlist->SetPosSubWeapon(D3DXVECTOR3(simon->GetPositionX(), simon->GetPositionY(), 0), true); subweaponlist->SetV(); subweaponlist->isDone = false; subweaponlist->isFire = true; simon->usemana(1); } Hit(); } void CPlayScenceKeyHandler::Stair_Down() { Simon *simon = ((CPlayScene*)scence)->simon; int Stairnx = simon->stairNx; //hướng cầu thang if (!simon->canmovedownstair)//ra khỏi cầu thang { if (simon->isStandOnStair) { float stairx; stairx = simon->stairCollided->GetPositionX(); if (Stairnx == 1) stairx -= dis_sub_auto_walk;//31.0f; else stairx += dis_add_auto_walk;//5; simon->nx = simon->stairNx; simon->SetState(simon_ani_stair_up); simon->AutoWalkStair(stairx, simon_ani_idle, -simon->nx);//tránh trường hợp ra khỏi cầu thang mà ko dụng vào mặt đất } else { simon->SetState(simon_ani_sit); return; } } if (!simon->isStandOnStair)// đi đúng đến vị trí cần đi { float stairx, simonx; stairx =simon->stairCollided->GetPositionX(); simonx = simon->GetPositionX(); if (Stairnx == 1) stairx += dis_down_st_1;//4.0f; else stairx -= dis_sub_auto_walk;//31.0f; if (stairx < simonx) simon->SetNx(-1); else if (stairx > simonx) simon->SetNx(1); simon->vy = 0; simon->SetState(simon_ani_run); simon->AutoWalkStair(stairx, simon_ani_stair_down, -Stairnx); simon->isStandOnStair = true; return; } else { simon->nx = -simon->stairNx; simon->SetState(simon_ani_stair_down); } return; } void CPlayScenceKeyHandler::Stair_Up() { Simon *simon = ((CPlayScene*)scence)->simon; int NxStair = simon->stairNx; if (!simon->canmoveupstair) { if (simon->isStandOnStair) { float stairx,sty; stairx = simon->stairCollided->GetPositionX(); if (NxStair == 1) stairx += dis_add_auto_walk;//5.0f; else stairx -= dis_sub_auto_walk_up;//32.0f; simon->nx = simon->stairNx; simon->SetState(simon_ani_stair_up); simon->AutoWalkStair(stairx, simon_ani_idle, simon->nx);//tránh trường hợp ra khỏi cầu thang mà ko dụng vào mặt đất } return; } if (!simon->isStandOnStair) // đi đúng đến vị trí cần đi { float stair_x, simon_x; stair_x = simon->stairCollided->GetPositionX(); simon_x = simon->GetPositionX(); if (NxStair == 1) stair_x -= dis_sub_auto_walk;//31.0f; else stair_x += dis_up_st;//4.0f; if (stair_x < simon_x) simon->SetNx(-1); else if (stair_x > simon_x) simon->SetNx(1); simon->SetState(simon_ani_run); simon->vy = 0; simon->AutoWalkStair(stair_x, simon_ani_stair_up, NxStair); simon->isStandOnStair = true; return; } else { simon->SetNx(NxStair); simon->SetState(simon_ani_stair_up); } return; } bool CPlayScenceKeyHandler::Simon_Stair_Stand() { Simon *simon = ((CPlayScene*)scence)->simon; if (simon->GetState() == simon_ani_stair_up || simon->GetState() == simon_ani_stair_down || simon->GetState() == simon_ani_stair_down_hit || simon->GetState() == simon_ani_stair_up_hit) { if (simon->GetState() == simon_ani_stair_up_hit) { simon->SetState(simon_ani_stair_up); simon->animation_set->at(simon_ani_stair_up)->startFrameTime = 0; } else if (simon->GetState() == simon_ani_stair_down_hit) { simon->SetState(simon_ani_stair_down); simon->animation_set->at(simon_ani_stair_down)->startFrameTime = 0; } simon->StandOnStair(); simon->animation_set->at(simon_ani_stair_up)->ResetcurrentFrame(); simon->animation_set->at(simon_ani_stair_down)->ResetcurrentFrame(); return true; } return false; } bool CPlayScenceKeyHandler::StairCollisionsDetectionLeft() { Simon *simon = ((CPlayScene*)scence)->simon; CPlayScene* playscene = ((CPlayScene*)scence); //simon->StairLeftFirst = true; return simon->SimonColliWithStair(playscene->GetListStairsLeft()); } bool CPlayScenceKeyHandler::StairCollisionsDetectionRight() { Simon *simon = ((CPlayScene*)scence)->simon; CPlayScene* playscene = ((CPlayScene*)scence); return simon->SimonColliWithStair(playscene->GetListStairsRight()); } void CPlayScenceKeyHandler::OnKeyDown(int KeyCode) { //DebugOut(L"[INFO] KeyDown: %d\n", KeyCode); CGame *game = CGame::GetInstance(); Simon *simon = ((CPlayScene*)scence)->simon; CPlayScene* playscene = ((CPlayScene*)scence); switch (KeyCode) { case DIK_A: if (game->IsKeyDown(DIK_UP)) Hit_SubWeapon(); else Hit(); break; case DIK_S: if (simon->isStandOnStair == false && simon->GetState() != simon_ani_hurt) Jump(); break; case DIK_Q: if (simon->GetState() != simon_ani_dead) { simon->currentscene = 0; simon->nextscene = map1; simon->bossdie = false; playscene->SwitchScene(map1); } break; case DIK_W: if (simon->GetState() != simon_ani_dead) { simon->currentscene = map1; simon->nextscene = map2; simon->bossdie = false; playscene->SwitchScene(map2); } break; case DIK_E: if (simon->GetState() != simon_ani_dead) { simon->currentscene = map2; simon->nextscene = map3; simon->bossdie = false; playscene->SwitchScene(map3); } break; case DIK_R: if (simon->GetState() != simon_ani_dead) { simon->currentscene = map3; simon->nextscene = map4;//4; simon->bossdie = false; playscene->SwitchScene(map4/*4*/); } break; case DIK_T: if (simon->GetState() != simon_ani_dead) { simon->currentscene = map4;//4; simon->nextscene = map5;//5; simon->bossdie = false; playscene->SwitchScene(5); } break; case DIK_Y: if (simon->GetState() != simon_ani_dead) { simon->currentscene = map5;//5; simon->nextscene = map6;//6; simon->bossdie = false; playscene->SwitchScene(map6); } break; case DIK_0: if(simon->GetState()!=simon_ani_dead) simon->isCross = true; break; case DIK_9: if (simon->GetState() != simon_ani_dead) simon->watertime->Start(); break; case DIK_1: if (simon->GetState() != simon_ani_dead) { simon->InstallKnife(); } break; case DIK_2: if (simon->GetState() != simon_ani_dead) { simon->InstallAxe(); } break; case DIK_3: if (simon->GetState() != simon_ani_dead) { simon->InstallBoom(); } break; case DIK_4: if (simon->GetState() != simon_ani_dead) { simon->InstallHoly(); } break; case DIK_5: if (simon->GetState() != simon_ani_dead) { simon->hitDoubleTriple = 0; } break; case DIK_6: if (simon->GetState() != simon_ani_dead) { simon->hitDoubleTriple = 1; } break; case DIK_7: if (simon->GetState() != simon_ani_dead) { simon->hitDoubleTriple = -1; } break; case DIK_8: if (simon->GetState() != simon_ani_dead) { simon->InstallClk(); } break; case DIK_O: if (simon->GetState() != simon_ani_dead) { simon->addHp(simon_max_health); } break; } } void CPlayScenceKeyHandler::OnKeyUp(int KeyCode) {} void CPlayScenceKeyHandler::KeyState(BYTE *states) { CGame *game = CGame::GetInstance(); Simon *simon = ((CPlayScene*)scence)->simon; if (simon->GetState() == simon_ani_dead||(simon->isWalkStair == true)) return; if (simon->GetState() == simon_ani_stand_hit && simon->animation_set->at(simon_ani_stand_hit)->RenderOver(simon_delay_hit))//để cho ko bị đánh 2 lần { if (!(simon->isGrounded)) simon->SetState(simon_ani_jump); else simon->SetState(simon_ani_idle); } if (!(simon->isGrounded)) return; if (simon->GetState() == simon_ani_hurt && !(simon->animation_set->at(simon_ani_hurt)->RenderOver(simon_delay_hurt))) return; if (simon->GetState() == simon_ani_stair_up_hit && !(simon->animation_set->at(simon_ani_stair_up_hit)->RenderOver(simon_delay_hit))) return; if (simon->GetState() == simon_ani_stair_down_hit && !(simon->animation_set->at(simon_ani_stair_down_hit)->RenderOver(simon_delay_hit))) return; if (simon->GetState() == simon_ani_stair_up && !(simon->animation_set->at(simon_ani_stair_up)->RenderOver(simon_delay_stair))) return; if (simon->GetState() == simon_ani_stair_down && !(simon->animation_set->at(simon_ani_stair_down)->RenderOver(simon_delay_stair))) return; if (simon->GetState() == simon_ani_led && !(simon->animation_set->at(simon_ani_led)->RenderOver(simon_delay_led))) return; if ((simon->GetState() == simon_ani_stand_hit && !(simon->animation_set->at(simon_ani_stand_hit)->RenderOver(simon_delay_hit))) || (simon->GetState() == simon_ani_sit_hit && !simon->animation_set->at(simon_ani_sit_hit)->RenderOver(simon_delay_hit))) { return; } else { simon->GetWhip()->Setdelaydamage(false); simon->isHitSubWeapon = false; } if (game->IsKeyDown(DIK_DOWN)) { if (StairCollisionsDetectionRight() /*&& !simon->StairLeftFirst*/) { Stair_Down(); return; } if (StairCollisionsDetectionLeft()) { Stair_Down(); return; } Sit(); if (game->IsKeyDown(DIK_RIGHT)) simon->SetNx(1); else if (game->IsKeyDown(DIK_LEFT)) simon->SetNx(-1); } else if (game->IsKeyDown(DIK_UP)) { if (StairCollisionsDetectionLeft()) { //simon->StairLeftFirst = false; Stair_Up(); return; } if (StairCollisionsDetectionRight()) { //simon->StairLeftFirst = false; Stair_Up(); return; } Idle(); } else if (game->IsKeyDown(DIK_LEFT)) { if (StairCollisionsDetectionRight() || StairCollisionsDetectionLeft()) { if (Simon_Stair_Stand()) return; } RunLeft(); } else if (game->IsKeyDown(DIK_RIGHT)) { if (StairCollisionsDetectionRight() || StairCollisionsDetectionLeft()) { if (Simon_Stair_Stand()) return; } RunRight(); } else { if (StairCollisionsDetectionRight() || StairCollisionsDetectionLeft()) { if (Simon_Stair_Stand()) { return; } } Idle(); } }
07c2b0989d8c23b6be33788d0472f897901e2b16
f053ab13816b888c7661b82e4dc226f618b8d01c
/DMOJ/04/J1/solution1.cpp
ca4b51fe43c24eb181bc0d8969b5040a775e8bba
[]
no_license
rowanzaitlin/CCC-DMOJ_Solutions
e223884b04be6b71d8423e05beb3f8afc1ec3ae5
da04ae4ed1f1385f70f8ec22054e90953b04a5f0
refs/heads/master
2020-12-23T09:26:19.738180
2020-01-29T23:37:55
2020-01-29T23:37:55
237,111,637
0
0
null
2020-01-30T00:42:25
2020-01-30T00:42:24
null
UTF-8
C++
false
false
191
cpp
solution1.cpp
#include <iostream> #include <math.h> using namespace std; int input; int main() { cin >> input; cout << "The largest square has side length " << floor(sqrt(input)) << "."; return 0; }
b63e4532615d909828b96604dce54068b7039a74
6b2a8dd202fdce77c971c412717e305e1caaac51
/solutions_2749486_0/C++/GauravKatoch007/CodeJam2013.cpp
3de2a836c2acec15689c3bcae90557dfd810491f
[]
no_license
alexandraback/datacollection
0bc67a9ace00abbc843f4912562f3a064992e0e9
076a7bc7693f3abf07bfdbdac838cb4ef65ccfcf
refs/heads/master
2021-01-24T18:27:24.417992
2017-05-23T09:23:38
2017-05-23T09:23:38
84,313,442
2
4
null
null
null
null
UTF-8
C++
false
false
1,367
cpp
CodeJam2013.cpp
//============================================================================ // Name : CodeJam2013.cpp // Author : Gaurav // Version : // Copyright : Your copyright notice // Description : Hello World in C++, Ansi-style //============================================================================ #include<iostream> #include<stdio.h> #include<algorithm> #include<vector> #include<stack> #include<math.h> #include<fstream> #include<string.h> using namespace std; int limit=500; vector<char> v; bool found; void eval(char X,int Y){ int step=1; if(X>0)while(X!=0){ v.push_back('W'); X+=step; step++; v.push_back('E'); X-=step; step++; } else while(X!=0){ v.push_back('E'); X-=step; step++; v.push_back('W'); X+=step; step++; } if(Y>0)while(Y!=0){ v.push_back('S'); Y+=step; step++; v.push_back('N'); Y-=step; step++; } else while(Y!=0){ v.push_back('N'); Y-=step; step++; v.push_back('S'); Y+=step; step++; } int i; for(i=0;i<v.size();i++) printf("%c",v[i]); } int main() { ofstream file; file.open("out.txt"); int i,j,k,T,X,Y; scanf("%d",&T); for(i=0;i<T;i++){ scanf("%d %d",&X,&Y); v.clear(); found=false; printf("\nCase #%d: ",i+1); eval(X,Y); } //file<<"Case #"<<i+1<<": "<<eval(str,N)<<"\n"; }
6e03b5d4759c499fb8ef5432170419eb3cab15fe
fe5f86faaec82f7f7706623d7c309a8d0820e387
/f00ale-cpp/p05.cpp
821b856d5f07649725e06922a8ac5beef7ab6dcf
[]
no_license
Dyr-El/advent_of_code_2017
01dac99cff9339d92360e89882aa5f1081e11c4f
6f09b1c15cc1070a4b3cca951dcb50b33ee5361b
refs/heads/master
2021-12-24T05:23:19.892898
2021-12-22T21:19:33
2021-12-22T21:19:33
112,791,062
1
0
null
2018-11-13T08:04:23
2017-12-01T22:00:31
C++
UTF-8
C++
false
false
627
cpp
p05.cpp
#include <iostream> #include <vector> int main() { std::vector<int> v; while(1) { int tmp = 0; std::cin >> tmp; if(!std::cin.good()) break; v.push_back(tmp); } auto v2 = v; size_t i = 0; int ans1 = 0; while(i < v.size()) { auto ni = i + v[i]; v[i]++; i = ni; ans1++; } std::cout << ans1 << std::endl; v = v2; int ans2 = 0; i = 0; while(i < v.size()) { auto ni = i + v[i]; if(v[i] >= 3) v[i]--; else v[i]++; i = ni; ans2++; } std::cout << ans2 << std::endl; }
8b35d7da9a37d1b04d5139fc4bb65c22a999bcae
36ce5430f26f11e7ebee67eda20853427479d0f5
/bake/WiEngineDemosNative/jni/Demos/Box2D/PulleysTest.inl
3d15ded693cecaba5a5d884a6aeef2adb4915020
[]
no_license
widerules/droidloft
7c23d25fb49742971849c16cd44ff9bd66de7a6f
0b8148fcdd6adc2920e68cb8da1aa542372df1f7
refs/heads/master
2020-07-25T15:06:49.335162
2012-01-09T05:02:33
2012-01-09T05:02:33
41,132,530
0
0
null
null
null
null
UTF-8
C++
false
false
1,353
inl
PulleysTest.inl
class wyPulleysTestLayer : public wyBox2DTestLayer { private: b2PulleyJoint* m_joint1; public: wyPulleysTestLayer() { // get world b2World* world = m_box2d->getWorld(); // set gravity world->SetGravity(b2Vec2(0, -10)); // place box2d to center of bottom edge m_box2d->setPosition(wyDevice::winWidth / 2, 0); b2Body* ground = NULL; { b2BodyDef bd; ground = world->CreateBody(&bd); b2EdgeShape shape; shape.Set(b2Vec2(-40.0f, 0.0f), b2Vec2(40.0f, 0.0f)); ground->CreateFixture(&shape, 0.0f); } { float32 a = 2.0f; float32 b = 4.0f; float32 y = 10.0f; float32 L = 8.0f; b2PolygonShape shape; shape.SetAsBox(a, b); b2BodyDef bd; bd.type = b2_dynamicBody; bd.position.Set(-4.0f, y); b2Body* body1 = world->CreateBody(&bd); body1->CreateFixture(&shape, 5.0f); bd.position.Set(4.0f, y); b2Body* body2 = world->CreateBody(&bd); body2->CreateFixture(&shape, 5.0f); b2PulleyJointDef pulleyDef; b2Vec2 anchor1(-4.0f, y + b); b2Vec2 anchor2(4.0f, y + b); b2Vec2 groundAnchor1(-4.0f, y + b + L); b2Vec2 groundAnchor2(4.0f, y + b + L); pulleyDef.Initialize(body1, body2, groundAnchor1, groundAnchor2, anchor1, anchor2, 2.0f); m_joint1 = (b2PulleyJoint*)world->CreateJoint(&pulleyDef); } startUpdateWorld(); } virtual ~wyPulleysTestLayer() { } };
03961391892eebd20d7fd76b8bc92d931559b9c9
8897f70beba2d947cd877e4ea19c6fd893479b82
/compy/representations/extractors/clang_ast/clang_extractor.h
dcf52b05783d1a76cef8e9833075a3f7e073dae9
[ "Apache-2.0" ]
permissive
OOiiOOiiOO/compy-learn
2b135c8006a67a5e64157e67227d3cb060f0efc1
36cd360522538b0a7eac1f14c9d7ccaf15bde77c
refs/heads/master
2023-05-09T15:10:31.952873
2021-05-21T09:33:01
2021-05-21T09:33:01
null
0
0
null
null
null
null
UTF-8
C++
false
false
3,369
h
clang_extractor.h
#pragma once #include <memory> #include <string> #include <tuple> #include <vector> #include "common/clang_driver.h" #include "common/visitor.h" namespace compy { namespace clang { namespace seq { struct FunctionInfo; using FunctionInfoPtr = std::shared_ptr<FunctionInfo>; struct ExtractionInfo; using ExtractionInfoPtr = std::shared_ptr<ExtractionInfo>; struct TokenInfo; using TokenInfoPtr = std::shared_ptr<TokenInfo>; struct TokenInfo : IVisitee { std::string name; std::string kind; void accept(IVisitor* v) override { v->visit(this); } }; struct FunctionInfo : IVisitee { std::string name; std::vector<TokenInfoPtr> tokenInfos; void accept(IVisitor* v) override { v->visit(this); for (const auto& it : tokenInfos) it->accept(v); } }; struct ExtractionInfo : IVisitee { std::vector<FunctionInfoPtr> functionInfos; void accept(IVisitor* v) override { v->visit(this); for (const auto& it : functionInfos) it->accept(v); } }; } // namespace seq namespace graph { struct OperandInfo; using OperandInfoPtr = std::shared_ptr<OperandInfo>; struct DeclInfo; using DeclInfoPtr = std::shared_ptr<DeclInfo>; struct StmtInfo; using StmtInfoPtr = std::shared_ptr<StmtInfo>; struct CFGBlockInfo; using CFGBlockInfoPtr = std::shared_ptr<CFGBlockInfo>; struct FunctionInfo; using FunctionInfoPtr = std::shared_ptr<FunctionInfo>; struct ExtractionInfo; using ExtractionInfoPtr = std::shared_ptr<ExtractionInfo>; struct TokenInfo : IVisitee { std::uint64_t index; std::string name; std::string kind; ::clang::SourceLocation location; void accept(IVisitor* v) override { v->visit(this); } }; struct OperandInfo : IVisitee { virtual ~OperandInfo() = default; }; struct DeclInfo : OperandInfo { std::string name; std::string type; std::string kind; std::vector<TokenInfo> tokens; TokenInfo nameToken; void accept(IVisitor* v) override { v->visit(this); for (auto& it : tokens) it.accept(v); } }; struct StmtInfo : OperandInfo { std::string name; std::vector<TokenInfo> tokens; std::string operation; std::vector<OperandInfoPtr> ast_relations; std::vector<OperandInfoPtr> ref_relations; void accept(IVisitor* v) override { v->visit(this); for (auto& it : tokens) it.accept(v); for (const auto& it : ast_relations) it->accept(v); } }; struct CFGBlockInfo { std::string name; std::vector<StmtInfoPtr> statements; std::vector<CFGBlockInfoPtr> successors; }; struct FunctionInfo : IVisitee { std::string name; std::string type; std::vector<TokenInfo> tokens; std::vector<DeclInfoPtr> args; std::vector<CFGBlockInfoPtr> cfgBlocks; StmtInfoPtr entryStmt; void accept(IVisitor* v) override { v->visit(this); for (auto& it : tokens) it.accept(v); for (const auto& it : args) it->accept(v); entryStmt->accept(v); } }; struct ExtractionInfo : IVisitee { std::vector<FunctionInfoPtr> functionInfos; void accept(IVisitor* v) override { v->visit(this); for (const auto& it : functionInfos) it->accept(v); } }; } // namespace graph class ClangExtractor { public: ClangExtractor(ClangDriverPtr clangDriver); graph::ExtractionInfoPtr GraphFromString(std::string src); seq::ExtractionInfoPtr SeqFromString(std::string src); private: ClangDriverPtr clangDriver_; }; } // namespace clang } // namespace compy
262941d9e5039fabd3785f22d9ceedcbb7937c98
115334b5bdd95c0ea2b22181d3d14337ce002141
/tests/knewpassworddialogtest.cpp
6aeea4d3d5a9f7e173d333ecaa21ca9593f0072d
[]
no_license
KDE/kwidgetsaddons
c7134d2c36b46a27407947329975d517e984dc9c
f7eaee841f3e6fec49ced791c705b35fec0a7252
refs/heads/master
2023-08-17T03:14:43.626475
2023-08-17T02:14:32
2023-08-17T02:14:32
42,730,074
26
9
null
2023-06-07T12:27:26
2015-09-18T15:20:02
C++
UTF-8
C++
false
false
690
cpp
knewpassworddialogtest.cpp
/* This file is part of the KDE libraries SPDX-FileCopyrightText: 2007 Olivier Goffart <ogoffart at kde.org> SPDX-License-Identifier: LGPL-2.0-or-later */ #include <iostream> #include <knewpassworddialog.h> #include <qapplication.h> int main(int argc, char *argv[]) { QApplication a(argc, argv); KNewPasswordDialog dlg; dlg.setPasswordStrengthWarningLevel(30); dlg.setPrompt(QApplication::translate("main", "Enter a password for the test")); if (dlg.exec()) { std::cout << "Entered password: " << qPrintable(dlg.password()) << std::endl; return 0; } else { std::cout << "No password" << std::endl; return -1; } }
537d72cc6aa78e1e24a1b30a3d2f40fabbbce4e6
7733fc43f6afd7f647408ceeff40f3480c13a6e4
/enemy.h
d96c0cb0e80124ac4aac430a2475a182ff316c86
[]
no_license
Guraxis/42towels
ece2f40ab0be1f087d32da5a5be8ef3c795af03a
9d6171a6194d1df499e64e72b7e7cbeb3ee35db2
refs/heads/master
2020-05-17T00:51:54.680721
2015-01-05T21:22:35
2015-01-05T21:22:35
27,391,849
0
0
null
null
null
null
UTF-8
C++
false
false
312
h
enemy.h
#ifndef ENEMY_H #define ENEMY_H #include "character.h" class Enemy : public Character { public: double tempangle; bool die; int spawnrate; Enemy(); }; class EnemyBasic : public Enemy { public: EnemyBasic(); }; class EnemyTank : public Enemy { public: Rectangle body; EnemyTank(); }; #endif // ENEMY_H
d425d5eec4f9a43d0e68e8a6e4ccd22268b7c7c5
a378123f71ccb6ee769cf36dd514f3ccfbb6756d
/HipMoveController.h
8d40a2b9243111d44035d02c87538b64f689bcfd
[ "MIT" ]
permissive
collabsoft/owo-track-driver
6027aa9365b471ddafdb7cdc354e2485f01d7ef2
d0f7560f2473a97d5d26428d16b98d8ad713dffb
refs/heads/main
2023-07-13T07:19:22.437988
2021-08-23T09:39:10
2021-08-23T09:39:10
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,268
h
HipMoveController.h
#pragma once #include <openvr_driver.h> #include "AbstractDevice.h" #include "vector3.h" class RemoteTracker; class HipMoveController : public AbstractDevice { private: RemoteTracker* tgt_tracker; vr::VRInputComponentHandle_t joystick_click_component = 0; vr::VRInputComponentHandle_t joystick_touch_component = 0; vr::VRInputComponentHandle_t joystick_x_component = 0; vr::VRInputComponentHandle_t joystick_y_component = 0; void SetDirection(float x, float y); public: HipMoveController(RemoteTracker* tgt); ~HipMoveController(); EVRInitError Activate(vr::TrackedDeviceIndex_t unObjectId) override; void Deactivate() override; void EnterStandby() override; void* GetComponent(const char* pchComponentNameAndVersion) override; void PowerOff() override; void DebugRequest(const char* pchRequest, char* pchResponseBuffer, uint32_t unResponseBufferSize) override; DriverPose_t GetPose() override; void send_invalid_pose(); void RunFrame(TrackedDevicePose_t* poses) override; void ProcessEvent(const vr::VREvent_t& vrEvent) override; const char* GetSerialNumber() const override; const char* GetModelNumber() const override; const char* GetId() const override; bool enabled = false; Vector3 analog_data; };
e1b8fdc52cbe24774dd99d9bc937be412a926c0c
a080ee76d1f1f70b006dc71e7510a1b6c0e869cf
/main.cpp
52ecfd057f834a9f0e8db69f6dc5fbf2cc7fc917
[]
no_license
99002540/new
b5373aa10b3ab4370501edb7b4a389441d5e9d1e
ee6af726478b083a3e88c13076c1b3fd9166704e
refs/heads/master
2022-12-23T05:28:07.897978
2020-09-19T01:46:30
2020-09-19T01:46:30
296,681,660
0
0
null
null
null
null
UTF-8
C++
false
false
143
cpp
main.cpp
#include<iostream> #include "sum.h" int main() { int my_sum = sum(10, 20); printf("Sum = %d", my_sum); return 0; }
f38c50c3397397e82b15d7f5357080c7e3b216b8
de5b28c7d6be37b33e7140835b290ebd74055a63
/include/ilang/target-itsy/interface.h
766725d94080791f3765d909487b76a1ade72b90
[ "MIT", "BSD-3-Clause", "LicenseRef-scancode-free-unknown" ]
permissive
zhanghongce/ILA-Tools
bf2797595d9283476852c05ee7eb0a067b22088a
5ec5ff4c7c26101232a7e22bd6510a0f34bd8467
refs/heads/master
2023-04-13T21:14:38.283818
2020-10-23T02:54:25
2020-10-23T02:54:25
161,229,920
2
1
MIT
2018-12-10T20:03:39
2018-12-10T20:03:39
null
UTF-8
C++
false
false
1,305
h
interface.h
/// \file /// Elevated interface for the synthesis engine. #ifndef ILANG_TARGET_ITSY_INTERFACE_H__ #define ILANG_TARGET_ITSY_INTERFACE_H__ #include <string> #include <ilang/ila/instr_lvl_abs.h> /// \namespace ilang namespace ilang { /// \brief Import from file the abstraction from the synthesis engine and /// convert it into an ILA model. /// \param[in] file_name file name of the abstraction from the synthesis engine. /// \param[in] ila_name name of the created ILA model. /// \return the generated ILA model. InstrLvlAbsPtr ImportSynthAbsFromFile(const std::string& file_name, const std::string& ila_name = ""); /// \brief Import from file the abstraction from the synthesis engine and /// convert it into a child-ILA of the specified parent ILA. /// \param[in] file_name file name of the abstraction from the synthesis engine. /// \param[in] parent pointer to the parent ILA. /// \param[in] ila_name name of the created ILA model. /// \return the generated ILA model. InstrLvlAbsPtr ImportSynthAbsFromFileHier(const std::string& file_name, const InstrLvlAbsPtr& parent, const std::string& ila_name = ""); }; // namespace ilang #endif // ILANG_TARGET_ITSY_INTERFACE_H__
b2b7273c0859ee3f3f413a18e50b80cf525ae1f6
30364e2f7edb157cbf9f73205dfbd5128e6218d7
/DataTeamInterface/src/captor/odo.cpp
199ecbff3832ad19fc90fa8eff1f411c5816aab1
[]
no_license
Aranud/Projet_Indu3A
332f09af4f6d7ff3d2ae158f089db8b10e891a35
e80a3af14971c213151a4e0c1aecd65ed9443c7e
refs/heads/master
2016-09-06T11:41:19.645138
2015-05-30T11:59:35
2015-05-30T11:59:35
30,911,932
2
0
null
null
null
null
UTF-8
C++
false
false
2,118
cpp
odo.cpp
#include "odo.h" /** * @brief Odo::Odo */ Odo::Odo(Protocole *p_pProtocole) { m_pProtocole = p_pProtocole; m_eIDCommand = eIDCommmandOdo; m_bFrontRight = 0; m_bRearRight = 0; m_bRearLeft = 0; m_bFrontLeft = 0; } /** * @brief Odo::~Odo */ Odo::~Odo() { } /*******************************************************************************/ /**************************** ACCESSOR - MODIFICATOR ***************************/ /*******************************************************************************/ /** * @brief Odo::getFrontRight * @return */ bool Odo::getFrontRight() const { return m_bFrontRight; } /** * @brief Odo::setFrontRight * @param p_bFrontRight */ void Odo::setFrontRight(bool p_bFrontRight) { m_bFrontRight = p_bFrontRight; } /** * @brief Odo::bRearRight * @return */ bool Odo::getRearRight() const { return m_bRearRight; } /** * @brief Odo::setRearRight * @param p_bRearRight */ void Odo::setRearRight(bool p_bRearRight) { m_bRearRight = p_bRearRight; } /** * @brief Odo::getRearLeft * @return */ bool Odo::getRearLeft() const { return m_bRearLeft; } /** * @brief Odo::setRearLeft * @param p_bRearLeft */ void Odo::setRearLeft(bool p_bRearLeft) { m_bRearLeft = p_bRearLeft; } /** * @brief Odo::getFrontLeft * @return */ bool Odo::getFrontLeft() const { return m_bFrontLeft; } /** * @brief Odo::setFrontLeft * @param p_bFrontLeft */ void Odo::setFrontLeft(bool p_bFrontLeft) { m_bFrontLeft = p_bFrontLeft; } /*******************************************************************************/ /********************************** SLOT ***************************************/ /*******************************************************************************/ /** * @brief Odo::slotOnDataExtractedReady * @param p_baDataExtracted */ void Odo::slotOnDataExtractedReady(QByteArray p_baDataExtracted) { m_bFrontRight = p_baDataExtracted.at(0); m_bRearRight = p_baDataExtracted.at(1); m_bRearLeft = p_baDataExtracted.at(2); m_bFrontLeft = p_baDataExtracted.at(3); emit emitDataAvailable(); }
d067ffdca6ce9dd723c77f9257e161ee0f2eaa40
8483830175b98ba2915d7bf90bed728bb6a4ed75
/Examples/include/asposecpplib/net/secure_protocols/negotiate_enum_types.h
7c4ee7df1564a9059f20b846d042121ff3c6649a
[ "MIT" ]
permissive
kashifiqb/Aspose.PDF-for-C
83393e3173e2d74540f7ec7904eb91fb23b13550
13d49bba591c5704685820185741e64a462a5bdc
refs/heads/master
2020-08-08T11:15:23.173738
2019-10-09T04:41:03
2019-10-09T04:41:03
213,819,800
0
0
MIT
2019-10-09T04:20:06
2019-10-09T04:20:06
null
UTF-8
C++
false
false
263
h
negotiate_enum_types.h
#pragma once namespace System { namespace Net { namespace Security { // WebRequest-specific authentication flags enum class AuthenticationLevel { None = 0, MutualAuthRequested = 1, MutualAuthRequired = 2 }; }}} // namespace System::Net::Security
998a04848c7440933abc04122528c3d575737e18
a15430224ec58dc5a77b24961f39ecf064bcc84f
/Beakjoon/11051.cpp
9a7ea52485c404c9e8401222a3365f59994c406a
[]
no_license
sun-pyo/algorithm
a91834d44cc2ef549f8b155946cd6840dd6d7175
3e623f8d012b2df86f2f46e6e6860e4d54d81ac0
refs/heads/main
2023-09-06T07:21:17.250972
2021-11-11T14:42:18
2021-11-11T14:42:18
325,583,431
0
0
null
null
null
null
UTF-8
C++
false
false
439
cpp
11051.cpp
#include <iostream> #include <vector> using namespace std; int DP[1001][1001]; int main(){ ios::sync_with_stdio(false); cin.tie(NULL); int N,K; cin>>N>>K; for(int n=1;n<=N;n++){ for(int k=0;k<=K;k++){ if(k==0 || k==n){ DP[n][k] = 1; } else{ DP[n][k] = (DP[n-1][k-1] + DP[n-1][k])%10007; } } } cout<<DP[N][K]; }
3fcdfaf583ad0b685bd74e51e0550c73c3519530
7a1ec2e273331932bdfe6db8c1025371969f5ea3
/srcs/methods.cpp
3f331c88142c7c1058b60e02b3f4de7476bf3400
[]
no_license
Xsergserg/webserv
c3a417657e8fbb23faa4ac12fc4b08d2d33e34f2
9ed1517e7765c25987e2fe8b1b3a05c8d7969bda
refs/heads/master
2023-06-17T01:13:22.944212
2021-07-18T13:03:27
2021-07-18T13:03:27
387,176,883
0
0
null
null
null
null
UTF-8
C++
false
false
19,519
cpp
methods.cpp
// // Created by Karyn Cedra on 4/5/21. // #include "methods.h" void *returnError(RequestHeaders request, int statusC, std::string reason, ConnectionClass &connection) { ResponseHeaders response; std::stringstream strstream; std::fstream fin; std::string body; std::string statusCode; std::string contentLength; std::string file; std::string ret; char *line; char *charbuffer; void *buffer; void *retline; int length; bool errorexist = 0; std::map<int, std::string> errors; std::string errorfile; if ((request.getResponseFlags() & CUSTOM_ERRORS) == CUSTOM_ERRORS) { if (request.getLocation() == -1) { errors = connection.getServer().getErrorPages(); } else { errors = (*connection.getServer().getLocations())[request.getLocation()]->getErrorPages(); } for (std::map<int, std::string>::iterator it = errors.begin(); it != errors.end() ; ++it) { if (it->first == statusC) { errorexist = 1; file = it->second; break;; } } if (errorexist) { fin.open(file); fin.seekg(0, fin.end); length = fin.tellg(); fin.seekg(0, fin.beg); charbuffer = new char[length]; fin.read(charbuffer, length); buffer = static_cast<void *>(charbuffer); response.setBinaryPage(buffer, length); fin.close(); response.setContentType(mimeDetect(file)); } } if (!errorexist) { body += "<html>\n" "<head><title>"; body += std::to_string(statusC); body += " " + reason; body += "</title></head>\n" "<body>\n" "<center><h1>"; body += std::to_string(statusC); body += " " + reason; body += "</h1></center>\n" "<hr><center>webserver</center>\n" "</body>\n" "</html>"; response.setPage(body); response.setContentType("text/html"); } response.setVersion(); response.setStatusCode(statusC); response.setReasonPhrase(reason); if (statusC == 308) { response.setLocation((*connection.getServer().getLocations())[request.getLocation()]->getRedirection()); } if (statusC == 405 || statusC == 501) response.setAllow(connection, request); response.setConnection("keep-alive"); if (errorexist) response.setContentLength(response.getBinaryPageLen()); else response.setContentLength(response.getPage().length()); response.setDate(request); response.setServer(); statusCode = std::to_string(response.getStatusCode()); contentLength = std::to_string(response.getContentLength()); ret = response.getVersion() + " " + statusCode + " " + response.getReasonPhrase(); if (statusC == 501 || statusC == 405) ret += "\r\nAllow: " + response.getAllow(); ret += "\r\nConnection: " + response.getConnection() + "\r\nContent-Length: " + contentLength; ret += "\r\nContent-Type: " + response.getContentType() + "\r\nServer: " + response.getServer(); if (statusC == 308) ret += "\r\nLocation: " + response.getLocation(); ret += "\r\n\r\n" + response.getPage(); if (errorexist) { line = ft_strdup(ret.c_str()); retline = newbuffer(line, response.getBinaryPage(), (int)(response.getBinaryPageLen())); connection.setAnswerSize(ret.size() + response.getBinaryPageLen()); return (retline); } else { ret += response.getPage(); line = ft_strdup(ret.c_str()); response.setBinaryPage(nullptr, 0); connection.setAnswerSize(ret.size() + response.getPage().size()); return (line); } } void *GET(RequestHeaders request, ConfigClass server, ConnectionClass &connection) { ResponseHeaders response; std::string body; std::string ret; std::string statusCode; std::string contentLength; std::string file; std::string directory; std::string uri = request.get_uri(); std::string::iterator it; std::string::iterator ite; std::fstream fin; std::stringstream strstream; struct stat buf; struct dirent *entry; std::string seekfilename; char *line; void *retline; DIR *dir; int length; void *buffer; char *charbuffer; size_t pos; size_t result; std::string index = ""; bool flag = 0; if (*(--uri.end()) == '/') { if ((request.getResponseFlags() & LISTING) == LISTING) { if ((request.getResponseFlags() & LISTING_RESULT_YES) != LISTING_RESULT_YES) { return (returnError(request, 403, "Forbidden", connection)); } flag = 1; } else { if ((request.getResponseFlags() & INDEX) == INDEX) { //Выбираю индекс из локейшена file = (*server.getLocations())[request.getLocation()]->getIndex(); } } } else { if ((pos = uri.find("?")) != std::string::npos) uri.erase(pos, uri.length() - 1); it = uri.end(); ite = uri.end(); while (*it != '/') { it--; } directory = (std::string(uri.begin(), it++)) + '/'; if ((result = directory.find("//")) != std::string::npos) { directory.replace(result, 2, std::string("/")); } dir = opendir(directory.c_str()); it--; while (++it != ite) { file += *(it); } while (dir != NULL && (entry = readdir(dir)) != NULL) { seekfilename = entry->d_name; stat(file.c_str(), &buf); if (seekfilename == file) { if (S_ISDIR(buf.st_mode)) { file = uri + "/" + index; } closedir(dir); break; } } if (dir == NULL || entry == NULL) { if (dir != NULL) { closedir(dir); } return (returnError(request, 404, "Not Found", connection)); } file = directory + file; } response.setBinaryPage(nullptr, 0); if ((request.getResponseFlags() & LISTING) == LISTING && flag == 1) { if ((request.getResponseFlags() & LISTING_RESULT_YES) == LISTING_RESULT_YES) { directory = uri; response.setPage(listing(directory)); } } else { if (mimeDetect(file) == "image/png" || mimeDetect(file) == "image/jpeg" || mimeDetect(file).find("font") != std::string::npos) { fin.open(file, std::ios::binary | std::ios::in); } else { fin.open(file, std::ios::in); } if (!fin.is_open()) return (returnError(request, 404, "Not Found", connection)); else { if (mimeDetect(file) == "image/png" || mimeDetect(file) == "image/jpeg" || mimeDetect(file).find("font") != std::string::npos) { fin.seekg(0, fin.end); length = fin.tellg(); fin.seekg(0, fin.beg); charbuffer = new char[length]; ft_bzero(charbuffer, sizeof(char)); fin.read(charbuffer, length); buffer = static_cast<void*>(charbuffer); response.setBinaryPage(buffer, length); fin.close(); } else { strstream << fin.rdbuf(); body = strstream.str(); response.setPage(body); fin.close(); } } } response.setVersion(); response.setStatusCode(200); response.setReasonPhrase("OK"); if (request.get_connection() == "close") { response.setConnection("close"); } else { response.setConnection("keep-alive"); } if (response.getBinaryPage() != nullptr) { response.setContentLength(response.getBinaryPageLen()); } else { response.setContentLength(response.getPage().length()); } if ((request.getResponseFlags() & LISTING) == LISTING && flag == 1) response.setContentType("text/html"); else response.setContentType(mimeDetect(file)); response.setServer(); statusCode = std::to_string(response.getStatusCode()); contentLength = std::to_string(response.getContentLength()); ret = response.getVersion() + " " + statusCode + " " + response.getReasonPhrase(); ret += "\r\nConnection: " + response.getConnection() + "\r\nContent-Length: " + contentLength; ret += "\r\nContent-Type: " + response.getContentType(); ret += "\r\nServer: " + response.getServer(); ret += "\r\n\r\n"; if (mimeDetect(file) == "image/png" || mimeDetect(file) == "image/jpeg" || mimeDetect(file).find("font") != std::string::npos) { line = ft_strdup(ret.c_str()); retline = newbuffer(line, response.getBinaryPage(), (int)(response.getBinaryPageLen())); //delete line; connection.setAnswerSize(ret.size() + response.getBinaryPageLen()); //delete charbuffer; //static_cast<char*>(response.getBinaryPage()); response.setBinaryPage(nullptr, 0); return (retline); } else { ret += response.getPage(); line = ft_strdup(ret.c_str()); connection.setAnswerSize(ret.size() + response.getPage().size()); return (line); } } void *POST(RequestHeaders request, ConfigClass server, ConnectionClass &connection) { ResponseHeaders response; std::fstream file; std::string openfile; std::string ret; std::string body; size_t result; std::string statucCode; char *line; if (request.getBody().length() == 0) { response.setVersion(); openfile = server.getRoot() + "/" + request.get_uri(); if ((result = openfile.find("//")) != std::string::npos) { openfile.replace(result, 2, std::string("/")); } file.open(openfile, std::fstream::out); if (file.is_open()) file.close(); response.setReasonPhrase("No Content"); response.setConnection("keep-alive"); response.setServer(); ret = response.getVersion() + " 204 " + response.getReasonPhrase(); ret += "\r\nConnection: " + response.getConnection(); ret += "\r\nServer: " + response.getServer() + "\r\n"; connection.setAnswerSize(ret.size()); return (ft_strdup(ret.c_str())); } else { response.setVersion(); response.setServer(); if ((request.getResponseFlags() & CLIENT_BODY_SIZE_EXIST) == CLIENT_BODY_SIZE_EXIST) { if (request.getLocation() < 0) { if (static_cast<int>(request.getBody().size()) > server.getClientBodySize()) return (returnError(request, 413, "Payload Too Large", connection)); } else { if (static_cast<int>(request.getBody().size()) > (*server.getLocations())[request.getLocation()]->getClientBodySize()) { return (returnError(request, 413, "Payload Too Large", connection)); } } } openfile = request.get_uri(); if ((result = openfile.find("//")) != std::string::npos) { openfile.replace(result, 2, std::string("/")); } if ((request.getResponseFlags() & CGI_FLAG) == CGI_FLAG) { CGI cgi(request, *(*server.getLocations())[request.getCGILocation()], connection, request.get_uri()); statucCode = cgi.run(body); if (statucCode == "500") return (returnError(request, 500, "Server Error", connection)); else { response.setStatusCode(200); response.setReasonPhrase("OK"); if (request.get_connection() == "close") { response.setConnection("close"); } else { response.setConnection("keep-alive"); } response.setContentType("text/html"); response.setContentLength(body.size()); ret = response.getVersion() + " " + "200" + " " + response.getReasonPhrase(); ret += "\r\nConnection: " + response.getConnection(); ret += "\r\nContent-Length: " + std::to_string(response.getContentLength()); ret += "\r\nContent-Type: " + response.getContentType(); ret += "\r\nServer: " + response.getServer(); ret += "\r\n\r\n"; ret += body; line = ft_strdup(ret.c_str()); connection.setAnswerSize(ret.size() + ft_strlen(line)); return (line); } } else { file.open(openfile, std::fstream::out); if (file.is_open()) { file << request.getBody(); response.setReasonPhrase("Created"); response.setConnection("keep-alive"); response.setServer(); ret = response.getVersion() + " 201 " + response.getReasonPhrase(); ret += "\r\nConnection: " + response.getConnection(); ret += "\r\nServer: " + response.getServer() + "\r\n"; connection.setAnswerSize(ret.size()); return (ft_strdup(ret.c_str())); } else { return (returnError(request, 404, "Found", connection)); } } } } void *DELETE(RequestHeaders request, ConnectionClass &connection) { ResponseHeaders response; std::string file; std::string ret; size_t result; file = request.get_uri(); if ((result = file.find("//")) != std::string::npos) { file.replace(result, 2, std::string("/")); } if (std::remove(file.c_str()) == 0) { response.setVersion(); response.setReasonPhrase("OK"); response.setConnection("keep-alive"); response.setServer(); ret = response.getVersion() + " 200 " + response.getReasonPhrase(); ret += "\r\nConnection: " + response.getConnection(); ret += "\r\nServer: " + response.getServer() + "\r\n"; connection.setAnswerSize(ret.size()); return (ft_strdup(ret.c_str())); } else { return (returnError(request, 400, "Bad Request", connection)); } } void *methodNotAllowed(RequestHeaders request, ConnectionClass &connection) { return (returnError(request, 405, "Method Not Allowed", connection)); } void *noSuchMethod(RequestHeaders request, ConnectionClass &connection) { return (returnError(request, 501, "Not Implemented", connection)); } static bool checkServer(RequestHeaders &request, std::vector<ConfigClass*> config, ConnectionClass &connection) { uint32_t ip; uint16_t port; std::string serverName; bool firstServerFlag = 0; size_t firstServer = 0; bool flag = 0; request.clearResponesFlag(); if (request.get_host() != "") { for (size_t i = 0; i < config.size(); ++i) { ip = config[i]->getIp(); port = config[i]->getPort(); serverName = config[i]->getServer_name(); if (firstServerFlag == 0 && port == connection.getListenPort()) { firstServer = i; firstServerFlag = 1; } if (serverName == request.get_host() && ip == connection.getListenIp() && port == connection.getListenPort()) { connection.setServer(*config[i]); request.setResponseFlag(SERVER_NAME); flag = 1; break; } } if (firstServerFlag && !flag) { connection.setServer(*config[firstServer]); request.setResponseFlag(SERVER_NAME); flag = 1; } } else { for (size_t i = 0; i < config.size(); ++i) { ip = config[i]->getIp(); port = config[i]->getPort(); if (ip == connection.getListenIp() && port == connection.getListenPort()) { connection.setServer(*config[i]); request.setResponseFlag(SERVER_NAME); flag = 1; break; } } } return (flag); } void setFlags(RequestHeaders &request, ConfigClass server) { std::string fileExtension; std::string uri = request.get_uri(); std::string locationRoot; std::string location; std::pair<std::string, std::string> root; std::vector<LocationClass*>::iterator allowIter; bool flag = 0; size_t result; size_t locationNumber = 0; size_t locationSize = 0; fileExtension = extensionDetect(uri); for (std::vector<LocationClass*>::iterator it = server.getLocations()->begin(); it != server.getLocations()->end(); ++it) { locationRoot = (*it)->getRoot(); location = (*it)->getLocation(); if (fileExtension != "none" && location == fileExtension) { request.setResponseFlag(CGI_FLAG); request.setCGILocation(locationNumber); } else if ((request.get_uri().find(location) == 0 || request.get_uri() == location) \ && ((flag == 1 && location.size() > locationSize) || flag == 0)) { locationSize = location.size(); request.setLocation(locationNumber); allowIter = it; flag = 1; } locationNumber++; } if (flag == 1) { if ((*allowIter)->getRoot() != "") { request.setResponseFlag(ROOT_EXISTS); uri.replace(0, (*allowIter)->getLocation().size(), (*allowIter)->getRoot()); if (uri.find("./") != std::string::npos) { uri = server.getRoot() + "/" + uri; } else { uri = locationRoot + "/" + uri; } if ((result = uri.find("./")) != std::string::npos || locationRoot == "./") uri.replace(result, 2, "/"); } else { uri = server.getRoot() + request.get_uri(); } if (uri != request.get_uri()) { if ((result = uri.find("?")) != std::string::npos) { uri.erase(result, uri.length() - 1); } if ((result = uri.find(".map")) != std::string::npos) { uri.erase(result, uri.length() - 1); } if ((result = uri.find("//")) != std::string::npos) uri.replace(result, 2,std::string("/")); request.setUri(uri); } if ((*allowIter)->getListing() != -1) { request.setResponseFlag(LISTING); if ((*allowIter)->getListing() == 1) { request.setResponseFlag(LISTING_RESULT_YES); } } if ((*allowIter)->getMethods()->size() > 0) request.setResponseFlag(ALLOW_METHODS); if ((*allowIter)->getClientBodySize() > 0) request.setResponseFlag(CLIENT_BODY_SIZE_EXIST); if ((*allowIter)->getIndex() != "") request.setResponseFlag(INDEX); if ((*allowIter)->getRedirection() != "") request.setResponseFlag(REDIRECTION); if ((*allowIter)->getErrorPages().size() > 0) { request.setResponseFlag(CUSTOM_ERRORS); } } else { request.setLocation(-1); if (server.getClientBodySize() > 0) request.setResponseFlag(CLIENT_BODY_SIZE_EXIST); if ((*allowIter)->getErrorPages().size() > 0) { request.setResponseFlag(CUSTOM_ERRORS); } } } static bool checkAllow(RequestHeaders &request, std::string method, ConfigClass server) { size_t locationNumber; if ((request.getResponseFlags() & ALLOW_METHODS) == ALLOW_METHODS) { locationNumber = request.getLocation(); // Создаю объект локации из той, что получил при парсе флагов LocationClass *location((*server.getLocations())[locationNumber]); // Создаю вектор доступных методов из полученного location std::vector<std::string> allow((*location->getMethods())); if (allow.size() > 0 && (std::find(allow.begin(), allow.end(), method) == allow.end())) { return (0); } } return (1); } static bool chUriDir(RequestHeaders &request, ConfigClass server, std::string GetRoot) { std::string root; std::string locationRoot; size_t locationNumber; size_t result; if ((request.getResponseFlags() & ROOT_EXISTS) == ROOT_EXISTS) { locationNumber = request.getLocation(); // Создаю объект локации из той, что получил при парсе флагов LocationClass *location((*server.getLocations())[locationNumber]); locationRoot = location->getRoot(); if (locationRoot.find("./") == 0 || locationRoot == "./") { locationRoot.replace(0, 2, "/"); root = server.getRoot() + "/" + locationRoot; if ((result = root.find("//")) != std::string::npos) root.replace(result, 2,"/"); } else { root = location->getRoot(); } if (chdir(root.c_str()) == -1) return (0); } else { if (chdir(GetRoot.c_str()) == -1) return (0); } return (1); } static bool checkRedirect(RequestHeaders &request) { if ((request.getResponseFlags() & REDIRECTION) == REDIRECTION) { return (0); } return (1); } void *generateAnswer(RequestHeaders &request, std::vector<ConfigClass*> config, ConnectionClass &connection) { std::string root; std::string method; std::string index; void *ret; if (!checkServer(request, config, connection)) return (returnError(request, 400, "Bad Request", connection)); method = request.get_method(); root = connection.getServer().getRoot(); if (method != "GET" && method != "POST" && method != "DELETE") return (noSuchMethod(request, connection)); setFlags(request, connection.getServer()); if (!checkAllow(request, method, connection.getServer())) return (methodNotAllowed(request, connection)); if (!checkRedirect(request)) return (returnError(request, 308, "Permanent Redirect", connection)); if (!chUriDir(request, connection.getServer(), root)) return (returnError(request, 404, "Not Found", connection)); if (method == "GET") { ret = GET(request, connection.getServer(), connection); } else if (method == "POST") { ret = POST(request, connection.getServer(), connection); } else { ret = DELETE(request, connection); } return (ret); }
c0e96cecf747f4c14ccbc6f163328a3a2314c0ff
49045130a658ed0fa67771817a0d160201e472fb
/Beautiful/YY/login/login.cpp
079b6a543c3f3de4a7840089d6ef86eb82009a73
[ "MIT" ]
permissive
martinkro/tutorial-qt
5108fedd409100260e93c8544c3aeac9b07770c6
8685434520c6ab61691722aa06ca075f8ddbeacf
refs/heads/master
2021-01-21T09:38:20.795623
2018-01-25T07:46:36
2018-01-25T07:46:36
91,661,126
3
0
null
null
null
null
GB18030
C++
false
false
10,691
cpp
login.cpp
/**************************************************************************** ** ** Copyright (C) 2013 HaiHan. ** All rights reserved. ** Contact: yanhubin@163.com ** Please keep the author contact information. ** 2013-10-30 ** ****************************************************************************/ #include "login.h" #include "ui_login.h" #include <QDebug> Login::Login(QWidget *parent) : QDialog(parent), ui(new Ui::Login) { ui->setupUi(this); init(); //初始化函数 } Login::~Login() { if (!loginkeyboard->isHidden()) //先把键盘隐藏,防止主窗口关闭比软键盘隐藏并释放掉 loginkeyboard->hide(); loginkeyboard->deleteLater(); //由于我们并没有指定软键盘的父类,在这里我们手动del delete ui; } void Login::init() { setWindowFlags(Qt::FramelessWindowHint); //隐去窗口边框 setAttribute(Qt::WA_TranslucentBackground, true); //设置窗口背景透明 ui->id->lineEdit()->setPlaceholderText(QString("HH号码/手机/邮箱")); ui->keyboard->installEventFilter(this); //注册监视对象keyboard到事件过滤器 loginkeyboard = new softkeyboard();//new一个软键盘 connect(loginkeyboard, SIGNAL(input(QString)), this, SLOT(softkeyboardinput(QString))); //连接软键盘输入到密码输入框 loginkeyboard->hide(); //先隐藏软键盘 hHnet=new HHnet(this); m_VerifyImgFrame = new VerifyImgFrame(ui->widget); connect(hHnet,SIGNAL(checkVerifycodeFinished(bool,QString)),this,SLOT(checkVerifycodeFinished(bool,QString))); connect(hHnet,SIGNAL(getVerifyImgFinished(QByteArray)),m_VerifyImgFrame,SLOT(getVerifyImgFinished(QByteArray))); connect(m_VerifyImgFrame, SIGNAL(verifyEditFinished(bool,QString)), this, SLOT(verifyCodeEditFinished(bool,QString))); connect(m_VerifyImgFrame, SIGNAL(clickOk()),this, SLOT(clickOk())); connect(hHnet,SIGNAL(loginFinished(bool,QString)),this,SLOT(loginFinished(bool,QString))); connect(hHnet,SIGNAL(loginErrorInf(int,QString)), this, SLOT(loginErrorInf(int,QString))); return; } void Login::changeEvent(QEvent *event) { if(event->type() == QEvent::WindowStateChange) //窗口状态改变时更新窗口 { repaint(); //刷新页面,否则窗口还原后最小化按钮为press状态 } } void Login::mousePressEvent(QMouseEvent *event) //鼠标单击事件 { if (event->button() == Qt::LeftButton) //判断按下的是否为左键 { m_ddragPos = event->globalPos() - frameGeometry().topLeft(); //记录按下的位置 event->accept(); //事件接受 } if (!loginkeyboard->isHidden()) { //判断软键盘是否被隐藏 loginkeyboard->hide(); //隐藏软键盘 ui->keyboard->setChecked(false); //设置软键盘按钮checked状态为false } } void Login::mouseMoveEvent(QMouseEvent *event) //鼠标移动事件 { if (event->buttons() & Qt::LeftButton) //判断按下的是否为左键 { move(event->globalPos() - m_ddragPos); //移动到当前位置 event->accept(); //事件接受 } } bool Login::eventFilter(QObject *obj, QEvent *event) //监视软键盘按钮,当它hover时使得pwd的lineEdit也具有hover效果 { if (obj == ui->keyboard) { if (event->type() == QEvent::HoverEnter) { ui->pwd->setStyleSheet(QString("border:2px solid gray;\ border-top-color: qlineargradient(spread:pad, x1:0.534, y1:1, x2:0.545, y2:0, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-right-color: qlineargradient(spread:pad, x1:0, y1:0.506, x2:1, y2:0.511364, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-bottom-color: qlineargradient(spread:pad, x1:0.517, y1:0, x2:0.5, y2:1, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-left-color: qlineargradient(spread:pad, x1:1, y1:0.579545, x2:0, y2:0.574, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ padding-left:3px;\ padding-right:25px;\ ")); } if (event->type() == QEvent::HoverLeave) { ui->pwd->setStyleSheet(QString("QLineEdit#pwd::hover{border:2px solid gray;\ border-top-color: qlineargradient(spread:pad, x1:0.534, y1:1, x2:0.545, y2:0, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-right-color: qlineargradient(spread:pad, x1:0, y1:0.506, x2:1, y2:0.511364, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-bottom-color: qlineargradient(spread:pad, x1:0.517, y1:0, x2:0.5, y2:1, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-left-color: qlineargradient(spread:pad, x1:1, y1:0.579545, x2:0, y2:0.574, stop:0 rgba(36, 132, 238, 255), stop:0.982955 rgba(143, 192, 255, 0));}\ QLineEdit#pwd{border-radius: 1px;border:2px solid gray;\ border-top-color: qlineargradient(spread:pad, x1:0.471273, y1:0.71, x2:0.483, y2:0, stop:0 rgba(191, 191, 191, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-right-color: qlineargradient(spread:pad, x1:0.301, y1:0.510682, x2:1, y2:0.522, stop:0 rgba(191, 191, 191, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-bottom-color: qlineargradient(spread:pad, x1:0.523, y1:0.294455, x2:0.528, y2:1, stop:0 rgba(191, 191, 191, 255), stop:0.982955 rgba(143, 192, 255, 0));\ border-left-color: qlineargradient(spread:pad, x1:0.682091, y1:0.544, x2:0, y2:0.557, stop:0 rgba(191, 191, 191, 255), stop:0.982955 rgba(143, 192, 255, 0));\ padding-left:3px;padding-right: 25px;font: 9pt 'Meiryo';} ")); return true; } } return QDialog::eventFilter(obj, event); } void Login::on_keyboard_clicked(bool checked) { if (checked) { //是否被按下 loginkeyboard->move(frameGeometry().topLeft().x() + ui->keyboard->x() - loginkeyboard->width()/2 - 7, frameGeometry().topLeft().y() + 209); //移动到指定位置 loginkeyboard->show(); //显示软键盘 } else { loginkeyboard->hide(); //隐藏软键盘 } return; } void Login::softkeyboardinput(QString str) { if (str == QString("del")) { ui->pwd->setText(ui->pwd->text().left(ui->pwd->text().length() - 1)); //去掉最后一个字符 return; } ui->pwd->setText(ui->pwd->text()+str); //统一处理输入内容 return; } void Login::on_button_login_clicked() { #ifdef _HH_DEBUG_ accept(); return; #endif ui->id->hide(); ui->pwd->hide(); ui->auto_login->hide(); ui->rem_pwd->hide(); ui->mima->hide(); ui->zhuce->hide(); ui->switch_single->hide(); ui->corner_right->hide(); ui->keyboard->hide(); movie = new QMovie("./images/gif/loading.gif"); loading = new QLabel(ui->frame_4); loading->show(); loading->setFixedSize(378, 2); loading->move(0, ui->frame_4->height()-2); loading->setMovie(movie); movie->start(); QPropertyAnimation *animation = new QPropertyAnimation(ui->login_head, "pos"); animation->setDuration(200); animation->setStartValue(QPoint(ui->login_head->x(), ui->login_head->y())); animation->setEndValue(QPoint(148, ui->login_head->y())); animation->start(); hHnet->checkVerifyCode(ui->id->currentText().trimmed()); } void Login::on_switch_single_clicked(bool checked) { } void Login::checkVerifycodeFinished(bool getCode, QString code){ qDebug()<<getCode<<code<<endl; if(getCode){ verifyCode = code; hHnet->login(ui->id->currentText().trimmed(),ui->pwd->text().trimmed(), verifyCode); } else{ ui->frame_4->hide(); ui->frame_3->hide(); m_VerifyImgFrame->move(0, ui->widget->height()-m_VerifyImgFrame->height()); m_VerifyImgFrame->m_SetCurrentIndex(0); m_VerifyImgFrame->show(); hHnet->getVerifyImg(ui->id->currentText().trimmed()); } } void Login::verifyCodeEditFinished(bool getVerify, QString verify){ m_VerifyImgFrame->hide(); ui->frame_3->show(); ui->frame_4->show(); if (getVerify) { verifyCode = verify; } hHnet->login(ui->id->currentText().trimmed(),ui->pwd->text().trimmed(), verifyCode); } void Login::loginFinished(bool loginok, QString message){ qDebug()<<loginok<<message<<endl; if(loginok){ emit loginMainWidget(hHnet->nickname); accept(); }else{ ui->id->show(); ui->pwd->show(); ui->auto_login->show(); ui->rem_pwd->show(); ui->mima->show(); ui->zhuce->show(); ui->switch_single->show(); ui->corner_right->show(); ui->keyboard->show(); ui->login_head->move(20, 43); movie->deleteLater(); loading->deleteLater(); } } void Login::loginErrorInf(int id, QString message) { switch(id) { case 3: ui->frame_4->hide(); ui->frame_3->hide(); m_VerifyImgFrame->move(0, ui->widget->height()-m_VerifyImgFrame->height()); m_VerifyImgFrame->m_SetCurrentIndex(1); m_VerifyImgFrame->show(); break; case 4: ui->frame_4->hide(); ui->frame_3->hide(); m_VerifyImgFrame->move(0, ui->widget->height()-m_VerifyImgFrame->height()); m_VerifyImgFrame->m_SetCurrentIndex(0); m_VerifyImgFrame->show(); hHnet->getVerifyImg(ui->id->currentText().trimmed()); } return; } void Login::clickOk() { m_VerifyImgFrame->hide(); ui->frame_3->show(); ui->frame_4->show(); ui->id->show(); ui->pwd->show(); ui->auto_login->show(); ui->rem_pwd->show(); ui->mima->show(); ui->zhuce->show(); ui->switch_single->show(); ui->corner_right->show(); ui->keyboard->show(); ui->login_head->move(20, 43); movie->deleteLater(); loading->deleteLater(); ui->pwd->clear(); ui->pwd->setFocus(); return; }
ec8e61457682ca2e3c3732908d1055a6cc79236d
65e3391b6afbef10ec9429ca4b43a26b5cf480af
/TEvtGen/EvtGen/EvtGenModels/EvtSVVCP.cpp
6d2ebf787fa4a39ad4cf018da6eeefb0494f6f19
[]
permissive
alisw/AliRoot
c0976f7105ae1e3d107dfe93578f819473b2b83f
d3f86386afbaac9f8b8658da6710eed2bdee977f
refs/heads/master
2023-08-03T11:15:54.211198
2023-07-28T12:39:57
2023-07-28T12:39:57
53,312,169
61
299
BSD-3-Clause
2023-07-28T13:19:50
2016-03-07T09:20:12
C++
UTF-8
C++
false
false
3,652
cpp
EvtSVVCP.cpp
//-------------------------------------------------------------------------- // // Environment: // This software is part of the EvtGen package developed jointly // for the BaBar and CLEO collaborations. If you use all or part // of it, please give an appropriate acknowledgement. // // Copyright Information: See EvtGen/COPYRIGHT // Copyright (C) 1998 Caltech, UCSB // // Module: EvtSVVCP.cc // // Description: The decay of a scalar to two vector particles are // performed with CP violation. E.g. B->J/psi K*. // // Modification history: // // RYD January 19, 1997 Module created // //------------------------------------------------------------------------ // #include "EvtGenBase/EvtPatches.hh" #include <stdlib.h> #include "EvtGenBase/EvtParticle.hh" #include "EvtGenBase/EvtGenKine.hh" #include "EvtGenBase/EvtCPUtil.hh" #include "EvtGenBase/EvtPDL.hh" #include "EvtGenModels/EvtSVVHelAmp.hh" #include "EvtGenBase/EvtReport.hh" #include "EvtGenModels/EvtSVVCP.hh" #include "EvtGenBase/EvtId.hh" #include <string> #include "EvtGenBase/EvtConst.hh" EvtSVVCP::~EvtSVVCP() {} std::string EvtSVVCP::getName(){ return "SVV_CP"; } EvtDecayBase* EvtSVVCP::clone(){ return new EvtSVVCP; } void EvtSVVCP::init(){ // check that there are 9 arguments checkNArg(9); checkNDaug(2); checkSpinParent(EvtSpinType::SCALAR); checkSpinDaughter(0,EvtSpinType::VECTOR); checkSpinDaughter(1,EvtSpinType::VECTOR); } void EvtSVVCP::initProbMax(){ //This is probably not quite right, but it should do as a start... //Anders setProbMax(2*(getArg(3)*getArg(3)+getArg(5)*getArg(5)+getArg(7)*getArg(7))); } void EvtSVVCP::decay( EvtParticle *p){ //added by Lange Jan4,2000 static EvtId B0=EvtPDL::getId("B0"); static EvtId B0B=EvtPDL::getId("anti-B0"); double t; EvtId other_b; EvtCPUtil::getInstance()->OtherB(p,t,other_b,0.5); EvtComplex G0P,G1P,G1M; G1P=EvtComplex(getArg(3)*cos(getArg(4)),getArg(3)*sin(getArg(4))); G0P=EvtComplex(getArg(5)*cos(getArg(6)),getArg(5)*sin(getArg(6))); G1M=EvtComplex(getArg(7)*cos(getArg(8)),getArg(7)*sin(getArg(8))); EvtComplex lambda_km=EvtComplex(cos(-2*getArg(0)),sin(-2*getArg(0))); double cdmt=cos(getArg(1)*t/(2*EvtConst::c)); double sdmt=sin(getArg(1)*t/(2*EvtConst::c)); EvtComplex cG0P,cG1P,cG1M; if (other_b==B0B){ cG0P=G0P*(cdmt+lambda_km*EvtComplex(0.0,getArg(2)*sdmt)); cG1P=G1P*(cdmt+lambda_km*EvtComplex(0.0,getArg(2)*sdmt)); cG1M=G1M*(cdmt-lambda_km*EvtComplex(0.0,getArg(2)*sdmt)); } if (other_b==B0){ cG0P=G0P*(cdmt+(1.0/lambda_km)*EvtComplex(0.0,getArg(2)*sdmt)); cG1P=G1P*(cdmt+(1.0/lambda_km)*EvtComplex(0.0,getArg(2)*sdmt)); cG1M=-G1M*(cdmt-(1.0/lambda_km)*EvtComplex(0.0,getArg(2)*sdmt)); } EvtComplex A0,AP,AM; A0=cG0P/sqrt(2.0); AP=(cG1P+cG1M)/sqrt(2.0); AM=(cG1P-cG1M)/sqrt(2.0); EvtSVVHelAmp::SVVHel(p,_amp2,getDaug(0),getDaug(1),AP,A0,AM); return ; } std::string EvtSVVCP::getParamName(int i) { switch(i) { case 0: return "weakPhase"; case 1: return "deltaM"; case 2: return "eta"; case 3: return "G1Plus"; case 4: return "G1PlusPhase"; case 5: return "G0Plus"; case 6: return "G0PlusPhase"; case 7: return "G1Minus"; case 8: return "G1MinusPhase"; default: return ""; } } std::string EvtSVVCP::getParamDefault(int i) { switch(i) { case 3: return "1.0"; case 4: return "0.0"; case 5: return "1.0"; case 6: return "0.0"; case 7: return "1.0"; case 8: return "0.0"; default: return ""; } }
f84c75c1a6d0d287d01c500429cdb51971d17997
e9ee7be9bbddab7231461b09c6de7c4ccae7da60
/pch.cpp
725c9a5f13924434087862940d4953c22ed835aa
[]
no_license
HungryAnteater/file_tools
c87fac7b3a39582558a33b4e737a4fa28b435c6a
bc0266237d18fc245f22486c9eb9182454d08614
refs/heads/master
2021-04-24T01:11:34.349732
2020-03-29T06:45:48
2020-03-29T06:45:48
250,051,120
0
0
null
null
null
null
UTF-8
C++
false
false
247
cpp
pch.cpp
//----------------------------------------------------------------------------- // Copyright (C) Doppelgamer LLC, 2020 // All rights reserved. //----------------------------------------------------------------------------- #include "pch.h"
8a16d29b25ebf0df725092636b43423f466b3d11
2ae0b8d95d439ccfd55ea7933ad4a2994ad0f6c5
/src/core/shape_inference/include/assign_shape_inference.hpp
307e71b87743535107a68c4f7dc221a55e26af5d
[ "Apache-2.0" ]
permissive
openvinotoolkit/openvino
38ea745a247887a4e14580dbc9fc68005e2149f9
e4bed7a31c9f00d8afbfcabee3f64f55496ae56a
refs/heads/master
2023-08-18T03:47:44.572979
2023-08-17T21:24:59
2023-08-17T21:24:59
153,097,643
3,953
1,492
Apache-2.0
2023-09-14T21:42:24
2018-10-15T10:54:40
C++
UTF-8
C++
false
false
1,322
hpp
assign_shape_inference.hpp
// Copyright (C) 2018-2023 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // #pragma once #include <openvino/core/graph_util.hpp> #include <openvino/op/assign.hpp> #include "copy_shape_inference.hpp" #include "utils.hpp" namespace ov { namespace op { namespace v3 { template <class TShape, class TRShape = result_shape_t<TShape>> std::vector<TRShape> shape_infer(const Assign* op, const std::vector<TShape>& input_shapes) { auto output_shapes = ov::op::copy_shape_infer(op, input_shapes); const auto& input_shape = input_shapes[0]; const auto& variable_info = op->get_variable()->get_info(); NODE_VALIDATION_CHECK(op, op->get_variable_id() == variable_info.variable_id, "Variables identifiers are inconsistent."); const auto& arg_t = op->get_input_element_type(0); NODE_VALIDATION_CHECK(op, arg_t == variable_info.data_type, "Variables types are inconsistent."); if (input_shape.is_static() && variable_info.data_shape.is_static()) { NODE_VALIDATION_CHECK(op, input_shape.to_shape() == variable_info.data_shape.to_shape(), "Variables output shapes are inconsistent."); } return output_shapes; } } // namespace v3 } // namespace op } // namespace ov
9b14795f66395ab5a53f4534a34214256e1e4df3
0a3da5a64d396e3a2f27bfdbe75feea759b579ef
/focus_controller_ws/src/focus_control/src/old_files/path_planner.cpp
e81a685bd13f64808d228c2121bb7753962d4505
[ "BSD-2-Clause" ]
permissive
gurumurthy0308/EVAutomation
8cc3eb8be2598e74f95532080874d4c2b574976a
a9e27e8916fd6dfc060dac1496a3b2f327ef6322
refs/heads/master
2020-09-03T09:47:04.425368
2017-03-03T01:46:08
2017-03-03T01:46:08
null
0
0
null
null
null
null
UTF-8
C++
false
false
6,831
cpp
path_planner.cpp
#include "ros/ros.h" #include "nav_msgs/Odometry.h" #include "std_msgs/Bool.h" #include <sstream> #include <fstream> //GLOBAL VARIABLES //GLOBAL VARIABLES float desired_speed = 0; float current_speed = 0; float desired_heading = 0; float desired_anglep2p = 0; float current_heading = 0; float current_angle = 0; float current_app = 0; float current_throttle = 0; float desired_angle = 0; float torque_value = 0; float turn_rate = 0; float serial_app = 0; float serial_bpp = 0; float serial_torque = 0; float previous_speed_error = 0; float previous_steer_error = 0; float previous_speed_pidout = 0; float previous_steer_pidout = 0; //float Ts = 0.02; //Loop rate float Ts = 0.1; //PID loop rate float integrator = 0; float error_d1 = 0; ros::Time begin; bool time_started = false; float start_time = 0; bool gps_data_received = false; bool target_data_received = false; float psidiff = 0; std::ofstream outFile_car; std::ofstream outFile_gps; std::ifstream inFile_gps; const int I_ACCUM_SIZE = 100; std::vector<float> i_accum_speed(I_ACCUM_SIZE,0); std::vector<float> i_accum_steer(I_ACCUM_SIZE,0); int i_accum_iter_speed = 0; int i_accum_iter_steer = 0; const double pi = 3.141592653589793; bool go = false; float t = 0; float x = 0; //GPS position values float y = 0; float z = 0; float qx = 0; //GPS quarternion values float qy = 0; float qz = 0; float qw = 0; float vx = 0; //GPS linear velocity values float vy = 0; float vz = 0; float ang_vx = 0; //GPS angular velocity values float ang_vy = 0; float ang_vz = 0; double pos_covariance [36] = {}; //GPS position covariance matrix double twist_covariance [36] = {}; //GPS twist covariance matrix float tar_x = 0; float tar_y = 0; float tar_vx = 0; float tar_vy = 0; //Function prototypes void gpsCallback(const nav_msgs::Odometry); float sat2(float in, float max, float min); void pathController(); float pi2pi(float); //Saturation function for +/- limit value float sat(float in, float limit){ if(in > limit) return limit; else if(in < -limit) return -limit; else return in; } //Callback for GPS data, store in global variables to be used in controllers void gpsCallback(const nav_msgs::Odometry msg){ //std::cout << "In gpsCallback" << std::endl; if(!time_started){ //start_time = t; start_time = msg.header.stamp.sec + msg.header.stamp.nsec * pow(10,-9); time_started = 1; } //Time difference from start of GPS node t = (msg.header.stamp.sec + msg.header.stamp.nsec * pow(10,-9)) - start_time; //GPS position (x,y,z) x = (float) msg.pose.pose.position.x; y = (float) msg.pose.pose.position.y; z = (float) msg.pose.pose.position.z; //GPS quaternion (x,y,z,w) qx = (float) msg.pose.pose.orientation.x; qy = (float) msg.pose.pose.orientation.y; qz = (float) msg.pose.pose.orientation.z; qw = (float) msg.pose.pose.orientation.w; //GPS linear velocity (x,y,z) vx = (float) msg.twist.twist.linear.x; vy = (float) msg.twist.twist.linear.y; vz = (float) msg.twist.twist.linear.z; //GPS angular velocity (x,y,z) ang_vx = (float) msg.twist.twist.angular.x; ang_vy = (float) msg.twist.twist.angular.y; ang_vz = (float) msg.twist.twist.angular.z; //GPS covariance matrices //pos_covariance = msg.pose.covariance; //twist_covariance = msg.twist.covariance; //Calculate heading current_heading = atan2(vy,vx); gps_data_received = true; } //Callback for virtual target void targetCallback(const nav_msgs::Odometry msg){ tar_x = msg.pose.pose.position.x; tar_y = msg.pose.pose.position.y; tar_vx = msg.twist.twist.linear.x; tar_vy = msg.twist.twist.linear.y; target_data_received = true; } //User input Callback void usrCallback(const std_msgs::Bool in){ if(in.data == true) go = true; } int main(int argc, char **argv){ float Ts = 0.1; //10 Hz ros::init(argc, argv, "path_planner"); ros::NodeHandle n; begin = ros::Time::now(); ros::Subscriber sub_gps = n.subscribe("/gps/rtkfix", 1000, gpsCallback); ros::Subscriber sub_target_gps = n.subscribe("target_gps_data", 1000, targetCallback); ros::Rate loop_rate(1/Ts); while (ros::ok()){ if(go) pathController(); else{ std::cout << "Waiting for Go" << std::endl; } ros::spinOnce(); loop_rate.sleep(); } ros::spin(); return 0; } float pi2pi(float in){ float out = in; if(in < -pi) out = in + 2*pi; else if(in > pi) out = in - 2*pi; return out; } void pathController(){ float pn = y; float pe = x; float pnt = 0; float pet = 0; float vxt = 0; float vyt = 0; float in_array [7] = {}; int pos = 0; float u1 = 0; float u2 = 0; //float k1 = 0.0316; // Q1 R1000 float k2 = 0; float k3 = 0; //float k1 = 0.1; // Q1 R100 //float k4 = 0.1; // Q1 R100 //float k1 = 0.1414; // Q1 R50 //float k4 = 0.1414; // Q1 R50 //float k1 = 0.1118; // Q1 R80 //float k4 = 0.1118; // Q1 R80 //float k1 = 0.0913; // Q1 R120 //float k4 = 0.0913; // Q1 R120 //float k1 = 0.0707; // Q1 R200 //float k4 = 0.0707; // Q1 R200 //float k1 = 0.0816; // Q1 R150 //float k4 = 0.0816; // Q1 R150 //float k4 = 0.0316; // Q1 R1000 //float k1 = 0.0845; //Q1 R140 //float k4 = 0.0845; //Q1 R140 //float k1 = 0.0877; //Q1 R130 //float k4 = 0.0877; //Q1 R130 //float k1 = 0.0791; //Q1 R160 //float k4 = 0.0791; //Q1 R160 //float k1 = 0.0767; //Q1 R170 //float k4 = 0.0767; //Q1 R170 //float k1 = 0.0674; //Q1 R220 //float k4 = 0.0674; //Q1 R220 float k1 = 0.069; //Q1 R210 float k4 = 0.069; //Q1 R210 float vc = 0; float psic = 0; float psi = 0; float psidot = 0; float psidotp2p = 0; //float max_error = 0.5236; //float steering_angle_limit = 1000; //float kp = steering_angle_limit/max_error; float kp = 6250; /* std::string input; std::string delimiter = ","; std::string token; getline(inFile_gps,input); std::cout << input << std::endl; char* newtoken = new char[input.length()+1]; for(int i = 0; i < 7; i++){ pos = input.find(delimiter); token = input.substr(0,pos); std::strcpy(newtoken,token.c_str()); in_array[i] = atof(newtoken); input.erase(0,pos+delimiter.length()); } pet = in_array[1]; pnt = in_array[2]; vxt = in_array[4]; vyt = in_array[5]; */ pet = tar_x; pnt = tar_y; vxt = tar_vx; vyt = tar_vy; psi = atan2(vy,vx); //u1 = vxt - k2*(pe - pet) - k1*(pn - pnt); //u2 = vyt - k4*(pe - pet) - k3*(pn - pnt); u1 = vyt - k1*(pn-pnt) - k2*(pe-pet); u2 = vxt - k3*(pn-pnt) - k4*(pe-pet); vc = 2.23694*sqrt(pow(u1,2) + pow(u2,2)); psic = atan2(u1,u2); psidot = -1*kp*pi2pi(psic - psi); psidiff = pi2pi(psic - psi); psidot = sat(psidot,5000); vc = sat2(vc,20,0); desired_angle = psidot; desired_speed = vc; desired_heading = psic; } //Saturation function for max,min limit value float sat2(float in, float max, float min){ if(in > max) return max; else if(in < min) return min; else return in; }
4be5e1cf72b0a6a08e4435b2c3dd7a98b52bb7e0
f6c0270b00ae78607c91a1b393510144f0f595b3
/TestAppMK66F+KSZ8794/main.cpp
41203d890e9f9fc2796e1615c3e32fd3f13b566c
[ "Apache-2.0" ]
permissive
yacoub-automation/mstp-lib
3d9bea7d93308aa9e7a80b427a8a7ccb6d4a1ab5
57089f9b7826a65fdd8d391a31d0598476c3488c
refs/heads/master
2023-04-26T05:28:04.951248
2021-05-04T08:30:24
2021-05-04T08:30:24
null
0
0
null
null
null
null
UTF-8
C++
false
false
15,871
cpp
main.cpp
#include "drivers/clock.h" #include "drivers/gpio.h" #include "drivers/pit.h" #include "drivers/ethernet.h" #include "drivers/event_queue.h" #include "drivers/scheduler.h" #include "drivers/serial_console.h" #include "switch.h" #include "stp.h" #include <CMSIS/MK66F18.h> #include <debugio.h> #include <assert.h> #include <string.h> #include <stdio.h> extern "C" void __assert(const char *__expression, const char *__filename, int __line) { if (debug_enabled()) debug_printf("Assertion failure.\n"); __BKPT(); } extern "C" void SystemInit() { // Disable the watchdog WDOG->UNLOCK = 0xC520; WDOG->UNLOCK = 0xD928; WDOG->STCTRLH = 0x1D2; MPU_CESR = 0; // Disable MPU. All accesses from all bus masters are allowed. The Ethernet peripheral needs this. SMC->PMPROT = 0xAA; // allow entering all power modes // Enable HSRUN mode SMC->PMCTRL = 0x60; while (SMC->PMSTAT != 0x80) ; } // ============================================================================ static const uint8_t bpdu_dest_address[6] = { 0x01, 0x80, 0xC2, 0, 0, 0 }; static const uint8_t bpdu_llc_field[3] = { 0x42, 0x42, 0x03 }; static const size_t stp_port_count = 3; static void print_port_info (size_t port_index, STP_PORT_ROLE role, bool learning, bool forwarding) { assert (debug_enabled()); const char* role_string = STP_GetPortRoleString(role); const char* state = (!learning && !forwarding) ? "Blocking" : (forwarding ? "Forwarding" : "Learning"); debug_printf("Port %d: %s & %s\n", port_index + 1, role_string, state); } static void StpCallback_EnableBpduTrapping (const STP_BRIDGE* bridge, bool enable, unsigned int timestamp) { uint8_t val; if (enable) { // Write 8 bytes containing an entry in the static MAC address table. switch_write_reg (113, 0); // bits 63..56 = 0 (filter by MAC, not by FID) switch_write_reg (114, 0b01110000); // bits 55..48 (override, valid, forward to port 4) switch_write_reg (115, bpdu_dest_address[0]); // bits 47..40 switch_write_reg (116, bpdu_dest_address[1]); // bits 39..32 switch_write_reg (117, bpdu_dest_address[2]); // bits 31..24 switch_write_reg (118, bpdu_dest_address[3]); // bits 23..16 switch_write_reg (119, bpdu_dest_address[4]); // bits 15..8 switch_write_reg (120, bpdu_dest_address[5]); // bits 7..0 // Write reg 110 to say that next operation is a write to the static MAC address table. switch_write_reg (110, 0); // Write the index into the table; writing initiates the operation. switch_write_reg (111, 0); // Enable tail tagging. val = switch_read_reg (12); switch_write_reg (12, val | (1u << 1)); } else { // Disable tail tagging. val = switch_read_reg (12); switch_write_reg (12, val & ~(1u << 1)); switch_write_reg (114, 0); // bits 55..48 (entry not valid) switch_write_reg (110, 0); switch_write_reg (111, 0); } // We've just changed tail tagging mode. The switch IC offers no way to tell between tagged and // non-tagged frames, so if there's traffic going on right now on the RMII port of the switch, // our software may send or receive frames with one byte missing or one byte added. Let's ignore // this problem in this demo app. } static void StpCallback_EnableLearning (const STP_BRIDGE* bridge, unsigned int portIndex, unsigned int treeIndex, bool enable, unsigned int timestamp) { uint16_t reg = 0x12 + (portIndex << 4); auto val = switch_read_reg (reg); if (enable) { if (val & 1) switch_write_reg (reg, val & 0xFE); } else { if ((val & 1) == 0) switch_write_reg (reg, val | 1); } if (debug_enabled()) { auto role = STP_GetPortRole(bridge, portIndex, treeIndex); bool learning = enable; bool forwarding = STP_GetPortForwarding(bridge, portIndex, treeIndex); print_port_info (portIndex, role, learning, forwarding); } } static void StpCallback_EnableForwarding (const STP_BRIDGE* bridge, unsigned int portIndex, unsigned int treeIndex, bool enable, unsigned int timestamp) { uint16_t reg = 0x12 + (portIndex << 4); auto val = switch_read_reg (reg); if (enable) { if ((val & 0b110) != 0b110) switch_write_reg (reg, val | 0b110); } else { if (val & 0b110) switch_write_reg (reg, val & ~0b110); } if (debug_enabled()) { auto role = STP_GetPortRole(bridge, portIndex, treeIndex); bool learning = STP_GetPortLearning(bridge, portIndex, treeIndex); bool forwarding = enable; print_port_info (portIndex, role, learning, forwarding); } } static void* StpCallback_TransmitGetBuffer (const STP_BRIDGE* bridge, unsigned int portIndex, unsigned int bpduSize, unsigned int timestamp) { // 6 bytes for DA // 6 bytes for SA // 2 bytes for EtherType Or Size // 3 bytes for LLC // then the BPDU content // 1 byte for the Microchip tail tag size_t frame_size = 6 + 6 + 2 + 3 + bpduSize + 1; // The Ethernet peripheral makes sure to transmit frames at least 64 bytes long, as required by the standard. // Since we ask it to append 4 bytes of CRC, it will extend to 60 bytes all our small frames. // We must take this into account when we append the tail tag, because the tag must be in the byte // just before the CRC in the frame received by the switch IC from our Ethernet peripheral. if (frame_size < 60) frame_size = 60; uint8_t* frame = enet_write_get_buffer(frame_size); if (!frame) return nullptr; memcpy (frame, bpdu_dest_address, 6); memcpy (&frame[6], STP_GetBridgeAddress(bridge)->bytes, 6); bool wrap = (uint32_t) frame[11] + 1 + portIndex >= 256; frame[11] += (1 + portIndex); if (wrap) frame[10]++; uint16_t etherTypeOrSize = sizeof(bpdu_llc_field) + bpduSize; frame[12] = uint8_t (etherTypeOrSize >> 8); frame[13] = uint8_t (etherTypeOrSize & 0xFF); memcpy (&frame[14], bpdu_llc_field, sizeof(bpdu_llc_field)); // Tail-tag field that tells the switch IC which port to send this bpdu out of. // Bit 6 tells the switch to send the frame without searching the DA in its MAC tables. frame[frame_size - 1] = (1 << portIndex) | (1 << 6); return &frame[17]; } static void StpCallback_TransmitReleaseBuffer (const STP_BRIDGE* bridge, void* bufferReturnedByGetBuffer) { uint8_t* data = (uint8_t*)bufferReturnedByGetBuffer - 17; enet_write_release_buffer(data); } static void StpCallback_FlushFdb (const STP_BRIDGE* bridge, unsigned int portIndex, unsigned int treeIndex, enum STP_FLUSH_FDB_TYPE flushType, unsigned int timestamp) { // The KSZ8794 switch doesn't offer a straightforward way of flushing the table // for a given port; see description of Bit 5 in Register 2 in its datasheet. // // Let's implement this callback by forcing learning to 'disabled' for our port, // then flushing the table, then restoring the learning state to whatever it was. // This might flush more ports than necessary, and this in turn might lead // to slightly increased traffic for a short time; we're ok with that in this demo app. // TODO: see what the spec has to say about flushing in TABLE 3-13 section "Disabled State". uint16_t reg = 0x12 + (portIndex << 4); uint8_t val = switch_read_reg(reg); if ((val & 1) == 0) switch_write_reg (reg, val | 1); uint8_t reg2val = switch_read_reg(2); switch_write_reg (2, reg2val | (1 << 5)); if ((val & 1) == 0) switch_write_reg (reg, val); } static void StpCallback_DebugStrOut (const STP_BRIDGE* bridge, int portIndex, int treeIndex, const char* nullTerminatedString, unsigned int stringLength, unsigned int flush) { if (debug_enabled()) debug_printf("%s", nullTerminatedString); } static void StpCallback_OnTopologyChange (const STP_BRIDGE* bridge, unsigned int treeIndex, unsigned int timestamp) { if (debug_enabled()) debug_printf("TC\n"); } static void StpCallback_OnPortRoleChanged (const STP_BRIDGE* bridge, unsigned int portIndex, unsigned int treeIndex, STP_PORT_ROLE role, unsigned int timestamp) { if (debug_enabled()) { bool learning = STP_GetPortLearning(bridge, portIndex, treeIndex); bool forwarding = STP_GetPortForwarding(bridge, portIndex, treeIndex); print_port_info (portIndex, role, learning, forwarding); } } static uint8_t stp_heap[1500]; static size_t stp_heap_used_size = 0; static void* StpCallback_AllocAndZeroMemory (unsigned int size) { assert (stp_heap_used_size + size <= sizeof(stp_heap)); void* res = &stp_heap[stp_heap_used_size]; stp_heap_used_size += size; return res; } static void StpCallback_FreeMemory (void* p) { assert(false); // not implemented } static const STP_CALLBACKS stp_callbacks = { &StpCallback_EnableBpduTrapping, &StpCallback_EnableLearning, &StpCallback_EnableForwarding, &StpCallback_TransmitGetBuffer, &StpCallback_TransmitReleaseBuffer, &StpCallback_FlushFdb, &StpCallback_DebugStrOut, &StpCallback_OnTopologyChange, &StpCallback_OnPortRoleChanged, &StpCallback_AllocAndZeroMemory, &StpCallback_FreeMemory }; static STP_BRIDGE* bridge; // ============================================================================ static void make_mac_address (uint8_t address[6]) { uint64_t v0 = SIM->UIDH; uint64_t v1 = ((uint64_t)SIM->UIDMH << 16) | ((uint64_t)SIM->UIDML >> 16); uint64_t v2 = ((uint64_t)(SIM->UIDML & 0xFFFF) << 32) | SIM->UIDL; uint64_t sum = v0 + v1 + v2; address[0] = (sum >> 40) & 0xFE; address[1] = (sum >> 32); address[2] = (sum >> 24); address[3] = (sum >> 16); address[4] = (sum >> 8); address[5] = sum; } static const ethernet_pins eth_pins = { .rmii_ref_clk = { { PTE, 26 }, 2 }, .rmii_crs_dv = { { PTA, 14 }, 4 }, .rmii_rxd0 = { { PTA, 13 }, 4 }, .rmii_rxd1 = { { PTA, 12 }, 4 }, .rmii_tx_en = { { PTA, 15 }, 4 }, .rmii_txd0 = { { PTA, 16 }, 4 }, .rmii_txd1 = { { PTA, 17 }, 4 }, .rmii_mdio = { }, .rmii_mdc = { }, }; static bool dump_received_packets = true; static void read_port_speed_and_duplex (size_t port_index, uint32_t& speed, bool& duplex) { uint8_t val = switch_read_reg (0x19 + (port_index << 4)); speed = (val & (1u << 2)) ? 100 : 10; duplex = (val & (1u << 1)); } static void process_received_frames() { size_t frame_size; uint8_t* frame; while ((frame = enet_read_get_buffer (&frame_size)) != nullptr) { uint32_t timestamp = scheduler_get_time_ms32(); if (dump_received_packets) { if (debug_enabled()) { gpio_toggle(PTA, 10); /* gpio_set(PTA, 10, false); debug_printf ("%02X%02X%02X%02X%02X%02X %02X%02X%02X%02X%02X%02X %02X%02X ...(%d bytes)\r\n", frame[0], frame[1], frame[2], frame[3], frame[4], frame[5], frame[6], frame[7], frame[8], frame[9], frame[10], frame[11], frame[12], frame[13], frame_size); gpio_set(PTA, 10, true); */ } } size_t port_index = -1; if (STP_IsBridgeStarted(bridge)) { // If STP is started, it means that we have enabled tail tagging in StpCallback_EnableBpduTrapping. // Still, we might be processing a frame received just before we enabled tail tagging, // so let's additionally verify that the tag contains a valid port index; it's not a failsafe check // but that's the best we can manage on these KSZ switches... if (frame[frame_size - 1] < stp_port_count) { port_index = frame[frame_size - 1]; frame_size--; } } if (memcmp (frame, bpdu_dest_address, 6) == 0) { if ((frame_size > 14 + sizeof(bpdu_llc_field)) && (memcmp(&frame[14], bpdu_llc_field, sizeof(bpdu_llc_field)) == 0) && STP_IsBridgeStarted(bridge) && (port_index != -1)) { if (!STP_GetPortEnabled(bridge, port_index)) { uint32_t speed; bool duplex; read_port_speed_and_duplex (port_index, speed, duplex); STP_OnPortEnabled(bridge, port_index, speed, duplex, timestamp); } STP_OnBpduReceived(bridge, port_index, &frame[17], frame_size - 17, timestamp); } } else { // TODO: process non-STP frame } enet_read_release_buffer(frame); } } static void poll_port_state() { uint32_t timestamp = scheduler_get_time_ms32(); for (size_t port_index = 0; port_index < stp_port_count; port_index++) { uint16_t reg = 0x1E + (port_index << 4); uint8_t val = switch_read_reg(reg); bool link_up = val & (1u << 5); if (link_up) { if (!STP_GetPortEnabled(bridge, port_index)) { uint32_t speed; bool duplex; read_port_speed_and_duplex (port_index, speed, duplex); STP_OnPortEnabled (bridge, port_index, speed, duplex, timestamp); } } else { if (STP_GetPortEnabled(bridge, port_index)) STP_OnPortDisabled(bridge, port_index, timestamp); } } } static volatile bool rx_pending = false; static void rx_isr() { rx_pending = true; } static constexpr struct enet_callbacks enet_callbacks = { .rx = rx_isr, .tx = nullptr, .error = nullptr }; static void on_one_second_tick() { uint32_t timestamp = scheduler_get_time_ms32(); STP_OnOneSecondTick (bridge, timestamp); } static void serial_console_output (char ch) { if (debug_enabled()) debug_putchar(ch); } static void serial_console_poll_input() { gpio_set(PTA, 8, false); while (debug_enabled() && debug_kbhit()) { char ch = (char)debug_getch(); serial_console_process_input(ch); } gpio_set(PTA, 8, true); } static void process_stp_command (const char* params) { uint32_t timestamp = scheduler_get_time_ms32(); if (strcmp(params, "on") == 0) { if (STP_IsBridgeStarted(bridge)) printf ("STP already started.\r\n"); else STP_StartBridge(bridge, timestamp); } else if (strcmp(params, "off") == 0) { if (!STP_IsBridgeStarted(bridge)) printf ("STP already stopped.\r\n"); else STP_StopBridge(bridge, timestamp); } else if (*params == 0) { printf ("STP is %s.\r\n", STP_IsBridgeStarted(bridge) ? "started" : "stopped"); } else printf ("Invalid params.\r\n"); } static const serial_command commands[] = { { "stp", "stp [on|off]", process_stp_command }, { nullptr, nullptr, nullptr } }; // ============================================================================ int main() { clock_init (12); static uint8_t event_queue_buffer[1024] __attribute__((section (".non_init"))); event_queue_init (event_queue_buffer, sizeof(event_queue_buffer)); scheduler_init(); serial_console_init (serial_console_output, false, false); printf ("Test App MK66F+KSZ8794.\r\n"); scheduler_schedule_event_timer (serial_console_poll_input, "serial_console_poll_input", 100, true); pit_init(0, 21000, scheduler_process_tick_irql); // initialize the led pins (leds off) gpio_make_output (PTA, 8, true); gpio_make_output (PTA, 9, true); gpio_make_output (PTA, 10, true); gpio_make_output (PTA, 11, true); scheduler_schedule_event_timer([]{ gpio_toggle(PTA, 9); }, nullptr, 1000, true); switch_init(); SIM->SOPT2 |= SIM_SOPT2_RMIISRC_MASK; // Tell the Ethernet peripheral to take its clock from ENET_1588_CLKIN (not EXTAL) gpio_make_alternate(PTE, 26, 2); PORTE_PCR26 = PORT_PCR_MUX(0x02) | PORT_PCR_ODE_MASK; // Set PTE26 as ENET_1588_CLKIN uint8_t mac_address[6]; make_mac_address(mac_address); enet_init (eth_pins, mac_address, &enet_callbacks); // Enable promiscuous mode in the Ethernet peripheral, to let incoming BPDUs through. // That's good enough for this STP demo app. ENET->RCR |= ENET_RCR_PROM_MASK; bridge = STP_CreateBridge (stp_port_count, 0, 0, &stp_callbacks, mac_address, 128); STP_StartBridge(bridge, scheduler_get_time_ms32()); // Let's read the link states right now, and then set up polling every 100 ms. // A real application would use interrupts; for this demo app polling is good enough. poll_port_state(); scheduler_schedule_event_timer (poll_port_state, "poll_port_state", 100, true); scheduler_schedule_event_timer(on_one_second_tick, "on_one_second_tick", 1000, true); serial_console_register_command_set(commands); while(1) { __WFI(); event_queue_pop_all(); if (rx_pending) { bool pushed = event_queue_try_push (process_received_frames, "process_received_frames"); if (pushed) rx_pending = false; } } }
c55e68cfd676838ff70eb91caffbc17fa77c8273
d43fabc5149c3446f2200033c604d1296297f26b
/include/Player.h
1445b8386f133b4c2c414a279a4e7f2a80470b5e
[]
no_license
pasolano/gamedes
23d49bda8928f0cf6c103f2f62ef9003873acbce
ae43f60352b17c2e076661e098c9e99cfd74dc18
refs/heads/main
2023-04-19T22:54:58.764081
2021-05-14T08:04:11
2021-05-14T08:04:11
339,482,384
2
2
null
2021-05-04T01:53:52
2021-02-16T17:50:54
C++
UTF-8
C++
false
false
340
h
Player.h
//Edited by Yixuan Xu on 02/28 #include <SpriteActor.h> #ifndef _PLAYER_H_ #define _PLAYER_H_ class Player : public SpriteActor { public: Player(); Player(/*Weapon w*/float x, float y, float v); //x,y position and speed void movePlayer(float, float); //trigger move event (global x and y) }; #endif /* _PLAYER_H_ */
5b1e5f059df87726738866af6bebfa0c4034bf87
223dd6cdf14a826fead3aba84fbb310e2757c448
/Volume 10000/Volume 104/10474 - Where is the Marble.cpp
bcea93b86c7999f37f82d3abc9d9fc817a588f60
[]
no_license
badstyle319/UVA
dad2972fcdd0dc219e90328607547a3524b8b047
28c27e8dfe766d7d83969a0f5b7dbc9a6b9282c6
refs/heads/master
2022-11-29T07:07:35.957202
2020-08-03T06:46:40
2020-08-03T06:46:40
284,227,832
0
0
null
null
null
null
UTF-8
C++
false
false
1,519
cpp
10474 - Where is the Marble.cpp
#include <bits/stdc++.h> #define LL long long #define ULL unsigned long long #define VI vector<int> #define VS vector<string> using namespace std; template<typename T> void PV(vector<T> &v) { for(auto it:v) cout<<it<<" "; cout<<endl; }; // static int dx[] = {-1,-1,-1,0,0,1,1,1}; // static int dy[] = {-1,0,1,-1,1,-1,0,1}; int main() { ios::sync_with_stdio(0); cin.tie(0); #ifndef ONLINE_JUDGE freopen("in.txt", "r", stdin); freopen("out.txt", "w", stdout); clock_t begin = clock(); #endif int N, Q, case_no = 1; while(cin>>N>>Q) { if(!N && !Q) break; VI v; int num; while(N--) { cin>>num; v.push_back(num); } sort(v.begin(), v.end()); cout<<"CASE# " << case_no++ << ":" <<endl; while(Q--) { cin>>num; auto it = lower_bound(v.begin(), v.end(), num) - v.begin(); cout<<num; if(v[it] == num) cout<<" found at "<<(it+1); else cout<<" not found"; cout<<endl; } } #ifndef ONLINE_JUDGE clock_t end = clock(); double elapsed_secs = double(end-begin) / CLOCKS_PER_SEC; cout<<fixed<<setprecision(3)<<"elapsed: "<<elapsed_secs<<" sec."<<endl; fclose(stdin); fclose(stdout); #endif return 0; }
4e6b21c30ed2caed944c3ecb1474cbab8da5eaa8
9cb58b81dcf7aa2e82fe66bde01d27f723fc9e93
/cpp/revolve/gazebo/plugin/_SoundSensorPlugin.h
b47e39649214f58eabcadef17ccd2d430e35c375
[]
no_license
egdman/revolve
88de935a425dce5d37eb3004bd163ac249548315
5f4ffe7d932c7941fb5054ba58202f9724457920
refs/heads/master
2020-04-01T22:48:13.716943
2018-05-24T16:13:15
2018-05-24T16:13:15
46,378,128
0
2
null
null
null
null
UTF-8
C++
false
false
803
h
_SoundSensorPlugin.h
#ifndef REVOLVE_SOUND_SENSOR_PLUGIN #define REVOLVE_SOUND_SENSOR_PLUGIN #include <revolve/gazebo/Types.h> #include <revolve/gazebo/sensors/SoundSensor.h> #include <gazebo/gazebo.hh> #include <gazebo/common/common.hh> #include "gazebo/common/Plugin.hh" #include "gazebo/sensors/sensors.hh" namespace revolve{ namespace gazebo{ class GAZEBO_VISIBLE SoundSensorPlugin: public ::gazebo::SensorPlugin { public: SoundSensorPlugin(); public: virtual ~SoundSensorPlugin(); public: virtual void Load(::gazebo::sensors::SensorPtr _parent, sdf::ElementPtr _sdf); protected: virtual void OnUpdate(SoundSensorPtr _sensor); protected: SoundSensorPtr parentSensor; private: ::gazebo::event::ConnectionPtr connection; }; } // namespace gazebo } // namespace revolve #endif // REVOLVE_SOUND_SENSOR_PLUGIN
ab0ecdb191324132c76108a56971c55ac01c3f68
36b9c44c6f2702036beb7e0ffc1c2ef7ca5b1420
/MyPaint/CMyPaintWidthDialog.cpp
fef4ee317dc0da510d3241a76a447918402ec69d
[]
no_license
lexfor/MyPaint
bf15eeada287429abf17fd470bddae550e28ae96
8c8df7a1a1879e83c3aaa40295808ffb1ab897ad
refs/heads/master
2021-07-12T22:10:40.046034
2021-02-24T18:23:53
2021-02-24T18:23:53
236,993,913
0
0
null
null
null
null
UTF-8
C++
false
false
1,618
cpp
CMyPaintWidthDialog.cpp
// CMyPaintWidthDialog.cpp: файл реализации // #include "pch.h" #include "MyPaint.h" #include "CMyPaintWidthDialog.h" #include "afxdialogex.h" #define DEFAULTWIDTH 1 // Диалоговое окно CMyPaintWidthDialog IMPLEMENT_DYNAMIC(CMyPaintWidthDialog, CDialogEx) CMyPaintWidthDialog::CMyPaintWidthDialog(CWnd* pParent /*=nullptr*/) : CDialogEx(IDD_DIALOG_WIDTH, pParent) , penWidth_(DEFAULTWIDTH) { } CMyPaintWidthDialog::~CMyPaintWidthDialog() { } void CMyPaintWidthDialog::DoDataExchange(CDataExchange* pDX) { CDialogEx::DoDataExchange(pDX); DDX_CBIndex(pDX, IDC_COMBO_WIDTH, penWidth_); //DDV_MinMaxInt(pDX, penWidth_, 1, 30); DDX_Control(pDX, IDC_COMBO_WIDTH, penWidthControl_); } BEGIN_MESSAGE_MAP(CMyPaintWidthDialog, CDialogEx) ON_BN_CLICKED(IDOK, &CMyPaintWidthDialog::OnBnClickedOk) END_MESSAGE_MAP() // Обработчики сообщений CMyPaintWidthDialog BOOL CMyPaintWidthDialog::OnInitDialog() { CDialogEx::OnInitDialog(); CString str; for (auto i = 1; i < 31; i++) { str.Format(_T("%d"), i); penWidthControl_.AddString(str); } penWidthControl_.SetCurSel(penWidth_ - 1); return TRUE; // return TRUE unless you set the focus to a control // Исключение: страница свойств OCX должна возвращать значение FALSE } void CMyPaintWidthDialog::OnBnClickedOk() { UpdateData(); penWidth_ = penWidthControl_.GetCurSel(); CDialogEx::OnOK(); } void CMyPaintWidthDialog::setCurrentWidth(int width) { penWidth_ = width; } int CMyPaintWidthDialog::getCurrentWidth() { return (penWidth_ + 1); }
b9696d40ea619a1c137ddb197625fca718161c31
fcb5a47663e7647fb7999066ac831a01e4672e17
/Test/Test1.cpp
ebb1cadb95b5a8d2cf9f1d7b211c2a1893a8528b
[]
no_license
renren123/ProcessInjection
fca809733ee1e38dc96d68a36945e04e929570e5
807f355683c335034c04ac8b9715a994a36a65c3
refs/heads/master
2021-06-21T12:38:56.525936
2021-05-13T10:02:42
2021-05-13T10:02:42
217,478,818
4
0
null
null
null
null
GB18030
C++
false
false
3,161
cpp
Test1.cpp
#include "pch.h" #include "Test1.h" #include <iostream> #include <stdio.h> #include <Windows.h> typedef int(WINAPI* pfMessageBoxA)(HWND, LPCSTR, LPCSTR, UINT); pfMessageBoxA OldMessageBoxA = NULL; int WINAPI MyMessageBoxA(HWND hWnd, LPCSTR lpText, LPCSTR lpCaption, UINT uType) { return OldMessageBoxA(hWnd, "hello lyshark", lpCaption, uType); } PIMAGE_NT_HEADERS GetLocalNtHead() { DWORD dwTemp = NULL; PIMAGE_DOS_HEADER pDosHead = NULL; PIMAGE_NT_HEADERS pNtHead = NULL; HMODULE ImageBase = GetModuleHandle(NULL); // 取自身ImageBase //pDosHead = (PIMAGE_DOS_HEADER)(DWORD)ImageBase; // 取pDosHead地址 pDosHead = (PIMAGE_DOS_HEADER)ImageBase; // 取pDosHead地址 dwTemp = (DWORD)pDosHead + (DWORD)pDosHead->e_lfanew; //dwTemp = (DWORD)pDosHead + (DWORD)pDosHead->e_lfanew; pNtHead = (PIMAGE_NT_HEADERS)dwTemp; // 取出NtHead头地址 return pNtHead; } void IATHook() { PVOID pFuncAddress = NULL; pFuncAddress = GetProcAddress(GetModuleHandleA("user32.dll"), "MessageBoxA"); // 取Hook函数地址 OldMessageBoxA = (pfMessageBoxA)pFuncAddress; // 保存原函数指针 PIMAGE_NT_HEADERS pNtHead = GetLocalNtHead(); // 获取到程序自身NtHead PIMAGE_FILE_HEADER pFileHead = (PIMAGE_FILE_HEADER)&pNtHead->FileHeader; PIMAGE_OPTIONAL_HEADER pOpHead = (PIMAGE_OPTIONAL_HEADER)&pNtHead->OptionalHeader; DWORD dwInputTable = pOpHead->DataDirectory[1].VirtualAddress; // 找出导入表偏移 DWORD dwTemp = (DWORD)GetModuleHandle(NULL) + dwInputTable; PIMAGE_IMPORT_DESCRIPTOR pImport = (PIMAGE_IMPORT_DESCRIPTOR)dwTemp; PIMAGE_IMPORT_DESCRIPTOR pCurrent = pImport; DWORD* pFirstThunk; //导入表子表,IAT存储函数地址表. //遍历导入表 while (pCurrent->Characteristics && pCurrent->FirstThunk != NULL) { dwTemp = pCurrent->FirstThunk + (DWORD)GetModuleHandle(NULL);// 找到内存中的导入表 pFirstThunk = (DWORD*)dwTemp; // 赋值 pFirstThunk while (*(DWORD*)pFirstThunk != NULL) // 不为NULl说明没有结束 { if (*(DWORD*)pFirstThunk == (DWORD)OldMessageBoxA) // 相等说明正是我们想要的地址 { DWORD oldProtected; VirtualProtect(pFirstThunk, 0x1000, PAGE_EXECUTE_READWRITE, &oldProtected); // 开启写权限 dwTemp = (DWORD)MyMessageBoxA; memcpy(pFirstThunk, (DWORD*)&dwTemp, 4); // 将MyMessageBox地址拷贝替换 VirtualProtect(pFirstThunk, 0x1000, oldProtected, &oldProtected); // 关闭写保护 } pFirstThunk++; // 继续递增循环 } pCurrent++; // 每次是加1个导入表结构. } } BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) { IATHook(); return TRUE; } int main() { const char* a = "123"; IATHook(); while (1) { std::cout << "1" << std::endl; Sleep(1000); } /*while (true) { Sleep(2000); std::cout << "Test" << std::endl; } std::std::cout << "Hello World!\n"; */ }
4cafc4958e3f58420bb7c7e5dc2cb6119233429a
725d6c3f192941b14740f082ae0cce4cc392914f
/game/Map.cpp
248209e6de194edfb75c74493b20fab54fb42b87
[]
no_license
Rrpe/C-C-
812f68eaa1238b4f95234374700620b0516fc464
a345d4869d86e35fbb2a9a2fe4558cf048ed6738
refs/heads/main
2023-03-06T17:23:01.097687
2021-02-22T04:13:15
2021-02-22T04:13:15
341,075,525
0
0
null
null
null
null
UTF-8
C++
false
false
101
cpp
Map.cpp
#include "Map.h" void loadMap() { } void freeMap() { } void drawMap(float dt) { }
a8b9780420f3fedfdfcba2d3040798f5cc4180e1
87a0a9c5edd5c94e1aa79421132b668af9f629ee
/Codeforces/Codeforces/SWEA_2477.cpp
e5272fdddfdedae431041f6487ede38aea2cf992
[]
no_license
dhrdlxl/Codeforces
c3b37d92819a9787091f7faf6a0548abcbc3a713
80c674f6115ee2047b45afb809058137d663f646
refs/heads/master
2021-04-18T21:57:33.356455
2018-04-30T13:34:43
2018-04-30T13:34:43
126,686,717
1
0
null
null
null
null
UHC
C++
false
false
3,609
cpp
SWEA_2477.cpp
#include <iostream> #include <vector>//vector #include <utility>//make_pair, pair #include <queue> using namespace std; int main() { int T;// cin >> T; for (int x = 1; x < T+1; x++) { int N, M, K, A, B; cin >> N >> M >> K >> A >> B; int a_tick[10] = { 0, };//첫 번째 창구 이용시간 저장할 배열 int b_tick[10] = { 0, };//두 번째 창구 이용시간 저장할 배열 int t[1001] = { 0, };//고객 도착시간 저장할 배열 for (int i = 1; i < N + 1; i++)//첫 번째 창구 이용시간 { scanf_s("%d", &a_tick[i]); } for (int i = 1; i < M + 1; i++)//두 번째 창구 이용시간 { scanf_s("%d", &b_tick[i]); } for (int i = 1; i < K + 1; i++) { scanf_s("%d", &t[i]); } //여기까지 입력받는다. queue<int> que1;//첫 번째 창구 대기열 queue<int> que2;//두 번째 창구 대기열 vector<vector<pair<int, int>>> a(N + 1);//첫 번째 창구 현재 상태 //a = vector<vector<pair<int, int>>>(N + 1); vector<vector<pair<int, int>>> b(M + 1);//두 번째 창구 현재 상태 int tick = 0;//시간의 흐름. int j = 1;//첫번째 창구 대기열에 들어갈 때 쓸 변수 int answer[1001] = {0,};//고객이 해당 창구를 이용하면 +1 할 배열 int counter = 0; //실제 시뮬레이션 부분. while (counter < K) { for (; t[j] == tick;) {//고객이 도착했을때 큐에 넣음. que1.push(j); j++; } for (int i = 1; i < N + 1; i++)//첫번째 창구 탐색 { if (a[i].size() == 1)//현재 처리중인 창구이면 { if (tick - a[i][0].second == a_tick[i])//현재시간 - 고객이 들어온 시간 == 창구 처리시간 {//즉 처리 완료했을 때 que2.push(a[i][0].first);//두 번째 창구 대기열에 넣음 a[i].pop_back();//첫번째 해당 창구의 고객 제거 } } if (a[i].size() == 0)//창구에 고객이 없을 때. { if (que1.size() > 0)//기다리는 사용자가 있으면 { a[i].push_back(make_pair(que1.front(), tick));//가장 먼저 온 고객, 현재 시간을 넘긴다. if (i == A)//분실 고객과 같은 창구이면 { answer[que1.front()]++;//해당 손님의 값 1증가.(2가 되면 정답으로 더해진다.) } que1.pop();//고객이 창구에 갔으므로 대기열에서 제거 } } } //두 번째 창구에서 나갈때 counter++ 해주자. for (int i = 1; i < M + 1; i++)//두번 째 창구 탐색. { if (b[i].size() == 1)//현재 처리중인 창구이면 { if (tick - b[i][0].second == b_tick[i])//현재시간 - 고객이 들어온 시간 == 창구 처리시간 {//즉 처리 완료했을 때 b[i].pop_back();//두번째 해당 창구의 고객 제거 counter++;//고객이 다 나가면 끝나도록. } } if (b[i].size() == 0)//창구에 고객이 없을 때. { if (que2.size() > 0)//두번째 창구를 기다리는 사용자가 있으면 { b[i].push_back(make_pair(que2.front(), tick));//가장 먼저 온 고객, 현재 시간을 넘긴다. if (i == B)//분실 고객과 같은 창구이면 { answer[que2.front()]++;//해당 손님의 값 1증가.(2가 되면 정답으로 더해진다.) } que2.pop();//고객이 창구에 갔으므로 대기열에서 제거 } } } //시간 증가 tick++; } int sum = 0; for (int i = 1; i < 1001; i++) { if (answer[i] == 2) sum += i; } if (sum == 0) sum = -1; cout << "#" << x << " " << sum<<endl; } system("pause"); return 0; }
d797caf1dc6b93bd37bf13890d930820b76d1057
e4cdc8e266c3963e45cbd1afd5ae8db3ae5dd14a
/PCB.h
52706de71ce702bfdfdcb0dff848df163f1161fa
[]
no_license
isabellab3/OS-Simulation
8ca7672f1c8e19aadb430db5170bb28786facb52
aa61d190e565a9eaad722bfcd66bcd3764fc8adf
refs/heads/master
2022-02-23T05:58:54.561312
2019-10-06T01:44:58
2019-10-06T01:44:58
197,069,812
3
2
null
null
null
null
UTF-8
C++
false
false
3,337
h
PCB.h
#ifndef PCB_H #define PCB_H #include <vector> class PCB { public: PCB(int & pid_) : pid(pid_), child_processes(0), parent_process(0), process_is_zombie(0), waiting(0) {} ~PCB() { for (auto child : child_processes) { delete child; } ClearChildren(); } int GetPid() const { return pid; } // Adds a pointer to a child process of this pcb void AddChildProcess(PCB* child_process) { child_processes.push_back(child_process); } // Sets the process to waiting or not waiting void SetWaitingState(bool state) { waiting = state; } // Marks the process as a zombie (1) or not a zombie (0) void SetZombie(bool state) { process_is_zombie = state; } // Returns true if the process is waiting, otherwise returns false bool IsWaiting() { return waiting; } // Returns true if the process is a zombie process. Returns false otherwise bool IsZombieProcess() const { return process_is_zombie; } // If the process has a child that is a zombie, returns the pid of that child. If it does not, returns 0. int ProcessHasZombieChild() const { for (auto itr = child_processes.begin(); itr != child_processes.end(); itr++) { if ((*itr)->process_is_zombie) { return (*itr)->pid; } } return 0; } //Returns true if the process has children. bool HasChildren() const { return !child_processes.empty(); } // When called on a process, removes the given child if it is found in child_processes. void RemoveChild(PCB* & child) { for (auto itr = child_processes.begin(); itr != child_processes.end(); itr++) { if ((*itr) == child) { child_processes.erase(itr); return; } } } // Sets the parent pid of a process void SetParent(const int parent_pid) { parent_process = parent_pid; } // Returns the parent pid of a process int GetParent() { return parent_process; } // Returns a constant reference to the vector of child processes. const std::vector<PCB*> & GetChildren() const { return child_processes; } // Clears the vector of child processes. void ClearChildren() { child_processes.clear(); } private: int pid; // Unique id of the process std::vector<PCB*> child_processes; // Pointers of all children of the process int parent_process; // The pid of the parent of the process bool process_is_zombie; // True is process is a zombie process, false otherwise bool waiting; // True if this process is waiting for a child process to terminate. }; #endif // PCB_H
16675c5b75607b6da714fc441cf03ae659417727
3844b2976c4aad44bdc951472cb786498aeb947c
/Project 3/Child.h
21d30329dd712704cd4d7fb3e3c6018f6e7396e8
[]
no_license
mBeh95/Data-Structure-and-Algorithms-I
010acfd3d387151ff7464cbbf65dd4178cf5e068
8c01e153ae19b82033b36a4da597aa316ef6a323
refs/heads/master
2020-04-05T14:46:07.780794
2018-11-10T03:15:47
2018-11-10T03:15:47
156,940,076
0
0
null
null
null
null
UTF-8
C++
false
false
485
h
Child.h
#pragma once #include <iostream> #include <fstream> #include <string> #include "List342.h" using namespace std; class Child { public: Child(); Child(string lName, string fName, int age); ~Child(); string getLastName() const; bool operator==(const Child &rhs) const; bool operator!=(const Child &rhs) const; bool operator<(const Child &rhs) const; friend ostream& operator<<(ostream &outStream, const Child &rhs); private: string lastName; string firstName; int age; };
a96dba9a75413ad9a841b90807a45781e61c761e
0a9b5dce7cb7e265fe17e80caf8939ccd140be60
/ImageCluster/bin/cluster_tmp.cxx
617e71b81165a9c186263fb35d92663b90291a7f
[]
no_license
richa2710/LArOpenCV
7ddc1a45c1d72512ba17132ccbcacfc3ec8e5a36
522bf1d873a8133ff203a198a191d5e8042f943f
refs/heads/master
2023-07-18T00:20:34.021055
2016-08-03T14:58:38
2016-08-03T14:58:38
null
0
0
null
null
null
null
UTF-8
C++
false
false
340
cxx
cluster_tmp.cxx
#ifndef __CLASSNAME_CXX__ #define __CLASSNAME_CXX__ #include "ClassName.h" namespace larcv{ void ClassName::_Configure_(const ::fcllite::PSet &pset) {} Cluster2DArray_t ClassName::_Process_(const larcv::Cluster2DArray_t& clusters, const ::cv::Mat& img, larcv::ImageMeta& meta) { return Cluster2DArray_t(); } } #endif
fd7b0d7a8e4450b76909bad55fd6da73f2e71a18
34f65375b05dc9dfd7789a93d2f53fa2c6fa307f
/src/engine/common.h
995a398c767529d19b7cc93068b403ea4140e791
[]
no_license
LoneBoco/2drp
e71644a3dd7a63c8e3fd81d49254330c6002c44a
432faeceeddd1f962b4aebcad27fa0d92eefdf5a
refs/heads/main
2023-03-06T00:48:10.431247
2023-02-28T08:39:05
2023-02-28T08:39:05
156,314,823
5
0
null
null
null
null
UTF-8
C++
false
false
1,378
h
common.h
#pragma once #ifndef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN #endif #ifndef NOMINMAX #define NOMINMAX #endif #include <cstdint> #include <cstddef> #include <locale> #include <memory> #include <string> #include <vector> #include <map> #include <functional> #include <algorithm> #include <numeric> #include <atomic> #include <chrono> #include <type_traits> #include <concepts> #include <ranges> #include <boost/algorithm/string.hpp> #include "engine/events/Events.h" #include "engine/helper/math.h" #include "engine/helper/flags.h" #include "engine/filesystem/Log.h" #include <BabyDI.hpp> namespace chrono { using clock = std::chrono::steady_clock; } using namespace std::chrono_literals; namespace tdrp { template <typename T> concept is_numeric = std::integral<T> || std::floating_point<T>; template <class T> concept is_string = std::convertible_to<T, std::string>; } // end namespace tdrp namespace tdrp { using SceneObjectID = uint32_t; using AttributeID = uint16_t; using ItemID = uint16_t; } // end namespace tdrp /* namespace tdrp { class MyClass { public: MyClass() = default; ~MyClass() = default; MyClass(const MyClass&) = delete; MyClass(MyClass&&) noexcept = delete; MyClass& operator=(const MyClass&) = delete; MyClass& operator=(MyClass&&) noexcept = delete; bool operator==(const MyClass&) = delete; }; } // end namespace tdrp */
970c42e80b566cd24caa42a4ac360bc53a209ac6
a1d02891040347a071814e94478be20eefbe470b
/Tests/svngui/SVNDialogCommit.cpp
012b15df599d963910cb5de5307da57aaa2c9f5f
[]
no_license
lefevre-fraser/GME
3edee4f2c8668a9b03ab41bff13ceb03eec26295
123e9f96782fb6b5931d01c40aa22d2d55e4d81c
refs/heads/master
2020-09-19T20:28:12.598585
2019-09-26T18:26:13
2019-09-26T18:26:13
224,279,886
0
0
null
null
null
null
UTF-8
C++
false
false
912
cpp
SVNDialogCommit.cpp
// SVNDialogCommit.cpp : implementation file // #include "stdafx.h" #include "svngui.h" #include "SVNDialogCommit.h" #include "afxdialogex.h" // CSVNDialogCommit dialog IMPLEMENT_DYNAMIC(CSVNDialogCommit, CDialogEx) CSVNDialogCommit::CSVNDialogCommit(CWnd* pParent /*=NULL*/) : CDialogEx(CSVNDialogCommit::IDD, pParent) , filename(_T("")) , repository(_T("")) , revision(0) , logMessage(_T("")) { } CSVNDialogCommit::~CSVNDialogCommit() { } void CSVNDialogCommit::DoDataExchange(CDataExchange* pDX) { CDialogEx::DoDataExchange(pDX); DDX_Text(pDX, IDC_EDIT_SVNCOMMIT_FILENAME, filename); DDX_Text(pDX, IDC_EDIT_SVNCOMMIT_REPO, repository); DDX_Text(pDX, IDC_EDIT_SVNCOMMIT_REVISION, revision); DDX_Text(pDX, IDC_EDIT_SVNCOMMIT_LOG, logMessage); } BEGIN_MESSAGE_MAP(CSVNDialogCommit, CDialogEx) END_MESSAGE_MAP() // CSVNDialogCommit message handlers
7dea9d8044964eb7d48ca22f8f5001187132a202
8d882a6676b0e68ca054ecbec445d983be59e91e
/src/ExposurePrep2.cpp
58811c13feb32ea1e0f135e5dc3720157943bf0b
[]
no_license
gbernstein/orbitspp
2eda08c55ac6046a7a3d1492632797affb823d57
a2d979678be2034a28b92becbf212c62a72cebef
refs/heads/master
2023-06-22T13:23:04.992330
2023-06-13T19:56:19
2023-06-13T19:56:19
121,978,905
5
0
null
2022-07-05T18:25:20
2018-02-18T18:35:27
C++
UTF-8
C++
false
false
4,183
cpp
ExposurePrep2.cpp
// Add a second extension to exposure table containing // time and pointing info for exposures not in the first table. #include <vector> #include <iostream> #include "Std.h" #include "StringStuff.h" #include "FitsTable.h" #include "Astrometry.h" #include "Ephemeris.h" using namespace std; /** New output table will include: expnum mjd_mid ra, dec (from initial header, less accurate) observatory position (ICRS) ecliptic lat, lon of pointing ecliptic lon of observatory **/ string usage = "Add a table of times/points for exposures without astrometric solutions\n" "to the FITS file holding info on exposures with astrometry.\n" "usage: ExposurePrep2 <exposure list input> <exposure FITS table to augment>\n" " <exposure list input> is FITS table of all exposures from DESDB with MJD, etc.\n" " <exposure FITS...> is name of existing astrometric exposure list to give new extension\n"; int main(int argc, char *argv[]) { if (argc != 3) { cerr << usage << endl; exit(1); } string allExposureFile = argv[1]; string targetExposureFile = argv[2]; // Get info on all exposures img::FTable allExposuresTable; try { FITS::FitsTable ff(allExposureFile); allExposuresTable = ff.extract(); } catch (std::runtime_error& m) { cerr << "Error reading all-exposure table" << endl; quit(m); } try { orbits::Ephemeris ephem; // Record which exposures have astrometric information set<int> knownExposures; { FITS::FitsTable ff(targetExposureFile,FITS::ReadOnly,1); vector<string> useColumns(1,"EXPNUM"); img::FTable tab = ff.extract(0,-1,useColumns); vector<int> expnum; tab.readCells(expnum,"EXPNUM"); knownExposures.insert(expnum.begin(), expnum.end()); } // Collect info on new exposures vector<int> expnum; vector<double> mjd_mid; vector<string> filter; vector<vector<double>> observatory; //ICRS observatory position vector<double> ra; vector<double> dec; vector<double> ecl_lat; vector<double> ecl_lon; vector<double> obs_ecl_lon; for (int i=0; i<allExposuresTable.nrows(); i++) { LONGLONG expnumInLong; // Skip any exposure in the first table allExposuresTable.readCell(expnumInLong, "EXPNUM", i); int expnumIn = expnumInLong; if (knownExposures.count(expnumIn)) continue; // Collect other info for this exposure double mjdIn, raIn, decIn; string bandIn; allExposuresTable.readCell(mjdIn, "MJD_MID", i); allExposuresTable.readCell(raIn, "RADEG", i); allExposuresTable.readCell(decIn, "DECDEG", i); allExposuresTable.readCell(bandIn, "BAND", i); expnum.push_back(expnumIn); mjd_mid.push_back(mjdIn); ra.push_back(raIn); dec.push_back(decIn); filter.push_back(bandIn); // Get observatory position astrometry::CartesianICRS obspos = ephem.observatory(807, ephem.mjd2tdb(mjdIn)); std::vector<double> v3 = {obspos[0], obspos[1], obspos[2]}; observatory.push_back(v3); // Get ecliptic longitude of observatory { astrometry::CartesianEcliptic cc(obspos); astrometry::SphericalEcliptic ecl(cc); double lon,lat; ecl.getLonLat(lon, lat); obs_ecl_lon.push_back(lon/DEGREE); } // Get ecliptic coordinates of pointing { astrometry::SphericalICRS icrs(raIn*DEGREE, decIn*DEGREE); astrometry::SphericalEcliptic ecl(icrs); double lon,lat; ecl.getLonLat(lon, lat); ecl_lon.push_back(lon/DEGREE); ecl_lat.push_back(lat/DEGREE); } } // End loop over input exposures // Write a new table to the exposure table FITS::FitsTable ff(targetExposureFile,FITS::Create+FITS::OverwriteHDU,2); img::FTable out = ff.use(); out.addColumn(expnum,"expnum"); out.addColumn(mjd_mid,"mjd_mid"); out.addColumn(ra,"ra"); out.addColumn(dec,"dec"); out.addColumn(filter,"filter"); out.addColumn(observatory,"observatory",3); out.addColumn(ecl_lon,"ecl_lon"); out.addColumn(ecl_lat,"ecl_lat"); out.addColumn(obs_ecl_lon,"obs_ecl_lon"); } catch (std::runtime_error& m) { quit(m); } exit(0); }
fbf79eb2880c1d834028ccab147160738f0387ea
ef187313537d520739b4918e0ef4c0b0041bf4e7
/C25_GlobalPosition/src/C25_Node.cpp
5165bfc1476769b062e7c027b1adab72aa1e41b9
[]
no_license
robotil/robil
e4a0a4eb92c0758101ecc1963d77142d51ed4c9c
257cd66266f299fd5f696cd4b5e92fa195237e47
refs/heads/master
2021-05-30T13:34:35.303549
2013-11-20T06:46:25
2013-11-20T06:46:25
null
0
0
null
null
null
null
UTF-8
C++
false
false
9,709
cpp
C25_Node.cpp
/************************************************************************************** * This is a template for the C25_GlobalPosition module for the robil project * The C25_GlobalPosition module goal is to provide UTM global positioning according to the data * Received from GPS and camera sensors. data is relative to the pelvis of the drc robot **************************************************************************************/ #include "ros/ros.h" #include "C25_GlobalPosition/C25.h" #include "C25_GlobalPosition/C25C0_ROP.h" #include "ros/service.h" #include "LocalizationTrackServer.hpp" #include <message_filters/subscriber.h> #include <message_filters/synchronizer.h> #include <message_filters/time_synchronizer.h> #include <message_filters/sync_policies/approximate_time.h> #include "std_msgs/String.h" #include "std_msgs/Empty.h" #include "std_srvs/Empty.h" #include "geometry_msgs/PoseWithCovarianceStamped.h" #include "C25_GlobalPosition/C25BDI.h" #include <nav_msgs/Odometry.h> #include <sensor_msgs/Imu.h> //#include <C21_VisionAndLidar/C21_C22.h> #include <atlas_msgs/AtlasSimInterfaceState.h> #include <tf/tf.h> #include <tf/transform_listener.h> //#include <tf/Matrix3x3.h> #include <pcl/correspondence.h> #include <pcl/point_cloud.h> #include <pcl/common/common_headers.h> #include "tf/transform_datatypes.h" #include "pcl/point_types.h" #include "pcl_ros/transforms.h" #include "boost/assign.hpp" using namespace sensor_msgs; using namespace nav_msgs; using namespace message_filters; /** * this class represent the C25_Node, **/ class C25_Node{ private: ros::NodeHandle nh_; ros::Publisher c25_publisher,bdi_pub; //ros::Publisher object_location_publisher; //ros::Subscriber object_detector_subscriber; //ros::Subscriber C21_subscriber; ros::ServiceServer c25_service; ros::ServiceServer ground_truth_service; ros::ServiceServer bdi_service; typedef sync_policies::ApproximateTime<Imu, atlas_msgs::AtlasSimInterfaceState> MySyncPolicy; message_filters::Subscriber<Imu> imu_sub; message_filters::Subscriber< atlas_msgs::AtlasSimInterfaceState> bdi_sub; Synchronizer<MySyncPolicy> sync; ros::Subscriber pos_sub,ground_truth_sub; bool switch_,switch2_; C25_GlobalPosition::C25C0_ROP last_msg; geometry_msgs::PoseWithCovarianceStamped kalman_last_msg; atlas_msgs::AtlasSimInterfaceState bdi_last_msg; sensor_msgs::Imu imu_last_msg; float bdi_delta_x,bdi_delta_y,bdi_delta_z,bdi_delta_time; float kalman_delta_x,kalman_delta_y,kalman_delta_z,kalman_delta_time; //C23_ObjectRecognition::C23C0_ODIM last_obj_msg; bool gotObj; LocalizationTrackServer *taskserver; public: /** * public, initializes the ROS node, subscribe it to the given topics and instruct it to provide the service */ C25_Node(int argc, char **argv): imu_sub(nh_,"/atlas/imu",1), bdi_sub(nh_,"/atlas/atlas_sim_interface_state",1), sync(MySyncPolicy(100), imu_sub, bdi_sub) { switch_=true; switch2_=true; bdi_delta_x=0; bdi_delta_y=0; bdi_delta_z=0; bdi_delta_time=0; kalman_delta_x=0; kalman_delta_y=0; kalman_delta_z=0; kalman_delta_time=0; sync.registerCallback( boost::bind( &C25_Node::bdi_callback, this, _1, _2 ) ); c25_publisher=nh_.advertise<C25_GlobalPosition::C25C0_ROP>("C25/publish",1); c25_service=nh_.advertiseService("C25/service",&C25_Node::proccess,this); ground_truth_service=nh_.advertiseService("C25/ground_truth",&C25_Node::groundtruthProccess,this); bdi_service=nh_.advertiseService("C25/BDIswitch",&C25_Node::BDIProccess,this); //bdi_pub=nh_.advertise<nav_msgs::Odometry>("C25/bdi_stripped",100); //bdi_sub= nh_.subscribe("/atlas/atlas_sim_interface_state", 1, &C25_Node::bdi_callback, this); pos_sub=nh_.subscribe("/robot_pose_ekf/odom",1,&C25_Node::callback,this); ROS_INFO("service on\n"); boost::thread mythread( &C25_Node::startActionServer,this,argc,argv); } void startActionServer(int argc, char **argv){ ros::init(argc, argv, "C25_LocalizationTrackServer"); taskserver=new LocalizationTrackServer(); while(ros::ok()){ ros::Duration(0.02).sleep(); } } bool BDIProccess(C25_GlobalPosition::C25BDI::Request &req,C25_GlobalPosition::C25BDI::Response &res ){ if(switch_){ if(req.state.data==0){ switch2_=false; //bdi_sub.shutdown(); //pos_sub=nh_.subscribe("/robot_pose_ekf/odom",1,&C25_Node::callback,this); }else{ if(req.state.data==1){ switch2_=true; } //pos_sub.shutdown(); //bdi_sub= nh_.subscribe("/atlas/atlas_sim_interface_state", 1, &C25_Node::bdi_callback, this); } }else{ return false; } return true; } bool groundtruthProccess(std_srvs::Empty::Response &req, std_srvs::Empty::Response &res ) {//cout<<"isdfkjhsadfjhsdfhj\n"; if(switch_){ switch_=false; /*if(!switch2_) pos_sub.shutdown(); else bdi_sub.unsubscribe();*/ ground_truth_sub= nh_.subscribe("/ground_truth_odom", 1, &C25_Node::poseCallback, this); }else{ switch_=true; ground_truth_sub.shutdown(); /*if(!switch2_) pos_sub=nh_.subscribe("/robot_pose_ekf/odom",1,&C25_Node::callback,this); else bdi_sub.subscribe(nh_,"/atlas/atlas_sim_interface_state", 1, &C25_Node::bdi_callback, this);*/ } return true; } /** * The call back function executed when a service is requested */ bool proccess(C25_GlobalPosition::C25::Request &req, C25_GlobalPosition::C25::Response &res ) { res.robotPosition=last_msg; return true; } void bdi_callback(const sensor_msgs::Imu::ConstPtr &imu_msg, const atlas_msgs::AtlasSimInterfaceState::ConstPtr &msg){ bdi_delta_x=msg->pos_est.position.x-bdi_last_msg.pos_est.position.x; bdi_delta_y=msg->pos_est.position.y-bdi_last_msg.pos_est.position.y; bdi_delta_z=msg->pos_est.position.z-bdi_last_msg.pos_est.position.z; bdi_delta_time=msg->header.stamp.toSec()-bdi_last_msg.header.stamp.toSec(); bdi_last_msg.pos_est.position=msg->pos_est.position; bdi_last_msg.header=msg->header; imu_last_msg.orientation=imu_msg->orientation; if(switch2_ && switch_){ double r0,p0,y0,r1,p1,y1; tf::Quaternion oldQ; tf::quaternionMsgToTF(last_msg.pose.pose.pose.orientation, oldQ); tf::Matrix3x3 mOld(oldQ); mOld.getRPY(r0,p0,y0); tf::Quaternion newQ; tf::quaternionMsgToTF(imu_msg->orientation, newQ); tf::Matrix3x3 mNew(newQ); mOld.getRPY(r1,p1,y1); last_msg.header=bdi_last_msg.header; last_msg.pose.header=bdi_last_msg.header; last_msg.pose.pose.pose.position.x+=bdi_delta_x; last_msg.pose.pose.pose.position.y+=bdi_delta_y; last_msg.pose.pose.pose.position.z+=bdi_delta_z; last_msg.pose.pose.pose.orientation.x=imu_last_msg.orientation.x; last_msg.pose.pose.pose.orientation.y=imu_last_msg.orientation.y; last_msg.pose.pose.pose.orientation.z=imu_last_msg.orientation.z; last_msg.pose.pose.pose.orientation.w=imu_last_msg.orientation.w; last_msg.pose.twist.twist.angular.x=(r1-r0)/(bdi_delta_time); last_msg.pose.twist.twist.angular.y=(p1-p0)/(bdi_delta_time); last_msg.pose.twist.twist.angular.z=(y1-y0)/(bdi_delta_time); c25_publisher.publish(last_msg); } } void poseCallback(const nav_msgs::Odometry::ConstPtr &msg){ last_msg.pose.header=msg->header; last_msg.pose.pose=msg->pose; last_msg.pose.twist=msg->twist; c25_publisher.publish(last_msg); } /** * The call back function executed when a data is available */ void callback(const geometry_msgs::PoseWithCovarianceStampedConstPtr& pos_msg){ kalman_delta_x=pos_msg->pose.pose.position.x-kalman_last_msg.pose.pose.position.x; kalman_delta_y=pos_msg->pose.pose.position.y-kalman_last_msg.pose.pose.position.y; kalman_delta_z=pos_msg->pose.pose.position.z-kalman_last_msg.pose.pose.position.z; kalman_delta_time=pos_msg->header.stamp.toSec()-kalman_last_msg.header.stamp.toSec(); kalman_last_msg.pose.pose.position=pos_msg->pose.pose.position; kalman_last_msg.header=pos_msg->header; kalman_last_msg.pose.pose.orientation=pos_msg->pose.pose.orientation; if(!switch2_ && switch_){ double r0,p0,y0,r1,p1,y1; tf::Quaternion oldQ; tf::quaternionMsgToTF(last_msg.pose.pose.pose.orientation, oldQ); tf::Matrix3x3 mOld(oldQ); mOld.getRPY(r0,p0,y0); tf::Quaternion newQ; tf::quaternionMsgToTF(pos_msg->pose.pose.orientation, newQ); tf::Matrix3x3 mNew(newQ); mOld.getRPY(r1,p1,y1); last_msg.header=pos_msg->header; last_msg.pose.header=pos_msg->header; last_msg.pose.pose.pose.position.x+=kalman_delta_x; last_msg.pose.pose.pose.position.y+=kalman_delta_y; last_msg.pose.pose.pose.position.z+=kalman_delta_z; last_msg.pose.pose.pose.orientation.x=pos_msg->pose.pose.orientation.x; last_msg.pose.pose.pose.orientation.y=pos_msg->pose.pose.orientation.y; last_msg.pose.pose.pose.orientation.z=pos_msg->pose.pose.orientation.z; last_msg.pose.pose.pose.orientation.w=pos_msg->pose.pose.orientation.w; last_msg.pose.twist.twist.angular.x=(r1-r0)/(kalman_delta_time); last_msg.pose.twist.twist.angular.y=(p1-p0)/(kalman_delta_time); last_msg.pose.twist.twist.angular.z=(y1-y0)/(kalman_delta_time); c25_publisher.publish(last_msg); } } }; int main(int argc, char **argv) { ros::init(argc, argv, "C25_GlobalPosition"); C25_Node *my_node=new C25_Node(argc,argv); while(ros::ok()){ ros::Duration(0.02).sleep(); ros::spinOnce(); //ros::spin(); } return 0; }
b68798cbc15f6eff20a73a113d56737f139299ae
7a14b95faad3f002bffec51854f4932578ef3877
/dragonhoard.cc
42212d7b430df5494690c0d683e3dc3201316ffa
[]
no_license
AndreasRicci/CC3k
fbae07a65d64688ec77e1bea8f6a5c6fd02eac37
3082c4f63ef99c9147d08247a912ed3a3a508341
refs/heads/master
2021-01-20T07:42:09.887071
2015-08-09T04:34:54
2015-08-09T04:34:54
40,425,346
2
0
null
null
null
null
UTF-8
C++
false
false
1,075
cc
dragonhoard.cc
#include <sstream> #include <string> #include "dragonhoard.h" #include "constants.h" #include "cell.h" #include "language.h" #include "baseplayer.h" using namespace std; DragonHoard::DragonHoard(Game * game, Dragon * keeper): Treasure(TREASURES[DRAGON_HOARD][VALUE], game), keeper(keeper) {} DragonHoard::~DragonHoard() {} Dragon * DragonHoard::getDragon(){ return keeper; } void DragonHoard::setDragon(Dragon * dragon){ keeper = dragon; } Player * DragonHoard::take(Player * player){ if (!keeper){ int loot = value * player->getGoldMultiplier()/100; BasePlayer::getInstance()->setGold(player->getGold() + loot); game->addToScore(loot * player->getScoreMultiplier()/100); location->setOccupant(NULL); location = NULL; ostringstream goldAmount; goldAmount << loot; game->addAction(Language::getText("pc") + Language::getText("picksUp") + Language::getText("dragonHoard") + Language::getText("worth") + goldAmount.str() + " " + Language::getText("Gold") + "."); } return player; }
e3e112eade40be02fd2d7fb8b02683df3e013113
e6df7c4a0e955ac7ed2068efabd35a740ccd8895
/keypoints/UniformKeypoints.h
678278ed5ec4bb11c19f50bec9d671d2f8c2c5ce
[]
no_license
dvallin/pclref
3bbb77e2d8e822b9fd7a00251f23a99e469b8cac
5b7ddf45fba7c5caa99fdf5a31c5cf33bb251131
refs/heads/master
2020-12-02T22:08:20.150424
2017-07-03T08:17:06
2017-07-03T08:17:06
96,087,163
3
0
null
null
null
null
UTF-8
C++
false
false
1,324
h
UniformKeypoints.h
/** * * \author $Author: schuler $ * * \version $Revision: 0.1 $ * * \date $Date: 2012/07/24 $ * * Contact: schuler.maximilian@gmail.com * * Created on: September 5 2014 * */ #ifndef UNIFORM_KEYPOINTS_H_ #define UNIFORM_KEYPOINTS_H_ #include <PclRefLIB.h> #include <ProcessingStep.h> namespace pclref { /** * \class UniformKeypoints * * \brief Generates keypoints by downsampling the point cloud using a voxel grid filter * * \param uk_radius : double (0.4) * * \pre ProcessingContext::PointCloud cloud * \post ProcessingContext::KeypointCloud keypoints * \post ProcessingContext::IndexCloud keypoint_indices */ template<typename PointType, typename KeypointType, typename FeatureType> class UniformKeypoints : public ProcessingStep<PointType, KeypointType, FeatureType> { public: typedef ProcessingStep<PointType, KeypointType, FeatureType> BaseType; ///< The type of the base class using typename BaseType::Ptr; typedef ProcessingContext<PointType, KeypointType, FeatureType> ContextType; ///< The Context UniformKeypoints(); void init(); int compute(size_t run, typename ContextType::Ptr context); std::string getName() const; }; } #define PCLREF_INSTANTIATE_UniformKeypoints(T,K,F) template class pclref::UniformKeypoints <T,K,F>; #endif
a6e83dfee94f22a5706adf0b6029edb38f582b1d
de80b91a12b10bd962b59a89b2badbb83a0193da
/ClientProject/Mof/RatchetNClankCopy/RatchetApplication/Actor/Character/Queen.cpp
0eae4605250ee2f3f42f2f0b91ea4009941db423
[ "MIT" ]
permissive
OIC-Shinchaemin/RatchetNclank-PrivateCopy
8845eea799b3346646c8c93435c0149e842dede8
e2e646e89ef3c29d474a503f5ca80405c4c676c9
refs/heads/main
2023-08-15T06:36:05.244293
2021-10-08T00:34:48
2021-10-08T00:34:48
350,923,064
0
0
MIT
2021-10-06T11:05:03
2021-03-24T02:35:36
C++
UTF-8
C++
false
false
3,053
cpp
Queen.cpp
#include "Queen.h" #include "../../Factory/FactoryManager.h" #include "../../Component/VelocityComponent.h" #include "../../Event/EventManager.h" #include "../../Event/EventReferenceTable.h" #include "../../Event/BridgeEvent.h" #include "../../Light/LightManager.h" #include "../../Component/BillboardComponent.h" ratchet::actor::character::Queen::Queen() : super(), _event_activated(false), _light_pillar() { } ratchet::actor::character::Queen::~Queen() { } bool ratchet::actor::character::Queen::Initialize(ratchet::actor::Actor::Param* param) { super::Initialize(param); auto shadow_param = Actor::Param(); shadow_param.name = "shadow"; _shadow_child_actor = ratchet::factory::FactoryManager::Singleton().CreateActor<ratchet::actor::Actor>("builder/shadow.json", &shadow_param); if (auto light = event::EventReferenceTable::Singleton().Get < std::shared_ptr < ratchet::light::LightManager> >("LightManager")) { auto info = light::LightPillarCreateInfo(); auto pos = super::GetPosition(); auto rotate = super::GetRotate(); float offset = 3.0f; auto front = Mof::CVector3(-math::vec3::kUnitZ * offset); front.RotationY(rotate.y - math::kHalfPi); pos.y -= 10.0f; pos += front; info.position = pos; _light_pillar = light->CreateLightPillar(info); } // if return true; } bool ratchet::actor::character::Queen::Update(float delta_time) { super::Update(delta_time); return true; } bool ratchet::actor::character::Queen::Render(void) { super::Render(); if (_shadow_child_actor) { _shadow_child_actor->SetPosition(super::GetPosition()); _shadow_child_actor->Render(); } // if return false; } void ratchet::actor::character::Queen::Talk(void) { // auto player = _player.lock(); auto billboard = super::GetComponent<component::BillboardComponent>(); auto dir = Mof::CVector3(super::GetPosition() - super::GetTalkedTarget()->GetPosition()); float angle_y = std::atan2f(-dir.z, dir.x) + math::kHalfPi; super::SetRotate(Mof::CVector3(0.0f, angle_y, 0.0f)); billboard->SetOffsetRotation(-super::GetRotate()); billboard->Inactivate(); auto message = ratchet::game::gamesystem::text::TextSystemMessage(); if (_event_activated) { message.type = decltype(message.type)::QueenFreeTalkTextEvent; super::GetTextSystemMessageSubject()->Notify(message); } // if else { message.type = decltype(message.type)::QueenTextEvent; message.on_close = [&]() { if (auto e = event::EventReferenceTable::Singleton().Get<std::shared_ptr<event::EventManager> >("EventManager")) { auto bridge_event = e->CreateGameEvent<event::BridgeEvent>(); bridge_event->Initialize(); _light_pillar.lock()->Disable(); } // if return true; }; super::GetTextSystemMessageSubject()->Notify(message); _event_activated = true; } // else }
15547f9b0091d06b9b1bd87a49d6745a00a249e8
42ac9b9a5cb115a07d138f5307bf4af486e83571
/OpenGl barebone/src/cpp/main.cpp
b4f81fbe218ea64c659505f2df35913005e0d0e8
[ "Apache-2.0" ]
permissive
Alexandre-1Briere/OpenGlWrapper
24fd0b46f6a14bde9dc26918e8019cb20d2cdfd7
46ede9ad9744efcf8e0af21244672a672241653f
refs/heads/master
2022-12-04T10:28:41.432351
2020-08-26T20:34:24
2020-08-26T20:34:24
290,358,831
0
0
null
null
null
null
UTF-8
C++
false
false
754
cpp
main.cpp
#include <window.h> #include <iostream> int main(void) { window windowController; GLFWwindow* window; if (!glfwInit()) return -1; window = glfwCreateWindow(WINDOW_WIDTH, WINDOW_HEIGHT, WINDOW_NAME, NULL, NULL); if (!window) { glfwTerminate(); return -1; } glfwMakeContextCurrent(window); GLenum err = glewInit(); if (GLEW_OK != err) { LogMessage::critical("GlewInit failed"); } windowController.start(); while (!glfwWindowShouldClose(window)) { glClear(GL_COLOR_BUFFER_BIT); windowController.update(); glfwSwapBuffers(window); glfwPollEvents(); } windowController.end(); glfwTerminate(); return 0; }
6ad40864bb14d82d545ed6dc39c5b9d12ad31907
ec0aed816cd18ac00c1bffe5fa594f9f0ffeabb6
/两个栈实现一个队列.cpp
0a9cdc9c1baec71156d3465f4ac223c7a398f0ea
[]
no_license
YangShiXiong/learn
f132284845bc3072c5e17e6ed021656950089739
708176f72325e9fd65c62e66874bdc0c3b70f4b7
refs/heads/master
2020-06-22T22:26:15.370421
2019-07-25T09:08:57
2019-07-25T09:08:57
198,416,337
0
0
null
null
null
null
GB18030
C++
false
false
708
cpp
两个栈实现一个队列.cpp
#include<iostream> #include<stack> using namespace std; class Solution{ public: //两次反转等于不反转 int Achieve(stack<int>& s1,stack<int>& s2){ //初始化元素2,1 s1.push(1); s1.push(2);//插入s1栈中,反转一次 if(s2.empty()){ while(!s1.empty()){ s2.push(s1.top());//插入s2中再反转一次 s1.pop(); } } //输出结果 for(int i=0;i<=s2.size();i++){ int a=s2.top(); s2.pop(); cout<<a<<" "; } } }; int main(){ stack<int> s1; stack<int> s2; Solution p; p.Achieve(s1,s2); }
a427e42973313414eb1984f1563b155d44369581
7b0bf562eca9f4bbccf2aedaa7788d4787888cb8
/assignment08/huffman_backup.cpp
f85e77db3f37764e254b2b2714bf16fa9ab06b66
[]
no_license
Sirrine-Jonathan/Data-Structures
aea18afddfe097b78815cf6971fb45b8644f4f05
c1e50f4adc01ac78b6ce1493904913c5a512c3a8
refs/heads/master
2020-03-11T04:21:55.455139
2018-04-16T16:39:22
2018-04-16T16:39:22
129,774,660
0
2
null
null
null
null
UTF-8
C++
false
false
1,802
cpp
huffman_backup.cpp
#include "huffman.h" #include <string> #include "pair.h" #include "bnode.h" #include "node.h" using namespace std; void huffman(string fileName) { ifstream inputFile(fileName.c_str()); //BNode <custom::pair <string, float> > * nHead; Node <custom::pair <float, string> > * hNodePtr = NULL; // put pairs from file into a linked list while(!inputFile.eof()) { // build pair from the data in the current line string s; float f; inputFile >> s >> f; custom::pair <string, float> linePair(f, s); // build a new node //Node <custom::pair <string, float> > n(linePair); //if no list started, make the first node the head if (hNodePtr == NULL) hNodePtr = nHead.insert(NULL, linePair); //traverse list setting the compare to the next node to be compared Node <custom::pair <float, string> > * cNodePtr = hNodePtr; bool addToRight = false; while (cNodePtr != NULL && cNodePtr->data < linePair) { //compare next node if (cNodePtr->pNext != NULL) cNodePtr = cNodePtr->pNext; else { addToRight = true; return; } } //place new node in ordered position insert(cNodePtr, linePair, addToRight); } cout << "finished making sorted list\n"; //list sorted // test node orde Node <custom::pair <float, string> > * lNodePtr = hNodePtr->next; while (lNodePtr != NULL){ cout << lNodePtr->data cout << endl; lNodePtr = hNodePtr->next; } /* for(list<int> :: iterator it = nextList.begin(); it != nextList.end(); ++it) { if(*it != nextList.back()) { cout << *it << ","; } else { cout << *it << endl; } } */ }
20a542dbeac7af1883f8e5f86c14bbba72a87017
c130fc29c48af4b36bc0c51ea9135e1660e9c318
/API_GAME/my_lib/19_0_EffectC.cpp
1c5c6e84eb2df3f5e6361593132cbf4a480bb3e9
[]
no_license
kimisaak0/indi_project
74ba40bb08317a910c8595efa6901120ee31eeca
24a5adf6ad4eca30fc8ff5aec85813a089af3831
refs/heads/master
2020-03-25T17:24:50.839546
2018-10-25T14:07:46
2018-10-25T14:07:46
143,976,532
0
0
null
null
null
null
UTF-8
C++
false
false
454
cpp
19_0_EffectC.cpp
#include "19_0_EffectC.h" void EffectC::PlayPos(double x, double y) { m_ptPosition.x = x; m_ptPosition.y = y; m_ptDrawPosition.x = m_ptPosition.x + (m_rtDraw.right / 2); m_ptDrawPosition.y = m_ptPosition.y + (m_rtDraw.bottom / 2); } bool EffectC::Init() { return true; } bool EffectC::Frame() { return true; } bool EffectC::Render() { return true; } bool EffectC::Release() { return true; } bool EffectC::getExist() { return m_bExist; }
9c29aa7a0a98c98e957822e35411d77b7c25e36d
8700fa500c760a8049c65df590632783cd64940a
/bookopencv/ch3_ex3_19.cpp
b1384b0b23eab669980c2dcbf4d2828dc93c6e4e
[ "MIT" ]
permissive
SrikanthParsha14/test
8ebac746f31d450b39eca1001525961497d962ba
8cee69e09c8557d53d8d30382cec8ea5c1f82f6e
refs/heads/master
2020-06-05T06:54:36.274446
2017-08-03T08:39:43
2017-08-03T08:39:43
192,351,172
1
0
MIT
2019-06-17T13:20:39
2019-06-17T13:20:38
null
UTF-8
C++
false
false
1,624
cpp
ch3_ex3_19.cpp
/* License: Oct. 3, 2008 Right to use this code in any way you want without warrenty, support or any guarentee of it working. BOOK: It would be nice if you cited it: Learning OpenCV: Computer Vision with the OpenCV Library by Gary Bradski and Adrian Kaehler Published by O'Reilly Media, October 3, 2008 AVAILABLE AT: http://www.amazon.com/Learning-OpenCV-Computer-Vision-Library/dp/0596516134 Or: http://oreilly.com/catalog/9780596516130/ ISBN-10: 0596516134 or: ISBN-13: 978-0596516130 OTHER OPENCV SITES: * The source code is on sourceforge at: http://sourceforge.net/projects/opencvlibrary/ * The OpenCV wiki page (As of Oct 1, 2008 this is down for changing over servers, but should come back): http://opencvlibrary.sourceforge.net/ * An active user group is at: http://tech.groups.yahoo.com/group/OpenCV/ * The minutes of weekly OpenCV development meetings are at: http://pr.willowgarage.com/wiki/OpenCV */ #include <cv.h> #include <highgui.h> #include <stdio.h> int main(int argc, char** argv) { printf("Example 3_19 Reading in cfg.xml\n"); CvFileStorage* fs = cvOpenFileStorage("cfg.xml", 0, CV_STORAGE_READ); int frame_count = cvReadIntByName(fs, 0, "frame_count", 5 /* default value */ ); CvSeq* s = cvGetFileNodeByName(fs, 0, "frame_size")->data.seq; int frame_width = cvReadInt((CvFileNode*) cvGetSeqElem(s, 0)); int frame_height = cvReadInt((CvFileNode*) cvGetSeqElem(s, 1)); CvMat* color_cvt_matrix = (CvMat*) cvRead(fs, 0); printf("frame_count=%d, frame_width=%d, frame_height=%d\n", frame_count, frame_width, frame_height); cvReleaseFileStorage(&fs); return 0; }
a4440f346379b4ea65e2213e1c974f7b69d473f5
9d52500bc05ddf70a26d183c3a8aba2ad2d3d05b
/gridWorld/src/rl/q_learning.hpp
bfd8cf66da51f3fa794638548ad655179a8ac2b6
[ "MIT" ]
permissive
corno93/self-balancing-robot-using-RL
b04c05297a786f84e6b61ff3f068f7b9d57c3240
24a52e141f20aee0279a4c0a47a4ca738612cc08
refs/heads/master
2021-03-27T15:10:11.265617
2019-02-05T03:19:25
2019-02-05T03:19:25
96,851,488
3
2
null
null
null
null
UTF-8
C++
false
false
424
hpp
q_learning.hpp
/** Q-Learning class declaration @author Alex Cornelio */ #ifndef Q_LEARNING_H #define Q_LEARNING_H #include "rl.hpp" #include <iostream> #include <stdlib.h> #include <cmath> class q_learning : public reinforcement_learning { public: q_learning();//float ep); ~q_learning(); char choose_action(float epsilon, std::vector<bool> available_actions, std::vector<float> state_row); }; #endif // Q_LEARNING_H
b769d2ccdf269c5cc562bdc6acceebdf56f244ef
9777c2fc0b3f1032f2fb367eda5bf3c2bb49e109
/GradientDomainBlending/PoissonSolver.h
dce31db75378ddd2a05b8b0dfa32b7b6a22d9d4b
[]
no_license
SingleZombie/Gradient-Domain-Image-Processing-Cpp
6725b82d24564a1199d696e7e30c781c37f9ed48
80eaa0fd8511946fae41036ddef55f971b205b80
refs/heads/master
2023-05-08T01:22:28.221698
2021-06-02T10:15:40
2021-06-02T10:15:40
356,269,829
0
0
null
null
null
null
UTF-8
C++
false
false
622
h
PoissonSolver.h
#ifndef POISSON_SOLVER_H #define POISSON_SOLVER_H #include <Eigen/Core> #include <Eigen/Sparse> #include <opencv2/imgproc/imgproc.hpp> #include <opencv2/core/core.hpp> #include "ImageUtil.h" class PoissonSolver { public: static void getFactorMatrixAndEdgeTerm( // Input const ImageRegion& region, int dstLeft, int dstTop, const cv::Mat& dstMat, // Output Eigen::SparseMatrix<float>& factor, Eigen::VectorXf& edgeTerm); static Eigen::VectorXf solvePoissonEquation( const Eigen::SparseMatrix<float>& lhs, const Eigen::VectorXf& rhs); private: PoissonSolver() { } }; #endif // !POSSION_SOLVER_H
e2d396ec9d06363ea8accf8a879719dbda16880f
5dfa881776b02b0158f3413ec6d06d95c6bb2dee
/1075链表元素分类/main.cpp
9e9bd8df85efa83b708996e0ca050e2103dbbad5
[]
no_license
Esrappelt/PAT-BasicLevel
17880f041e852c1e664a77b432ce50f332055e21
91cc087f8ab46784da99ab4d638100088a99610d
refs/heads/master
2020-04-05T11:26:40.354587
2019-03-14T02:44:15
2019-03-14T02:44:15
156,835,017
1
0
null
null
null
null
GB18030
C++
false
false
2,800
cpp
main.cpp
#include <cstdio> #include <cmath> #include <iostream> #include <algorithm> #include <queue> #include <stack> #include <list> #include <vector> #include <malloc.h> #include <memory.h> using namespace std; struct element{ int address; int data; int nextaddress; }; int main() { int N,K,adr,i,j,first; vector<int> a(100000),next(100000); scanf("%05d%d%d",&first,&N,&K);//N是整数,K是基准,first是首地址 int tmp = first; vector<element> ans(N); for(i = 0; i < N; ++i) { scanf("%05d",&adr); scanf("%d %05d",&a[adr],&next[adr]);//a数组装的是adr这个地址的值,b数组装的是这个值的下一个地址 } if(N == 1) { printf("%05d %d -1\n",first,a[first]); return 0; } int temp = tmp,index = 0; for(j = 1; j <= 3; ++j) { temp = tmp; while(temp != -1) { if(a[temp] < 0 && j == 1) { ans[index].data = a[temp]; ans[index].address = temp; index++; } else if(j == 2 && a[temp] >= 0 && a[temp] <= K) { ans[index].data = a[temp]; ans[index].address = temp; index++; } else if(j == 3 && a[temp] > K) { ans[index].data = a[temp]; ans[index].address = temp; index++; } temp = next[temp]; } } for(i = 0; i < index; ++i) { if(i < index - 1) printf("%05d %d %05d\n",ans[i].address,ans[i].data,ans[i+1].address); else printf("%05d %d %d\n",ans[i].address,ans[i].data,-1); } return 0; } /* 输入格式: 每个输入包含1个测试用例。 每个测试用例第1行给出:第1个结点的地址;结点总个数,即正整数N (<= 105);以及正整数K (<=1000)。 结点的地址是5位非负整数,NULL地址用-1表示。 接下来有N行,每行格式为: Address Data Next 其中Address是结点地址;Data是该结点保存的数据,为[-105, 105]区间内的整数;Next是下一结点的地址。题目保证给出的链表不为空。 输出格式: 对每个测试用例,按链表从头到尾的顺序输出重排后的结果链表,其上每个结点占一行,格式与输入相同。 输入样例: 00100 9 10 23333 10 27777 00000 0 99999 00100 18 12309 68237 -6 23333 33218 -4 00000 48652 -2 -1 99999 5 68237 27777 11 48652 12309 7 33218 输出样例: 33218 -4 68237 68237 -6 48652 48652 -2 12309 12309 7 00000 00000 0 99999 99999 5 23333 23333 10 00100 00100 18 27777 27777 11 -1 */
e42ec6956d70618f9d6be918eaa9db1ec3b7e894
37cca16f12e7b1d4d01d6f234da6d568c318abee
/src/rice/environment/params/simple/ParamsNotPresentException.cpp
140f454cc2859207135131f123860ea4060de020
[]
no_license
subhash1-0/thirstyCrow
e48155ce68fc886f2ee8e7802567c1149bc54206
78b7e4e3d2b9a9530ad7d66b44eacfe73ceea582
refs/heads/master
2016-09-06T21:25:54.075724
2015-09-21T17:21:15
2015-09-21T17:21:15
42,881,521
0
0
null
null
null
null
UTF-8
C++
false
false
1,942
cpp
ParamsNotPresentException.cpp
// Generated from /pastry-2.1/src/rice/environment/params/simple/ParamsNotPresentException.java #include <rice/environment/params/simple/ParamsNotPresentException.hpp> #include <java/lang/Exception.hpp> #include <java/lang/NullPointerException.hpp> template<typename T> static T* npc(T* t) { if(!t) throw new ::java::lang::NullPointerException(); return t; } rice::environment::params::simple::ParamsNotPresentException::ParamsNotPresentException(const ::default_init_tag&) : super(*static_cast< ::default_init_tag* >(0)) { clinit(); } rice::environment::params::simple::ParamsNotPresentException::ParamsNotPresentException(::java::lang::String* reason, ::java::lang::Exception* e) : ParamsNotPresentException(*static_cast< ::default_init_tag* >(0)) { ctor(reason,e); } void rice::environment::params::simple::ParamsNotPresentException::ctor(::java::lang::String* reason, ::java::lang::Exception* e) { super::ctor(reason); this->subexception = e; } void rice::environment::params::simple::ParamsNotPresentException::printStackTrace(::java::io::PrintStream* arg0) { super::printStackTrace(arg0); npc(subexception)->printStackTrace(arg0); } void rice::environment::params::simple::ParamsNotPresentException::printStackTrace() { super::printStackTrace(); npc(subexception)->printStackTrace(); } void rice::environment::params::simple::ParamsNotPresentException::printStackTrace(::java::io::PrintWriter* pw) { super::printStackTrace(pw); npc(subexception)->printStackTrace(pw); } extern java::lang::Class *class_(const char16_t *c, int n); java::lang::Class* rice::environment::params::simple::ParamsNotPresentException::class_() { static ::java::lang::Class* c = ::class_(u"rice.environment.params.simple.ParamsNotPresentException", 56); return c; } java::lang::Class* rice::environment::params::simple::ParamsNotPresentException::getClass0() { return class_(); }
f4da0692480458d85963b627871ea045a15f88a1
4bea57e631734f8cb1c230f521fd523a63c1ff23
/projects/openfoam/rarefied-flows/impingment/sims/templates/compressible/rhoCentralFoam/wedge15Ma5/0.08/U
16fe8b82510bd0dc0a45a48bb4491fdacd133dbf
[]
no_license
andytorrestb/cfal
76217f77dd43474f6b0a7eb430887e8775b78d7f
730fb66a3070ccb3e0c52c03417e3b09140f3605
refs/heads/master
2023-07-04T01:22:01.990628
2021-08-01T15:36:17
2021-08-01T15:36:17
294,183,829
1
0
null
null
null
null
UTF-8
C++
false
false
179,151
U
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: v1912 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volVectorField; location "0.08"; object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 1 -1 0 0 0 0]; internalField nonuniform List<vector> 9600 ( (3 3.37376e-17 0) (3 1.68688e-18 0) (3 -1.68688e-17 0) (3 -1.68688e-18 0) (3 -3.20507e-17 0) (3 -2.53032e-17 0) (3 -1.68688e-17 0) (3 -5.06063e-18 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -5.39801e-17 0) (3 -5.06063e-17 0) (3 -4.55457e-17 0) (3 -3.87982e-17 0) (3 -3.20507e-17 0) (3 -2.69901e-17 0) (3 -1.85557e-17 0) (3 -1.18081e-17 0) (3 4.04851e-17 0) (3 9.27783e-17 0) (3 1.58567e-16 0) (3 1.8893e-16 0) (3 1.77122e-16 0) (3 1.82183e-16 0) (3 1.75435e-16 0) (3 1.67001e-16 0) (3 2.19294e-16 0) (3 2.1086e-16 0) (3 2.17607e-16 0) (3 2.34476e-16 0) (3 2.09173e-16 0) (3 2.00739e-16 0) (3 1.73748e-16 0) (3 0 0) (3 -4.04851e-17 0) (3 -3.71113e-17 0) (3 -3.37376e-17 0) (3 -5.90407e-17 0) (3 -1.48445e-16 0) (3 3.20507e-17 0) (3 1.3495e-17 0) (3 8.43439e-18 0) (3 1.18081e-17 0) (3 1.3495e-17 0) (3 1.01213e-17 0) (3 -1.18081e-17 0) (3 4.72326e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 2.86769e-17 0) (3 3.37376e-18 0) (3 -2.86769e-17 0) (3 -5.22932e-17 0) (3 -5.73539e-17 0) (3 -1.18081e-17 0) (3 -1.68688e-17 0) (3 -1.68688e-17 0) (3 -1.51819e-17 0) (3 -1.68688e-17 0) (3 -3.37376e-17 0) (3 -5.06063e-17 0) (3 -5.5667e-17 0) (3 -6.74751e-17 0) (3 -5.73539e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -2.69901e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 -1.68688e-18 0) (3 -1.07629e-16 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -7.92833e-17 0) (3 -1.63627e-16 0) (3 -1.43385e-16 0) (3 -1.48445e-16 0) (3 -1.40011e-16 0) (3 -1.63627e-16 0) (3 -1.5688e-16 0) (3 -1.41698e-16 0) (3 -1.38324e-16 0) (3 -1.38324e-16 0) (3 -1.73748e-16 0) (3 -1.6194e-16 0) (3 -2.02425e-16 0) (3 -1.82183e-16 0) (3 -1.80496e-16 0) (3 -1.70375e-16 0) (3 -1.46758e-16 0) (3 -1.43385e-16 0) (3 -1.40011e-16 0) (3 -1.85557e-16 0) (3 -2.3785e-16 0) (3 -3.07012e-16 0) (3 -2.96891e-16 0) (3 -2.93517e-16 0) (3 -2.9183e-16 0) (3 -2.44597e-16 0) (3 -2.31102e-16 0) (3 -2.39537e-16 0) (3 -2.26042e-16 0) (3 -2.88456e-16 0) (3 -2.59779e-16 0) (3 -2.36163e-16 0) (3 -2.3785e-16 0) (3 -3.80598e-16 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -1.18081e-16 0) (3 -1.31577e-16 0) (3 -1.78809e-16 0) (3 -2.27729e-16 0) (3 -2.02425e-16 0) (3 -2.04112e-16 0) (3 -2.54719e-16 0) (3 -2.32789e-16 0) (3 -1.6194e-16 0) (3 -2.24355e-16 0) (3 -2.04112e-16 0) (3 -2.27729e-16 0) (3 -2.90143e-16 0) (3 -2.04112e-16 0) (3 -2.47971e-16 0) (3 -2.12547e-16 0) (3 -6.74751e-17 0) (3 -1.60253e-16 0) (3 -7.75964e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -9.78389e-17 0) (3 -8.43439e-17 0) (3 -7.25358e-17 0) (3 -7.08489e-17 0) (3 -5.90407e-17 0) (3 -5.5667e-17 0) (3 -5.5667e-17 0) (3 -4.55457e-17 0) (3 -7.59095e-17 0) (3 -1.18081e-16 0) (3 -1.06273e-16 0) (3 -7.59095e-17 0) (3 -2.86287e-16 0) (3 0 0) (3 0 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 3.37376e-17 0) (3 1.68688e-17 0) (3 2.86769e-17 0) (3 1.68688e-17 0) (3 -1.18081e-17 0) (3 -2.69901e-17 0) (3 -3.87982e-17 0) (3 -8.43439e-18 0) (3 -2.36163e-17 0) (3 3.20507e-17 0) (3 2.02425e-17 0) (3 -1.18081e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 5.06063e-18 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -1.01213e-16 0) (3 1.18081e-17 0) (3 2.19294e-17 0) (3 7.25358e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 3.20507e-17 0) (3 9.61521e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 7.25358e-17 0) (3 1.26516e-16 0) (3 1.92304e-16 0) (3 3.89669e-16 0) (3 1.11024e-16 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 1.18081e-16 0) (3 1.06273e-16 0) (3 1.01213e-16 0) (3 9.95258e-17 0) (3 9.78389e-17 0) (3 1.45072e-16 0) (3 2.04112e-16 0) (3 1.93991e-16 0) (3 1.19768e-16 0) (3 1.18081e-16 0) (3 1.18081e-16 0) (3 1.5688e-16 0) (3 2.24355e-16 0) (3 1.80496e-16 0) (3 2.24355e-16 0) (3 1.73748e-16 0) (3 5.39801e-17 0) (3 1.16395e-16 0) (3 7.42226e-17 0) (3 1.14708e-16 0) (3 1.63627e-16 0) (3 1.3495e-16 0) (3 9.78389e-17 0) (3 9.61521e-17 0) (3 7.92833e-17 0) (3 7.75964e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 8.60308e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 1.38324e-16 0) (3 1.14708e-16 0) (3 1.16395e-16 0) (3 1.55605e-16 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -1.18081e-17 0) (3 2.02425e-17 0) (3 4.04851e-17 0) (3 6.74751e-17 0) (3 5.5667e-17 0) (3 5.5667e-17 0) (3 1.18081e-17 0) (3 2.69901e-17 0) (3 5.39801e-17 0) (3 -6.74751e-18 0) (3 1.85557e-17 0) (3 3.03638e-17 0) (3 3.37376e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 -8.43439e-18 0) (3 -2.19294e-17 0) (3 -4.04851e-17 0) (3 -5.22932e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 5.22932e-17 0) (3 -1.01213e-17 0) (3 3.20507e-17 0) (3 2.19294e-17 0) (3 -4.2172e-17 0) (3 -1.0796e-16 0) (3 -1.6194e-16 0) (3 -1.40011e-16 0) (3 -2.11696e-16 0) (3 0 0) (3 0 0) (3 0 0) (3 6.74751e-18 0) (3 5.39801e-17 0) (3 6.74751e-17 0) (3 1.18081e-16 0) (3 1.18081e-16 0) (3 1.18081e-16 0) (3 5.73539e-17 0) (3 6.24145e-17 0) (3 7.59095e-17 0) (3 8.77177e-17 0) (3 1.46758e-16 0) (3 2.26042e-16 0) (3 2.12547e-16 0) (3 1.19768e-16 0) (3 1.82183e-16 0) (3 1.80496e-16 0) (3 1.80496e-16 0) (3 1.80496e-16 0) (3 1.40011e-16 0) (3 1.38324e-16 0) (3 1.13021e-16 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 2.02425e-17 0) (3 -3.37376e-18 0) (3 5.22932e-17 0) (3 -3.20507e-17 0) (3 -1.3495e-17 0) (3 1.18081e-17 0) (3 2.19294e-17 0) (3 5.5667e-17 0) (3 9.61521e-17 0) (3 8.2657e-17 0) (3 6.57883e-17 0) (3 2.01656e-16 0) (3 0 0) (3 0 0) (3 4.38588e-17 0) (3 1.41698e-16 0) (3 1.23142e-16 0) (3 1.09647e-16 0) (3 9.78389e-17 0) (3 1.31577e-16 0) (3 2.68214e-16 0) (3 2.36163e-16 0) (3 2.07486e-16 0) (3 2.93517e-16 0) (3 2.24355e-16 0) (3 2.49658e-16 0) (3 2.26042e-16 0) (3 2.07486e-16 0) (3 2.66527e-16 0) (3 2.47971e-16 0) (3 2.31102e-16 0) (3 2.1592e-16 0) (3 1.80496e-16 0) (3 1.55193e-16 0) (3 1.18081e-16 0) (3 1.40011e-16 0) (3 1.40011e-16 0) (3 1.40011e-16 0) (3 1.5688e-16 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.58567e-16 0) (3 2.24355e-16 0) (3 2.22668e-16 0) (3 2.90143e-16 0) (3 2.14234e-16 0) (3 1.82183e-16 0) (3 2.04112e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 2.00396e-16 0) (3 0 0) (3 0 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 -6.74751e-18 0) (3 -8.43439e-18 0) (3 -5.22932e-17 0) (3 -3.87982e-17 0) (3 3.20507e-17 0) (3 3.03638e-17 0) (3 3.37376e-17 0) (3 5.5667e-17 0) (3 5.5667e-17 0) (3 3.20507e-17 0) (3 -6.57883e-17 0) (3 -3.20507e-17 0) (3 -1.3495e-17 0) (3 -5.06063e-17 0) (3 -1.38324e-16 0) (3 -1.18081e-16 0) (3 -1.04586e-16 0) (3 -1.51819e-17 0) (3 -6.74751e-18 0) (3 -2.53032e-17 0) (3 -3.20507e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 6.41014e-17 0) (3 1.68688e-16 0) (3 1.31577e-16 0) (3 1.58567e-16 0) (3 1.63627e-16 0) (3 1.6194e-16 0) (3 2.26042e-16 0) (3 1.5688e-16 0) (3 7.25358e-17 0) (3 1.38324e-16 0) (3 1.28203e-16 0) (3 9.7312e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -3.20507e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.0796e-16 0) (3 -2.02425e-16 0) (3 -1.82183e-16 0) (3 -1.82183e-16 0) (3 -2.41224e-16 0) (3 -2.46284e-16 0) (3 -2.32789e-16 0) (3 -2.04112e-16 0) (3 -2.14234e-16 0) (3 -2.74961e-16 0) (3 -2.61466e-16 0) (3 -1.82183e-16 0) (3 -1.93991e-16 0) (3 -2.17607e-16 0) (3 -2.26042e-16 0) (3 -2.26042e-16 0) (3 -1.77122e-16 0) (3 -1.55193e-16 0) (3 -8.09702e-17 0) (3 -7.75964e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -5.39801e-17 0) (3 -1.01213e-16 0) (3 -1.85557e-16 0) (3 -1.60253e-16 0) (3 -1.73748e-16 0) (3 -1.55193e-16 0) (3 -9.27783e-17 0) (3 8.43439e-18 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -5.97167e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 -5.06063e-18 0) (3 -1.01213e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 -4.89195e-17 0) (3 -4.2172e-17 0) (3 -3.37376e-17 0) (3 -1.14708e-16 0) (3 -9.61521e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -7.42226e-17 0) (3 -9.44652e-17 0) (3 -9.44652e-17 0) (3 -9.61521e-17 0) (3 -8.2657e-17 0) (3 -5.39801e-17 0) (3 -1.16395e-16 0) (3 -9.95258e-17 0) (3 -9.61521e-17 0) (3 -3.03638e-17 0) (3 -9.61521e-17 0) (3 -9.10914e-17 0) (3 -7.59095e-17 0) (3 -1.14708e-16 0) (3 -2.04112e-16 0) (3 -1.82183e-16 0) (3 -2.04112e-16 0) (3 -1.63627e-16 0) (3 -1.029e-16 0) (3 -2.04112e-16 0) (3 -1.63627e-16 0) (3 -1.6194e-16 0) (3 -2.3785e-16 0) (3 -1.90617e-16 0) (3 -1.1985e-16 0) (3 0 0) (3 2.19294e-17 0) (3 -4.55457e-17 0) (3 -8.94045e-17 0) (3 -5.06063e-17 0) (3 -4.2172e-17 0) (3 1.01213e-17 0) (3 -5.39801e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 -1.18081e-17 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -7.42226e-17 0) (3 -6.07276e-17 0) (3 -3.71113e-17 0) (3 -3.37376e-17 0) (3 -1.01213e-17 0) (3 -5.22932e-17 0) (3 -3.37376e-17 0) (3 -1.01213e-17 0) (3 -5.39801e-17 0) (3 -3.20507e-17 0) (3 -7.08489e-17 0) (3 -7.42226e-17 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -6.24145e-17 0) (3 -5.39801e-17 0) (3 -1.11334e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -9.95258e-17 0) (3 -1.60253e-16 0) (3 -1.18081e-16 0) (3 -8.94045e-17 0) (3 -5.92386e-17 0) (3 0 0) (3 0 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 2.86769e-17 0) (3 5.39801e-17 0) (3 1.18081e-16 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.3495e-16 0) (3 1.90617e-16 0) (3 1.60253e-16 0) (3 1.38324e-16 0) (3 1.80496e-16 0) (3 2.22668e-16 0) (3 2.1086e-16 0) (3 1.80496e-16 0) (3 1.67001e-16 0) (3 1.50132e-16 0) (3 1.19768e-16 0) (3 3.87982e-17 0) (3 1.28662e-31 0) (3 7.59095e-17 0) (3 7.75964e-17 0) (3 7.75964e-17 0) (3 7.75964e-17 0) (3 7.75964e-17 0) (3 7.75964e-17 0) (3 3.54244e-17 0) (3 -2.69901e-17 0) (3 7.25358e-17 0) (3 7.25358e-17 0) (3 1.19768e-16 0) (3 1.06273e-16 0) (3 4.55457e-17 0) (3 -4.6751e-17 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 1.18081e-17 0) (3 1.3495e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -2.86769e-17 0) (3 -1.18081e-17 0) (3 -8.43439e-18 0) (3 -1.01213e-17 0) (3 -1.68688e-18 0) (3 1.18081e-17 0) (3 2.02425e-17 0) (3 1.18081e-17 0) (3 3.37376e-17 0) (3 5.22932e-17 0) (3 3.54244e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.99052e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 1.41698e-16 0) (3 1.41698e-16 0) (3 1.40011e-16 0) (3 1.38324e-16 0) (3 1.19768e-16 0) (3 7.42226e-17 0) (3 1.18081e-16 0) (3 1.0796e-16 0) (3 8.60308e-17 0) (3 7.18088e-17 0) (3 -1.18081e-17 0) (3 7.92833e-17 0) (3 1.18081e-17 0) (3 8.94045e-17 0) (3 5.39801e-17 0) (3 1.38324e-16 0) (3 9.78389e-17 0) (3 3.37376e-17 0) (3 5.5667e-17 0) (3 5.90407e-17 0) (3 6.41014e-17 0) (3 5.90407e-17 0) (3 5.73539e-17 0) (3 1.01213e-17 0) (3 2.19294e-17 0) (3 1.68688e-17 0) (3 1.51819e-17 0) (3 -3.37376e-17 0) (3 -1.85557e-17 0) (3 1.01213e-17 0) (3 1.18081e-17 0) (3 3.37376e-17 0) (3 5.22932e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 1.72062e-16 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 1.40011e-16 0) (3 1.23142e-16 0) (3 1.18081e-16 0) (3 1.18081e-16 0) (3 9.95258e-17 0) (3 9.95258e-17 0) (3 6.07276e-17 0) (3 -3.20507e-17 0) (3 -5.22932e-17 0) (3 -4.04851e-17 0) (3 -2.19294e-17 0) (3 4.4801e-17 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 5.06063e-17 0) (3 3.20507e-17 0) (3 3.37376e-17 0) (3 1.11334e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.06273e-16 0) (3 1.06273e-16 0) (3 9.78389e-17 0) (3 1.40011e-16 0) (3 2.24355e-16 0) (3 1.95678e-16 0) (3 1.60253e-16 0) (3 1.6194e-16 0) (3 1.63627e-16 0) (3 1.8893e-16 0) (3 5.5667e-17 0) (3 5.90407e-17 0) (3 1.68688e-17 0) (3 1.68688e-17 0) (3 -5.22932e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -3.03638e-17 0) (3 -2.53032e-17 0) (3 4.34492e-32 0) (3 1.51819e-17 0) (3 1.51819e-17 0) (3 1.3495e-17 0) (3 -5.06063e-17 0) (3 -4.38588e-17 0) (3 -5.06063e-17 0) (3 -4.28523e-17 0) (3 1.18081e-17 0) (3 -5.22932e-17 0) (3 1.01213e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -1.63627e-16 0) (3 -9.78389e-17 0) (3 -5.90407e-17 0) (3 5.06063e-18 0) (3 2.19294e-17 0) (3 2.69901e-17 0) (3 9.10914e-17 0) (3 9.61521e-17 0) (3 1.60253e-16 0) (3 9.61521e-17 0) (3 9.44652e-17 0) (3 1.06273e-16 0) (3 1.16395e-16 0) (3 5.90407e-17 0) (3 5.39801e-17 0) (3 6.24145e-17 0) (3 9.10914e-17 0) (3 9.27783e-17 0) (3 1.40011e-16 0) (3 1.16395e-16 0) (3 6.07276e-17 0) (3 7.25358e-17 0) (3 1.38324e-16 0) (3 7.59095e-17 0) (3 9.61521e-17 0) (3 7.92833e-17 0) (3 1.28203e-16 0) (3 2.1086e-16 0) (3 2.05799e-16 0) (3 1.99052e-16 0) (3 1.90617e-16 0) (3 1.60253e-16 0) (3 1.63627e-16 0) (3 1.48445e-16 0) (3 1.33286e-16 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -3.37376e-18 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.3495e-17 0) (3 -1.18081e-17 0) (3 -9.61521e-17 0) (3 -5.90407e-17 0) (3 5.06063e-18 0) (3 6.24145e-17 0) (3 1.40011e-16 0) (3 1.21455e-16 0) (3 1.2989e-16 0) (3 1.3495e-16 0) (3 1.36637e-16 0) (3 1.36637e-16 0) (3 1.8893e-16 0) (3 1.82183e-16 0) (3 1.80496e-16 0) (3 2.71587e-16 0) (3 2.58092e-16 0) (3 2.27729e-16 0) (3 2.26042e-16 0) (3 2.90143e-16 0) (3 2.76648e-16 0) (3 2.47971e-16 0) (3 2.78335e-16 0) (3 3.03638e-16 0) (3 3.20507e-16 0) (3 3.00264e-16 0) (3 2.81709e-16 0) (3 2.47971e-16 0) (3 3.10386e-16 0) (3 2.9183e-16 0) (3 2.9183e-16 0) (3 2.8667e-16 0) (3 6.9162e-17 0) (3 7.42226e-17 0) (3 1.01213e-17 0) (3 2.69901e-17 0) (3 3.54244e-17 0) (3 8.94045e-17 0) (3 6.07276e-17 0) (3 5.22932e-17 0) (3 -1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -3.37376e-17 0) (3 -4.04851e-17 0) (3 -9.61521e-17 0) (3 -8.2657e-17 0) (3 -6.57883e-17 0) (3 -1.01213e-17 0) (3 -8.43439e-18 0) (3 -1.01213e-17 0) (3 5.22932e-17 0) (3 4.2172e-17 0) (3 -3.20507e-17 0) (3 3.37376e-17 0) (3 -3.37376e-17 0) (3 8.43439e-18 0) (3 -3.37376e-18 0) (3 -6.74751e-18 0) (3 -5.22932e-17 0) (3 -4.04851e-17 0) (3 -2.19294e-17 0) (3 1.01213e-17 0) (3 -4.89195e-17 0) (3 -9.61521e-17 0) (3 -8.43439e-17 0) (3 -6.24145e-17 0) (3 -4.55457e-17 0) (3 -3.37376e-18 0) (3 1.85557e-17 0) (3 4.72326e-17 0) (3 4.98738e-17 0) (3 3.54244e-17 0) (3 9.10914e-17 0) (3 1.40011e-16 0) (3 2.24355e-16 0) (3 1.99052e-16 0) (3 2.46284e-16 0) (3 2.36163e-16 0) (3 1.99052e-16 0) (3 1.70375e-16 0) (3 1.5688e-16 0) (3 1.50132e-16 0) (3 1.0796e-16 0) (3 -1.01213e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -1.11334e-16 0) (3 -2.00739e-16 0) (3 -1.8893e-16 0) (3 -1.60253e-16 0) (3 -2.02425e-16 0) (3 -1.8893e-16 0) (3 -1.77122e-16 0) (3 -1.80496e-16 0) (3 -2.02425e-16 0) (3 -2.00739e-16 0) (3 -2.00739e-16 0) (3 -2.00739e-16 0) (3 -2.02425e-16 0) (3 -1.65314e-16 0) (3 -2.39537e-16 0) (3 -3.10386e-16 0) (3 -2.44597e-16 0) (3 -2.17607e-16 0) (3 -1.95678e-16 0) (3 -1.6194e-16 0) (3 -2.19294e-16 0) (3 -2.02425e-16 0) (3 -2.04112e-16 0) (3 -1.98578e-16 0) (3 -1.18081e-16 0) (3 -6.74751e-17 0) (3 -4.89195e-17 0) (3 1.68688e-18 0) (3 1.85557e-17 0) (3 6.9162e-17 0) (3 7.42226e-17 0) (3 1.3495e-17 0) (3 -3.35233e-32 0) (3 5.06063e-18 0) (3 8.43439e-18 0) (3 8.43439e-18 0) (3 8.43439e-18 0) (3 8.43439e-18 0) (3 2.86769e-17 0) (3 3.71113e-17 0) (3 -3.20507e-17 0) (3 -7.59095e-17 0) (3 1.51819e-17 0) (3 -1.14708e-16 0) (3 -1.16395e-16 0) (3 -2.19294e-17 0) (3 -1.73748e-16 0) (3 -7.75964e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -9.61521e-17 0) (3 -4.55457e-17 0) (3 -1.01213e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -5.73539e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -8.57263e-17 0) (3 -1.51819e-17 0) (3 -5.73539e-17 0) (3 -1.40011e-16 0) (3 -1.6194e-16 0) (3 -1.2989e-16 0) (3 -1.38324e-16 0) (3 -9.95258e-17 0) (3 -9.61521e-17 0) (3 -9.44652e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -9.44652e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -1.28203e-16 0) (3 -1.13021e-16 0) (3 -1.029e-16 0) (3 -9.95258e-17 0) (3 -1.13021e-16 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.14708e-16 0) (3 -4.2172e-17 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.38324e-16 0) (3 -7.92833e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 3.20507e-17 0) (3 -4.86397e-18 0) (3 5.73539e-17 0) (3 -5.22932e-17 0) (3 1.01213e-17 0) (3 -8.94045e-17 0) (3 -9.10914e-17 0) (3 -1.99052e-16 0) (3 -1.72062e-16 0) (3 -1.67001e-16 0) (3 -1.77122e-16 0) (3 -1.55193e-16 0) (3 -1.46758e-16 0) (3 -1.28203e-16 0) (3 -1.23142e-16 0) (3 -9.61521e-17 0) (3 -1.46758e-16 0) (3 -1.3495e-16 0) (3 -1.11334e-16 0) (3 -8.43439e-17 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.8893e-16 0) (3 -1.70375e-16 0) (3 -1.82183e-16 0) (3 -1.72062e-16 0) (3 -1.06273e-16 0) (3 -1.04586e-16 0) (3 -5.90407e-17 0) (3 -5.5667e-17 0) (3 -5.22932e-17 0) (3 -4.04851e-17 0) (3 2.36163e-17 0) (3 5.22932e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -8.43439e-18 0) (3 -2.69901e-17 0) (3 -3.03638e-17 0) (3 -3.20507e-17 0) (3 -2.46301e-17 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -3.37376e-17 0) (3 -1.01213e-17 0) (3 -3.37376e-17 0) (3 1.51819e-17 0) (3 1.3495e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 9.61521e-17 0) (3 8.43439e-17 0) (3 5.22932e-17 0) (3 1.16395e-16 0) (3 1.029e-16 0) (3 8.43439e-17 0) (3 5.5667e-17 0) (3 5.5667e-17 0) (3 3.20507e-17 0) (3 -5.06063e-17 0) (3 3.20507e-17 0) (3 1.51819e-17 0) (3 3.03638e-17 0) (3 3.37376e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.22932e-17 0) (3 1.18081e-16 0) (3 1.14708e-16 0) (3 5.90407e-17 0) (3 4.55457e-17 0) (3 -8.43439e-18 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -9.78389e-17 0) (3 -1.7161e-16 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 -1.01213e-17 0) (3 7.42226e-17 0) (3 7.42226e-17 0) (3 1.16395e-16 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 7.42226e-17 0) (3 4.89195e-17 0) (3 1.18081e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 1.40011e-16 0) (3 1.14708e-16 0) (3 1.60253e-16 0) (3 1.40011e-16 0) (3 1.41698e-16 0) (3 1.38324e-16 0) (3 1.51819e-16 0) (3 1.48445e-16 0) (3 1.09647e-16 0) (3 1.029e-16 0) (3 3.37376e-17 0) (3 8.2657e-17 0) (3 -3.03638e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -2.19294e-17 0) (3 -1.18081e-17 0) (3 -6.74751e-17 0) (3 -9.27783e-17 0) (3 -9.44652e-17 0) (3 -9.61521e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -7.13964e-17 0) (3 3.20507e-17 0) (3 1.38324e-16 0) (3 1.18081e-16 0) (3 1.6194e-16 0) (3 1.53506e-16 0) (3 1.6194e-16 0) (3 1.60253e-16 0) (3 1.01213e-16 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 -3.20507e-17 0) (3 2.86769e-17 0) (3 3.20507e-17 0) (3 -1.3495e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-18 0) (3 3.37376e-18 0) (3 -1.01213e-17 0) (3 6.74751e-18 0) (3 1.18081e-17 0) (3 -1.85557e-17 0) (3 -3.20507e-17 0) (3 1.01213e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 5.39801e-17 0) (3 1.09647e-16 0) (3 -3.71113e-17 0) (3 5.22932e-17 0) (3 3.37376e-17 0) (3 5.06063e-17 0) (3 5.39801e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 5.73539e-17 0) (3 4.96782e-17 0) (3 3.37376e-18 0) (3 0 0) (3 0 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -5.39801e-17 0) (3 -3.87982e-17 0) (3 -5.22932e-17 0) (3 -4.04851e-17 0) (3 -5.5667e-17 0) (3 -1.18081e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 3.54244e-17 0) (3 -9.44652e-17 0) (3 1.68688e-17 0) (3 -3.20507e-17 0) (3 -2.19294e-17 0) (3 -1.18081e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -8.43439e-18 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 9.61521e-17 0) (3 7.75964e-17 0) (3 7.59095e-17 0) (3 1.53506e-16 0) (3 1.38324e-16 0) (3 1.5688e-16 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.19939e-16 0) (3 -1.3495e-17 0) (3 -7.75964e-17 0) (3 -7.59095e-17 0) (3 -1.38324e-16 0) (3 -1.18081e-16 0) (3 -1.6194e-16 0) (3 -1.50132e-16 0) (3 -1.31577e-16 0) (3 -1.11334e-16 0) (3 -9.10914e-17 0) (3 -6.74751e-17 0) (3 -4.72326e-17 0) (3 -1.01213e-17 0) (3 1.01213e-17 0) (3 -5.22932e-17 0) (3 -4.2172e-17 0) (3 2.69901e-17 0) (3 2.53032e-17 0) (3 9.44652e-17 0) (3 9.78389e-17 0) (3 1.18081e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 5.22932e-17 0) (3 5.39801e-17 0) (3 5.5667e-17 0) (3 1.18081e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 3.87982e-17 0) (3 7.25358e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 9.27783e-17 0) (3 1.55193e-16 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.60694e-16 0) (3 -1.01213e-17 0) (3 5.06063e-17 0) (3 3.37376e-17 0) (3 9.61521e-17 0) (3 7.59095e-17 0) (3 1.18081e-16 0) (3 9.78389e-17 0) (3 1.3495e-16 0) (3 2.04112e-16 0) (3 1.82183e-16 0) (3 1.18081e-16 0) (3 9.61521e-17 0) (3 9.78389e-17 0) (3 1.3495e-16 0) (3 2.3785e-16 0) (3 2.19294e-16 0) (3 1.5688e-16 0) (3 1.33263e-16 0) (3 1.04586e-16 0) (3 9.44652e-17 0) (3 9.44652e-17 0) (3 9.44652e-17 0) (3 9.61521e-17 0) (3 8.94045e-17 0) (3 1.11334e-16 0) (3 7.59095e-17 0) (3 9.44652e-17 0) (3 9.61521e-17 0) (3 7.59095e-17 0) (3 9.61521e-17 0) (3 9.78389e-17 0) (3 1.53506e-16 0) (3 1.60253e-16 0) (3 9.95258e-17 0) (3 9.78389e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.10914e-17 0) (3 7.59095e-17 0) (3 9.72521e-17 0) (3 0 0) (3 0 0) (3 7.08489e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 6.07276e-17 0) (3 3.03638e-17 0) (3 8.43439e-17 0) (3 5.5667e-17 0) (3 5.39801e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -5.22932e-17 0) (3 5.73539e-17 0) (3 -1.01213e-17 0) (3 5.06063e-18 0) (3 -7.75964e-17 0) (3 -1.18081e-17 0) (3 -5.39801e-17 0) (3 -2.36163e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 4.55457e-17 0) (3 5.90407e-17 0) (3 1.18081e-17 0) (3 1.68688e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 -2.69901e-17 0) (3 -9.78389e-17 0) (3 -8.43439e-17 0) (3 -5.39801e-17 0) (3 -5.77066e-17 0) (3 0 0) (3 -6.24145e-17 0) (3 -4.38588e-17 0) (3 -3.87982e-17 0) (3 -3.37376e-17 0) (3 -7.25358e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -1.3495e-16 0) (3 -1.23142e-16 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -1.14708e-16 0) (3 -1.60253e-16 0) (3 -1.18081e-16 0) (3 -3.37376e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -5.06063e-18 0) (3 8.43439e-18 0) (3 2.53032e-17 0) (3 2.86769e-17 0) (3 9.61521e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 9.61521e-17 0) (3 -8.43439e-18 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 4.72326e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 4.28523e-17 0) (3 0 0) (3 6.24145e-17 0) (3 -1.16395e-16 0) (3 -5.39801e-17 0) (3 -5.73539e-17 0) (3 -1.51819e-17 0) (3 -1.68688e-18 0) (3 1.01213e-17 0) (3 -8.43439e-18 0) (3 1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 1.18081e-17 0) (3 7.42226e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 2.02425e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.14708e-16 0) (3 -8.77177e-17 0) (3 -6.74751e-17 0) (3 -2.69901e-17 0) (3 -9.78389e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -2.86769e-17 0) (3 5.39801e-17 0) (3 9.61521e-17 0) (3 1.38324e-16 0) (3 1.24829e-16 0) (3 1.06273e-16 0) (3 8.43439e-17 0) (3 8.70936e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -3.37376e-17 0) (3 -1.40011e-16 0) (3 -9.78389e-17 0) (3 -1.40011e-16 0) (3 -1.24829e-16 0) (3 -1.14708e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -1.23142e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.16395e-16 0) (3 -5.39801e-17 0) (3 -9.61521e-17 0) (3 -9.44652e-17 0) (3 -1.18081e-16 0) (3 -1.09647e-16 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.6194e-16 0) (3 -1.40011e-16 0) (3 -1.40011e-16 0) (3 -1.40011e-16 0) (3 -1.82183e-16 0) (3 -1.82183e-16 0) (3 -2.24355e-16 0) (3 -1.93991e-16 0) (3 -1.90617e-16 0) (3 -1.029e-16 0) (3 -1.60253e-16 0) (3 -1.48445e-16 0) (3 -1.28203e-16 0) (3 -1.029e-16 0) (3 -9.44652e-17 0) (3 -8.53736e-17 0) (3 0 0) (3 -7.42226e-17 0) (3 -1.18081e-17 0) (3 -4.2172e-17 0) (3 1.01213e-17 0) (3 -1.18081e-17 0) (3 5.06063e-18 0) (3 8.43439e-18 0) (3 1.18081e-17 0) (3 -6.9162e-17 0) (3 -7.25358e-17 0) (3 -6.24145e-17 0) (3 -4.2172e-17 0) (3 -7.42226e-17 0) (3 -1.6194e-16 0) (3 -1.51819e-16 0) (3 -8.77177e-17 0) (3 -6.9162e-17 0) (3 3.20507e-17 0) (3 3.03638e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 1.51819e-17 0) (3 -5.06063e-17 0) (3 -3.20507e-17 0) (3 -3.54244e-17 0) (3 -6.07276e-17 0) (3 -3.54244e-17 0) (3 -4.04851e-17 0) (3 -4.04851e-17 0) (3 -9.10914e-17 0) (3 -1.01213e-17 0) (3 -5.39801e-17 0) (3 -1.38324e-16 0) (3 -1.63627e-16 0) (3 -2.26042e-16 0) (3 -2.1086e-16 0) (3 -1.93991e-16 0) (3 -1.67001e-16 0) (3 -1.60543e-16 0) (3 0 0) (3 0 0) (3 -1.18081e-17 0) (3 1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-18 0) (3 -3.20507e-17 0) (3 3.20507e-17 0) (3 3.03638e-17 0) (3 9.10914e-17 0) (3 9.61521e-17 0) (3 1.38324e-16 0) (3 1.28203e-16 0) (3 7.42226e-17 0) (3 1.16395e-16 0) (3 5.22932e-17 0) (3 9.61521e-17 0) (3 7.92833e-17 0) (3 7.42226e-17 0) (3 1.36637e-16 0) (3 1.40011e-16 0) (3 1.19768e-16 0) (3 1.16395e-16 0) (3 1.38324e-16 0) (3 1.31577e-16 0) (3 1.23142e-16 0) (3 1.029e-16 0) (3 9.10914e-17 0) (3 1.04586e-16 0) (3 8.09702e-17 0) (3 7.59095e-17 0) (3 7.25358e-17 0) (3 1.51819e-17 0) (3 1.18081e-17 0) (3 5.39801e-17 0) (3 4.04851e-17 0) (3 2.19294e-17 0) (3 -3.37376e-18 0) (3 -1.78654e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 5.39801e-17 0) (3 3.03638e-17 0) (3 -1.01213e-17 0) (3 -3.20507e-17 0) (3 -1.01213e-17 0) (3 9.61521e-17 0) (3 6.9162e-17 0) (3 3.54244e-17 0) (3 3.20507e-17 0) (3 2.53032e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.01213e-17 0) (3 -5.06063e-18 0) (3 8.43439e-18 0) (3 5.06063e-18 0) (3 -5.06063e-17 0) (3 -5.39801e-17 0) (3 -4.2172e-17 0) (3 -3.37376e-17 0) (3 -7.42226e-17 0) (3 -4.72326e-17 0) (3 -5.22932e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 1.68688e-17 0) (3 -5.06063e-17 0) (3 -5.22932e-17 0) (3 2.19294e-17 0) (3 3.20507e-17 0) (3 3.03638e-17 0) (3 3.03638e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 5.28919e-30 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -6.74751e-18 0) (3 -5.22932e-17 0) (3 -1.18081e-16 0) (3 -9.78389e-17 0) (3 -1.50132e-16 0) (3 -1.40011e-16 0) (3 -1.93991e-16 0) (3 -1.72062e-16 0) (3 -1.6194e-16 0) (3 -2.05799e-16 0) (3 -1.40011e-16 0) (3 -1.82183e-16 0) (3 -1.24829e-16 0) (3 -7.42226e-17 0) (3 -1.18081e-16 0) (3 -1.06273e-16 0) (3 -8.77177e-17 0) (3 -7.59095e-17 0) (3 -9.78389e-17 0) (3 -8.60308e-17 0) (3 -7.42226e-17 0) (3 -5.39801e-17 0) (3 -9.78389e-17 0) (3 -6.07276e-17 0) (3 -1.5688e-16 0) (3 -5.06063e-17 0) (3 -3.20507e-17 0) (3 -5.39801e-17 0) (3 -6.74751e-17 0) (3 -1.18081e-16 0) (3 -5.06063e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -2.9795e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -8.09702e-17 0) (3 -1.36637e-16 0) (3 -1.40011e-16 0) (3 -9.10914e-17 0) (3 -7.08489e-17 0) (3 2.02425e-17 0) (3 -2.02425e-17 0) (3 4.55457e-17 0) (3 6.57883e-17 0) (3 -2.69901e-17 0) (3 1.38324e-16 0) (3 5.39801e-17 0) (3 1.58567e-16 0) (3 1.31577e-16 0) (3 9.61521e-17 0) (3 1.45072e-16 0) (3 1.2989e-16 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 1.16395e-16 0) (3 1.06273e-16 0) (3 7.92833e-17 0) (3 7.59095e-17 0) (3 9.27783e-17 0) (3 8.43439e-17 0) (3 9.61521e-17 0) (3 7.92833e-17 0) (3 7.42226e-17 0) (3 2.86769e-17 0) (3 4.2172e-17 0) (3 9.61521e-17 0) (3 7.59095e-17 0) (3 9.44652e-17 0) (3 9.61521e-17 0) (3 9.47074e-17 0) (3 0 0) (3 1.18081e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 1.85557e-17 0) (3 4.2172e-17 0) (3 1.38324e-16 0) (3 1.26516e-16 0) (3 1.06273e-16 0) (3 1.80496e-16 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.06273e-16 0) (3 9.27783e-17 0) (3 3.54244e-17 0) (3 3.37376e-17 0) (3 7.59095e-17 0) (3 5.39801e-17 0) (3 9.61521e-17 0) (3 1.40011e-16 0) (3 1.16395e-16 0) (3 9.78389e-17 0) (3 9.61521e-17 0) (3 9.78389e-17 0) (3 1.16395e-16 0) (3 1.18081e-16 0) (3 9.61521e-17 0) (3 1.3495e-16 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.14354e-17 0) (3 0 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 4.2172e-17 0) (3 9.10914e-17 0) (3 1.21455e-16 0) (3 1.6194e-16 0) (3 1.24829e-16 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 -3.03638e-17 0) (3 1.01213e-17 0) (3 -5.06063e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -1.18081e-16 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -1.60253e-16 0) (3 -9.95258e-17 0) (3 -5.5667e-17 0) (3 -7.42226e-17 0) (3 -9.78389e-17 0) (3 -8.2657e-17 0) (3 -7.59095e-17 0) (3 -8.60308e-17 0) (3 -1.38324e-16 0) (3 -8.2657e-17 0) (3 -1.18081e-16 0) (3 -1.11334e-16 0) (3 -1.16395e-16 0) (3 -5.39801e-17 0) (3 -6.41014e-17 0) (3 -1.33263e-16 0) (3 -1.40011e-16 0) (3 -1.41698e-16 0) (3 -1.26516e-16 0) (3 -1.09824e-16 0) (3 6.74751e-18 0) (3 -3.87982e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -4.2172e-17 0) (3 -2.53032e-17 0) (3 -5.39801e-17 0) (3 -1.40011e-16 0) (3 -1.41698e-16 0) (3 -3.87982e-17 0) (3 -1.6194e-16 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -9.78389e-17 0) (3 -1.18081e-17 0) (3 -7.59095e-17 0) (3 -1.18081e-17 0) (3 -5.22932e-17 0) (3 -1.18081e-16 0) (3 -2.53032e-17 0) (3 -9.78389e-17 0) (3 -1.75435e-16 0) (3 -1.38324e-16 0) (3 -1.5688e-16 0) (3 -1.45072e-16 0) (3 -1.41698e-16 0) (3 -1.40011e-16 0) (3 -1.67001e-16 0) (3 -1.18081e-16 0) (3 -1.40011e-16 0) (3 -1.40011e-16 0) (3 -1.58567e-16 0) (3 -1.24829e-16 0) (3 -1.21455e-16 0) (3 -7.92833e-17 0) (3 -1.51819e-17 0) (3 7.42226e-17 0) (3 6.24145e-17 0) (3 3.23768e-17 0) (3 0 0) (3 0 0) (3 1.18081e-17 0) (3 -1.68688e-17 0) (3 -4.72326e-17 0) (3 -8.77177e-17 0) (3 -1.36637e-16 0) (3 -5.5667e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -6.41014e-17 0) (3 -5.39801e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 6.74751e-18 0) (3 1.18081e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.3495e-17 0) (3 1.68688e-17 0) (3 4.55457e-17 0) (3 9.61521e-17 0) (3 8.2657e-17 0) (3 5.22932e-17 0) (3 4.89195e-17 0) (3 4.89195e-17 0) (3 4.04851e-17 0) (3 -3.20507e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -8.23609e-18 0) (3 0 0) (3 6.41014e-17 0) (3 5.90407e-17 0) (3 5.73539e-17 0) (3 6.24145e-17 0) (3 7.75964e-17 0) (3 1.18081e-17 0) (3 7.25358e-17 0) (3 5.5667e-17 0) (3 5.5667e-17 0) (3 5.06063e-18 0) (3 -1.68688e-18 0) (3 -5.22932e-17 0) (3 1.18081e-17 0) (3 1.3495e-17 0) (3 -3.20507e-17 0) (3 1.18081e-17 0) (3 -3.20507e-17 0) (3 -1.18081e-17 0) (3 1.18081e-17 0) (3 -5.22932e-17 0) (3 -4.72326e-17 0) (3 5.06063e-18 0) (3 3.37376e-18 0) (3 8.43439e-18 0) (3 4.89195e-17 0) (3 1.40011e-16 0) (3 1.6194e-16 0) (3 1.6194e-16 0) (3 1.60253e-16 0) (3 1.60253e-16 0) (3 1.60253e-16 0) (3 1.6194e-16 0) (3 1.40011e-16 0) (3 1.40011e-16 0) (3 9.10914e-17 0) (3 2.86769e-17 0) (3 -7.25358e-17 0) (3 -6.07276e-17 0) (3 -3.40302e-17 0) (3 0 0) (3 -3.37376e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -6.24145e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 5.06063e-18 0) (3 1.18081e-17 0) (3 7.59095e-17 0) (3 7.25358e-17 0) (3 1.19768e-16 0) (3 1.31577e-16 0) (3 1.31577e-16 0) (3 1.80496e-16 0) (3 1.18081e-16 0) (3 1.78809e-16 0) (3 1.60253e-16 0) (3 1.18081e-16 0) (3 1.80496e-16 0) (3 1.73748e-16 0) (3 1.40011e-16 0) (3 1.40011e-16 0) (3 1.26516e-16 0) (3 8.2657e-17 0) (3 -1.18081e-17 0) (3 -1.68688e-17 0) (3 -3.20507e-17 0) (3 -1.68688e-17 0) (3 -3.03638e-17 0) (3 -1.68688e-17 0) (3 -2.53032e-17 0) (3 -1.68688e-18 0) (3 -1.01213e-17 0) (3 4.04851e-17 0) (3 1.38324e-16 0) (3 1.26516e-16 0) (3 1.029e-16 0) (3 9.34414e-17 0) (3 0 0) (3 0 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -5.06063e-18 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -1.01213e-17 0) (3 -6.74751e-18 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -3.54244e-17 0) (3 -8.09702e-17 0) (3 -9.10914e-17 0) (3 -9.27783e-17 0) (3 -9.44652e-17 0) (3 -9.44652e-17 0) (3 -9.44652e-17 0) (3 -1.16395e-16 0) (3 -3.37376e-17 0) (3 -5.06063e-17 0) (3 -5.39801e-17 0) (3 -4.89195e-17 0) (3 -5.06063e-17 0) (3 -5.22932e-17 0) (3 -4.28523e-17 0) (3 0 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 4.2172e-17 0) (3 8.09702e-17 0) (3 1.029e-16 0) (3 1.38324e-16 0) (3 9.95258e-17 0) (3 1.51819e-17 0) (3 1.68688e-18 0) (3 -7.42226e-17 0) (3 -3.20507e-17 0) (3 -7.42226e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -9.61521e-17 0) (3 -7.59095e-17 0) (3 -1.36637e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -1.60253e-16 0) (3 -1.14708e-16 0) (3 -7.42226e-17 0) (3 -7.75964e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -5.39801e-17 0) (3 -7.59095e-17 0) (3 -6.07276e-17 0) (3 -4.55457e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 -1.18081e-17 0) (3 -6.41014e-17 0) (3 -1.38324e-16 0) (3 -1.26516e-16 0) (3 -1.04586e-16 0) (3 -7.41612e-17 0) (3 0 0) (3 -2.19294e-17 0) (3 -9.27783e-17 0) (3 -9.78389e-17 0) (3 -8.60308e-17 0) (3 -6.9162e-17 0) (3 -1.51819e-17 0) (3 -7.42226e-17 0) (3 -5.5667e-17 0) (3 -5.06063e-17 0) (3 1.01213e-17 0) (3 1.18081e-17 0) (3 7.42226e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 1.18081e-16 0) (3 5.22932e-17 0) (3 9.61521e-17 0) (3 8.60308e-17 0) (3 3.20507e-17 0) (3 8.2657e-17 0) (3 7.92833e-17 0) (3 5.06063e-17 0) (3 5.22932e-17 0) (3 3.37376e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 2.36163e-17 0) (3 9.78389e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.20507e-17 0) (3 -3.03638e-17 0) (3 -3.20507e-17 0) (3 3.37376e-17 0) (3 1.18081e-17 0) (3 7.42226e-17 0) (3 7.59095e-17 0) (3 7.11523e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 9.78389e-17 0) (3 7.25358e-17 0) (3 3.37376e-17 0) (3 1.18081e-17 0) (3 3.54244e-17 0) (3 9.78389e-17 0) (3 8.43439e-17 0) (3 7.75964e-17 0) (3 7.42226e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 -8.43439e-18 0) (3 -8.43439e-18 0) (3 -1.01213e-17 0) (3 4.89195e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.03638e-17 0) (3 2.02425e-17 0) (3 -1.01213e-17 0) (3 -7.42226e-17 0) (3 -6.74751e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -6.07276e-17 0) (3 -5.73539e-17 0) (3 -5.39801e-17 0) (3 -9.78389e-17 0) (3 -9.27783e-17 0) (3 -9.10914e-17 0) (3 -8.09702e-17 0) (3 -6.24145e-17 0) (3 -5.73539e-17 0) (3 -5.5667e-17 0) (3 -5.5667e-17 0) (3 -5.39801e-17 0) (3 -8.09702e-17 0) (3 -1.22976e-16 0) (3 0 0) (3 0 0) (3 0 0) (3 2.86769e-17 0) (3 7.59095e-17 0) (3 8.60308e-17 0) (3 9.78389e-17 0) (3 8.43439e-17 0) (3 6.41014e-17 0) (3 5.73539e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -8.94045e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.67001e-16 0) (3 -9.78389e-17 0) (3 -1.58567e-16 0) (3 -7.92833e-17 0) (3 -7.59095e-17 0) (3 -1.38324e-16 0) (3 -1.41698e-16 0) (3 -9.78389e-17 0) (3 -1.18081e-16 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -1.09647e-16 0) (3 -8.60308e-17 0) (3 -7.92833e-17 0) (3 -3.37376e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 -4.55457e-17 0) (3 -9.78389e-17 0) (3 -7.59095e-17 0) (3 -1.33263e-16 0) (3 -1.38324e-16 0) (3 -1.20802e-16 0) (3 -4.55457e-17 0) (3 -3.37376e-17 0) (3 -7.59095e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.21455e-16 0) (3 -2.47971e-16 0) (3 -2.36163e-16 0) (3 -1.46758e-16 0) (3 -1.04586e-16 0) (3 -5.06063e-18 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.18081e-17 0) (3 2.69901e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -2.02425e-17 0) (3 5.06063e-17 0) (3 5.5667e-17 0) (3 4.55457e-17 0) (3 5.06063e-17 0) (3 5.39801e-17 0) (3 7.59095e-17 0) (3 7.25358e-17 0) (3 7.42226e-17 0) (3 7.42226e-17 0) (3 8.43439e-17 0) (3 6.74751e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.0796e-16 0) (3 1.24829e-16 0) (3 1.87243e-16 0) (3 1.6194e-16 0) (3 2.02425e-16 0) (3 1.90617e-16 0) (3 1.6989e-16 0) (3 -5.39801e-17 0) (3 -4.38588e-17 0) (3 -5.22932e-17 0) (3 -4.89195e-17 0) (3 -8.43439e-17 0) (3 -1.11334e-16 0) (3 -5.39801e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 5.22932e-17 0) (3 3.37376e-17 0) (3 3.20507e-17 0) (3 7.92833e-17 0) (3 1.48445e-16 0) (3 2.1086e-16 0) (3 2.24355e-16 0) (3 2.02425e-16 0) (3 2.00739e-16 0) (3 1.48445e-16 0) (3 1.16395e-16 0) (3 1.55193e-16 0) (3 1.60253e-16 0) (3 1.23142e-16 0) (3 1.18081e-16 0) (3 9.78389e-17 0) (3 1.51819e-16 0) (3 2.26042e-16 0) (3 2.07486e-16 0) (3 2.24355e-16 0) (3 2.02425e-16 0) (3 2.02425e-16 0) (3 1.16395e-16 0) (3 1.18081e-16 0) (3 1.80496e-16 0) (3 1.82183e-16 0) (3 1.6194e-16 0) (3 2.20981e-16 0) (3 2.22668e-16 0) (3 2.24355e-16 0) (3 2.09199e-16 0) (3 4.55457e-17 0) (3 8.43439e-17 0) (3 9.61521e-17 0) (3 9.44652e-17 0) (3 5.90407e-17 0) (3 6.74751e-17 0) (3 5.39801e-17 0) (3 1.85557e-17 0) (3 -5.73539e-17 0) (3 -6.57883e-17 0) (3 -1.16395e-16 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -5.22932e-17 0) (3 -3.71113e-17 0) (3 -1.85557e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.71113e-17 0) (3 -9.61521e-17 0) (3 -8.60308e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -5.22932e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -3.37376e-17 0) (3 -5.39801e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 -1.18081e-17 0) (3 1.68688e-18 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -9.61521e-17 0) (3 -7.59095e-17 0) (3 -1.18081e-16 0) (3 -1.06273e-16 0) (3 -9.03382e-17 0) (3 5.22932e-17 0) (3 5.39801e-17 0) (3 4.89195e-17 0) (3 4.04851e-17 0) (3 3.71113e-17 0) (3 3.54244e-17 0) (3 1.01213e-17 0) (3 -5.5667e-17 0) (3 -5.39801e-17 0) (3 -1.16395e-16 0) (3 -7.75964e-17 0) (3 -1.3495e-17 0) (3 -1.16395e-16 0) (3 -1.99052e-16 0) (3 -2.61466e-16 0) (3 -2.68214e-16 0) (3 -2.95204e-16 0) (3 -2.78335e-16 0) (3 -2.63153e-16 0) (3 -1.82183e-16 0) (3 -2.63153e-16 0) (3 -2.41224e-16 0) (3 -2.31102e-16 0) (3 -2.29415e-16 0) (3 -2.02425e-16 0) (3 -2.44597e-16 0) (3 -3.10386e-16 0) (3 -2.56406e-16 0) (3 -1.8387e-16 0) (3 -1.97365e-16 0) (3 -1.80496e-16 0) (3 -1.67001e-16 0) (3 -1.6194e-16 0) (3 -2.19294e-16 0) (3 -2.26042e-16 0) (3 -1.45072e-16 0) (3 -2.24355e-16 0) (3 -2.05799e-16 0) (3 -1.85557e-16 0) (3 -1.92835e-16 0) (3 -5.22932e-17 0) (3 -9.78389e-17 0) (3 -7.75964e-17 0) (3 -7.75964e-17 0) (3 -7.75964e-17 0) (3 -6.57883e-17 0) (3 -2.02425e-17 0) (3 7.25358e-17 0) (3 7.59095e-17 0) (3 5.90407e-17 0) (3 5.73539e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -1.51819e-17 0) (3 -3.03638e-17 0) (3 -3.03638e-17 0) (3 3.20507e-17 0) (3 2.02425e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.3495e-17 0) (3 -5.39801e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.85557e-17 0) (3 -1.18081e-17 0) (3 -5.39801e-17 0) (3 -5.5667e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.59095e-17 0) (3 -7.08489e-17 0) (3 -7.42226e-17 0) (3 -7.2397e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 3.20507e-17 0) (3 1.85557e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 2.53032e-17 0) (3 7.42226e-17 0) (3 5.39801e-17 0) (3 1.14708e-16 0) (3 3.54244e-17 0) (3 3.20507e-17 0) (3 1.14708e-16 0) (3 1.11334e-16 0) (3 1.80496e-16 0) (3 1.82183e-16 0) (3 2.22668e-16 0) (3 2.24355e-16 0) (3 2.24355e-16 0) (3 1.60253e-16 0) (3 2.29415e-16 0) (3 2.07486e-16 0) (3 2.04112e-16 0) (3 1.92304e-16 0) (3 1.60253e-16 0) (3 2.00739e-16 0) (3 2.88456e-16 0) (3 2.31102e-16 0) (3 1.78809e-16 0) (3 1.53506e-16 0) (3 1.21455e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 1.18081e-17 0) (3 9.61521e-17 0) (3 5.39801e-17 0) (3 5.73539e-17 0) (3 5.41755e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.54244e-17 0) (3 1.01213e-17 0) (3 -1.16395e-16 0) (3 -1.31577e-16 0) (3 -9.61521e-17 0) (3 -9.61521e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 2.36163e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 8.60308e-17 0) (3 2.36163e-17 0) (3 9.44652e-17 0) (3 9.27783e-17 0) (3 1.21455e-16 0) (3 1.78809e-16 0) (3 1.65314e-16 0) (3 1.58567e-16 0) (3 1.51819e-16 0) (3 1.24829e-16 0) (3 1.21455e-16 0) (3 1.19768e-16 0) (3 1.19768e-16 0) (3 9.95258e-17 0) (3 9.95258e-17 0) (3 7.92833e-17 0) (3 7.75964e-17 0) (3 7.59095e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.50132e-16 0) (3 2.26042e-16 0) (3 2.27729e-16 0) (3 2.26042e-16 0) (3 2.35688e-16 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 9.61521e-17 0) (3 8.43439e-17 0) (3 8.09702e-17 0) (3 6.57883e-17 0) (3 4.55457e-17 0) (3 3.20507e-17 0) (3 -3.20507e-17 0) (3 -1.3495e-17 0) (3 -1.18081e-17 0) (3 -6.41014e-17 0) (3 -6.9162e-17 0) (3 -1.16395e-16 0) (3 -9.95258e-17 0) (3 -9.61521e-17 0) (3 -7.59095e-17 0) (3 -7.75964e-17 0) (3 -5.39801e-17 0) (3 -9.44652e-17 0) (3 -7.92833e-17 0) (3 -7.08489e-17 0) (3 -7.08489e-17 0) (3 -7.25358e-17 0) (3 -7.25358e-17 0) (3 -9.10914e-17 0) (3 -9.44652e-17 0) (3 -9.61521e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -1.3495e-17 0) (3 2.36163e-17 0) (3 3.37376e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 -6.74751e-18 0) (3 -1.01213e-17 0) (3 -8.43439e-18 0) (3 -1.02741e-17 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 0 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.14708e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -1.43385e-16 0) (3 -7.59095e-17 0) (3 -9.78389e-17 0) (3 -3.37376e-17 0) (3 -6.9162e-17 0) (3 -1.6194e-16 0) (3 -1.6194e-16 0) (3 -1.6194e-16 0) (3 -1.6194e-16 0) (3 -1.40011e-16 0) (3 -1.55193e-16 0) (3 -1.82183e-16 0) (3 -1.82183e-16 0) (3 -1.70375e-16 0) (3 -1.65314e-16 0) (3 -1.51819e-16 0) (3 -1.01213e-16 0) (3 -1.0796e-16 0) (3 -1.18081e-16 0) (3 -1.18081e-16 0) (3 -1.72062e-16 0) (3 -2.44597e-16 0) (3 -2.9183e-16 0) (3 -2.66527e-16 0) (3 -2.69164e-16 0) (3 0 0) (3 0 0) (3 -5.39801e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -8.09702e-17 0) (3 -9.61521e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.51819e-17 0) (3 -1.68688e-18 0) (3 6.74751e-18 0) (3 -1.01213e-17 0) (3 2.19294e-17 0) (3 -1.18081e-17 0) (3 -7.42226e-17 0) (3 -9.78389e-17 0) (3 -1.16395e-16 0) (3 -3.54244e-17 0) (3 -3.54244e-17 0) (3 -3.71113e-17 0) (3 -4.38588e-17 0) (3 -3.54244e-17 0) (3 -4.72326e-17 0) (3 -7.92833e-17 0) (3 -1.40011e-16 0) (3 -1.40011e-16 0) (3 -1.8387e-16 0) (3 -1.50132e-16 0) (3 -1.95678e-16 0) (3 -3.12072e-16 0) (3 -3.13759e-16 0) (3 -2.9183e-16 0) (3 -3.32315e-16 0) (3 -2.39537e-16 0) (3 -1.70375e-16 0) (3 -1.16395e-16 0) (3 -1.41698e-16 0) (3 -1.72287e-16 0) (3 0 0) (3 0 0) (3 1.18081e-17 0) (3 -1.18081e-17 0) (3 4.2172e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 9.61521e-17 0) (3 7.92833e-17 0) (3 7.42226e-17 0) (3 5.39801e-17 0) (3 5.5667e-17 0) (3 5.22932e-17 0) (3 5.06063e-17 0) (3 5.06063e-17 0) (3 1.3495e-17 0) (3 1.01213e-17 0) (3 -1.51819e-17 0) (3 -7.42226e-17 0) (3 -5.90407e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -2.86769e-17 0) (3 -1.51819e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 7.42226e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -3.37376e-17 0) (3 -4.72326e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 -4.55457e-17 0) (3 -5.22932e-17 0) (3 -4.28523e-17 0) (3 0 0) (3 0 0) (3 3.37376e-17 0) (3 6.41014e-17 0) (3 6.24145e-17 0) (3 5.39801e-17 0) (3 4.38588e-17 0) (3 1.62935e-32 0) (3 -7.42226e-17 0) (3 -3.20507e-17 0) (3 -7.42226e-17 0) (3 -7.08489e-17 0) (3 -7.25358e-17 0) (3 -7.42226e-17 0) (3 -7.42226e-17 0) (3 -1.68688e-17 0) (3 2.86769e-17 0) (3 9.95258e-17 0) (3 1.82183e-16 0) (3 1.40011e-16 0) (3 1.28203e-16 0) (3 1.24829e-16 0) (3 1.23142e-16 0) (3 7.59095e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.31577e-16 0) (3 1.18081e-16 0) (3 1.82183e-16 0) (3 2.47971e-16 0) (3 2.47971e-16 0) (3 2.29415e-16 0) (3 2.14234e-16 0) (3 1.68688e-16 0) (3 7.92833e-17 0) (3 7.42226e-17 0) (3 7.42226e-17 0) (3 7.11417e-17 0) (3 0 0) (3 0 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -5.73539e-17 0) (3 -1.31577e-16 0) (3 -8.77177e-17 0) (3 -1.31577e-16 0) (3 5.06063e-18 0) (3 -5.73539e-17 0) (3 7.42226e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 1.3495e-16 0) (3 7.59095e-17 0) (3 1.14708e-16 0) (3 1.6194e-16 0) (3 9.78389e-17 0) (3 2.04112e-16 0) (3 2.04112e-16 0) (3 2.02425e-16 0) (3 2.24355e-16 0) (3 2.05799e-16 0) (3 2.05799e-16 0) (3 2.04112e-16 0) (3 2.02425e-16 0) (3 1.77122e-16 0) (3 1.90617e-16 0) (3 1.73748e-16 0) (3 1.38324e-16 0) (3 1.38324e-16 0) (3 1.6194e-16 0) (3 1.60253e-16 0) (3 2.02425e-16 0) (3 2.90143e-16 0) (3 2.78335e-16 0) (3 2.71587e-16 0) (3 2.70285e-16 0) (3 -5.39801e-17 0) (3 -4.72326e-17 0) (3 -3.87982e-17 0) (3 -3.54244e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -8.43439e-18 0) (3 2.86769e-17 0) (3 9.44652e-17 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.45072e-16 0) (3 2.02425e-16 0) (3 1.82183e-16 0) (3 2.46284e-16 0) (3 1.95678e-16 0) (3 1.77122e-16 0) (3 1.029e-16 0) (3 1.029e-16 0) (3 5.39801e-17 0) (3 7.75964e-17 0) (3 1.60253e-16 0) (3 1.55193e-16 0) (3 1.43385e-16 0) (3 1.40011e-16 0) (3 1.77122e-16 0) (3 2.66527e-16 0) (3 2.46284e-16 0) (3 2.46284e-16 0) (3 2.24355e-16 0) (3 1.85557e-16 0) (3 2.22668e-16 0) (3 2.07486e-16 0) (3 2.02425e-16 0) (3 2.24355e-16 0) (3 2.19294e-16 0) (3 1.95678e-16 0) (3 1.72062e-16 0) (3 1.65314e-16 0) (3 1.56612e-16 0) (3 4.55457e-17 0) (3 8.2657e-17 0) (3 7.92833e-17 0) (3 8.77177e-17 0) (3 8.60308e-17 0) (3 8.94045e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 6.24145e-17 0) (3 -8.43439e-18 0) (3 -1.18081e-17 0) (3 -5.06063e-17 0) (3 -8.43439e-18 0) (3 3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -9.27783e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -1.28203e-16 0) (3 -1.19768e-16 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -7.75964e-17 0) (3 -7.59095e-17 0) (3 -5.90407e-17 0) (3 -4.2172e-17 0) (3 -1.68688e-18 0) (3 8.43439e-18 0) (3 2.36163e-17 0) (3 9.78389e-17 0) (3 8.60308e-17 0) (3 5.5667e-17 0) (3 5.22932e-17 0) (3 1.3495e-17 0) (3 -5.39801e-17 0) (3 -3.20507e-17 0) (3 -3.54244e-17 0) (3 -3.34034e-17 0) (3 5.22932e-17 0) (3 5.39801e-17 0) (3 5.5667e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 3.03638e-17 0) (3 -2.69901e-17 0) (3 -7.25358e-17 0) (3 -1.18081e-16 0) (3 -1.18081e-17 0) (3 -6.41014e-17 0) (3 -9.44652e-17 0) (3 -4.2172e-17 0) (3 -1.28203e-16 0) (3 -1.16395e-16 0) (3 -2.00739e-16 0) (3 -1.80496e-16 0) (3 -2.24355e-16 0) (3 -1.87243e-16 0) (3 -1.0796e-16 0) (3 -2.53032e-16 0) (3 -2.24355e-16 0) (3 -2.24355e-16 0) (3 -2.02425e-16 0) (3 -2.39537e-16 0) (3 -3.10386e-16 0) (3 -2.27729e-16 0) (3 -2.44597e-16 0) (3 -1.87243e-16 0) (3 -1.60253e-16 0) (3 -2.02425e-16 0) (3 -1.90617e-16 0) (3 -1.45072e-16 0) (3 -1.58567e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -3.54244e-17 0) (3 -3.20507e-17 0) (3 -3.1654e-17 0) (3 0 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-18 0) (3 3.37376e-18 0) (3 3.37376e-17 0) (3 7.42226e-17 0) (3 1.40011e-16 0) (3 1.18081e-16 0) (3 1.41698e-16 0) (3 1.28203e-16 0) (3 9.44652e-17 0) (3 5.22932e-17 0) (3 1.18081e-17 0) (3 1.01213e-17 0) (3 1.18081e-17 0) (3 -1.68688e-18 0) (3 -4.2172e-17 0) (3 -5.90407e-17 0) (3 -7.25358e-17 0) (3 -7.25358e-17 0) (3 -9.10914e-17 0) (3 -9.61521e-17 0) (3 -5.22932e-17 0) (3 -6.57883e-17 0) (3 -8.43439e-17 0) (3 -9.61521e-17 0) (3 -5.39801e-17 0) (3 -9.61521e-17 0) (3 -6.74751e-18 0) (3 -1.36637e-16 0) (3 -1.18081e-16 0) (3 -1.16395e-16 0) (3 -1.16395e-16 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -3.87982e-17 0) (3 -1.27303e-28 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 2.69901e-17 0) (3 -1.3495e-17 0) (3 5.22932e-17 0) (3 3.37376e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 -5.22932e-17 0) (3 -3.87982e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -6.41014e-17 0) (3 -3.37376e-17 0) (3 -6.9162e-17 0) (3 -1.38324e-16 0) (3 -1.23142e-16 0) (3 -1.0796e-16 0) (3 -7.42226e-17 0) (3 -5.73539e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -1.16395e-16 0) (3 -9.95258e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -9.61521e-17 0) (3 -9.78389e-17 0) (3 -1.40011e-16 0) (3 -9.78389e-17 0) (3 -1.60253e-16 0) (3 -9.10914e-17 0) (3 2.60739e-18 0) (3 -6.9162e-17 0) (3 -7.08489e-17 0) (3 -9.27783e-17 0) (3 -9.78389e-17 0) (3 -1.68688e-16 0) (3 -9.27783e-17 0) (3 -1.6194e-16 0) (3 -1.50132e-16 0) (3 -1.43385e-16 0) (3 -1.26516e-16 0) (3 -1.04586e-16 0) (3 -8.94045e-17 0) (3 0 0) (3 8.43439e-18 0) (3 8.43439e-18 0) (3 6.9162e-17 0) (3 7.25358e-17 0) (3 1.2989e-16 0) (3 1.28203e-16 0) (3 1.58567e-16 0) (3 2.24355e-16 0) (3 2.12547e-16 0) (3 1.90617e-16 0) (3 1.73748e-16 0) (3 1.40011e-16 0) (3 1.40011e-16 0) (3 1.41698e-16 0) (3 1.28203e-16 0) (3 9.95258e-17 0) (3 9.78389e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.78389e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.61521e-17 0) (3 9.78389e-17 0) (3 1.16395e-16 0) (3 1.09647e-16 0) (3 5.02048e-17 0) (3 0 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -5.39801e-17 0) (3 -4.2172e-17 0) (3 -1.01213e-17 0) (3 4.55457e-17 0) (3 3.20507e-17 0) (3 7.42226e-17 0) (3 5.22932e-17 0) (3 9.44652e-17 0) (3 9.44652e-17 0) (3 9.44652e-17 0) (3 1.50132e-16 0) (3 1.51819e-16 0) (3 2.02425e-16 0) (3 1.82183e-16 0) (3 1.80496e-16 0) (3 2.32789e-16 0) (3 2.4291e-16 0) (3 2.36163e-16 0) (3 2.26042e-16 0) (3 2.26042e-16 0) (3 2.26042e-16 0) (3 2.26042e-16 0) (3 2.26042e-16 0) (3 2.46284e-16 0) (3 2.47971e-16 0) (3 2.46284e-16 0) (3 2.26042e-16 0) (3 2.24355e-16 0) (3 2.26042e-16 0) (3 2.24355e-16 0) (3 2.14234e-16 0) (3 1.45072e-16 0) (3 2.02425e-16 0) (3 1.41698e-16 0) (3 3.28703e-17 0) (3 0 0) (3 1.18081e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 8.60308e-17 0) (3 1.6194e-16 0) (3 1.36637e-16 0) (3 7.25358e-17 0) (3 6.24145e-17 0) (3 5.90407e-17 0) (3 5.73539e-17 0) (3 3.54244e-17 0) (3 7.59095e-17 0) (3 7.59095e-17 0) (3 3.54244e-17 0) (3 3.20507e-17 0) (3 3.20507e-17 0) (3 4.89195e-17 0) (3 5.22932e-17 0) (3 5.06063e-18 0) (3 1.68688e-18 0) (3 -3.37376e-18 0) (3 -1.01213e-17 0) (3 -2.86769e-17 0) (3 -1.68688e-17 0) (3 -1.85557e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -5.06063e-17 0) (3 -5.5667e-17 0) (3 -1.16395e-16 0) (3 -5.90407e-17 0) (3 3.17002e-17 0) (3 6.74751e-17 0) (3 7.42226e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 9.78389e-17 0) (3 9.78389e-17 0) (3 1.01213e-16 0) (3 8.09702e-17 0) (3 7.92833e-17 0) (3 7.59095e-17 0) (3 9.61521e-17 0) (3 7.59095e-17 0) (3 -2.19294e-17 0) (3 -3.20507e-17 0) (3 -3.37376e-17 0) (3 -1.04586e-16 0) (3 -9.78389e-17 0) (3 -1.60253e-16 0) (3 -1.58567e-16 0) (3 -1.50132e-16 0) (3 -2.19294e-16 0) (3 -2.26042e-16 0) (3 -2.26042e-16 0) (3 -2.26042e-16 0) (3 -2.44597e-16 0) (3 -2.44597e-16 0) (3 -2.46284e-16 0) (3 -2.32789e-16 0) (3 -2.04112e-16 0) (3 -2.02425e-16 0) (3 -2.22668e-16 0) (3 -2.46284e-16 0) (3 -2.34476e-16 0) (3 -2.29415e-16 0) (3 -2.27729e-16 0) (3 -1.78809e-16 0) (3 -1.70375e-16 0) (3 -1.60253e-16 0) (3 -1.6194e-16 0) (3 -1.83028e-16 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 1.01213e-17 0) (3 -1.68688e-18 0) (3 3.03638e-17 0) (3 -2.19294e-17 0) (3 -1.6194e-16 0) (3 -1.21455e-16 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -1.16395e-16 0) (3 -1.04586e-16 0) (3 -3.20507e-17 0) (3 -7.42226e-17 0) (3 -5.5667e-17 0) (3 -1.18081e-17 0) (3 -1.01213e-17 0) (3 -2.36163e-17 0) (3 -4.2172e-17 0) (3 -1.14708e-16 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -9.44652e-17 0) (3 -6.74751e-17 0) (3 -5.90407e-17 0) (3 -4.72326e-17 0) (3 -6.24145e-17 0) (3 -5.73539e-17 0) (3 -5.5667e-17 0) (3 -5.5667e-17 0) (3 -5.5667e-17 0) (3 -4.2172e-17 0) (3 -3.37376e-17 0) (3 -7.25358e-17 0) (3 -1.55671e-16 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 1.01213e-17 0) (3 -2.36163e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -4.89195e-17 0) (3 -1.18081e-16 0) (3 -1.19768e-16 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -9.61521e-17 0) (3 -9.61521e-17 0) (3 -5.22932e-17 0) (3 -5.22932e-17 0) (3 -5.06063e-17 0) (3 4.2172e-17 0) (3 5.22932e-17 0) (3 9.61521e-17 0) (3 8.2657e-17 0) (3 6.9162e-17 0) (3 1.16395e-16 0) (3 1.18081e-16 0) (3 1.16395e-16 0) (3 1.75435e-16 0) (3 1.70375e-16 0) (3 1.50132e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.16395e-16 0) (3 1.11334e-16 0) (3 1.16395e-16 0) (3 1.09647e-16 0) (3 5.22932e-17 0) (3 5.22932e-17 0) (3 -2.86769e-17 0) (3 -3.37376e-17 0) (3 -3.02989e-17 0) (3 7.75964e-17 0) (3 7.59095e-17 0) (3 7.42226e-17 0) (3 7.59095e-17 0) (3 1.04586e-16 0) (3 7.75964e-17 0) (3 1.18081e-16 0) (3 9.10914e-17 0) (3 3.71113e-17 0) (3 1.18081e-17 0) (3 5.06063e-17 0) (3 4.2172e-17 0) (3 -8.43439e-18 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -7.42226e-17 0) (3 -5.22932e-17 0) (3 -7.59095e-17 0) (3 -7.42226e-17 0) (3 -5.22932e-17 0) (3 -7.42226e-17 0) (3 -5.5667e-17 0) (3 -4.04851e-17 0) (3 -1.85557e-17 0) (3 -1.85557e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 1.01213e-17 0) (3 -3.03638e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 1.18081e-17 0) (3 6.74751e-18 0) (3 4.2172e-17 0) (3 7.08489e-17 0) (3 6.42785e-17 0) (3 -1.18081e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -7.08489e-17 0) (3 -6.41014e-17 0) (3 -5.90407e-17 0) (3 -3.37376e-17 0) (3 -1.01213e-17 0) (3 7.42226e-17 0) (3 7.42226e-17 0) (3 5.39801e-17 0) (3 5.06063e-17 0) (3 9.61521e-17 0) (3 8.43439e-17 0) (3 5.22932e-17 0) (3 9.61521e-17 0) (3 8.43439e-17 0) (3 6.24145e-17 0) (3 4.55457e-17 0) (3 1.18081e-17 0) (3 5.39801e-17 0) (3 9.27783e-17 0) (3 -1.18081e-17 0) (3 -3.03638e-17 0) (3 -3.03638e-17 0) (3 -8.94045e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -7.75964e-17 0) (3 -9.61521e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.22932e-17 0) (3 1.18081e-17 0) (3 1.01213e-17 0) (3 9.10914e-17 0) (3 9.44652e-17 0) (3 8.73203e-17 0) (3 -6.24145e-17 0) (3 -5.90407e-17 0) (3 -5.73539e-17 0) (3 -5.39801e-17 0) (3 -7.59095e-17 0) (3 -6.74751e-17 0) (3 -7.59095e-17 0) (3 -6.41014e-17 0) (3 -4.55457e-17 0) (3 -3.37376e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -6.07276e-17 0) (3 -4.38588e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 6.74751e-18 0) (3 -5.06063e-18 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -3.20507e-17 0) (3 -3.20507e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 -1.3495e-17 0) (3 1.3495e-17 0) (3 5.22932e-17 0) (3 3.37376e-17 0) (3 5.22932e-17 0) (3 5.5667e-17 0) (3 5.39801e-17 0) (3 7.75964e-17 0) (3 1.68688e-17 0) (3 1.51819e-17 0) (3 -3.71113e-17 0) (3 -3.37376e-17 0) (3 -3.39346e-17 0) (3 6.24145e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 4.72326e-17 0) (3 7.59095e-17 0) (3 6.07276e-17 0) (3 7.59095e-17 0) (3 5.5667e-17 0) (3 3.54244e-17 0) (3 3.37376e-17 0) (3 5.22932e-17 0) (3 5.39801e-17 0) (3 -2.86769e-17 0) (3 -3.20507e-17 0) (3 -1.01213e-17 0) (3 -7.42226e-17 0) (3 -7.59095e-17 0) (3 -1.36637e-16 0) (3 -1.18081e-16 0) (3 -1.43385e-16 0) (3 -2.00739e-16 0) (3 -1.82183e-16 0) (3 -1.65314e-16 0) (3 -1.60253e-16 0) (3 -1.01213e-16 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -9.78389e-17 0) (3 -7.59095e-17 0) (3 -1.01213e-16 0) (3 -3.54244e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 -1.51819e-17 0) (3 -1.18081e-17 0) (3 -1.3495e-16 0) (3 -1.40011e-16 0) (3 -1.37774e-16 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -3.37376e-17 0) (3 -4.2172e-17 0) (3 -4.2172e-17 0) (3 -4.55457e-17 0) (3 -3.37376e-17 0) (3 -2.19294e-17 0) (3 3.20507e-17 0) (3 1.01213e-17 0) (3 -3.37376e-18 0) (3 -3.20507e-17 0) (3 3.03638e-17 0) (3 1.01213e-17 0) (3 -3.20507e-17 0) (3 6.74751e-18 0) (3 6.74751e-18 0) (3 3.20507e-17 0) (3 8.43439e-18 0) (3 -1.18081e-17 0) (3 3.20507e-17 0) (3 6.74751e-18 0) (3 2.36163e-17 0) (3 -1.18081e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 1.01213e-17 0) (3 -3.37376e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -1.18081e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 -5.39801e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.70786e-17 0) (3 -4.04851e-17 0) (3 -9.78389e-17 0) (3 -9.61521e-17 0) (3 -1.06273e-16 0) (3 -1.45072e-16 0) (3 -1.65314e-16 0) (3 -2.24355e-16 0) (3 -2.14234e-16 0) (3 -1.82183e-16 0) (3 -1.87243e-16 0) (3 -2.26042e-16 0) (3 -2.20981e-16 0) (3 -1.65314e-16 0) (3 -1.18081e-16 0) (3 -1.40011e-16 0) (3 -8.09702e-17 0) (3 -7.75964e-17 0) (3 -1.01213e-17 0) (3 -1.01213e-17 0) (3 -1.18081e-17 0) (3 2.53032e-17 0) (3 3.20507e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 1.18081e-17 0) (3 5.06063e-17 0) (3 5.22932e-17 0) (3 5.39801e-17 0) (3 5.39801e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.37376e-17 0) (3 3.20507e-17 0) (3 -3.37376e-17 0) (3 -3.37376e-17 0) (3 4.89195e-17 0) (3 5.5667e-17 0) (3 5.5667e-17 0) (2.96876 -0.00194375 0) (2.92608 0.024168 0) (2.88212 0.0686855 0) (2.84378 0.082188 0) (2.81109 0.110367 0) (2.76399 0.198221 0) (2.73043 0.244098 0) (2.71274 0.251113 0) (2.66639 0.317188 0) (2.63899 0.379106 0) (2.61569 0.412951 0) (2.59467 0.441371 0) (2.57598 0.490894 0) (2.55046 0.52113 0) (2.53227 0.558983 0) (2.52061 0.601681 0) (2.4977 0.628308 0) (2.48253 0.656026 0) (2.48123 0.683374 0) (2.48912 0.706018 0) (2.49908 0.718612 0) (2.50983 0.721131 0) (2.51941 0.714229 0) (2.52412 0.718946 0) (2.52668 0.718747 0) (2.53192 0.709973 0) (2.5346 0.706998 0) (2.53594 0.705817 0) (2.54188 0.699873 0) (2.54762 0.696312 0) (2.55386 0.691219 0) (2.5585 0.683205 0) (2.5677 0.679563 0) (2.5763 0.680459 0) (2.58154 0.680385 0) (2.5885 0.681823 0) (2.59657 0.684462 0) (2.60252 0.686327 0) (2.6082 0.68683 0) (2.61502 0.688038 0) (2.62353 0.690944 0) (2.62939 0.695143 0) (2.63284 0.698336 0) (2.63576 0.699263 0) (2.63843 0.699823 0) (2.64065 0.700213 0) (2.64301 0.700802 0) (2.6459 0.701475 0) (2.64872 0.702086 0) (2.65167 0.702816 0) (2.65421 0.70321 0) (2.65644 0.703173 0) (2.65845 0.703232 0) (2.66075 0.703928 0) (2.66387 0.705038 0) (2.66881 0.70662 0) (2.67483 0.707795 0) (2.68107 0.708883 0) (2.68593 0.711028 0) (2.6882 0.712098 0) (2.69187 0.713763 0) (2.6951 0.715705 0) (2.6978 0.717537 0) (2.70024 0.718892 0) (2.70306 0.720322 0) (2.7056 0.72149 0) (2.70794 0.722242 0) (2.70998 0.722924 0) (2.71187 0.723654 0) (2.71381 0.724472 0) (2.71598 0.725291 0) (2.71841 0.726015 0) (2.72101 0.72652 0) (2.72364 0.727 0) (2.72591 0.727962 0) (2.72755 0.72948 0) (2.729 0.731175 0) (2.73097 0.732713 0) (2.73397 0.734252 0) (2.74115 0.735815 0) (2.9989 0.00121001 0) (2.99447 0.00679991 0) (2.9857 0.0193402 0) (2.9721 0.0411737 0) (2.95114 0.0738243 0) (2.92139 0.119996 0) (2.88545 0.186861 0) (2.85065 0.257007 0) (2.80019 0.340264 0) (2.76223 0.414765 0) (2.7065 0.51695 0) (2.64834 0.623966 0) (2.6341 0.678466 0) (2.5569 0.77012 0) (2.51524 0.834485 0) (2.48966 0.862484 0) (2.46475 0.892444 0) (2.44483 0.885385 0) (2.43136 0.856654 0) (2.43432 0.831798 0) (2.44233 0.811713 0) (2.46647 0.79117 0) (2.49963 0.768618 0) (2.50969 0.753634 0) (2.52432 0.736945 0) (2.53973 0.71591 0) (2.54348 0.700187 0) (2.54831 0.686584 0) (2.56059 0.672623 0) (2.56617 0.665698 0) (2.57296 0.661726 0) (2.58122 0.659577 0) (2.59012 0.662004 0) (2.59874 0.666173 0) (2.6075 0.671387 0) (2.61344 0.677325 0) (2.61584 0.685192 0) (2.61986 0.689404 0) (2.62394 0.690282 0) (2.62792 0.690266 0) (2.63186 0.690321 0) (2.63566 0.69185 0) (2.63952 0.694447 0) (2.64305 0.69619 0) (2.64639 0.697391 0) (2.64961 0.69842 0) (2.65264 0.6993 0) (2.65589 0.699982 0) (2.65912 0.700636 0) (2.66254 0.701449 0) (2.66666 0.701886 0) (2.67177 0.702032 0) (2.67718 0.703053 0) (2.68218 0.705012 0) (2.68662 0.706575 0) (2.69084 0.707588 0) (2.69468 0.709561 0) (2.69832 0.713017 0) (2.70126 0.715631 0) (2.70502 0.717773 0) (2.70848 0.72014 0) (2.71157 0.722626 0) (2.71426 0.724936 0) (2.71705 0.726954 0) (2.71979 0.728514 0) (2.72192 0.729377 0) (2.72362 0.729694 0) (2.72502 0.729885 0) (2.72638 0.730182 0) (2.72788 0.730722 0) (2.72962 0.731438 0) (2.73165 0.7322 0) (2.73391 0.732636 0) (2.73619 0.732858 0) (2.73848 0.733303 0) (2.74081 0.734522 0) (2.74329 0.736469 0) (2.74624 0.738588 0) (2.7498 0.74083 0) (2.75676 0.743206 0) (3 1.31814e-07 0) (3 4.33271e-06 0) (2.99997 3.71672e-05 0) (2.9999 0.000131844 0) (2.99971 0.000401335 0) (2.99914 0.00122012 0) (2.99807 0.00304923 0) (2.99636 0.00609989 0) (2.99261 0.0122632 0) (2.9852 0.0251691 0) (2.97434 0.0464446 0) (2.96012 0.0794428 0) (2.94095 0.119756 0) (2.90462 0.195673 0) (2.87002 0.285019 0) (2.84833 0.347802 0) (2.79241 0.467953 0) (2.73738 0.576695 0) (2.73154 0.602177 0) (2.65785 0.666846 0) (2.60899 0.71292 0) (2.59246 0.714714 0) (2.56843 0.729038 0) (2.56282 0.73316 0) (2.56132 0.729311 0) (2.55984 0.723849 0) (2.55858 0.719379 0) (2.55592 0.72155 0) (2.55594 0.721397 0) (2.55941 0.721031 0) (2.5712 0.716456 0) (2.58536 0.711322 0) (2.59629 0.704223 0) (2.6064 0.697995 0) (2.61777 0.694093 0) (2.62635 0.692555 0) (2.63289 0.689556 0) (2.63949 0.686768 0) (2.64196 0.685155 0) (2.64545 0.682906 0) (2.64921 0.682088 0) (2.65376 0.684007 0) (2.65734 0.687484 0) (2.66094 0.689204 0) (2.66603 0.69196 0) (2.67116 0.694084 0) (2.67686 0.695675 0) (2.68208 0.696804 0) (2.68723 0.697676 0) (2.69213 0.698639 0) (2.69646 0.699619 0) (2.70031 0.700651 0) (2.7048 0.702269 0) (2.7093 0.703779 0) (2.71398 0.704865 0) (2.71818 0.706094 0) (2.72162 0.708118 0) (2.72509 0.710512 0) (2.72865 0.712827 0) (2.73178 0.715087 0) (2.73459 0.717486 0) (2.73734 0.719832 0) (2.74035 0.722084 0) (2.74343 0.724573 0) (2.74652 0.72689 0) (2.74904 0.728779 0) (2.75111 0.730213 0) (2.75303 0.731147 0) (2.7549 0.731638 0) (2.75666 0.731948 0) (2.75831 0.732065 0) (2.75988 0.73193 0) (2.7614 0.73205 0) (2.76281 0.732629 0) (2.76442 0.733385 0) (2.76658 0.734506 0) (2.76961 0.736136 0) (2.77376 0.738291 0) (2.77868 0.741132 0) (2.78654 0.744452 0) (3 4.15065e-12 0) (3 -1.75893e-09 0) (3 3.98898e-09 0) (3 -6.09758e-08 0) (3 1.60407e-07 0) (3 2.47748e-07 0) (3 1.73189e-06 0) (2.99999 7.658e-06 0) (2.99998 2.60837e-05 0) (2.99994 9.35095e-05 0) (2.99982 0.000303303 0) (2.99953 0.000834825 0) (2.99876 0.00221998 0) (2.99674 0.00570458 0) (2.99199 0.0152099 0) (2.98338 0.0329712 0) (2.96129 0.0732762 0) (2.92016 0.156727 0) (2.89067 0.233802 0) (2.81355 0.371436 0) (2.73904 0.503877 0) (2.71926 0.538183 0) (2.63002 0.647293 0) (2.58161 0.738136 0) (2.57126 0.731487 0) (2.55697 0.742301 0) (2.54785 0.766657 0) (2.53826 0.773092 0) (2.54147 0.767957 0) (2.54371 0.764167 0) (2.55224 0.755084 0) (2.56556 0.741868 0) (2.57919 0.727868 0) (2.59773 0.711775 0) (2.61346 0.698046 0) (2.62507 0.692035 0) (2.63831 0.682059 0) (2.64627 0.676361 0) (2.65029 0.676191 0) (2.65654 0.680072 0) (2.66248 0.684054 0) (2.66783 0.688282 0) (2.67265 0.691613 0) (2.67771 0.693823 0) (2.68252 0.695111 0) (2.68735 0.695389 0) (2.69254 0.696094 0) (2.6974 0.696549 0) (2.70238 0.696901 0) (2.7074 0.697643 0) (2.7118 0.698627 0) (2.71652 0.699279 0) (2.72138 0.699467 0) (2.726 0.699097 0) (2.73094 0.698689 0) (2.73548 0.699148 0) (2.73917 0.70037 0) (2.74241 0.701836 0) (2.74565 0.703475 0) (2.74892 0.705774 0) (2.75241 0.708786 0) (2.75616 0.711914 0) (2.75996 0.714677 0) (2.7636 0.717425 0) (2.7671 0.720169 0) (2.77048 0.722504 0) (2.77367 0.724371 0) (2.77655 0.725988 0) (2.77912 0.727423 0) (2.78142 0.728864 0) (2.7835 0.730248 0) (2.78533 0.731695 0) (2.78707 0.733024 0) (2.78881 0.734663 0) (2.79078 0.73623 0) (2.79321 0.737596 0) (2.79649 0.738687 0) (2.80109 0.73997 0) (2.80628 0.741813 0) (2.8126 0.744787 0) (3 1.61255e-15 0) (3 -7.56507e-11 0) (3 -9.02551e-11 0) (3 -2.07107e-09 0) (3 -2.58598e-09 0) (3 -2.67367e-09 0) (3 -2.73266e-09 0) (3 -1.25726e-09 0) (3 -5.88452e-10 0) (3 -4.27485e-08 0) (3 1.36057e-07 0) (3 1.64085e-07 0) (3 4.77018e-07 0) (3 4.98481e-06 0) (2.99998 2.23664e-05 0) (2.99993 9.73208e-05 0) (2.99967 0.000443599 0) (2.9988 0.00169824 0) (2.99607 0.00588915 0) (2.98723 0.0184721 0) (2.9681 0.0493024 0) (2.93542 0.101058 0) (2.87793 0.186058 0) (2.81065 0.30508 0) (2.77294 0.369322 0) (2.69768 0.47839 0) (2.62617 0.614759 0) (2.61695 0.625035 0) (2.61542 0.629466 0) (2.58852 0.677952 0) (2.57524 0.698434 0) (2.57604 0.697526 0) (2.58106 0.696126 0) (2.59089 0.695894 0) (2.60257 0.695138 0) (2.616 0.694063 0) (2.63005 0.691085 0) (2.6404 0.68937 0) (2.64684 0.691696 0) (2.65382 0.693099 0) (2.65767 0.694033 0) (2.66395 0.695534 0) (2.67065 0.696939 0) (2.67624 0.69689 0) (2.68123 0.695486 0) (2.68641 0.694029 0) (2.69122 0.693146 0) (2.69604 0.691643 0) (2.70119 0.689953 0) (2.7066 0.688998 0) (2.71195 0.688936 0) (2.71739 0.688586 0) (2.72266 0.686967 0) (2.72827 0.685115 0) (2.73399 0.684416 0) (2.73894 0.685053 0) (2.74303 0.686609 0) (2.74674 0.688205 0) (2.75026 0.689777 0) (2.75397 0.691592 0) (2.75762 0.694535 0) (2.76176 0.697906 0) (2.76605 0.701227 0) (2.77013 0.704519 0) (2.77399 0.707912 0) (2.77758 0.711073 0) (2.78096 0.714006 0) (2.78418 0.71668 0) (2.78725 0.718836 0) (2.79022 0.720757 0) (2.79315 0.722515 0) (2.79609 0.724053 0) (2.79902 0.725581 0) (2.80199 0.727357 0) (2.80502 0.729122 0) (2.80815 0.73088 0) (2.81165 0.732485 0) (2.81492 0.735671 0) (2.81919 0.739156 0) (2.82191 0.741943 0) (3 5.90986e-16 0) (3 -1.01188e-13 0) (3 -2.2512e-12 0) (3 -3.24235e-11 0) (3 -1.14342e-10 0) (3 -2.70363e-10 0) (3 -3.18645e-10 0) (3 -3.44286e-10 0) (3 -6.31842e-10 0) (3 -1.0929e-09 0) (3 -7.60506e-10 0) (3 -8.22475e-10 0) (3 -1.57471e-09 0) (3 -2.07115e-09 0) (3 1.03507e-09 0) (3 -5.43575e-08 0) (3 7.93452e-08 0) (3 5.8764e-07 0) (3 2.5687e-06 0) (2.99997 3.40705e-05 0) (2.99985 0.000198098 0) (2.99933 0.000863878 0) (2.99724 0.00364316 0) (2.99133 0.0119023 0) (2.97797 0.0313425 0) (2.94513 0.0744545 0) (2.89705 0.14556 0) (2.83768 0.241831 0) (2.77614 0.335551 0) (2.68694 0.474131 0) (2.64119 0.562253 0) (2.64171 0.582305 0) (2.59816 0.641401 0) (2.57868 0.70644 0) (2.57718 0.714788 0) (2.58772 0.712871 0) (2.60447 0.716773 0) (2.61455 0.717395 0) (2.62635 0.716608 0) (2.63618 0.71135 0) (2.65003 0.705508 0) (2.65747 0.699697 0) (2.66465 0.695761 0) (2.67264 0.691964 0) (2.68087 0.688372 0) (2.68809 0.685864 0) (2.6946 0.68457 0) (2.70028 0.683112 0) (2.70573 0.681464 0) (2.71081 0.681125 0) (2.7155 0.682118 0) (2.72033 0.682792 0) (2.7249 0.681343 0) (2.72987 0.681238 0) (2.73453 0.682465 0) (2.73857 0.684394 0) (2.74206 0.687025 0) (2.74554 0.68954 0) (2.74866 0.692141 0) (2.75218 0.694556 0) (2.75506 0.697942 0) (2.75862 0.701824 0) (2.76219 0.706148 0) (2.76569 0.710373 0) (2.76913 0.714763 0) (2.77249 0.719011 0) (2.77571 0.723161 0) (2.77917 0.726709 0) (2.78235 0.729941 0) (2.78548 0.732669 0) (2.78837 0.735575 0) (2.79119 0.738437 0) (2.79393 0.741319 0) (2.79665 0.74408 0) (2.79942 0.746745 0) (2.80224 0.749246 0) (2.80511 0.751843 0) (2.80961 0.753505 0) (2.81383 0.755409 0) (2.81391 0.755575 0) (3 4.89674e-17 0) (3 -2.26648e-16 0) (3 -6.29763e-15 0) (3 -1.48332e-15 0) (3 -1.37564e-13 0) (3 -8.10729e-13 0) (3 -1.84129e-12 0) (3 -4.77616e-12 0) (3 -7.37002e-12 0) (3 -2.32058e-11 0) (3 -6.95358e-11 0) (3 -1.49639e-10 0) (3 -2.28221e-10 0) (3 -2.66498e-10 0) (3 -3.86206e-10 0) (3 -2.0495e-09 0) (3 -1.62453e-09 0) (3 -9.23327e-10 0) (3 -1.03752e-09 0) (3 -1.86784e-08 0) (3 5.26047e-08 0) (3 2.86201e-08 0) (3 1.18642e-06 0) (2.99999 1.5176e-05 0) (2.99993 8.92304e-05 0) (2.99959 0.000508627 0) (2.9983 0.00230041 0) (2.9946 0.00732994 0) (2.98393 0.0210774 0) (2.95689 0.0567455 0) (2.92004 0.111405 0) (2.86787 0.193142 0) (2.80313 0.293352 0) (2.76065 0.374582 0) (2.73234 0.436614 0) (2.69981 0.503367 0) (2.67365 0.568599 0) (2.66926 0.60335 0) (2.67667 0.611046 0) (2.68987 0.608677 0) (2.69632 0.618901 0) (2.69558 0.632658 0) (2.69779 0.641376 0) (2.70196 0.644604 0) (2.70577 0.648944 0) (2.71043 0.653222 0) (2.715 0.657169 0) (2.71929 0.660161 0) (2.72201 0.663732 0) (2.72441 0.666771 0) (2.72728 0.669252 0) (2.72995 0.672525 0) (2.73301 0.675649 0) (2.73533 0.678518 0) (2.73593 0.681223 0) (2.73762 0.68464 0) (2.73996 0.688785 0) (2.74131 0.693664 0) (2.74163 0.697758 0) (2.7442 0.702776 0) (2.74599 0.707632 0) (2.74921 0.711756 0) (2.75148 0.716212 0) (2.75522 0.720308 0) (2.7589 0.724819 0) (2.76244 0.729031 0) (2.76549 0.733664 0) (2.76885 0.736928 0) (2.77163 0.740715 0) (2.77457 0.743493 0) (2.77712 0.747043 0) (2.77983 0.750046 0) (2.78263 0.753115 0) (2.78563 0.755522 0) (2.78854 0.758162 0) (2.79143 0.760517 0) (2.79454 0.762662 0) (2.79771 0.763794 0) (2.79965 0.76442 0) (2.80089 0.764095 0) (3 -6.41642e-17 0) (3 -3.04452e-17 0) (3 -8.47139e-18 0) (3 3.97137e-16 0) (3 3.04312e-16 0) (3 6.64159e-16 0) (3 -2.23472e-15 0) (3 -4.90602e-15 0) (3 -4.86824e-15 0) (3 -5.71786e-14 0) (3 -3.54375e-13 0) (3 -1.02912e-12 0) (3 -1.99583e-12 0) (3 -4.63926e-12 0) (3 -1.07951e-11 0) (3 -1.36887e-11 0) (3 -6.61562e-11 0) (3 -1.08586e-10 0) (3 -2.0002e-10 0) (3 -1.0651e-09 0) (3 -1.03964e-09 0) (3 -1.07608e-09 0) (3 -8.12532e-10 0) (3 -1.76726e-09 0) (3 5.30016e-09 0) (3 -8.24102e-09 0) (3 5.83796e-07 0) (2.99999 6.40523e-06 0) (2.99996 4.86711e-05 0) (2.99975 0.000317563 0) (2.99901 0.00136607 0) (2.99662 0.00455354 0) (2.98986 0.0137501 0) (2.97542 0.0350032 0) (2.95151 0.0723663 0) (2.91707 0.127286 0) (2.87928 0.19359 0) (2.84557 0.262795 0) (2.81397 0.333092 0) (2.78518 0.403044 0) (2.76365 0.463165 0) (2.75169 0.506533 0) (2.74408 0.540831 0) (2.73639 0.572143 0) (2.73062 0.598721 0) (2.72852 0.618798 0) (2.72719 0.635797 0) (2.72833 0.648259 0) (2.72592 0.662724 0) (2.72416 0.674718 0) (2.72525 0.681088 0) (2.72583 0.688165 0) (2.72596 0.696589 0) (2.72355 0.705445 0) (2.72327 0.710844 0) (2.72444 0.712735 0) (2.7266 0.714229 0) (2.72907 0.716992 0) (2.73132 0.720028 0) (2.73432 0.720919 0) (2.73709 0.721725 0) (2.74056 0.721653 0) (2.74424 0.722583 0) (2.7487 0.723308 0) (2.753 0.725797 0) (2.7578 0.728015 0) (2.76206 0.731845 0) (2.7668 0.733991 0) (2.77036 0.738024 0) (2.77424 0.740411 0) (2.7771 0.744692 0) (2.78057 0.747123 0) (2.78366 0.750395 0) (2.78707 0.752319 0) (2.78993 0.755213 0) (2.79294 0.757395 0) (2.79584 0.758855 0) (2.79864 0.759863 0) (2.79974 0.759223 0) (2.80133 0.758818 0) (3 1.62099e-16 0) (3 1.84363e-16 0) (3 1.84676e-16 0) (3 -8.48583e-18 0) (3 1.02004e-17 0) (3 7.66338e-17 0) (3 7.50592e-17 0) (3 9.91115e-17 0) (3 8.55879e-17 0) (3 9.77382e-17 0) (3 1.16801e-16 0) (3 -6.71047e-16 0) (3 5.51556e-16 0) (3 -7.73345e-15 0) (3 -1.28475e-14 0) (3 -1.50321e-14 0) (3 -1.24688e-13 0) (3 -8.76778e-13 0) (3 -2.51808e-12 0) (3 -7.46976e-12 0) (3 -4.89336e-11 0) (3 -1.03981e-10 0) (3 -1.28145e-10 0) (3 -3.34649e-10 0) (3 -3.96276e-10 0) (3 -4.50093e-10 0) (3 -4.55963e-10 0) (3 8.41523e-11 0) (3 -1.67334e-08 0) (3 4.24913e-08 0) (3 2.01588e-07 0) (3 2.76586e-06 0) (2.99998 2.42568e-05 0) (2.9999 0.000137347 0) (2.99959 0.000573662 0) (2.99865 0.00194794 0) (2.99637 0.0054821 0) (2.99182 0.0128639 0) (2.98387 0.0261653 0) (2.97166 0.0476587 0) (2.95564 0.0783255 0) (2.93735 0.117055 0) (2.91853 0.160574 0) (2.90044 0.205624 0) (2.88354 0.250664 0) (2.86789 0.295109 0) (2.854 0.337283 0) (2.84134 0.377472 0) (2.83129 0.412383 0) (2.82343 0.442762 0) (2.81568 0.471506 0) (2.80889 0.497276 0) (2.80374 0.51978 0) (2.80195 0.536025 0) (2.80093 0.550964 0) (2.79916 0.566121 0) (2.7969 0.581061 0) (2.79569 0.594041 0) (2.79656 0.602388 0) (2.79752 0.610455 0) (2.79846 0.618287 0) (2.79819 0.62749 0) (2.79774 0.636496 0) (2.79772 0.644919 0) (2.79774 0.653571 0) (2.79903 0.661109 0) (2.8002 0.669067 0) (2.80281 0.675285 0) (2.80424 0.682984 0) (2.80706 0.688522 0) (2.80865 0.695717 0) (2.81178 0.699593 0) (2.81349 0.705298 0) (2.81624 0.707998 0) (2.81755 0.712606 0) (2.82005 0.714331 0) (2.82136 0.717253 0) (2.82374 0.718885 0) (2.82272 0.719857 0) (2.82407 0.72158 0) (3 1.18197e-16 0) (3 1.06558e-16 0) (3 7.45482e-17 0) (3 2.2742e-16 0) (3 2.00608e-16 0) (3 1.41347e-16 0) (3 9.72358e-17 0) (3 1.07656e-16 0) (3 2.03699e-16 0) (3 1.68041e-16 0) (3 3.26356e-17 0) (3 4.30158e-17 0) (3 1.20653e-16 0) (3 1.07049e-16 0) (3 -1.55664e-16 0) (3 -1.1262e-16 0) (3 -2.4646e-16 0) (3 3.56426e-16 0) (3 -3.27789e-15 0) (3 -2.37113e-15 0) (3 -5.65141e-14 0) (3 -4.3411e-13 0) (3 -1.3815e-12 0) (3 -2.08188e-12 0) (3 -1.93256e-11 0) (3 -4.62358e-11 0) (3 -6.6925e-11 0) (3 -2.23372e-10 0) (3 -2.43614e-10 0) (3 -2.06513e-10 0) (3 -2.31615e-10 0) (3 -1.33387e-09 0) (3 2.13673e-09 0) (3 1.66438e-08 0) (3 1.25891e-08 0) (3 6.5296e-07 0) (3 4.88566e-06 0) (2.99998 2.38793e-05 0) (2.99994 9.18304e-05 0) (2.99981 0.000294564 0) (2.99951 0.000802308 0) (2.99891 0.00188661 0) (2.99782 0.00393636 0) (2.99603 0.00748102 0) (2.99325 0.0131787 0) (2.98926 0.0216992 0) (2.98386 0.0336597 0) (2.97703 0.0493778 0) (2.96877 0.069246 0) (2.95928 0.0930727 0) (2.94885 0.120041 0) (2.93763 0.149818 0) (2.92592 0.18194 0) (2.91386 0.216573 0) (2.90198 0.252289 0) (2.89076 0.287628 0) (2.88043 0.321637 0) (2.87107 0.354373 0) (2.8619 0.387498 0) (2.85416 0.418782 0) (2.84729 0.448781 0) (2.84206 0.475248 0) (2.83755 0.499257 0) (2.83369 0.52092 0) (2.83076 0.539993 0) (2.82815 0.558317 0) (2.82685 0.574325 0) (2.8255 0.590433 0) (2.82544 0.603903 0) (2.8256 0.616822 0) (2.82583 0.628863 0) (2.82715 0.638715 0) (2.82634 0.650282 0) (2.82832 0.656538 0) (2.82625 0.667076 0) (2.82818 0.671067 0) (2.82536 0.680013 0) (2.82687 0.682542 0) (2.82306 0.688448 0) (2.82876 0.694578 0) (3 1.35082e-17 0) (3 1.18398e-17 0) (3 3.38856e-17 0) (3 -1.34076e-16 0) (3 -1.39405e-16 0) (3 -1.27723e-16 0) (3 -2.90001e-17 0) (3 -3.93028e-17 0) (3 -9.75702e-17 0) (3 -8.57353e-17 0) (3 -1.5459e-17 0) (3 1.03238e-17 0) (3 -9.82459e-17 0) (3 -8.80567e-17 0) (3 3.4592e-17 0) (3 1.73261e-17 0) (3 3.47126e-18 0) (3 -6.60692e-17 0) (3 -1.35853e-16 0) (3 -9.59617e-17 0) (3 -8.38954e-17 0) (3 5.60287e-17 0) (3 -5.4198e-16 0) (3 -1.58137e-16 0) (3 -1.95187e-14 0) (3 -2.73893e-13 0) (3 -8.28429e-13 0) (3 -1.93072e-12 0) (3 -8.97336e-12 0) (3 -2.01344e-11 0) (3 -3.36926e-11 0) (3 -1.32695e-10 0) (3 -1.28487e-10 0) (3 -2.73891e-10 0) (3 -1.27061e-09 0) (3 -1.98952e-09 0) (3 -1.97731e-09 0) (3 -9.5499e-09 0) (3 1.98486e-08 0) (3 -1.08779e-07 0) (3 5.63841e-07 0) (3 7.18579e-07 0) (3 3.30823e-06 0) (2.99999 1.06417e-05 0) (2.99998 2.9263e-05 0) (2.99996 7.24981e-05 0) (2.99991 0.000163988 0) (2.99982 0.000342245 0) (2.99967 0.000665643 0) (2.99941 0.00121732 0) (2.999 0.00211055 0) (2.99839 0.00348694 0) (2.9975 0.00553577 0) (2.99625 0.00846168 0) (2.99457 0.0125252 0) (2.9924 0.0179623 0) (2.98971 0.0249548 0) (2.9865 0.0336116 0) (2.98282 0.0439474 0) (2.97871 0.0560552 0) (2.97432 0.0697472 0) (2.96978 0.084847 0) (2.96522 0.100917 0) (2.96075 0.117549 0) (2.95638 0.134602 0) (2.95231 0.151568 0) (2.94852 0.168485 0) (2.94528 0.184663 0) (2.94237 0.20045 0) (2.94002 0.215204 0) (2.93802 0.229064 0) (2.93646 0.241707 0) (2.935 0.25329 0) (2.93379 0.263757 0) (2.93223 0.27376 0) (2.93136 0.281626 0) (2.9289 0.291113 0) (2.92845 0.29667 0) (2.92413 0.306734 0) (2.93514 0.318779 0) (3 -5.4033e-17 0) (3 -7.44216e-17 0) (3 -7.45482e-17 0) (3 -9.84356e-17 0) (3 -9.18035e-17 0) (3 -7.66338e-17 0) (3 -1.39883e-16 0) (3 -9.74027e-17 0) (3 -1.164e-16 0) (3 -9.08794e-17 0) (3 -3.26356e-17 0) (3 -3.2692e-17 0) (3 -4.99848e-17 0) (3 -3.79852e-17 0) (3 -2.24848e-17 0) (3 8.66306e-18 0) (3 9.8931e-17 0) (3 3.65119e-17 0) (3 1.88104e-16 0) (3 2.75672e-16 0) (3 2.63921e-16 0) (3 2.46876e-16 0) (3 1.42072e-16 0) (3 7.73113e-17 0) (3 8.44888e-17 0) (3 1.93963e-17 0) (3 -1.13581e-15 0) (3 5.83958e-17 0) (3 -1.04679e-14 0) (3 -1.09561e-13 0) (3 -2.68276e-13 0) (3 -8.62635e-13 0) (3 -4.88154e-12 0) (3 -2.45143e-11 0) (3 -1.10308e-10 0) (3 -2.34028e-10 0) (3 -4.57199e-10 0) (3 -6.46027e-10 0) (3 -4.9833e-10 0) (3 -5.97404e-10 0) (3 -6.03227e-10 0) (3 -4.10254e-10 0) (3 -8.06057e-10 0) (3 5.15224e-10 0) (3 -3.36917e-09 0) (3 1.32948e-08 0) (3 -3.60642e-09 0) (3 1.12421e-07 0) (3 2.72117e-07 0) (3 2.16865e-07 0) (3 1.97876e-06 0) (3 2.59966e-06 0) (3 7.71727e-06 0) (2.99999 1.43665e-05 0) (2.99999 2.99103e-05 0) (2.99997 5.53023e-05 0) (2.99995 0.000100707 0) (2.99992 0.000172099 0) (2.99988 0.000284812 0) (2.99981 0.000449514 0) (2.99972 0.000687237 0) (2.99961 0.00100797 0) (2.99946 0.00143497 0) (2.99928 0.00196802 0) (2.99906 0.00263237 0) (2.99882 0.00341018 0) (2.99855 0.00432736 0) (2.99826 0.00534374 0) (2.99795 0.00647155 0) (2.99765 0.00765138 0) (2.99734 0.0088903 0) (2.99706 0.0101115 0) (2.99676 0.0113796 0) (2.9965 0.0125533 0) (2.99619 0.0138148 0) (2.99593 0.0149244 0) (2.99554 0.0162514 0) (2.99527 0.0174256 0) (2.99465 0.0189795 0) (2.99609 0.0217048 0) (3 -4.39018e-17 0) (3 -4.90506e-17 0) (3 -5.59112e-17 0) (3 -5.26122e-17 0) (3 -5.2702e-17 0) (3 6.81189e-17 0) (3 3.41178e-17 0) (3 1.19617e-16 0) (3 5.47762e-17 0) (3 1.02882e-17 0) (3 1.0306e-17 0) (3 2.23682e-17 0) (3 6.54973e-17 0) (3 5.52513e-17 0) (3 1.7296e-16 0) (3 2.23507e-16 0) (3 3.26299e-16 0) (3 1.9473e-16 0) (3 1.27145e-16 0) (3 -1.57028e-17 0) (3 -4.36955e-17 0) (3 -3.50179e-17 0) (3 9.99769e-17 0) (3 7.90684e-17 0) (3 9.32897e-17 0) (3 6.17155e-17 0) (3 -7.94893e-17 0) (3 -6.19349e-17 0) (3 -9.74996e-17 0) (3 1.77588e-17 0) (3 -5.97763e-16 0) (3 3.02981e-17 0) (3 -1.74134e-14 0) (3 -3.40826e-14 0) (3 -2.91354e-13 0) (3 -1.5591e-12 0) (3 -4.87912e-12 0) (3 -1.04975e-11 0) (3 -4.17884e-11 0) (3 -4.80265e-11 0) (3 -7.93443e-11 0) (3 -8.57467e-11 0) (3 -1.09177e-10 0) (3 -9.48125e-11 0) (3 -2.12496e-10 0) (3 -1.60299e-10 0) (3 -2.70622e-10 0) (3 -2.75798e-10 0) (3 -2.07355e-10 0) (3 -8.41566e-11 0) (3 -1.45408e-10 0) (3 9.59998e-11 0) (3 -2.94822e-10 0) (3 1.34234e-09 0) (3 -5.00505e-10 0) (3 8.82123e-09 0) (3 3.19212e-09 0) (3 4.40559e-08 0) (3 3.34185e-08 0) (3 1.75577e-07 0) (3 1.7391e-07 0) (3 5.46317e-07 0) (3 6.71125e-07 0) (3 1.36097e-06 0) (3 1.95161e-06 0) (3 3.10781e-06 0) (3 4.43101e-06 0) (3 6.38172e-06 0) (3 8.44737e-06 0) (3 1.14818e-05 0) (3 1.39638e-05 0) (2.99999 1.81024e-05 0) (2.99999 2.06784e-05 0) (2.99999 2.56536e-05 0) (2.99999 2.82247e-05 0) (2.99999 3.40571e-05 0) (2.99999 3.66535e-05 0) (2.99999 4.61549e-05 0) (2.99998 4.74007e-05 0) (2.99999 6.61914e-05 0) (3 -7.42953e-17 0) (3 -6.25818e-17 0) (3 6.77711e-17 0) (3 4.24292e-17 0) (3 3.74014e-17 0) (3 -3.23565e-17 0) (3 -3.24119e-17 0) (3 -2.22146e-17 0) (3 -8.55879e-18 0) (3 8.40206e-17 0) (3 1.42566e-16 0) (3 1.11841e-16 0) (3 8.79042e-17 0) (3 6.73375e-17 0) (3 2.24848e-17 0) (3 -4.50479e-17 0) (3 -6.5954e-17 0) (3 -8.34559e-17 0) (3 -1.20178e-16 0) (3 -5.58323e-17 0) (3 -6.99129e-17 0) (3 -7.35376e-17 0) (3 -1.50842e-16 0) (3 -6.32547e-17 0) (3 -1.61937e-16 0) (3 -1.00508e-16 0) (3 -1.21884e-16 0) (3 -1.00865e-16 0) (3 -1.01045e-16 0) (3 -7.10353e-17 0) (3 -3.73602e-17 0) (3 -7.12896e-17 0) (3 -1.32122e-16 0) (3 -2.18215e-16 0) (3 -1.29014e-16 0) (3 -1.61379e-15 0) (3 -6.58192e-16 0) (3 -2.72401e-14 0) (3 -2.01541e-13 0) (3 -4.01741e-13 0) (3 -8.24328e-13 0) (3 -1.51888e-12 0) (3 -2.00725e-12 0) (3 -7.24291e-12 0) (3 -6.44693e-12 0) (3 -1.21116e-11 0) (3 -1.23582e-11 0) (3 -2.00452e-11 0) (3 -2.34819e-11 0) (3 -1.95986e-11 0) (3 -2.04176e-11 0) (3 -1.50106e-11 0) (3 -1.97391e-11 0) (3 -1.26633e-11 0) (3 -1.799e-11 0) (3 -1.25146e-11 0) (3 -6.40194e-12 0) (3 -1.2015e-12 0) (3 -2.85591e-12 0) (3 3.93854e-12 0) (3 -2.73829e-12 0) (3 1.55131e-11 0) (3 -1.75298e-12 0) (3 4.86843e-11 0) (3 1.04524e-11 0) (3 1.31718e-10 0) (3 7.1049e-11 0) (3 3.15182e-10 0) (3 2.28039e-10 0) (3 6.5359e-10 0) (3 5.14754e-10 0) (3 1.16805e-09 0) (3 9.38727e-10 0) (3 1.83527e-09 0) (3 1.45704e-09 0) (3 2.69948e-09 0) (3 2.07998e-09 0) (3 4.19748e-09 0) (3 2.59621e-09 0) (3 7.23704e-09 0) (3 2.5328e-17 0) (3 1.86054e-17 0) (3 -2.88027e-17 0) (3 -3.39433e-17 0) (3 -3.40013e-17 0) (3 -5.44951e-17 0) (3 -5.45885e-17 0) (3 5.46822e-17 0) (3 3.25234e-17 0) (3 -8.23059e-17 0) (3 -1.63178e-16 0) (3 -1.75505e-16 0) (3 -1.80979e-16 0) (3 -1.64027e-16 0) (3 -2.07552e-16 0) (3 -1.35144e-16 0) (3 -1.73563e-16 0) (3 -1.72128e-16 0) (3 -5.39929e-17 0) (3 -1.23878e-16 0) (3 -1.04869e-16 0) (3 -1.20812e-16 0) (3 -1.21025e-16 0) (3 -9.66392e-17 0) (3 1.76018e-18 0) (3 1.23431e-17 0) (3 -1.05986e-17 0) (3 1.2387e-17 0) (3 1.2409e-17 0) (3 -2.13106e-17 0) (3 -4.44764e-17 0) (3 -5.52495e-17 0) (3 -5.7134e-17 0) (3 -3.75616e-17 0) (3 -2.50861e-17 0) (3 3.59019e-17 0) (3 3.59668e-18 0) (3 1.98175e-17 0) (3 1.80486e-18 0) (3 1.80814e-18 0) (3 -1.34046e-16 0) (3 -1.43001e-15 0) (3 -9.03568e-16 0) (3 -2.64354e-14 0) (3 -2.14184e-14 0) (3 -5.58106e-14 0) (3 -5.24336e-14 0) (3 -7.95201e-14 0) (3 -1.54479e-13 0) (3 -3.54277e-13 0) (3 -3.81158e-13 0) (3 -9.09527e-13 0) (3 -6.26485e-13 0) (3 -8.37448e-13 0) (3 -5.45234e-13 0) (3 -7.52724e-13 0) (3 -6.8866e-13 0) (3 -4.30324e-13 0) (3 -3.21153e-13 0) (3 -1.48796e-13 0) (3 -1.60531e-13 0) (3 -8.66192e-14 0) (3 -3.25935e-14 0) (3 -6.44866e-15 0) (3 -8.71307e-17 0) (3 2.13877e-15 0) (3 6.08442e-16 0) (3 4.48632e-15 0) (3 1.02305e-15 0) (3 1.09558e-14 0) (3 2.10379e-15 0) (3 2.11341e-14 0) (3 1.42564e-14 0) (3 2.90883e-14 0) (3 1.63024e-14 0) (3 4.49029e-14 0) (3 1.91941e-14 0) (3 7.2863e-14 0) (3 1.19269e-14 0) (3 1.32044e-13 0) (3 -3.54591e-17 0) (3 -3.3828e-17 0) (3 -7.62425e-17 0) (3 1.18802e-17 0) (3 -1.19005e-17 0) (3 -1.02178e-17 0) (3 1.79544e-31 0) (3 1.36706e-17 0) (3 -2.05411e-16 0) (3 -1.92047e-16 0) (3 -1.59743e-16 0) (3 -8.4311e-17 0) (3 -6.205e-17 0) (3 -3.97118e-17 0) (3 -5.01584e-17 0) (3 -1.1955e-16 0) (3 -1.05874e-16 0) (3 3.82506e-17 0) (3 -1.79396e-16 0) (3 -1.70986e-16 0) (3 -1.22347e-16 0) (3 -5.42778e-17 0) (3 -1.05239e-17 0) (3 -1.05425e-17 0) (3 -1.68978e-16 0) (3 -1.58697e-16 0) (3 -9.18543e-17 0) (3 -7.25523e-17 0) (3 -4.4318e-17 0) (3 -3.37418e-17 0) (3 -8.53947e-17 0) (3 -6.95074e-17 0) (3 -8.92719e-18 0) (3 3.75616e-17 0) (3 7.52583e-17 0) (3 2.06436e-16 0) (3 2.19397e-16 0) (3 2.17993e-16 0) (3 1.9673e-16 0) (3 1.97087e-16 0) (3 3.804e-17 0) (3 1.45178e-16 0) (3 1.98167e-16 0) (3 -8.56044e-17 0) (3 -3.28448e-17 0) (3 1.46245e-17 0) (3 3.29656e-17 0) (3 -3.6696e-18 0) (3 -7.16892e-17 0) (3 -9.7604e-17 0) (3 -3.8745e-16 0) (3 -2.78742e-15 0) (3 -2.07409e-15 0) (3 -3.34142e-15 0) (3 -2.0967e-15 0) (3 -3.34834e-15 0) (3 -4.56175e-15 0) (3 -5.63205e-15 0) (3 -3.59009e-15 0) (3 -7.92172e-15 0) (3 -5.69967e-15 0) (3 -5.20005e-15 0) (3 -3.09085e-15 0) (3 -1.15512e-15 0) (3 -2.25403e-16 0) (3 -3.07436e-16 0) (3 -2.90911e-16 0) (3 -2.28602e-16 0) (3 -1.2979e-16 0) (3 -1.60636e-16 0) (3 -1.5903e-16 0) (3 -4.41534e-16 0) (3 -3.94302e-16 0) (3 -2.92926e-16 0) (3 -2.68393e-16 0) (3 -2.1281e-17 0) (3 -1.43442e-16 0) (3 -3.59304e-16 0) (3 -2.99681e-16 0) (3 -2.15146e-16 0) (3 -5.4033e-17 0) (3 -4.2285e-17 0) (3 -1.01657e-17 0) (3 -1.3747e-16 0) (3 -7.8203e-17 0) (3 -7.83367e-17 0) (3 -5.45885e-17 0) (3 -1.05947e-16 0) (3 -3.42351e-17 0) (3 1.38891e-16 0) (3 1.27107e-16 0) (3 9.80761e-17 0) (3 9.82459e-17 0) (3 8.11503e-17 0) (3 7.95617e-17 0) (3 4.15827e-17 0) (3 3.99195e-17 0) (3 3.47733e-17 0) (3 4.52843e-17 0) (3 2.54735e-16 0) (3 1.88765e-16 0) (3 2.31118e-16 0) (3 2.03462e-16 0) (3 1.66922e-16 0) (3 1.9186e-16 0) (3 1.56934e-16 0) (3 2.64964e-16 0) (3 1.2387e-17 0) (3 3.54544e-17 0) (3 -3.55176e-18 0) (3 1.20976e-16 0) (3 3.65359e-16 0) (3 3.17808e-16 0) (3 3.25533e-16 0) (3 3.47622e-16 0) (3 2.42338e-16 0) (3 2.01414e-16 0) (3 1.29715e-16 0) (3 1.24535e-16 0) (3 1.03064e-16 0) (3 1.10497e-16 0) (3 2.55877e-16 0) (3 7.45398e-17 0) (3 8.19616e-17 0) (3 7.11636e-17 0) (3 4.38734e-17 0) (3 5.86055e-17 0) (3 7.33919e-17 0) (3 1.56246e-16 0) (3 -5.3406e-17 0) (3 -9.77849e-17 0) (3 -9.05728e-17 0) (3 -5.74078e-17 0) (3 -1.05753e-16 0) (3 -9.29389e-17 0) (3 2.60716e-17 0) (3 -8.02271e-17 0) (3 -5.42082e-17 0) (3 -3.93281e-17 0) (3 -1.03196e-16 0) (3 -2.2746e-16 0) (3 -2.01523e-16 0) (3 -1.62279e-16 0) (3 -1.15323e-16 0) (3 -1.15543e-16 0) (3 -1.32843e-17 0) (3 2.85207e-17 0) (3 1.31446e-16 0) (3 6.68035e-17 0) (3 -1.7211e-17 0) (3 3.64043e-17 0) (3 -2.11168e-17 0) (3 6.73198e-17 0) (3 7.9013e-17 0) (3 1.11991e-16 0) (3 7.15815e-17 0) (3 -8.33513e-17 0) (3 1.94218e-18 0) (3 6.03254e-17 0) (3 -2.43964e-17 0) (3 1.6041e-16 0) (3 1.84363e-16 0) (3 1.62651e-16 0) (3 2.24026e-16 0) (3 2.09108e-16 0) (3 2.04357e-16 0) (3 2.69531e-16 0) (3 2.08476e-16 0) (3 3.1154e-16 0) (3 7.03029e-17 0) (3 8.41656e-17 0) (3 8.08698e-17 0) (3 5.68792e-17 0) (3 5.69779e-17 0) (3 7.26433e-17 0) (3 6.58392e-17 0) (3 6.07471e-17 0) (3 -5.38986e-17 0) (3 1.35853e-16 0) (3 -3.29759e-16 0) (3 -1.22347e-16 0) (3 -1.64584e-16 0) (3 -1.3681e-16 0) (3 -9.83963e-17 0) (3 -3.16833e-17 0) (3 -1.05798e-17 0) (3 -1.41314e-17 0) (3 8.67089e-17 0) (3 1.41818e-16 0) (3 1.93571e-16 0) (3 1.8858e-16 0) (3 6.77252e-17 0) (3 1.35693e-16 0) (3 -6.87085e-31 0) (3 5.37559e-17 0) (3 4.30823e-17 0) (3 1.25884e-17 0) (3 1.26112e-17 0) (3 1.2634e-17 0) (3 -1.08488e-17 0) (3 1.19554e-16 0) (3 1.45178e-17 0) (3 6.36315e-17 0) (3 3.64274e-17 0) (3 1.00359e-16 0) (3 6.94662e-17 0) (3 1.83142e-18 0) (3 -3.11916e-17 0) (3 -1.32349e-16 0) (3 -1.74951e-16 0) (3 -1.5129e-16 0) (3 -1.36783e-16 0) (3 -1.22223e-16 0) (3 -1.20595e-16 0) (3 9.29389e-18 0) (3 -1.22909e-16 0) (3 -1.28736e-16 0) (3 -1.30847e-16 0) (3 -1.06748e-16 0) (3 -1.06949e-16 0) (3 -7.33137e-17 0) (3 -6.02686e-17 0) (3 8.11395e-17 0) (3 7.56219e-17 0) (3 -1.36378e-16 0) (3 2.23935e-16 0) (3 2.12955e-16 0) (3 1.04776e-16 0) (3 -3.05387e-17 0) (3 2.84938e-16 0) (3 2.64411e-16 0) (3 2.51482e-16 0) (3 2.00036e-16 0) (3 1.69589e-16 0) (3 1.48678e-16 0) (3 9.67318e-17 0) (3 1.74456e-17 0) (3 2.81617e-16 0) (3 2.70491e-16 0) (3 1.83729e-16 0) (3 3.36018e-16 0) (3 3.12909e-16 0) (3 2.84639e-16 0) (3 2.59666e-16 0) (3 2.41409e-16 0) (3 1.85624e-16 0) (3 5.80003e-17 0) (3 5.6391e-17 0) (3 4.45057e-17 0) (3 1.20029e-17 0) (3 3.43533e-17 0) (3 3.44127e-17 0) (3 4.65375e-17 0) (3 7.25173e-17 0) (3 9.33985e-17 0) (3 9.3561e-17 0) (3 3.47126e-18 0) (3 1.87776e-16 0) (3 1.89846e-16 0) (3 1.44815e-16 0) (3 2.00999e-16 0) (3 1.40072e-16 0) (3 1.15763e-16 0) (3 7.90684e-17 0) (3 1.0033e-16 0) (3 8.8165e-17 0) (3 6.88907e-17 0) (3 1.2387e-16 0) (3 7.97724e-17 0) (3 9.94494e-17 0) (3 2.84649e-17 0) (3 -8.55476e-17 0) (3 -2.28536e-16 0) (3 -4.29275e-17 0) (3 -1.84562e-16 0) (3 -3.94921e-17 0) (3 -5.57485e-17 0) (3 -3.24287e-17 0) (3 -5.77555e-17 0) (3 -3.61627e-17 0) (3 -8.51371e-17 0) (3 -3.23022e-16 0) (3 -2.45436e-16 0) (3 -2.56813e-16 0) (3 -3.55818e-16 0) (3 -3.54643e-16 0) (3 -2.76545e-16 0) (3 -2.56872e-16 0) (3 -1.26835e-16 0) (3 -1.30753e-16 0) (3 -3.8745e-17 0) (3 -5.73012e-17 0) (3 -4.44447e-17 0) (3 -7.42126e-17 0) (3 -1.50561e-16 0) (3 -1.39669e-16 0) (3 -1.15676e-16 0) (3 -9.90702e-17 0) (3 -1.12366e-17 0) (3 -2.62681e-17 0) (3 7.51935e-17 0) (3 8.0986e-17 0) (3 -2.64175e-17 0) (3 -1.51244e-17 0) (3 -1.51532e-17 0) (3 6.83192e-17 0) (3 -9.5069e-18 0) (3 7.81058e-17 0) (3 6.10775e-17 0) (3 1.10916e-16 0) (3 2.91235e-16 0) (3 1.15183e-17 0) (3 -3.26982e-17 0) (3 3.85429e-17 0) (3 5.40647e-17 0) (3 6.96469e-17 0) (3 1.58949e-16 0) (3 6.21499e-17 0) (3 7.39473e-17 0) (3 1.20968e-16 0) (3 -5.06559e-18 0) (3 -5.41248e-17 0) (3 -3.38856e-17 0) (3 -1.35773e-16 0) (3 -1.41105e-16 0) (3 -9.87724e-17 0) (3 -2.55884e-16 0) (3 4.61381e-17 0) (3 4.27939e-17 0) (3 3.77235e-17 0) (3 1.20237e-17 0) (3 9.97967e-17 0) (3 -5.17084e-18 0) (3 -5.1798e-17 0) (3 -5.53472e-17 0) (3 -5.71762e-17 0) (3 -4.33908e-17 0) (3 -1.39093e-17 0) (3 9.05687e-17 0) (3 9.94512e-17 0) (3 3.49564e-17 0) (3 3.50179e-17 0) (3 5.08654e-17 0) (3 5.27123e-17 0) (3 1.44335e-16 0) (3 1.02271e-16 0) (3 1.05986e-16 0) (3 7.96306e-17 0) (3 2.30454e-16 0) (3 -1.04777e-16 0) (3 1.24534e-16 0) (3 9.26765e-17 0) (3 8.5701e-17 0) (3 7.33345e-17 0) (3 5.01722e-17 0) (3 -2.02846e-16 0) (3 4.49585e-17 0) (3 -4.8643e-17 0) (3 -5.23409e-17 0) (3 -5.42441e-17 0) (3 -1.32234e-16 0) (3 -1.46993e-16 0) (3 -3.12704e-16 0) (3 -2.89598e-16 0) (3 -2.88304e-16 0) (3 -2.04743e-16 0) (3 -1.06222e-16 0) (3 -2.42193e-16 0) (3 -2.44479e-16 0) (3 -1.5101e-16 0) (3 -1.7343e-16 0) (3 -9.05728e-17 0) (3 -5.74078e-17 0) (3 3.5251e-17 0) (3 1.30114e-17 0) (3 1.11735e-17 0) (3 1.30602e-17 0) (3 -9.34624e-18 0) (3 -1.62931e-16 0) (3 -6.3794e-17 0) (3 -1.86104e-16 0) (3 -1.39371e-16 0) (3 -1.37748e-16 0) (3 -1.20995e-16 0) (3 1.89414e-17 0) (3 -1.32843e-16 0) (3 -1.31195e-16 0) (3 -2.20982e-16 0) (3 -2.06137e-16 0) (3 -3.61432e-16 0) (3 -3.10395e-16 0) (3 -2.53402e-16 0) (3 -1.92342e-18 0) (3 2.64019e-16 0) (3 -1.11991e-16 0) (3 2.34091e-16 0) (3 1.86087e-16 0) (3 2.58311e-16 0) (3 2.39356e-16 0) (3 1.37937e-16 0) (3 -2.46525e-16 0) (3 -1.64066e-16 0) (3 -1.60956e-16 0) (3 -7.46753e-17 0) (3 -3.23012e-17 0) (3 -3.23565e-17 0) (3 -8.52945e-18 0) (3 -3.24676e-17 0) (3 5.09316e-32 0) (3 2.05765e-17 0) (3 5.49653e-17 0) (3 -1.20444e-17 0) (3 7.75625e-17 0) (3 7.07907e-17 0) (3 5.36176e-17 0) (3 5.3711e-17 0) (3 5.38046e-17 0) (3 5.38986e-17 0) (3 1.04502e-17 0) (3 -3.48952e-18 0) (3 -7.8652e-17 0) (3 -4.20215e-17 0) (3 1.92938e-17 0) (3 5.44694e-17 0) (3 -3.52037e-18 0) (3 -5.11357e-17 0) (3 -1.58979e-17 0) (3 1.00865e-16 0) (3 7.6227e-17 0) (3 -3.55176e-18 0) (3 -1.54778e-16 0) (3 -1.28321e-16 0) (3 -1.07126e-16 0) (3 -9.47982e-17 0) (3 -9.85526e-17 0) (3 -1.36427e-16 0) (3 -1.74439e-16 0) (3 -2.10786e-16 0) (3 -2.16583e-16 0) (3 -2.06128e-16 0) (3 -1.97446e-16 0) (3 -1.97806e-16 0) (3 -9.63563e-17 0) (3 -8.19616e-17 0) (3 -8.7586e-17 0) (3 -1.3162e-16 0) (3 -1.77648e-16 0) (3 -8.25659e-17 0) (3 -4.59546e-17 0) (3 2.44931e-16 0) (3 1.6236e-16 0) (3 1.70055e-16 0) (3 1.50001e-16 0) (3 4.08169e-17 0) (3 -1.85878e-17 0) (3 -4.84186e-17 0) (3 -8.39586e-17 0) (3 -1.42063e-16 0) (3 5.6183e-18 0) (3 -5.62889e-17 0) (3 -1.37228e-16 0) (3 -4.33181e-17 0) (3 -1.09444e-16 0) (3 -1.09652e-16 0) (3 -1.5532e-16 0) (3 -2.06855e-16 0) (3 -1.73026e-16 0) (3 -1.29541e-16 0) (3 -8.39815e-17 0) (3 -1.31951e-16 0) (3 3.06563e-17 0) (3 8.63871e-17 0) (3 3.07748e-17 0) (3 7.32315e-17 0) (3 5.21339e-17 0) (3 -3.09542e-17 0) (3 -5.03985e-17 0) (3 -3.88437e-17 0) (3 -1.693e-16 0) (3 -1.52246e-16 0) (3 -8.10495e-17 0) (3 5.9199e-17 0) (3 1.62651e-16 0) (3 2.25723e-16 0) (3 2.00608e-16 0) (3 1.46456e-16 0) (3 2.25178e-16 0) (3 1.98223e-16 0) (3 1.72887e-16 0) (3 1.54324e-16 0) (3 1.15084e-16 0) (3 7.74285e-17 0) (3 9.65223e-17 0) (3 1.00143e-16 0) (3 1.00317e-16 0) (3 1.00491e-16 0) (3 1.24966e-16 0) (3 1.65173e-16 0) (3 1.07986e-16 0) (3 3.48952e-17 0) (3 3.49564e-17 0) (3 -3.50179e-18 0) (3 -9.2961e-17 0) (3 -1.1421e-16 0) (3 -2.11222e-17 0) (3 -4.40825e-17 0) (3 2.70264e-16 0) (3 -3.53914e-17 0) (3 -1.25863e-16 0) (3 -2.07778e-16 0) (3 -1.92138e-16 0) (3 -2.01393e-16 0) (3 -1.71402e-16 0) (3 -1.37726e-16 0) (3 -1.41557e-16 0) (3 -1.47198e-16 0) (3 -1.4027e-16 0) (3 -1.33318e-16 0) (3 -1.2995e-16 0) (3 -1.15721e-16 0) (3 -9.78171e-17 0) (3 -8.52923e-17 0) (3 -6.54496e-17 0) (3 -3.4606e-17 0) (3 -2.18965e-17 0) (3 4.57015e-17 0) (3 3.29656e-17 0) (3 2.91733e-16 0) (3 2.55508e-16 0) (3 -2.02574e-17 0) (3 8.67149e-17 0) (3 -3.88169e-17 0) (3 -5.00003e-17 0) (3 7.60679e-17 0) (3 6.13397e-17 0) (3 -1.50843e-16 0) (3 -9.88845e-17 0) (3 -7.66392e-17 0) (3 -1.68549e-17 0) (3 -9.38148e-18 0) (3 3.57169e-17 0) (3 -1.1677e-16 0) (3 3.77393e-17 0) (3 8.12936e-17 0) (3 1.85626e-16 0) (3 1.82185e-16 0) (3 1.55913e-16 0) (3 1.63832e-16 0) (3 1.33607e-16 0) (3 1.89321e-16 0) (3 1.03465e-16 0) (3 7.48688e-17 0) (3 6.73198e-17 0) (3 -1.15629e-17 0) (3 -1.35162e-17 0) (3 -6.77123e-17 0) (3 -7.55977e-17 0) (3 -2.50542e-16 0) (3 -6.03254e-17 0) (3 -5.42382e-17 0) (3 3.20821e-16 0) (3 2.36796e-17 0) (3 -8.13253e-17 0) (3 -1.15407e-16 0) (3 -1.17304e-16 0) (3 -8.34457e-17 0) (3 -1.50118e-16 0) (3 -7.86057e-17 0) (3 -1.42076e-16 0) (3 -7.71618e-17 0) (3 -8.93185e-17 0) (3 -1.20444e-16 0) (3 -3.44722e-17 0) (3 -7.59705e-17 0) (3 1.03776e-17 0) (3 -1.38609e-17 0) (3 -7.98391e-17 0) (3 -1.99946e-16 0) (3 -1.95071e-16 0) (3 -1.67497e-16 0) (3 -1.88765e-16 0) (3 -2.03104e-16 0) (3 -2.50819e-16 0) (3 -1.88007e-16 0) (3 -3.02751e-16 0) (3 -2.78601e-16 0) (3 -2.36702e-16 0) (3 -2.81361e-16 0) (3 -2.23363e-16 0) (3 -4.33315e-16 0) (3 -1.17418e-16 0) (3 -1.3545e-16 0) (3 -1.69617e-16 0) (3 -1.68133e-16 0) (3 -1.68435e-16 0) (3 -1.68739e-16 0) (3 -1.70842e-16 0) (3 -7.38653e-17 0) (3 -3.60972e-17 0) (3 -9.76394e-17 0) (3 -1.19554e-16 0) (3 -9.07365e-18 0) (3 3.63609e-17 0) (3 2.54992e-17 0) (3 1.38678e-16 0) (3 -2.541e-16 0) (3 -6.59312e-17 0) (3 -1.44949e-16 0) (3 -5.88219e-17 0) (3 -1.03129e-16 0) (3 -1.67895e-16 0) (3 -1.4048e-16 0) (3 -1.27779e-16 0) (3 -2.00374e-16 0) (3 -1.41267e-16 0) (3 -2.68165e-16 0) (3 2.23889e-16 0) (3 2.01879e-16 0) (3 2.00386e-16 0) (3 2.0264e-16 0) (3 1.71065e-16 0) (3 2.29774e-16 0) (3 2.28323e-16 0) (3 2.87363e-16 0) (3 8.90248e-17 0) (3 1.00581e-16 0) (3 1.2359e-16 0) (3 1.25731e-16 0) (3 1.06886e-16 0) (3 1.74023e-16 0) (3 -1.09213e-16 0) (3 -4.41534e-17 0) (3 -1.92342e-16 0) (3 -1.85006e-16 0) (3 -4.05486e-17 0) (3 -1.35425e-17 0) (3 -5.83208e-32 0) (3 8.73983e-17 0) (3 4.47576e-17 0) (3 2.48584e-17 0) (3 -7.59839e-17 0) (3 -8.96442e-17 0) (3 -1.35542e-16 0) (3 -1.57836e-16 0) (3 -1.63206e-16 0) (3 -1.41347e-16 0) (3 -3.1559e-16 0) (3 -3.55434e-16 0) (3 -3.14963e-16 0) (3 -3.58374e-16 0) (3 -3.34945e-16 0) (3 -2.7186e-16 0) (3 -3.39552e-16 0) (3 -3.19421e-16 0) (3 -3.18247e-16 0) (3 -2.99742e-16 0) (3 -2.96793e-16 0) (3 -2.97311e-16 0) (3 -2.97832e-16 0) (3 -3.00098e-16 0) (3 -2.86643e-16 0) (3 -2.69638e-16 0) (3 -2.28017e-16 0) (3 -2.37205e-16 0) (3 -2.78109e-16 0) (3 -2.46862e-16 0) (3 -2.57899e-16 0) (3 -2.35353e-16 0) (3 -2.58817e-16 0) (3 -2.43296e-16 0) (3 -3.9495e-16 0) (3 -3.5823e-16 0) (3 -2.96383e-16 0) (3 -2.57565e-16 0) (3 -2.18608e-16 0) (3 -1.68739e-16 0) (3 -1.5106e-16 0) (3 2.04017e-30 0) (3 1.98535e-17 0) (3 -2.82069e-16 0) (3 -1.75708e-16 0) (3 5.44419e-18 0) (3 2.76343e-16 0) (3 2.62277e-16 0) (3 1.47801e-16 0) (3 1.59041e-16 0) (3 1.53839e-16 0) (3 1.28436e-16 0) (3 1.63599e-16 0) (3 1.98891e-16 0) (3 1.60515e-16 0) (3 1.21996e-16 0) (3 9.81487e-17 0) (3 1.7811e-16 0) (3 2.45359e-16 0) (3 3.44517e-16 0) (3 2.03366e-16 0) (3 2.03748e-16 0) (3 1.91022e-16 0) (3 1.38846e-16 0) (3 1.29709e-16 0) (3 1.18654e-16 0) (3 6.41568e-17 0) (3 1.58806e-16 0) (3 1.45849e-16 0) (3 1.36638e-16 0) (3 1.33097e-16 0) (3 1.56212e-16 0) (3 1.08794e-16 0) (3 2.84938e-16 0) (3 1.05381e-16 0) (3 9.40659e-17 0) (3 2.11576e-17 0) (3 5.97415e-17 0) (3 -2.89633e-17 0) (3 1.35425e-17 0) (3 6.00905e-17 0) (3 -1.35953e-17 0) (3 3.89196e-18 0) (3 1.29998e-17 0) (3 -2.02624e-16 0) (3 -1.87745e-16 0) (3 -1.69428e-16 0) (3 -1.17104e-16 0) (3 -1.17304e-16 0) (3 -9.87724e-17 0) (3 -1.14295e-16 0) (3 -3.24676e-17 0) (3 -9.75702e-17 0) (3 -1.18315e-16 0) (3 -1.18519e-16 0) (3 -9.11936e-17 0) (3 -1.63743e-16 0) (3 -1.41581e-16 0) (3 -1.88527e-16 0) (3 -1.88855e-16 0) (3 -1.56207e-16 0) (3 -1.44309e-16 0) (3 -1.14953e-16 0) (3 -7.67694e-17 0) (3 -7.69041e-17 0) (3 -1.57581e-17 0) (3 1.22779e-17 0) (3 -7.90684e-17 0) (3 6.86471e-17 0) (3 -1.05798e-17 0) (3 2.29636e-17 0) (3 3.53914e-17 0) (3 3.54544e-17 0) (3 6.74835e-17 0) (3 1.06743e-16 0) (3 1.26539e-16 0) (3 1.46406e-16 0) (3 1.48458e-16 0) (3 1.48725e-16 0) (3 1.48993e-16 0) (3 -3.95634e-17 0) (3 5.60295e-16 0) (3 3.50143e-16 0) (3 -3.6886e-16 0) (3 -3.98514e-17 0) (3 2.86727e-16 0) (3 3.83607e-16 0) (3 3.64274e-16 0) (3 2.88304e-16 0) (3 8.77468e-17 0) (3 9.34025e-17 0) (3 1.13757e-16 0) (3 1.30511e-16 0) (3 2.2099e-16 0) (3 1.845e-16 0) (3 1.79297e-16 0) (3 1.64816e-16 0) (3 9.09104e-17 0) (3 4.27519e-17 0) (3 -3.53829e-17 0) (3 -2.61204e-17 0) (3 -5.60775e-18 0) (3 1.87277e-17 0) (3 9.19385e-17 0) (3 1.1467e-16 0) (3 1.54438e-16 0) (3 1.41522e-16 0) (3 1.15323e-16 0) (3 1.81838e-16 0) (3 6.26259e-17 0) (3 1.99645e-16 0) (3 1.92407e-16 0) (3 1.88958e-16 0) (3 1.24302e-16 0) (3 1.26457e-16 0) (3 1.13263e-16 0) (3 1.01941e-16 0) (3 2.81363e-16 0) (3 1.60263e-16 0) (3 2.72784e-16 0) (3 -1.10489e-16 0) (3 -1.16531e-16 0) (3 -7.39473e-17 0) (3 9.47176e-17 0) (3 -5.57215e-17 0) (3 -7.27302e-17 0) (3 -7.28539e-17 0) (3 -7.46753e-17 0) (3 -5.2702e-17 0) (3 -5.27922e-17 0) (3 -1.19412e-17 0) (3 -9.91115e-17 0) (3 -5.30645e-17 0) (3 2.915e-17 0) (3 -3.95063e-17 0) (3 1.03238e-17 0) (3 5.3432e-17 0) (3 1.00143e-16 0) (3 3.28624e-17 0) (3 5.02457e-17 0) (3 6.94253e-17 0) (3 8.86718e-17 0) (3 1.18436e-16 0) (3 1.22133e-16 0) (3 1.34582e-16 0) (3 1.22563e-16 0) (3 1.35056e-16 0) (3 1.45837e-16 0) (3 1.26733e-16 0) (3 1.5517e-16 0) (3 1.80176e-16 0) (3 1.80496e-16 0) (3 1.93226e-16 0) (3 1.84692e-16 0) (3 2.15266e-16 0) (3 3.35061e-16 0) (3 3.2495e-16 0) (3 2.91549e-16 0) (3 2.90282e-16 0) (3 2.8542e-16 0) (3 3.99231e-16 0) (3 3.89144e-16 0) (3 3.42923e-16 0) (3 3.48971e-16 0) (3 2.64468e-16 0) (3 5.00865e-16 0) (3 2.39982e-16 0) (3 1.03818e-16 0) (3 1.04008e-16 0) (3 1.00543e-16 0) (3 1.04391e-16 0) (3 1.02749e-16 0) (3 1.72789e-16 0) (3 9.76041e-17 0) (3 2.214e-16 0) (3 1.94085e-16 0) (3 1.20371e-16 0) (3 2.70876e-16 0) (3 2.04466e-16 0) (3 1.7319e-16 0) (3 2.72399e-16 0) (3 2.28048e-16 0) (3 2.49078e-16 0) (3 2.73939e-16 0) (3 2.51898e-16 0) (3 2.52375e-16 0) (3 2.05679e-16 0) (3 2.57115e-16 0) (3 5.87185e-17 0) (3 5.69327e-17 0) (3 4.37317e-17 0) (3 1.71452e-17 0) (3 -3.43561e-17 0) (3 -8.79675e-17 0) (3 -8.62208e-17 0) (3 -1.13263e-16 0) (3 -1.25022e-16 0) (3 -2.58238e-16 0) (3 -2.29775e-16 0) (3 -1.8379e-16 0) (3 -1.24058e-16 0) (3 -4.46702e-17 0) (3 2.10166e-16 0) (3 1.1559e-16 0) (3 7.42953e-17 0) (3 3.3828e-17 0) (3 3.38856e-17 0) (3 3.22462e-17 0) (3 3.23012e-17 0) (3 2.38416e-17 0) (3 -9.55299e-17 0) (3 1.09364e-16 0) (3 5.47762e-17 0) (3 1.68041e-16 0) (3 1.64896e-16 0) (3 1.20444e-16 0) (3 2.06833e-16 0) (3 1.65754e-16 0) (3 1.66042e-16 0) (3 2.04448e-16 0) (3 2.10012e-16 0) (3 1.70389e-16 0) (3 1.67204e-16 0) (3 1.67497e-16 0) (3 2.11486e-16 0) (3 1.83844e-16 0) (3 1.68382e-16 0) (3 2.26663e-16 0) (3 2.97471e-16 0) (3 2.89181e-16 0) (3 2.84395e-16 0) (3 2.83131e-16 0) (3 2.81862e-16 0) (3 2.94796e-16 0) (3 3.9673e-16 0) (3 3.33279e-16 0) (3 3.0531e-16 0) (3 3.11224e-16 0) (3 3.09993e-16 0) (3 3.08756e-16 0) (3 2.46372e-16 0) (3 1.17104e-16 0) (3 1.35364e-16 0) (3 1.98895e-16 0) (3 2.22806e-16 0) (3 9.61807e-17 0) (3 5.63594e-17 0) (3 8.19616e-17 0) (3 8.21119e-17 0) (3 1.11512e-16 0) (3 6.04369e-17 0) (3 7.88963e-17 0) (3 3.67637e-17 0) (3 3.31485e-17 0) (3 2.214e-17 0) (3 -2.40295e-17 0) (3 1.03704e-16 0) (3 9.64763e-17 0) (3 8.17863e-17 0) (3 9.31128e-17 0) (3 1.47394e-16 0) (3 -1.88794e-16 0) (3 -1.7604e-16 0) (3 -2.72063e-16 0) (3 -2.89495e-16 0) (3 -3.25827e-16 0) (3 -3.13236e-16 0) (3 -2.53333e-16 0) (3 -2.70863e-16 0) (3 -2.29628e-16 0) (3 -2.05349e-16 0) (3 -2.07647e-16 0) (3 -1.90867e-16 0) (3 -1.62549e-16 0) (3 -1.16877e-16 0) (3 -2.72599e-16 0) (3 2.23117e-16 0) (3 -8.28673e-17 0) (3 -7.91662e-17 0) (3 -9.47972e-17 0) (3 1.10489e-16 0) (3 5.63234e-17 0) (3 -1.94598e-17 0) (3 -1.24249e-16 0) (3 1.13132e-16 0) (3 7.44216e-17 0) (3 3.38856e-17 0) (3 5.26122e-17 0) (3 7.65029e-17 0) (3 8.85546e-17 0) (3 1.85942e-16 0) (3 1.17909e-16 0) (3 2.60187e-16 0) (3 1.01168e-16 0) (3 9.96245e-17 0) (3 1.20444e-16 0) (3 -1.89597e-17 0) (3 6.90641e-18 0) (3 2.11011e-16 0) (3 1.45539e-16 0) (3 1.16287e-16 0) (3 1.21706e-16 0) (3 2.50806e-16 0) (3 2.07626e-16 0) (3 2.07991e-16 0) (3 2.08357e-16 0) (3 2.10478e-16 0) (3 2.2842e-17 0) (3 8.97693e-17 0) (3 2.04543e-16 0) (3 2.98527e-16 0) (3 3.11444e-16 0) (3 2.85408e-16 0) (3 2.37968e-16 0) (3 1.56557e-16 0) (3 7.66364e-17 0) (3 1.19624e-16 0) (3 1.69921e-16 0) (3 1.64852e-16 0) (3 1.45403e-16 0) (3 5.75468e-17 0) (3 3.60319e-18 0) (3 1.80486e-18 0) (3 3.43546e-17 0) (3 1.44914e-16 0) (3 2.79468e-16 0) (3 3.29066e-16 0) (3 1.82137e-17 0) (3 -7.29883e-18 0) (3 8.22627e-17 0) (3 7.32569e-17 0) (3 5.68787e-17 0) (3 4.04401e-17 0) (3 3.86733e-17 0) (3 2.214e-17 0) (3 -7.3937e-18 0) (3 -1.25927e-16 0) (3 -1.42859e-16 0) (3 -1.43126e-16 0) (3 1.09873e-16 0) (3 -3.28371e-16 0) (3 -1.06547e-16 0) (3 -1.36712e-16 0) (3 -1.76372e-16 0) (3 -1.76705e-16 0) (3 -1.0547e-16 0) (3 -2.64175e-16 0) (3 -3.21393e-17 0) (3 -4.35653e-17 0) (3 -1.1007e-16 0) (3 -1.1028e-16 0) (3 -1.60022e-16 0) (3 -4.38994e-17 0) (3 -3.82468e-17 0) (3 -3.83204e-17 0) (3 -1.82373e-16 0) (3 -1.53874e-16 0) (3 -1.05993e-16 0) (3 -8.3028e-17 0) (3 -1.35425e-17 0) (3 -1.3375e-16 0) (3 -2.29178e-16 0) (3 -4.33954e-16 0) (3 -4.4542e-16 0) (3 7.42953e-17 0) (3 1.04867e-16 0) (3 1.23682e-16 0) (3 2.00266e-16 0) (3 1.71707e-16 0) (3 1.51565e-16 0) (3 5.45885e-17 0) (3 5.46822e-17 0) (3 7.53173e-17 0) (3 3.25794e-17 0) (3 3.43533e-17 0) (3 -4.47365e-17 0) (3 -5.3432e-17 0) (3 -3.4532e-17 0) (3 -5.53472e-17 0) (3 -5.02457e-17 0) (3 -2.95057e-17 0) (3 1.28661e-16 0) (3 5.9218e-17 0) (3 1.51794e-16 0) (3 1.15356e-16 0) (3 1.31317e-16 0) (3 2.33279e-16 0) (3 -1.0191e-16 0) (3 2.81629e-16 0) (3 4.79618e-16 0) (3 5.01666e-16 0) (3 4.90171e-16 0) (3 3.72271e-16 0) (3 1.27864e-16 0) (3 8.36156e-17 0) (3 6.59429e-17 0) (3 8.92719e-17 0) (3 9.12209e-17 0) (3 8.42176e-17 0) (3 4.48774e-17 0) (3 -7.37319e-17 0) (3 -9.36828e-17 0) (3 -1.13706e-16 0) (3 -1.73581e-16 0) (3 -1.48537e-16 0) (3 -1.27031e-16 0) (3 -2.01803e-16 0) (3 -3.82488e-17 0) (3 -6.02154e-17 0) (3 -1.60869e-16 0) (3 -1.70322e-16 0) (3 -1.87149e-16 0) (3 -7.16892e-17 0) (3 -6.07723e-17 0) (3 -1.107e-16 0) (3 -1.25693e-16 0) (3 -2.01853e-16 0) (3 -2.28204e-16 0) (3 -2.26771e-16 0) (3 -2.12297e-16 0) (3 -1.94038e-16 0) (3 -1.53278e-16 0) (3 -1.40457e-16 0) (3 -1.08825e-16 0) (3 -1.07151e-16 0) (3 -1.75156e-16 0) (3 -1.77375e-16 0) (3 -1.90945e-16 0) (3 -3.71252e-16 0) (3 -1.21456e-16 0) (3 -1.15984e-16 0) (3 -8.19158e-17 0) (3 -3.24474e-17 0) (3 -3.82468e-18 0) (3 2.10762e-17 0) (3 5.18323e-17 0) (3 6.73198e-17 0) (3 2.06205e-16 0) (3 2.02743e-16 0) (3 2.28287e-16 0) (3 3.12083e-16 0) (3 2.69964e-16 0) (3 4.37846e-16 0) (3 4.93095e-16 0) (3 1.53656e-16 0) (3 1.23472e-16 0) (3 2.01619e-16 0) (3 -5.26122e-17 0) (3 -5.44021e-17 0) (3 -3.23565e-17 0) (3 -8.18828e-17 0) (3 -1.36706e-17 0) (3 -1.02705e-17 0) (3 7.71618e-17 0) (3 7.72949e-17 0) (3 1.03238e-16 0) (3 2.03386e-16 0) (3 2.03739e-16 0) (3 2.28307e-16 0) (3 2.09646e-16 0) (3 2.60345e-16 0) (3 1.91253e-16 0) (3 5.9218e-17 0) (3 6.28113e-17 0) (3 6.11737e-17 0) (3 3.3267e-17 0) (3 -3.33256e-17 0) (3 3.90071e-16 0) (3 -4.61168e-16 0) (3 -4.47878e-16 0) (3 -6.35914e-17 0) (3 1.07944e-16 0) (3 -2.03863e-16 0) (3 -1.29639e-16 0) (3 -5.14147e-16 0) (3 -4.36649e-16 0) (3 -2.71386e-16 0) (3 -2.7724e-16 0) (3 -2.34734e-16 0) (3 -2.01051e-16 0) (3 -1.99616e-16 0) (3 -9.18812e-17 0) (3 -1.49803e-16 0) (3 -2.85686e-16 0) (3 -5.1988e-16 0) (3 -4.11944e-16 0) (3 -2.87251e-16 0) (3 -1.40245e-16 0) (3 -9.30601e-17 0) (3 -3.1077e-16 0) (3 -3.02185e-16 0) (3 -2.49532e-16 0) (3 -2.022e-16 0) (3 -1.19703e-16 0) (3 -1.2915e-16 0) (3 -1.23844e-16 0) (3 -1.18519e-16 0) (3 -1.20595e-16 0) (3 -1.0595e-16 0) (3 -1.06149e-16 0) (3 -8.39586e-17 0) (3 -9.90702e-17 0) (3 -5.99285e-17 0) (3 -8.44333e-17 0) (3 -8.45927e-17 0) (3 -8.85195e-17 0) (3 -3.77393e-17 0) (3 -4.72637e-17 0) (3 4.16712e-17 0) (3 5.12394e-17 0) (3 1.08379e-16 0) (3 3.25758e-16 0) (3 3.03479e-16 0) (3 3.02149e-16 0) (3 3.00815e-16 0) (3 3.05234e-16 0) (3 3.05824e-16 0) (3 3.27615e-16 0) (3 3.32112e-16 0) (3 3.86927e-16 0) (3 4.09003e-16 0) (3 3.8261e-16 0) (3 3.83358e-16 0) (3 3.18074e-16 0) (3 -3.20821e-17 0) (3 -4.05936e-17 0) (3 -2.20256e-17 0) (3 1.52745e-17 0) (3 5.44021e-17 0) (3 5.44951e-17 0) (3 5.45885e-17 0) (3 7.68969e-17 0) (3 7.70291e-17 0) (3 4.97265e-17 0) (3 1.20237e-17 0) (3 4.98984e-17 0) (3 1.8615e-16 0) (3 1.50214e-16 0) (3 3.4592e-17 0) (3 3.29196e-17 0) (3 -1.73563e-17 0) (3 -2.43413e-17 0) (3 -7.48933e-17 0) (3 -7.50246e-17 0) (3 -7.51563e-17 0) (3 -1.13808e-16 0) (3 -1.61366e-16 0) (3 -2.12606e-16 0) (3 -4.36525e-16 0) (3 -3.33264e-16 0) (3 -2.79096e-16 0) (3 -2.79592e-16 0) (3 -3.03135e-16 0) (3 -2.36192e-16 0) (3 -1.83243e-16 0) (3 -6.23784e-17 0) (3 -8.03447e-17 0) (3 9.83755e-17 0) (3 8.78014e-17 0) (3 5.38529e-17 0) (3 -1.20489e-16 0) (3 3.76533e-16 0) (3 2.88777e-16 0) (3 -2.58564e-16 0) (3 -1.59406e-16 0) (3 1.81473e-17 0) (3 1.30899e-16 0) (3 1.7303e-16 0) (3 1.38678e-16 0) (3 -1.27964e-17 0) (3 3.84599e-17 0) (3 1.24766e-16 0) (3 9.00711e-17 0) (3 -2.94654e-17 0) (3 -4.2435e-17 0) (3 -8.13307e-17 0) (3 -4.44447e-17 0) (3 -2.59744e-17 0) (3 -5.57634e-18 0) (3 9.31128e-18 0) (3 9.32873e-18 0) (3 2.2431e-17 0) (3 2.49078e-16 0) (3 -9.94436e-17 0) (3 1.07151e-16 0) (3 8.66361e-17 0) (3 1.54731e-16 0) (3 6.61692e-17 0) (3 2.31086e-16 0) (3 3.05539e-16 0) (3 2.28166e-16 0) (3 3.00993e-16 0) (3 3.28291e-16 0) (3 2.56253e-16 0) (3 3.54463e-16 0) (3 2.82198e-16 0) (3 3.42369e-16 0) (3 1.77297e-16 0) (3 1.37093e-16 0) (3 5.22352e-17 0) (3 -1.16304e-17 0) (3 5.43812e-17 0) (3 3.89196e-17 0) (3 8.18035e-17 0) (3 4.72789e-17 0) (3 6.93474e-17 0) (3 5.25226e-17 0) (3 5.26122e-17 0) (3 5.2702e-17 0) (3 5.27922e-17 0) (3 7.50592e-17 0) (3 1.53794e-17 0) (3 1.02705e-17 0) (3 6.00147e-17 0) (3 7.55772e-17 0) (3 6.36634e-17 0) (3 -1.91321e-16 0) (3 -1.20862e-17 0) (3 -3.28624e-17 0) (3 -3.1187e-17 0) (3 -5.90115e-17 0) (3 -9.91038e-17 0) (3 -1.01019e-16 0) (3 -1.01196e-16 0) (3 5.24346e-18 0) (3 -7.00358e-18 0) (3 -2.28017e-17 0) (3 -3.26816e-16 0) (3 4.04842e-17 0) (3 -2.29229e-17 0) (3 -9.892e-17 0) (3 -1.07944e-16 0) (3 -7.97724e-17 0) (3 -1.06553e-16 0) (3 -3.55811e-17 0) (3 -8.91121e-17 0) (3 -5.53486e-17 0) (3 -5.5448e-17 0) (3 -5.73397e-17 0) (3 -1.97461e-17 0) (3 -5.93452e-17 0) (3 -4.8643e-17 0) (3 -4.15118e-17 0) (3 -1.80814e-18 0) (3 3.62286e-17 0) (3 2.17768e-17 0) (3 1.27263e-17 0) (3 6.55693e-17 0) (3 -6.93389e-17 0) (3 3.89377e-16 0) (3 -6.77626e-17 0) (3 1.68801e-16 0) (3 5.69837e-17 0) (3 9.39209e-17 0) (3 7.011e-17 0) (3 6.28464e-17 0) (3 3.51854e-17 0) (3 1.15029e-16 0) (3 1.00374e-16 0) (3 8.56638e-17 0) (3 8.20928e-17 0) (3 8.2247e-17 0) (3 5.6183e-17 0) (3 5.62889e-17 0) (3 8.27129e-17 0) (3 9.41697e-17 0) (3 2.03792e-16 0) (3 2.26866e-16 0) (3 1.07966e-16 0) (3 2.27731e-16 0) (3 3.25136e-16 0) (3 2.60988e-16 0) (3 -2.02319e-16 0) (3 -1.58724e-16 0) (3 -2.31838e-16 0) (3 -1.84292e-16 0) (3 1.92342e-18 0) (3 -2.58238e-16 0) (3 -2.33637e-16 0) (3 -2.59241e-16 0) (3 -2.09348e-16 0) (3 -2.68021e-16 0) (3 -8.17312e-17 0) (3 -5.70169e-17 0) (3 7.76724e-17 0) (3 5.75076e-17 0) (3 5.25226e-17 0) (3 7.46753e-17 0) (3 5.2702e-17 0) (3 5.27922e-17 0) (3 5.28826e-17 0) (3 1.02529e-17 0) (3 -3.25234e-17 0) (3 -1.20029e-17 0) (3 -1.0306e-17 0) (3 -1.20444e-17 0) (3 -9.82459e-17 0) (3 -7.94237e-17 0) (3 -7.78321e-17 0) (3 -7.79675e-17 0) (3 -6.5954e-17 0) (3 -3.47733e-17 0) (3 -5.57346e-17 0) (3 -5.58323e-17 0) (3 -9.96258e-17 0) (3 -8.92957e-17 0) (3 -5.43734e-17 0) (3 -7.90684e-17 0) (3 3.52037e-17 0) (3 -3.5266e-17 0) (3 1.76643e-18 0) (3 8.84785e-18 0) (3 2.30454e-17 0) (3 9.057e-17 0) (3 2.49068e-17 0) (3 -1.06934e-17 0) (3 8.92719e-18 0) (3 -7.87004e-17 0) (3 -7.88421e-17 0) (3 -7.89842e-17 0) (3 -7.91269e-17 0) (3 -7.92701e-17 0) (3 -5.23409e-17 0) (3 1.08488e-17 0) (3 -5.61543e-17 0) (3 -4.53682e-17 0) (3 -1.27263e-17 0) (3 -3.64274e-17 0) (3 -5.47413e-18 0) (3 -1.82806e-18 0) (3 -5.31112e-17 0) (3 -1.52288e-16 0) (3 -1.39702e-16 0) (3 -7.18218e-17 0) (3 -5.904e-17 0) (3 -6.0998e-17 0) (3 -7.59264e-17 0) (3 -1.28017e-16 0) (3 -1.17103e-16 0) (3 -7.07657e-17 0) (3 -5.41066e-17 0) (3 3.55157e-17 0) (3 6.74196e-17 0) (3 1.12578e-16 0) (3 1.50387e-16 0) (3 1.54438e-16 0) (3 1.33974e-16 0) (3 5.8607e-17 0) (3 -6.44009e-17 0) (3 -2.23935e-16 0) (3 -3.76473e-16 0) (3 -3.61954e-16 0) (3 -2.78666e-16 0) (3 -2.48604e-16 0) (3 -2.2609e-16 0) (3 -1.11343e-16 0) (3 -1.17329e-16 0) (3 -1.13702e-16 0) (3 -8.88206e-17 0) (3 -8.5124e-17 0) (3 -3.58605e-16 0) (3 3.1075e-17 0) (3 -8.56232e-17 0) (3 1.18859e-17 0) (3 -9.62462e-17 0) (3 -8.457e-17 0) (3 -1.18599e-17 0) (3 -3.39433e-17 0) (3 -2.04008e-17 0) (3 6.81189e-18 0) (3 -1.19412e-17 0) (3 -1.19617e-17 0) (3 -1.19823e-17 0) (3 -1.166e-16 0) (3 -1.20237e-16 0) (3 -9.97967e-17 0) (3 -1.20653e-16 0) (3 -1.20862e-16 0) (3 -1.21072e-16 0) (3 -3.46522e-17 0) (3 -3.12414e-17 0) (3 -3.47733e-17 0) (3 -1.21919e-17 0) (3 -2.61714e-17 0) (3 -5.59303e-17 0) (3 -5.25269e-17 0) (3 -4.20955e-17 0) (3 2.10849e-17 0) (3 -7.39277e-17 0) (3 -1.23431e-17 0) (3 -3.53286e-17 0) (3 2.65435e-17 0) (3 5.49543e-17 0) (3 -1.42071e-17 0) (3 -3.55811e-18 0) (3 1.24757e-17 0) (3 -3.57087e-18 0) (3 -2.68297e-17 0) (3 -3.58373e-17 0) (3 -1.07706e-17 0) (3 1.079e-17 0) (3 1.80159e-18 0) (3 1.57023e-16 0) (3 -1.15721e-16 0) (3 1.81143e-18 0) (3 9.79954e-17 0) (3 7.99939e-17 0) (3 1.51174e-16 0) (3 2.42686e-16 0) (3 2.23023e-16 0) (3 6.9594e-17 0) (3 1.76141e-16 0) (3 5.88219e-17 0) (3 7.36634e-17 0) (3 6.4575e-17 0) (3 4.8059e-17 0) (3 -7.03708e-17 0) (3 -8.16338e-17 0) (3 -6.6916e-17 0) (3 -3.72451e-17 0) (3 -1.30602e-17 0) (3 -5.79467e-17 0) (3 1.53567e-16 0) (3 1.31341e-16 0) (3 1.37228e-16 0) (3 9.04029e-17 0) (3 -6.41568e-17 0) (3 -5.50149e-16 0) (3 -3.73147e-16 0) (3 -3.52983e-16 0) (3 -3.76473e-16 0) (3 -2.62893e-16 0) (3 -2.19497e-16 0) (3 -4.01591e-17 0) (3 -9.19689e-17 0) (3 -1.57416e-16 0) (3 -1.44257e-16 0) (3 -1.25264e-16 0) (3 -6.17883e-17 0) (3 -6.19083e-17 0) (3 -1.3375e-16 0) (3 -9.90514e-17 0) (3 -1.03137e-16 0) (3 -1.73506e-16 0) (3 -1.45214e-16 0) (3 -7.44216e-17 0) (3 -9.48796e-17 0) (3 -7.97668e-17 0) (3 -7.8203e-17 0) (3 -7.66338e-17 0) (3 -8.87063e-17 0) (3 -9.39851e-17 0) (3 -1.164e-16 0) (3 -1.18315e-16 0) (3 -9.96245e-17 0) (3 -1.18724e-16 0) (3 -5.51556e-17 0) (3 -7.07907e-17 0) (3 3.28624e-17 0) (3 3.46522e-18 0) (3 -6.5954e-17 0) (3 -5.56372e-17 0) (3 -5.57346e-17 0) (3 -5.58323e-17 0) (3 -7.51563e-17 0) (3 -7.87903e-17 0) (3 -7.89291e-17 0) (3 -7.73113e-17 0) (3 -3.52037e-18 0) (3 1.05798e-17 0) (3 -1.76643e-18 0) (3 -7.43219e-17 0) (3 -1.2409e-17 0) (3 -3.37418e-17 0) (3 -8.36156e-17 0) (3 -8.37653e-17 0) (3 -8.92719e-17 0) (3 7.15458e-18 0) (3 3.40454e-17 0) (3 1.77714e-16 0) (3 -1.49262e-16 0) (3 -8.64765e-17 0) (3 -2.70729e-17 0) (3 7.77499e-17 0) (3 1.03251e-16 0) (3 7.62186e-17 0) (3 2.72707e-17 0) (3 1.34781e-16 0) (3 -1.31379e-16 0) (3 -1.2248e-16 0) (3 -6.04369e-17 0) (3 -5.68787e-17 0) (3 3.67637e-17 0) (3 3.68317e-17 0) (3 3.69e-17 0) (3 -3.0499e-16 0) (3 2.70372e-16 0) (3 2.24493e-16 0) (3 1.78443e-16 0) (3 2.71889e-16 0) (3 2.68667e-16 0) (3 2.18702e-16 0) (3 4.12008e-17 0) (3 2.43918e-17 0) (3 -8.27129e-17 0) (3 -5.83852e-17 0) (3 -7.54786e-18 0) (3 3.47861e-16 0) (3 3.50417e-16 0) (3 3.05539e-16 0) (3 2.35771e-16 0) (3 1.67642e-16 0) (3 1.62237e-16 0) (3 7.45812e-17 0) (3 8.43048e-17 0) (3 1.3438e-17 0) (3 1.13482e-16 0) (3 8.67216e-17 0) (3 -1.27438e-16 0) (3 -1.3349e-16 0) (3 -2.48116e-16 0) (3 -8.93405e-17 0) (3 -1.28435e-16 0) (3 -2.38272e-16 0) (3 -1.18197e-17 0) (3 -9.3027e-17 0) (3 -6.94654e-17 0) (3 -6.1098e-17 0) (3 -4.42017e-17 0) (3 -6.1307e-17 0) (3 -1.63766e-16 0) (3 -1.36706e-16 0) (3 -1.40364e-16 0) (3 -1.18315e-16 0) (3 -1.23672e-16 0) (3 -9.80761e-17 0) (3 -1.17206e-16 0) (3 -1.20862e-17 0) (3 -2.94032e-17 0) (3 -7.62349e-17 0) (3 -1.19759e-16 0) (3 -1.21706e-17 0) (3 -1.21919e-17 0) (3 8.52311e-32 0) (3 2.9713e-17 0) (3 3.3267e-17 0) (3 1.05239e-17 0) (3 5.62264e-17 0) (3 9.15295e-17 0) (3 1.93963e-17 0) (3 3.35622e-17 0) (3 -1.76957e-17 0) (3 -4.60907e-17 0) (3 -1.01225e-16 0) (3 -1.77906e-18 0) (3 5.34672e-17 0) (3 4.28505e-17 0) (3 1.43092e-17 0) (3 3.24328e-16 0) (3 -2.15412e-16 0) (3 6.29419e-17 0) (3 1.80159e-17 0) (3 1.08292e-17 0) (3 -5.2436e-17 0) (3 -5.43428e-17 0) (3 -1.0344e-16 0) (3 -9.09022e-17 0) (3 -1.09282e-17 0) (3 -1.45977e-17 0) (3 3.65612e-17 0) (3 2.38085e-16 0) (3 -1.13757e-16 0) (3 3.49255e-17 0) (3 2.02574e-17 0) (3 -3.69e-17 0) (3 -3.51201e-17 0) (3 -7.40745e-18 0) (3 1.29872e-17 0) (3 1.30114e-17 0) (3 -2.79338e-17 0) (3 -5.03751e-17 0) (3 -3.7385e-17 0) (3 -2.75297e-16 0) (3 -9.38148e-18 0) (3 -5.63951e-18 0) (3 -4.70849e-17 0) (3 2.09453e-16 0) (3 2.51443e-16 0) (3 7.38717e-17 0) (3 4.55461e-17 0) (3 7.22525e-17 0) (3 5.14355e-17 0) (3 9.73422e-17 0) (3 3.82468e-17 0) (3 1.62862e-16 0) (3 6.14308e-17 0) (3 1.3464e-17 0) (3 -1.15629e-17 0) (3 6.17883e-17 0) (3 3.67581e-17 0) (3 2.9076e-17 0) (3 -2.33062e-17 0) (3 -9.14611e-17 0) (3 -1.19916e-16 0) (3 1.01312e-17 0) (3 -2.87538e-17 0) (3 -2.88027e-17 0) (3 -3.0549e-17 0) (3 -4.25016e-17 0) (3 -1.07287e-16 0) (3 1.19412e-17 0) (3 -5.12646e-18 0) (3 1.71176e-17 0) (3 1.20029e-16 0) (3 5.49653e-17 0) (3 7.74285e-17 0) (3 6.54973e-17 0) (3 6.90641e-18 0) (3 -1.90256e-17 0) (3 -1.24748e-16 0) (3 -7.81035e-17 0) (3 -1.00842e-16 0) (3 -8.01185e-17 0) (3 -7.67694e-17 0) (3 -5.24346e-18 0) (3 3.15161e-17 0) (3 3.33256e-17 0) (3 -1.05425e-17 0) (3 -3.8724e-17 0) (3 -2.29229e-17 0) (3 1.02453e-16 0) (3 9.0248e-17 0) (3 5.6727e-17 0) (3 6.74835e-17 0) (3 3.55811e-17 0) (3 -3.38626e-17 0) (3 -1.07126e-17 0) (3 -1.03741e-16 0) (3 -3.40454e-17 0) (3 -1.74124e-16 0) (3 1.09699e-16 0) (3 6.48574e-17 0) (3 -1.08292e-17 0) (3 3.61627e-17 0) (3 3.62286e-17 0) (3 3.62946e-17 0) (3 3.63609e-17 0) (3 1.27496e-17 0) (3 -1.2773e-17 0) (3 -9.68871e-17 0) (3 -7.69197e-17 0) (3 1.06418e-16 0) (3 6.06601e-17 0) (3 8.10298e-17 0) (3 8.118e-17 0) (3 6.83917e-17 0) (3 -7.77782e-17 0) (3 -8.16338e-17 0) (3 -7.99275e-17 0) (3 -1.52705e-16 0) (3 -1.30602e-16 0) (3 -1.47671e-16 0) (3 -8.05289e-17 0) (3 -8.06807e-17 0) (3 -8.27129e-17 0) (3 -5.83852e-17 0) (3 -1.79262e-16 0) (3 -1.26667e-16 0) (3 -1.3259e-16 0) (3 -1.19559e-16 0) (3 -6.08442e-17 0) (3 -7.62008e-17 0) (3 -6.29862e-17 0) (3 -8.22305e-17 0) (3 -1.09213e-16 0) (3 -6.33505e-17 0) (3 -3.30829e-16 0) (3 -2.5631e-16 0) (3 -3.76522e-16 0) (3 -2.10875e-16 0) (3 -2.09348e-16 0) (3 -2.07814e-16 0) (3 -1.84868e-16 0) (3 -2.36358e-20 0) (3 -3.37706e-17 0) (3 1.18398e-17 0) (3 -1.01657e-17 0) (3 2.0366e-17 0) (3 4.25016e-17 0) (3 6.301e-17 0) (3 1.17706e-16 0) (3 9.91115e-17 0) (3 1.64329e-16 0) (3 1.4575e-16 0) (3 2.00967e-16 0) (3 1.65181e-16 0) (3 1.34442e-16 0) (3 8.97833e-17 0) (3 1.24531e-16 0) (3 1.61133e-16 0) (3 3.36713e-16 0) (3 2.66016e-16 0) (3 1.88104e-16 0) (3 2.09371e-16 0) (3 8.73911e-17 0) (3 5.42778e-17 0) (3 6.31433e-17 0) (3 -3.86557e-17 0) (3 4.92851e-17 0) (3 2.82128e-17 0) (3 -1.2365e-17 0) (3 6.37045e-17 0) (3 9.92723e-17 0) (3 8.87941e-17 0) (3 1.24534e-17 0) (3 2.85159e-17 0) (3 3.57087e-17 0) (3 5.72367e-17 0) (3 3.58373e-17 0) (3 6.64185e-17 0) (3 -1.079e-17 0) (3 -1.26112e-17 0) (3 5.41458e-17 0) (3 -1.80814e-17 0) (3 5.43428e-17 0) (3 3.44799e-17 0) (3 7.63578e-17 0) (3 -3.82488e-17 0) (3 -3.64942e-17 0) (3 -6.76382e-17 0) (3 -9.15711e-17 0) (3 -1.24766e-16 0) (3 -9.55856e-17 0) (3 -7.36634e-17 0) (3 3.5055e-17 0) (3 3.69685e-17 0) (3 6.48152e-17 0) (3 5.38041e-17 0) (3 3.71756e-17 0) (3 5.95922e-17 0) (3 5.97039e-17 0) (3 1.12155e-17 0) (3 3.55825e-17 0) (3 1.68867e-17 0) (3 1.1279e-17 0) (3 1.13004e-17 0) (3 -1.09444e-16 0) (3 -6.04975e-17 0) (3 -8.71307e-17 0) (3 5.69327e-18 0) (3 -1.19787e-16 0) (3 -8.38208e-17 0) (3 -5.53515e-17 0) (3 1.1474e-17 0) (3 -1.34121e-17 0) (3 -1.53577e-17 0) (3 1.11558e-16 0) (3 8.28673e-17 0) (3 1.83434e-16 0) (3 1.60575e-16 0) (3 1.58949e-16 0) (3 1.82565e-16 0) (3 1.84868e-16 0) (3 1.35819e-16 0) (3 7.42953e-17 0) (3 7.78044e-17 0) (3 -6.60768e-17 0) (3 1.57836e-16 0) (3 1.25805e-16 0) (3 1.32832e-16 0) (3 1.41589e-16 0) (3 1.2987e-16 0) (3 8.90114e-17 0) (3 -7.71618e-17 0) (3 -5.15299e-17 0) (3 -1.54857e-17 0) (3 -1.20653e-17 0) (3 -2.24458e-17 0) (3 -7.43729e-17 0) (3 -7.45023e-17 0) (3 -1.68356e-16 0) (3 -1.54741e-16 0) (3 -1.27145e-16 0) (3 -1.25623e-16 0) (3 -1.15356e-16 0) (3 -8.75448e-17 0) (3 -7.71751e-17 0) (3 -1.00153e-16 0) (3 -1.54896e-16 0) (3 -1.83383e-16 0) (3 -2.27869e-16 0) (3 -2.37122e-16 0) (3 -2.2159e-16 0) (3 -1.24312e-16 0) (3 2.13487e-17 0) (3 1.78224e-17 0) (3 1.78544e-18 0) (3 -3.39843e-17 0) (3 -3.40454e-17 0) (3 -8.07793e-17 0) (3 -7.91269e-17 0) (3 -7.20637e-17 0) (3 -1.01072e-16 0) (3 -1.24761e-16 0) (3 -1.92011e-16 0) (3 -1.19772e-16 0) (3 -8.54481e-17 0) (3 -1.03818e-16 0) (3 -1.04008e-16 0) (3 -9.1403e-17 0) (3 4.94484e-17 0) (3 -1.74306e-16 0) (3 -1.50731e-16 0) (3 -1.34436e-16 0) (3 -1.9926e-16 0) (3 -1.82994e-16 0) (3 -1.51853e-16 0) (3 -3.71063e-17 0) (3 -5.76221e-17 0) (3 -4.65564e-17 0) (3 -7.46298e-18 0) (3 3.55157e-17 0) (3 -1.12366e-17 0) (3 -1.12578e-17 0) (3 -9.39919e-18 0) (3 -4.33181e-17 0) (3 4.90611e-17 0) (3 1.09652e-16 0) (3 1.0039e-16 0) (3 8.72968e-17 0) (3 8.55621e-17 0) (3 9.9061e-17 0) (3 2.06137e-16 0) (3 1.81672e-16 0) (3 1.41785e-16 0) (3 1.3438e-16 0) (3 2.1927e-16 0) (3 2.1584e-16 0) (3 3.51421e-16 0) (3 1.48967e-16 0) (3 1.27935e-16 0) (3 1.10705e-16 0) (3 1.10921e-16 0) (3 1.71137e-17 0) (3 -1.85738e-17 0) (3 1.18398e-17 0) (3 8.64082e-17 0) (3 1.18802e-17 0) (3 -7.48028e-17 0) (3 -7.66338e-17 0) (3 -1.27942e-16 0) (3 -7.68969e-17 0) (3 -8.72996e-17 0) (3 -2.53776e-16 0) (3 -1.88943e-17 0) (3 5.1619e-17 0) (3 5.3432e-17 0) (3 -1.7266e-17 0) (3 -7.26433e-17 0) (3 -1.50737e-16 0) (3 -2.20425e-16 0) (3 -1.66912e-16 0) (3 -2.68223e-16 0) (3 -1.48304e-16 0) (3 -1.57304e-17 0) (3 -1.22563e-17 0) (3 -1.22779e-17 0) (3 5.27123e-18 0) (3 -4.04842e-17 0) (3 -3.17394e-17 0) (3 7.24236e-17 0) (3 1.2387e-17 0) (3 1.06363e-17 0) (3 -1.06553e-17 0) (3 -6.2267e-17 0) (3 -4.63383e-17 0) (3 7.32029e-17 0) (3 7.51231e-17 0) (3 1.02136e-16 0) (3 8.79597e-17 0) (3 5.75468e-17 0) (3 5.94526e-17 0) (3 3.42923e-17 0) (3 -9.2215e-17 0) (3 -1.50348e-16 0) (3 -1.32475e-16 0) (3 -1.30899e-16 0) (3 -1.22032e-16 0) (3 -9.67095e-17 0) (3 -5.84979e-17 0) (3 -1.26368e-16 0) (3 8.25659e-17 0) (3 4.9631e-17 0) (3 2.76238e-17 0) (3 -1.107e-17 0) (3 1.0536e-16 0) (3 9.25932e-17 0) (3 5.93701e-17 0) (3 6.13397e-17 0) (3 2.4768e-16 0) (3 -3.54492e-17 0) (3 -1.12155e-17 0) (3 3.74553e-18 0) (3 4.12785e-17 0) (3 7.33137e-17 0) (3 2.22241e-16 0) (3 1.33974e-16 0) (3 1.32338e-16 0) (3 1.30696e-16 0) (3 1.91673e-16 0) (3 2.12955e-16 0) (3 3.77194e-16 0) (3 3.03479e-16 0) (3 2.77289e-16 0) (3 2.37586e-16 0) (3 2.32285e-16 0) (3 3.03901e-16 0) (3 2.698e-16 0) (3 3.0701e-16 0) (3 2.34091e-16 0) (3 2.1904e-16 0) (3 2.00045e-16 0) (3 1.5957e-16 0) (3 3.63685e-16 0) (3 -3.03935e-17 0) (3 -1.38695e-16 0) (3 -1.16905e-16 0) (3 -1.61231e-16 0) (3 -1.42805e-16 0) (3 -1.44753e-16 0) (3 -7.67651e-17 0) (3 -7.5188e-17 0) (3 -9.24349e-17 0) (3 -8.40206e-17 0) (3 -8.07302e-17 0) (3 -6.71047e-17 0) (3 -4.30903e-17 0) (3 -3.62586e-17 0) (3 1.90256e-17 0) (3 2.02716e-16 0) (3 1.73563e-16 0) (3 1.65173e-16 0) (3 2.38614e-16 0) (3 1.97158e-16 0) (3 1.29339e-16 0) (3 1.03303e-16 0) (3 1.01731e-16 0) (3 1.0191e-16 0) (3 1.0033e-16 0) (3 1.02271e-16 0) (3 3.53286e-17 0) (3 3.53914e-17 0) (3 1.18772e-16 0) (3 1.27864e-16 0) (3 1.49441e-16 0) (3 1.24757e-16 0) (3 1.2141e-16 0) (3 1.03741e-16 0) (3 1.50517e-16 0) (3 5.74431e-17 0) (3 4.31601e-17 0) (3 3.9635e-17 0) (3 1.2634e-17 0) (3 1.50075e-16 0) (3 1.37668e-16 0) (3 1.0344e-16 0) (3 1.03628e-16 0) (3 8.01403e-17 0) (3 1.67873e-16 0) (3 7.31224e-17 0) (3 2.16108e-16 0) (3 3.6696e-17 0) (3 5.14692e-17 0) (3 6.99803e-17 0) (3 1.27305e-16 0) (3 8.50275e-17 0) (3 1.53705e-16 0) (3 1.07608e-16 0) (3 1.35691e-16 0) (3 2.36506e-16 0) (3 2.10829e-16 0) (3 2.05617e-16 0) (3 1.5544e-16 0) (3 1.78248e-16 0) (3 1.57906e-16 0) (3 1.54438e-16 0) (3 1.41522e-16 0) (3 -3.59204e-17 0) (3 5.68243e-17 0) (3 9.86833e-17 0) (3 1.14083e-17 0) (3 -1.33351e-17 0) (3 -3.62648e-17 0) (3 -3.25097e-17 0) (3 -1.34121e-17 0) (3 -2.6876e-17 0) (3 -5.77027e-17 0) (3 -5.97415e-17 0) (3 -1.15853e-17 0) (3 -2.32156e-17 0) (3 1.25996e-16 0) (3 1.02936e-16 0) (3 8.17312e-17 0) (3 -1.31051e-18 0) (3 3.20821e-17 0) (3 3.21366e-17 0) (3 3.21913e-17 0) (3 1.86688e-17 0) (3 1.02004e-17 0) (3 1.02178e-17 0) (3 -4.09414e-17 0) (3 -1.19617e-17 0) (3 -8.55879e-18 0) (3 1.02882e-17 0) (3 1.0306e-17 0) (3 2.06476e-17 0) (3 9.99695e-17 0) (3 1.00143e-16 0) (3 1.90256e-17 0) (3 1.73261e-17 0) (3 -5.2069e-18 0) (3 3.82506e-17 0) (3 6.61848e-17 0) (3 1.39581e-17 0) (3 -2.44695e-17 0) (3 -2.97652e-17 0) (3 -3.15716e-17 0) (3 -3.16274e-17 0) (3 -3.34435e-17 0) (3 -1.05798e-17 0) (3 -7.419e-17 0) (3 -7.43219e-17 0) (3 -4.4318e-17 0) (3 1.24312e-17 0) (3 -2.31277e-17 0) (3 -2.85159e-17 0) (3 -1.46406e-16 0) (3 -3.57729e-17 0) (3 -3.58373e-17 0) (3 1.0232e-16 0) (3 8.99169e-17 0) (3 7.02621e-17 0) (3 1.2634e-17 0) (3 1.57308e-16 0) (3 1.48537e-16 0) (3 1.52437e-16 0) (3 1.50898e-16 0) (3 1.23853e-16 0) (3 2.55459e-17 0) (3 1.04199e-16 0) (3 -1.70322e-16 0) (3 3.28429e-16 0) (3 1.58084e-16 0) (3 2.2099e-16 0) (3 1.9557e-16 0) (3 1.25693e-16 0) (3 3.70373e-17 0) (3 4.82382e-17 0) (3 -3.15992e-17 0) (3 -3.53829e-17 0) (3 1.30602e-17 0) (3 -3.7385e-17 0) (3 1.5544e-16 0) (3 2.75815e-16 0) (3 2.04902e-16 0) (3 2.27891e-16 0) (3 1.58505e-16 0) (3 1.81493e-16 0) (3 1.0986e-16 0) (3 1.30945e-16 0) (3 6.08442e-17 0) (3 -1.33351e-16 0) (3 -1.24064e-16 0) (3 -1.58724e-16 0) (3 -1.34121e-16 0) (3 -1.3246e-16 0) (3 -9.61711e-18 0) (3 -1.05993e-16 0) (3 -1.1006e-16 0) (3 -6.57776e-17 0) (3 -1.41503e-16 0) (3 -1.243e-16 0) (3 -8.56232e-17 0) (3 -2.72623e-16 0) (3 -1.01312e-17 0) (3 -1.18398e-17 0) (3 -1.01657e-17 0) (3 2.0366e-17 0) (3 5.44021e-17 0) (3 5.44951e-17 0) (3 2.38825e-17 0) (3 3.24676e-17 0) (3 1.02705e-17 0) (3 1.02882e-17 0) (3 1.0306e-17 0) (3 3.2692e-17 0) (3 1.36165e-16 0) (3 1.31222e-16 0) (3 1.00317e-16 0) (3 3.29196e-17 0) (3 9.02529e-17 0) (3 -1.21706e-16 0) (3 -7.83767e-17 0) (3 -1.15154e-16 0) (3 -5.76781e-17 0) (3 -5.77795e-17 0) (3 2.45557e-17 0) (3 2.98703e-17 0) (3 3.34435e-17 0) (3 3.5266e-17 0) (3 5.65257e-17 0) (3 3.36218e-17 0) (3 4.60907e-17 0) (3 -6.57076e-17 0) (3 -8.71737e-17 0) (3 -1.26539e-16 0) (3 -6.78466e-17 0) (3 -1.23417e-16 0) (3 -1.23639e-16 0) (3 -1.43608e-16 0) (3 -1.04304e-16 0) (3 -1.65747e-16 0) (3 -8.66332e-17 0) (3 -3.43546e-17 0) (3 -3.62286e-17 0) (3 -9.25512e-17 0) (3 -9.27202e-17 0) (3 -5.82838e-17 0) (3 -6.56895e-17 0) (3 -1.42589e-16 0) (3 -1.50177e-16 0) (3 -2.44028e-16 0) (3 -2.00362e-16 0) (3 -2.22832e-16 0) (3 -1.3653e-16 0) (3 -1.01663e-16 0) (3 -1.27779e-16 0) (3 -2.72731e-16 0) (3 -2.7324e-16 0) (3 -2.4768e-16 0) (3 -2.70533e-16 0) (3 -1.38324e-16 0) (3 -2.04131e-16 0) (3 -2.79568e-16 0) (3 -2.81976e-16 0) (3 -2.76859e-16 0) (3 -2.35871e-16 0) (3 -1.32338e-16 0) (3 -1.49637e-16 0) (3 -1.84082e-16 0) (3 -2.52884e-16 0) (3 -2.05742e-16 0) (3 -2.06137e-16 0) (3 -1.68286e-16 0) (3 3.83204e-17 0) (3 -5.75914e-18 0) (3 -1.15405e-16 0) (3 -3.66158e-17 0) (3 -4.24794e-17 0) (3 -2.1281e-17 0) (3 -6.78441e-17 0) (3 -1.74797e-17 0) (3 6.22714e-17 0) (3 1.13197e-17 0) (3 -3.37706e-17 0) (3 -3.3828e-17 0) (3 8.64082e-17 0) (3 1.80886e-31 0) (3 2.04008e-17 0) (3 2.72476e-17 0) (3 2.90001e-17 0) (3 3.24676e-17 0) (3 1.88293e-17 0) (3 1.71471e-18 0) (3 5.15299e-18 0) (3 1.29047e-16 0) (3 -1.77532e-16 0) (3 -4.83448e-17 0) (3 7.78321e-17 0) (3 7.45023e-17 0) (3 4.51264e-17 0) (3 1.91253e-17 0) (3 2.9609e-17 0) (3 2.09371e-17 0) (3 2.79651e-17 0) (3 5.60287e-17 0) (3 2.80637e-17 0) (3 -3.51415e-18 0) (3 5.28055e-18 0) (3 7.93485e-17 0) (3 7.59565e-17 0) (3 9.37872e-17 0) (3 7.09088e-17 0) (3 -1.10105e-16 0) (3 4.98136e-17 0) (3 3.56448e-17 0) (3 1.48191e-16 0) (3 8.94323e-17 0) (3 1.07512e-17 0) (3 2.51313e-17 0) (3 3.41684e-17 0) (3 1.08096e-17 0) (3 1.02877e-16 0) (3 -1.0668e-16 0) (3 2.17371e-17 0) (3 -3.64761e-16 0) (3 -4.3633e-17 0) (3 1.63923e-17 0) (3 5.47413e-18 0) (3 -5.11857e-17 0) (3 -5.49427e-17 0) (3 -1.50453e-16 0) (3 -1.28673e-16 0) (3 -1.27069e-16 0) (3 -1.6974e-16 0) (3 -1.58965e-16 0) (3 -1.57408e-16 0) (3 -7.05019e-17 0) (3 -1.11527e-17 0) (3 -8.19392e-17 0) (3 9.32873e-18 0) (3 -3.36465e-17 0) (3 -6.3674e-17 0) (3 -1.53856e-16 0) (3 -1.37228e-16 0) (3 -1.54438e-16 0) (3 -9.43482e-18 0) (3 -3.21393e-17 0) (3 -3.59888e-17 0) (3 3.03641e-17 0) (3 7.60552e-17 0) (3 6.85807e-17 0) (3 1.41242e-16 0) (3 1.31951e-16 0) (3 1.09213e-16 0) (3 1.76614e-16 0) (3 2.30811e-16 0) (3 4.27826e-16 0) (3 4.13209e-16 0) (3 2.78588e-16 0) (3 3.58605e-16 0) (3 4.93315e-16 0) (3 4.32008e-16 0) (3 4.22983e-16 0) (3 7.59839e-17 0) (3 7.6113e-17 0) (3 3.38856e-17 0) (3 3.22462e-17 0) (3 1.19005e-17 0) (3 1.19208e-17 0) (3 1.19412e-17 0) (3 5.46822e-17 0) (3 2.56764e-17 0) (3 7.54471e-17 0) (3 1.92378e-16 0) (3 4.30158e-17 0) (3 2.06833e-17 0) (3 1.89926e-17 0) (3 1.38368e-16 0) (3 1.66331e-16 0) (3 1.57943e-16 0) (3 1.00842e-16 0) (3 7.14099e-17 0) (3 8.02589e-17 0) (3 1.27591e-16 0) (3 1.41823e-16 0) (3 7.89291e-17 0) (3 1.35295e-16 0) (3 1.05611e-17 0) (3 -5.81889e-17 0) (3 -6.00586e-17 0) (3 -4.77784e-17 0) (3 -5.6727e-17 0) (3 7.10353e-17 0) (3 -1.60115e-16 0) (3 1.06934e-17 0) (3 -2.6603e-16 0) (3 -2.39678e-16 0) (3 -1.36182e-16 0) (3 -1.97461e-16 0) (3 -1.47464e-16 0) (3 -1.09897e-16 0) (3 -3.06826e-17 0) (3 -1.12105e-16 0) (3 -8.33257e-17 0) (3 5.62566e-17 0) (3 7.99939e-17 0) (3 3.09633e-17 0) (3 3.28448e-17 0) (3 4.93576e-17 0) (3 6.77626e-17 0) (3 1.17427e-16 0) (3 1.26835e-16 0) (3 1.27069e-16 0) (3 7.011e-17 0) (3 7.57854e-17 0) (3 9.62969e-17 0) (3 1.70689e-16 0) (3 1.61714e-16 0) (3 1.30358e-16 0) (3 5.97039e-17 0) (3 7.29007e-17 0) (3 1.5544e-16 0) (3 1.42598e-16 0) (3 1.1843e-16 0) (3 1.01703e-16 0) (3 -8.30264e-17 0) (3 -6.99503e-17 0) (3 5.87185e-17 0) (3 -8.35013e-17 0) (3 -6.08442e-17 0) (3 1.61927e-16 0) (3 -2.48127e-17 0) (3 -1.33864e-17 0) (3 -2.2609e-16 0) (3 3.45548e-17 0) (3 -2.26964e-16 0) (3 -3.54595e-16 0) (3 -1.58332e-16 0) (3 -2.1281e-16 0) (3 -1.08551e-16 0) (3 -1.12647e-16 0) (3 -1.61516e-16 0) (3 -1.23933e-16 0) (3 -5.57215e-17 0) (3 -6.7656e-18 0) (3 -7.62425e-17 0) (3 -7.63725e-17 0) (3 -5.78022e-17 0) (3 -5.44951e-17 0) (3 -8.18828e-17 0) (3 -8.88586e-17 0) (3 -3.42351e-16 0) (3 1.32032e-16 0) (3 4.07086e-16 0) (3 -2.78743e-16 0) (3 -5.41214e-16 0) (3 -1.50214e-16 0) (3 1.22802e-16 0) (3 9.87589e-17 0) (3 6.07471e-17 0) (3 -2.43413e-17 0) (3 -5.39929e-17 0) (3 -4.01294e-17 0) (3 -2.62173e-17 0) (3 -1.7509e-18 0) (3 3.33256e-17 0) (3 2.05578e-16 0) (3 -8.80091e-17 0) (3 1.11088e-16 0) (3 1.05986e-16 0) (3 2.65435e-17 0) (3 5.31816e-18 0) (3 -1.06553e-17 0) (3 4.44764e-17 0) (3 3.20803e-17 0) (3 3.39233e-17 0) (3 3.39843e-17 0) (3 3.58373e-17 0) (3 8.25744e-17 0) (3 7.91269e-17 0) (3 7.92701e-17 0) (3 7.94138e-17 0) (3 1.93471e-16 0) (3 1.84766e-16 0) (3 1.63326e-16 0) (3 4.90872e-17 0) (3 1.25675e-16 0) (3 1.07658e-16 0) (3 1.16996e-16 0) (3 1.64828e-16 0) (3 1.76141e-16 0) (3 2.18744e-16 0) (3 1.76792e-16 0) (3 1.75275e-16 0) (3 1.58965e-16 0) (3 1.74075e-16 0) (3 1.744e-16 0) (3 1.54279e-16 0) (3 2.25333e-16 0) (3 2.14561e-16 0) (3 2.33656e-16 0) (3 1.62931e-16 0) (3 1.20083e-16 0) (3 1.1279e-16 0) (3 -1.69506e-17 0) (3 2.07566e-16 0) (3 -1.22886e-16 0) (3 1.51532e-16 0) (3 1.13865e-17 0) (3 1.14083e-17 0) (3 -1.14301e-17 0) (3 1.33607e-17 0) (3 8.98799e-17 0) (3 -1.30289e-16 0) (3 -1.55497e-16 0) (3 -2.0773e-16 0) (3 -2.8329e-16 0) (3 -3.0701e-16 0) (3 -2.84391e-16 0) (3 -3.60543e-16 0) (3 -6.11788e-16 0) (3 -5.48767e-16 0) (3 -4.58932e-16 0) (3 -5.4033e-17 0) (3 -7.6113e-17 0) (3 -7.62425e-17 0) (3 -7.63725e-17 0) (3 -7.65029e-17 0) (3 -7.66338e-17 0) (3 2.21766e-17 0) (3 -1.02529e-17 0) (3 3.25234e-17 0) (3 5.31559e-17 0) (3 2.5765e-17 0) (3 -3.44127e-18 0) (3 -9.82459e-17 0) (3 -6.90641e-17 0) (3 -6.0536e-17 0) (3 -1.90587e-17 0) (3 -3.12414e-17 0) (3 -3.12959e-17 0) (3 -3.13507e-17 0) (3 -7.85141e-17 0) (3 -6.64172e-17 0) (3 3.67688e-17 0) (3 -1.26287e-16 0) (3 2.45991e-17 0) (3 3.34435e-17 0) (3 -3.5266e-17 0) (3 1.53679e-16 0) (3 -8.31697e-17 0) (3 4.78634e-17 0) (3 4.26212e-17 0) (3 -1.42324e-17 0) (3 -5.34672e-18 0) (3 2.67816e-17 0) (3 1.4488e-16 0) (3 1.20055e-16 0) (3 5.92382e-17 0) (3 1.6185e-17 0) (3 1.08096e-17 0) (3 7.58041e-17 0) (3 -1.08488e-17 0) (3 7.24571e-18 0) (3 -1.12513e-16 0) (3 -9.63563e-17 0) (3 -4.9177e-17 0) (3 -7.4813e-17 0) (3 -5.84979e-17 0) (3 -1.61165e-16 0) (3 -1.21097e-16 0) (3 -1.74628e-16 0) (3 -1.63901e-16 0) (3 -5.904e-17 0) (3 -5.91496e-17 0) (3 -3.14817e-17 0) (3 -5.19488e-17 0) (3 -7.24924e-17 0) (3 -1.04286e-16 0) (3 -1.34334e-16 0) (3 -1.77579e-16 0) (3 -1.31094e-16 0) (3 -1.29464e-16 0) (3 -1.07151e-16 0) (3 -1.03587e-16 0) (3 -1.45296e-16 0) (3 3.40299e-17 0) (3 -2.12144e-16 0) (3 -1.21456e-16 0) (3 -6.08442e-17 0) (3 -1.33351e-16 0) (3 -1.5842e-16 0) (3 -1.58724e-16 0) (3 -1.74358e-16 0) (3 -2.09249e-16 0) (3 -1.57721e-16 0) (3 7.32315e-17 0) (3 -5.98574e-17 0) (3 -4.64313e-17 0) (3 -8.14129e-17 0) (3 -8.35139e-17 0) (3 -8.75691e-17 0) (3 -9.86882e-17 0) (3 5.23444e-17 0) (3 5.24334e-17 0) (3 3.21913e-17 0) (3 3.22462e-17 0) (3 3.23012e-17 0) (3 3.23565e-17 0) (3 -1.02353e-17 0) (3 1.12782e-16 0) (3 -6.16233e-17 0) (3 -2.74353e-17 0) (3 -1.88943e-17 0) (3 -3.44127e-18 0) (3 7.58389e-17 0) (3 6.56109e-17 0) (3 -5.1888e-18 0) (3 -7.62349e-17 0) (3 -7.63678e-17 0) (3 -7.65012e-17 0) (3 -1.01019e-16 0) (3 -5.93218e-17 0) (3 -1.206e-16 0) (3 -4.90251e-17 0) (3 -6.48973e-17 0) (3 -1.22995e-16 0) (3 -1.23213e-16 0) (3 -1.48117e-16 0) (3 -1.36015e-16 0) (3 -6.01653e-17 0) (3 -9.39542e-17 0) (3 -6.92594e-17 0) (3 -2.73975e-16 0) (3 -2.51296e-16 0) (3 -1.94613e-16 0) (3 -1.94962e-16 0) (3 -1.48725e-16 0) (3 -1.57968e-16 0) (3 -1.38472e-16 0) (3 -1.04492e-16 0) (3 -5.77555e-17 0) (3 -1.04872e-16 0) (3 9.60057e-17 0) (3 -1.21587e-16 0) (3 -1.25445e-16 0) (3 -1.52995e-16 0) (3 -1.64224e-16 0) (3 -1.07855e-16 0) (3 -1.90468e-16 0) (3 -1.52288e-16 0) (3 -1.69113e-16 0) (3 -1.73109e-16 0) (3 -1.56825e-16 0) (3 -1.58965e-16 0) (3 -2.22224e-16 0) (3 -1.91097e-16 0) (3 -1.71008e-16 0) (3 -1.88088e-16 0) (3 -2.46278e-16 0) (3 -2.03748e-16 0) (3 -2.26605e-16 0) (3 -2.04516e-16 0) (3 -2.04902e-16 0) (3 -1.80806e-16 0) (3 -1.83036e-16 0) (3 -1.32338e-16 0) (3 -1.57214e-16 0) (3 -1.57514e-16 0) (3 -1.44505e-16 0) (3 -8.57258e-17 0) (3 -1.31698e-16 0) (3 -1.20477e-16 0) (3 6.13126e-17 0) (3 4.79928e-17 0) (3 6.15495e-17 0) (3 3.85429e-17 0) (3 3.86177e-17 0) (3 -3.86927e-18 0) (3 -1.29873e-16 0) (3 -1.18473e-16 0) (3 -8.75691e-17 0) (3 -5.82749e-17 0) (3 -1.08066e-16 0) (3 -8.79528e-17 0) (3 -7.96311e-17 0) (3 -6.61895e-17 0) (3 -2.04008e-17 0) (3 7.49308e-17 0) (3 1.5353e-17 0) (3 1.19617e-17 0) (3 -7.53173e-17 0) (3 -7.71618e-17 0) (3 -6.35536e-17 0) (3 1.44533e-16 0) (3 -1.8615e-16 0) (3 -8.28769e-17 0) (3 -1.00317e-16 0) (3 -1.33411e-16 0) (3 -1.28437e-16 0) (3 -1.11274e-16 0) (3 -8.53436e-17 0) (3 -1.74476e-17 0) (3 -1.22347e-17 0) (3 -2.80143e-17 0) (3 -2.98177e-17 0) (3 -9.66392e-17 0) (3 -6.68869e-17 0) (3 -1.05798e-17 0) (3 -1.05986e-17 0) (3 -1.06174e-17 0) (3 -3.1909e-17 0) (3 -3.37418e-17 0) (3 5.69298e-17 0) (3 4.4556e-17 0) (3 3.57087e-17 0) (3 5.72367e-17 0) (3 5.73397e-17 0) (3 5.02627e-17 0) (3 3.59668e-17 0) (3 1.02691e-16 0) (3 3.7902e-17 0) (3 -7.9558e-17 0) (3 -7.06457e-17 0) (3 -8.89217e-17 0) (3 -8.363e-17 0) (3 -8.19616e-17 0) (3 -8.02872e-17 0) (3 -5.48418e-17 0) (3 -1.95962e-16 0) (3 8.07311e-17 0) (3 3.49255e-17 0) (3 8.10298e-17 0) (3 -8.118e-17 0) (3 -7.94823e-17 0) (3 -5.92596e-17 0) (3 -8.34891e-17 0) (3 -8.3645e-17 0) (3 -8.38015e-17 0) (3 -8.39586e-17 0) (3 -9.72009e-17 0) (3 -1.29221e-16 0) (3 -1.1633e-16 0) (3 -9.21121e-17 0) (3 -9.04029e-17 0) (3 6.22698e-17 0) (3 7.37314e-17 0) (3 1.62896e-16 0) (3 1.59411e-16 0) (3 1.31195e-16 0) (3 1.50496e-16 0) (3 8.39815e-17 0) (3 1.09003e-16 0) (3 3.64043e-17 0) (3 1.09424e-16 0) (3 1.09635e-16 0) (3 6.16687e-17 0) (3 8.3028e-17 0) (3 8.5124e-17 0) (3 1.49257e-16 0) (3 1.35953e-16 0) (3 1.36219e-16 0) (3 1.32635e-16 0) (3 -1.23263e-16 0) (3 -5.24334e-17 0) (3 -5.59112e-17 0) (3 -5.43093e-17 0) (3 -9.86037e-17 0) (3 -7.83367e-17 0) (3 -8.70004e-17 0) (3 -8.20233e-17 0) (3 5.47762e-17 0) (3 5.31559e-17 0) (3 7.72949e-17 0) (3 5.33396e-17 0) (3 7.75625e-17 0) (3 6.73375e-17 0) (3 7.61025e-17 0) (3 6.2374e-17 0) (3 3.2977e-17 0) (3 9.91038e-17 0) (3 7.31516e-17 0) (3 8.72379e-17 0) (3 1.11861e-16 0) (3 7.52885e-17 0) (3 3.33256e-17 0) (3 4.74411e-17 0) (3 7.04073e-17 0) (3 7.40586e-17 0) (3 8.12557e-17 0) (3 5.66262e-17 0) (3 1.2409e-16 0) (3 1.22536e-16 0) (3 1.42324e-16 0) (3 1.46144e-16 0) (3 1.32122e-16 0) (3 1.0553e-16 0) (3 1.0572e-16 0) (3 9.3345e-17 0) (3 4.85551e-17 0) (3 2.52223e-17 0) (3 -4.33166e-17 0) (3 -1.04872e-16 0) (3 8.51371e-17 0) (3 6.35155e-17 0) (3 5.81774e-17 0) (3 6.01052e-17 0) (3 6.02154e-17 0) (3 5.84979e-17 0) (3 1.88636e-16 0) (3 -5.50439e-17 0) (3 -8.08802e-17 0) (3 -8.10298e-17 0) (3 -1.107e-17 0) (3 -2.40295e-17 0) (3 -8.1482e-17 0) (3 -3.33957e-17 0) (3 -3.15992e-17 0) (3 8.56638e-17 0) (3 1.17542e-16 0) (3 1.4954e-16 0) (3 1.46076e-16 0) (3 2.25155e-16 0) (3 2.12422e-16 0) (3 1.92106e-16 0) (3 1.47183e-16 0) (3 1.68259e-16 0) (3 1.07966e-16 0) (3 1.80287e-16 0) (3 1.67321e-16 0) (3 1.46686e-16 0) (3 1.31698e-16 0) (3 2.29481e-16 0) (3 1.32205e-16 0) (3 1.45898e-16 0) (3 1.82725e-16 0) (3 1.56099e-16 0) (3 3.66868e-17 0) (3 8.89932e-17 0) (3 2.9076e-16 0) (3 2.68021e-16 0) (3 2.52978e-16 0) (3 1.98288e-16 0) (3 9.79348e-17 0) (3 2.04659e-16 0) (3 2.05008e-16 0) (3 1.799e-16 0) (3 1.46206e-16 0) (3 5.61981e-17 0) (3 5.45885e-17 0) (3 5.6391e-17 0) (3 5.47762e-17 0) (3 3.42941e-17 0) (3 3.26356e-17 0) (3 6.19428e-17 0) (3 3.44722e-17 0) (3 3.4532e-17 0) (3 5.36176e-17 0) (3 5.3711e-17 0) (3 7.63678e-17 0) (3 5.04212e-17 0) (3 5.39929e-17 0) (3 5.40875e-17 0) (3 4.36955e-17 0) (3 1.20812e-16 0) (3 1.05239e-16 0) (3 1.66922e-16 0) (3 1.28493e-16 0) (3 3.5266e-17 0) (3 3.53286e-17 0) (3 5.66262e-17 0) (3 3.36817e-17 0) (3 -3.55176e-17 0) (3 1.06743e-17 0) (3 8.91121e-18 0) (3 3.39233e-17 0) (3 -3.75616e-17 0) (3 -3.76292e-17 0) (3 -4.84676e-17 0) (3 -8.99169e-17 0) (3 -1.00889e-16 0) (3 -6.31701e-17 0) (3 -3.43546e-17 0) (3 -1.06874e-16 0) (3 -9.07365e-17 0) (3 -6.36315e-17 0) (3 -2.36778e-17 0) (3 -1.45977e-17 0) (3 1.50187e-32 0) (3 3.66284e-17 0) (3 1.28436e-17 0) (3 7.35274e-17 0) (3 3.68317e-17 0) (3 4.797e-17 0) (3 8.13307e-17 0) (3 2.01853e-16 0) (3 1.89242e-16 0) (3 1.84019e-16 0) (3 1.78777e-16 0) (3 2.46278e-16 0) (3 2.31787e-16 0) (3 2.3035e-16 0) (3 1.78248e-16 0) (3 1.57906e-16 0) (3 1.45021e-16 0) (3 -2.15114e-16 0) (3 -3.40299e-17 0) (3 -1.07966e-16 0) (3 -8.5399e-17 0) (3 -8.55621e-17 0) (3 6.66757e-17 0) (3 1.10703e-16 0) (3 8.60552e-17 0) (3 2.1651e-16 0) (3 1.9773e-16 0) (3 2.55815e-16 0) (3 1.29119e-16 0) (3 3.26319e-16 0) (3 1.85725e-16 0) (3 3.08206e-16 0) (3 3.08807e-16 0) (3 1.86814e-16 0) (3 3.1034e-16 0) (3 1.8405e-16 0) (3 1.35312e-16 0) (3 1.0674e-16 0) (3 1.34076e-16 0) (3 1.19005e-16 0) (3 1.17505e-16 0) (3 9.55299e-17 0) (3 1.60629e-16 0) (3 3.93704e-17 0) (3 2.22912e-17 0) (3 -5.49653e-17 0) (3 -5.50603e-17 0) (3 -9.82459e-17 0) (3 -9.49631e-17 0) (3 -2.42144e-17 0) (3 -3.29196e-17 0) (3 -1.04138e-17 0) (3 -5.56372e-17 0) (3 -5.57346e-17 0) (3 -6.28113e-17 0) (3 -6.8165e-17 0) (3 -1.20812e-16 0) (3 -1.01731e-16 0) (3 -1.54623e-16 0) (3 -1.46095e-16 0) (3 -1.46354e-16 0) (3 -7.77229e-17 0) (3 -9.0248e-17 0) (3 -1.55999e-16 0) (3 -1.27864e-16 0) (3 -1.45883e-16 0) (3 -5.8814e-17 0) (3 -6.42757e-17 0) (3 1.78865e-17 0) (3 5.55478e-17 0) (3 4.66725e-17 0) (3 8.81186e-17 0) (3 1.11699e-16 0) (3 9.56575e-17 0) (3 4.33953e-17 0) (3 1.08686e-17 0) (3 5.44419e-18 0) (3 1.25445e-16 0) (3 1.14746e-16 0) (3 1.07658e-16 0) (3 9.87152e-17 0) (3 1.04391e-16 0) (3 1.00914e-16 0) (3 1.6176e-16 0) (3 1.98891e-16 0) (3 1.78965e-16 0) (3 1.77449e-16 0) (3 1.74075e-16 0) (3 1.7811e-16 0) (3 3.21569e-16 0) (3 7.44902e-17 0) (3 3.73149e-17 0) (3 5.79467e-17 0) (3 2.99642e-17 0) (3 -3.94022e-17 0) (3 -3.57169e-17 0) (3 -3.76679e-17 0) (3 3.58523e-17 0) (3 -1.32338e-17 0) (3 1.3259e-17 0) (3 -6.07282e-17 0) (3 1.33097e-17 0) (3 -5.90556e-17 0) (3 4.19908e-17 0) (3 -9.56169e-17 0) (3 -1.91602e-17 0) (3 1.15183e-17 0) (3 -3.26982e-17 0) (3 -7.70858e-18 0) (3 8.49589e-17 0) (3 6.3843e-17 0) (3 -3.68297e-17 0) (3 -2.33062e-17 0) (3 1.40111e-16 0) (3 -4.95733e-17 0) (3 -7.42953e-17 0) (3 -8.79528e-17 0) (3 -1.18599e-16 0) (3 -1.03527e-16 0) (3 -9.69037e-17 0) (3 -9.70695e-17 0) (3 -7.67651e-17 0) (3 -1.17909e-16 0) (3 -1.06129e-16 0) (3 -8.745e-17 0) (3 -7.38596e-17 0) (3 -7.74285e-17 0) (3 -7.75625e-17 0) (3 -9.32365e-17 0) (3 -1.12424e-16 0) (3 -1.00491e-16 0) (3 -1.14552e-16 0) (3 -1.44309e-16 0) (3 -1.61979e-16 0) (3 -1.65752e-16 0) (3 -1.69539e-16 0) (3 -2.10107e-16 0) (3 -1.91184e-16 0) (3 -2.10849e-16 0) (3 -2.11222e-16 0) (3 -2.09833e-16 0) (3 -2.33169e-16 0) (3 -2.35353e-16 0) (3 -2.12726e-16 0) (3 -1.36743e-16 0) (3 1.79685e-16 0) (3 -1.37233e-16 0) (3 -5.7134e-17 0) (3 -6.97572e-17 0) (3 -8.06339e-17 0) (3 -5.74431e-17 0) (3 1.11497e-16 0) (3 8.10717e-17 0) (3 -6.85847e-17 0) (3 1.57308e-16 0) (3 7.97028e-17 0) (3 1.0344e-16 0) (3 6.54496e-17 0) (3 5.64625e-17 0) (3 1.25905e-16 0) (3 -4.57015e-17 0) (3 8.05826e-17 0) (3 5.68787e-17 0) (3 -3.49255e-17 0) (3 -3.49901e-17 0) (3 -3.69e-17 0) (3 4.99075e-17 0) (3 -3.51854e-17 0) (3 -7.05019e-17 0) (3 4.46107e-17 0) (3 8.7526e-17 0) (3 5.97039e-17 0) (3 5.79467e-17 0) (3 1.0862e-16 0) (3 1.05073e-16 0) (3 1.1843e-16 0) (3 1.46905e-16 0) (3 2.03792e-16 0) (3 2.19304e-16 0) (3 2.51921e-16 0) (3 2.71379e-16 0) (3 5.66611e-16 0) (3 8.57258e-17 0) (3 8.77989e-17 0) (3 1.01354e-16 0) (3 -6.13126e-17 0) (3 -7.29491e-17 0) (3 -1.30793e-16 0) (3 -1.349e-16 0) (3 -1.04268e-16 0) (3 -1.12209e-16 0) (3 -1.08551e-16 0) (3 -2.11698e-16 0) (3 -6.03254e-17 0) (3 -8.52116e-17 0) (3 -1.8405e-16 0) (3 -1.9282e-16 0) (3 -1.71122e-16 0) (3 -1.66322e-16 0) (3 -1.63206e-16 0) (3 -1.82218e-16 0) (3 -1.16001e-16 0) (3 -1.64047e-16 0) (3 -1.11264e-16 0) (3 -1.13171e-16 0) (3 -1.08213e-16 0) (3 1.37651e-17 0) (3 -1.44783e-16 0) (3 -3.4532e-17 0) (3 -1.15883e-16 0) (3 -1.43807e-16 0) (3 -1.31908e-16 0) (3 -1.26922e-16 0) (3 -1.09727e-16 0) (3 -9.07274e-17 0) (3 -7.8652e-17 0) (3 -1.01552e-16 0) (3 -1.19271e-16 0) (3 -1.15967e-16 0) (3 -1.03851e-16 0) (3 -1.04035e-16 0) (3 -8.6555e-17 0) (3 -7.07828e-17 0) (3 6.73634e-17 0) (3 -1.47398e-16 0) (3 -1.35208e-16 0) (3 -1.46144e-16 0) (3 -1.32122e-16 0) (3 -1.66344e-16 0) (3 -1.20055e-16 0) (3 -1.0232e-16 0) (3 -1.54657e-16 0) (3 -1.38723e-16 0) (3 -1.04682e-16 0) (3 -1.0668e-16 0) (3 -1.03251e-16 0) (3 -4.17388e-17 0) (3 -1.16355e-16 0) (3 5.82838e-17 0) (3 5.83907e-17 0) (3 4.93576e-17 0) (3 3.4797e-17 0) (3 5.68787e-17 0) (3 5.69837e-17 0) (3 1.10495e-17 0) (3 1.107e-17 0) (3 -3.69685e-17 0) (3 -2.40742e-17 0) (3 1.85531e-17 0) (3 -5.0187e-17 0) (3 1.11735e-17 0) (3 -1.30602e-17 0) (3 3.55157e-17 0) (3 1.77913e-16 0) (3 2.30784e-16 0) (3 3.21452e-16 0) (3 3.59728e-16 0) (3 2.9814e-16 0) (3 4.89652e-16 0) (3 7.00834e-17 0) (3 1.82185e-16 0) (3 1.67321e-16 0) (3 1.73357e-16 0) (3 1.18338e-16 0) (3 1.31951e-16 0) (3 8.43048e-17 0) (3 8.83068e-17 0) (3 9.04008e-17 0) (3 6.16687e-17 0) (3 1.35162e-16 0) (3 1.35425e-16 0) (3 9.88585e-17 0) (3 6.60343e-17 0) (3 -8.56232e-17 0) (3 8.44589e-17 0) (3 -6.41642e-17 0) (3 -5.24334e-17 0) (3 -5.25226e-17 0) (3 -7.1281e-17 0) (3 -7.48028e-17 0) (3 -4.25743e-17 0) (3 1.05765e-16 0) (3 5.29734e-17 0) (3 5.30645e-17 0) (3 3.42941e-17 0) (3 3.43533e-17 0) (3 2.23682e-17 0) (3 -3.27486e-17 0) (3 1.89926e-17 0) (3 -1.03776e-17 0) (3 1.55935e-17 0) (3 1.04138e-17 0) (3 2.26026e-17 0) (3 1.04502e-17 0) (3 1.04685e-17 0) (3 2.27217e-17 0) (3 4.20215e-17 0) (3 4.91114e-17 0) (3 5.27123e-17 0) (3 5.28055e-17 0) (3 5.46623e-17 0) (3 3.35622e-17 0) (3 3.36218e-17 0) (3 4.4318e-17 0) (3 1.74036e-16 0) (3 -2.13487e-17 0) (3 -2.85159e-17 0) (3 1.07126e-17 0) (3 8.40663e-17 0) (3 8.24258e-17 0) (3 6.28284e-17 0) (3 1.079e-17 0) (3 -3.06271e-17 0) (3 -3.7902e-17 0) (3 -2.53139e-17 0) (3 5.61543e-17 0) (3 -2.17768e-17 0) (3 3.09067e-17 0) (3 -6.55693e-17 0) (3 -1.05833e-16 0) (3 -7.31224e-17 0) (3 -8.05826e-17 0) (3 -5.68787e-17 0) (3 -8.27183e-17 0) (3 -6.07723e-17 0) (3 -5.7195e-17 0) (3 -8.31791e-17 0) (3 -1.11112e-16 0) (3 -1.00187e-16 0) (3 -1.30114e-16 0) (3 -1.76914e-16 0) (3 -1.6232e-16 0) (3 -2.69172e-16 0) (3 -1.49821e-17 0) (3 -9.5691e-17 0) (3 -2.331e-16 0) (3 -3.23944e-16 0) (3 -3.24558e-16 0) (3 -2.60896e-16 0) (3 -2.40556e-16 0) (3 -2.37219e-16 0) (3 -2.22462e-16 0) (3 -1.08586e-16 0) (3 -1.69872e-16 0) (3 -2.02708e-16 0) (3 -5.17325e-17 0) (3 1.3246e-16 0) (3 9.42477e-17 0) (3 8.28673e-17 0) (3 -9.65442e-18 0) (3 1.35425e-17 0) (3 -3.48913e-17 0) (3 -2.33062e-17 0) (3 3.69736e-17 0) (3 -2.44212e-17 0) (3 5.06559e-17 0) (3 8.79528e-17 0) (3 1.11822e-16 0) (3 1.18802e-16 0) (3 1.19005e-16 0) (3 2.24792e-16 0) (3 1.02353e-17 0) (3 8.5441e-18 0) (3 2.39646e-17 0) (3 4.62971e-17 0) (3 3.26356e-17 0) (3 4.47365e-17 0) (3 5.3432e-17 0) (3 1.03596e-17 0) (3 1.21072e-17 0) (3 2.07913e-17 0) (3 1.38851e-17 0) (3 2.26026e-17 0) (3 3.30924e-17 0) (3 3.14056e-17 0) (3 3.14608e-17 0) (3 4.55233e-17 0) (3 6.48973e-17 0) (3 7.37972e-17 0) (3 8.80091e-17 0) (3 1.39301e-16 0) (3 3.53286e-17 0) (3 9.73263e-17 0) (3 3.22635e-16 0) (3 -2.84141e-17 0) (3 2.33056e-16 0) (3 -1.1941e-16 0) (3 1.55333e-16 0) (3 1.53824e-16 0) (3 1.21847e-16 0) (3 8.61646e-17 0) (3 8.27236e-17 0) (3 8.10717e-17 0) (3 1.06487e-16 0) (3 1.15721e-16 0) (3 3.44171e-17 0) (3 7.98481e-17 0) (3 1.27263e-17 0) (3 1.09282e-17 0) (3 3.64942e-17 0) (3 5.48418e-18 0) (3 -3.66284e-18 0) (3 -4.22003e-17 0) (3 -5.69837e-17 0) (3 -1.65743e-17 0) (3 -9.22499e-18 0) (3 -2.58779e-17 0) (3 -2.96298e-17 0) (3 -5.93701e-17 0) (3 -1.57996e-16 0) (3 -2.36506e-16 0) (3 -2.48144e-16 0) (3 -6.16852e-17 0) (3 -3.46462e-16 0) (3 -3.75259e-16 0) (3 -4.19204e-16 0) (3 -3.71029e-16 0) (3 -2.67949e-16 0) (3 -3.30846e-16 0) (3 -7.76599e-17 0) (3 -1.00581e-16 0) (3 -1.36899e-16 0) (3 -1.61927e-16 0) (3 -1.37424e-16 0) (3 -1.64461e-16 0) (3 -1.82022e-16 0) (3 -2.32285e-16 0) (3 -1.25022e-16 0) (3 -8.47944e-17 0) (3 -1.48678e-16 0) (3 -1.31555e-16 0) (3 -2.09348e-16 0) (3 -2.07814e-16 0) (3 -5.83794e-17 0) (3 -1.85424e-16 0) (3 1.18197e-16 0) (3 2.01277e-16 0) (3 2.01619e-16 0) (3 2.05357e-16 0) (3 1.92107e-16 0) (3 1.75406e-16 0) (3 1.22824e-16 0) (3 7.68969e-17 0) (3 1.23247e-16 0) (3 1.35462e-16 0) (3 1.21954e-16 0) (3 1.23886e-16 0) (3 1.01693e-16 0) (3 1.00143e-16 0) (3 1.19342e-16 0) (3 1.1955e-16 0) (3 1.44057e-16 0) (3 2.53845e-16 0) (3 1.30628e-16 0) (3 3.82102e-16 0) (3 1.88765e-16 0) (3 2.17111e-16 0) (3 2.05216e-16 0) (3 1.58137e-16 0) (3 1.61937e-16 0) (3 2.11596e-16 0) (3 2.01373e-16 0) (3 1.68109e-16 0) (3 2.58817e-16 0) (3 2.37968e-16 0) (3 2.36614e-16 0) (3 5.52495e-17 0) (3 1.49977e-16 0) (3 -1.39514e-16 0) (3 -1.21847e-16 0) (3 -6.82136e-17 0) (3 2.87734e-17 0) (3 5.7651e-17 0) (3 8.12187e-17 0) (3 8.67906e-17 0) (3 3.804e-17 0) (3 -1.08884e-17 0) (3 -1.09083e-17 0) (3 1.82137e-18 0) (3 -1.09483e-17 0) (3 8.22627e-17 0) (3 8.2414e-17 0) (3 8.44007e-17 0) (3 8.08802e-17 0) (3 3.86733e-17 0) (3 3.321e-17 0) (3 3.51201e-17 0) (3 3.51854e-17 0) (3 3.33957e-17 0) (3 3.53168e-17 0) (3 4.28319e-17 0) (3 1.28736e-16 0) (3 1.15893e-16 0) (3 7.67834e-17 0) (3 3.56496e-17 0) (3 7.14338e-17 0) (3 -3.57845e-17 0) (3 -2.45305e-17 0) (3 5.8607e-17 0) (3 2.46239e-17 0) (3 -5.69327e-18 0) (3 -3.80276e-18 0) (3 -6.28656e-17 0) (3 -8.39815e-17 0) (3 -1.56812e-16 0) (3 -7.47247e-17 0) (3 -2.72599e-16 0) (3 -1.13482e-16 0) (3 -1.11774e-16 0) (3 -7.14427e-17 0) (3 1.85725e-16 0) (3 1.66703e-16 0) (3 1.53433e-16 0) (3 1.12867e-16 0) (3 1.45419e-16 0) (3 1.13132e-16 0) (3 -9.13356e-17 0) (3 -4.91341e-17 0) (3 -1.28985e-16 0) (3 -1.08804e-16 0) (3 -8.34457e-17 0) (3 -8.01769e-17 0) (3 -4.61381e-17 0) (3 -6.16233e-17 0) (3 -8.91647e-17 0) (3 -7.90126e-17 0) (3 -7.91491e-17 0) (3 -4.82611e-17 0) (3 -3.97118e-17 0) (3 -3.63216e-17 0) (3 -4.50479e-17 0) (3 -3.81839e-17 0) (3 2.78186e-17 0) (3 3.48341e-17 0) (3 -1.04685e-17 0) (3 6.99129e-18 0) (3 3.50179e-17 0) (3 2.98177e-17 0) (3 4.74411e-17 0) (3 6.33666e-17 0) (3 7.40586e-17 0) (3 1.00686e-16 0) (3 1.98192e-16 0) (3 7.97724e-17 0) (3 5.50524e-17 0) (3 5.51507e-17 0) (3 8.37653e-17 0) (3 1.24981e-16 0) (3 1.01953e-16 0) (3 8.06339e-17 0) (3 5.5648e-17 0) (3 8.81186e-17 0) (3 7.02621e-17 0) (3 3.42923e-17 0) (3 1.08488e-17 0) (3 3.44171e-17 0) (3 3.62946e-17 0) (3 1.81804e-18 0) (3 5.64625e-17 0) (3 4.56177e-17 0) (3 -5.48418e-18 0) (3 7.32569e-18 0) (3 1.10088e-17 0) (3 -3.67637e-18 0) (3 -7.91882e-17 0) (3 -8.118e-17 0) (3 -6.65433e-17 0) (3 5.18522e-17 0) (3 3.5251e-17 0) (3 2.47218e-16 0) (3 2.45818e-16 0) (3 2.27621e-16 0) (3 2.03748e-16 0) (3 1.77913e-16 0) (3 2.19527e-16 0) (3 1.48507e-16 0) (3 3.57845e-17 0) (3 8.30264e-17 0) (3 -5.67164e-18 0) (3 3.59888e-17 0) (3 -3.60574e-17 0) (3 -3.04221e-17 0) (3 -4.57205e-17 0) (3 -5.53515e-17 0) (3 -5.92825e-17 0) (3 2.08846e-16 0) (3 -3.05234e-16 0) (3 7.69369e-18 0) (3 -4.45171e-16 0) (3 -1.60263e-16 0) (3 -2.32156e-16 0) (3 8.14129e-17 0) (3 1.74797e-17 0) (3 -3.89196e-17 0) (3 1.57971e-16 0) (3 -1.82361e-16 0) (3 -2.43561e-16 0) (3 -1.82982e-16 0) (3 -1.84991e-16 0) (3 -1.64906e-16 0) (3 -1.61782e-16 0) (3 -1.6206e-16 0) (3 -1.17909e-16 0) (3 -1.83158e-16 0) (3 -1.86903e-16 0) (3 -1.87225e-16 0) (3 -1.65181e-16 0) (3 -1.20653e-16 0) (3 -1.41581e-16 0) (3 -1.3145e-16 0) (3 -6.2374e-17 0) (3 -3.47126e-17 0) (3 -1.13013e-16 0) (3 -9.75355e-17 0) (3 -8.89827e-17 0) (3 1.08365e-16 0) (3 1.66335e-16 0) (3 1.24533e-16 0) (3 1.22995e-16 0) (3 1.10892e-16 0) (3 -3.35027e-17 0) (3 -3.35622e-17 0) (3 -4.24697e-17 0) (3 -3.89998e-17 0) (3 -1.95347e-17 0) (3 -1.03185e-16 0) (3 -5.52495e-17 0) (3 -2.14252e-17 0) (3 -8.0489e-17 0) (3 -3.58373e-17 0) (3 -6.64185e-17 0) (3 -1.45665e-16 0) (3 -1.2431e-16 0) (3 -1.47998e-16 0) (3 -1.3561e-16 0) (3 -8.15142e-17 0) (3 -1.3429e-16 0) (3 -1.03628e-16 0) (3 -1.03818e-16 0) (3 -9.12354e-17 0) (3 -6.2154e-17 0) (3 -5.86055e-17 0) (3 -8.07311e-17 0) (3 5.88219e-17 0) (3 3.68317e-17 0) (3 8.67149e-17 0) (3 8.13307e-17 0) (3 1.05556e-16 0) (3 1.07608e-16 0) (3 7.99275e-17 0) (3 3.72451e-17 0) (3 5.97039e-17 0) (3 5.9816e-17 0) (3 8.05289e-17 0) (3 5.62889e-17 0) (3 8.83524e-17 0) (3 1.26187e-16 0) (3 1.30201e-16 0) (3 8.69652e-17 0) (3 7.19775e-17 0) (3 3.79551e-17 0) (3 -2.66193e-17 0) (3 -1.14301e-17 0) (3 -2.48127e-17 0) (3 -5.92825e-17 0) (3 -4.21524e-17 0) (3 -4.60731e-17 0) (3 1.05788e-16 0) (3 1.11774e-16 0) (3 1.44816e-16 0) (3 -1.10274e-16 0) (3 -8.52897e-17 0) (3 -2.83559e-16 0) (3 -1.94598e-18 0) (3 -2.52699e-16 0) (3 -1.65476e-16 0) (3 -6.7656e-17 0) (3 -1.93148e-16 0) (3 -1.62928e-16 0) (3 -1.41105e-16 0) (3 -1.54971e-16 0) (3 -1.9106e-16 0) (3 -1.43541e-16 0) (3 -1.43788e-16 0) (3 -5.31559e-17 0) (3 -9.96245e-17 0) (3 1.04959e-16 0) (3 -2.30964e-16 0) (3 -1.00143e-16 0) (3 5.36176e-17 0) (3 1.90587e-17 0) (3 -5.38046e-17 0) (3 -1.19968e-16 0) (3 -1.20178e-16 0) (3 -1.22133e-16 0) (3 -2.07991e-16 0) (3 -2.13609e-16 0) (3 -1.982e-16 0) (3 -1.82736e-16 0) (3 -7.21675e-17 0) (3 -1.922e-16 0) (3 -1.69577e-16 0) (3 -1.69879e-16 0) (3 -1.34727e-16 0) (3 -1.11881e-16 0) (3 -9.429e-17 0) (3 -5.70317e-17 0) (3 -9.99845e-17 0) (3 1.43092e-17 0) (3 -1.25431e-17 0) (3 3.59019e-17 0) (3 1.25884e-17 0) (3 1.44127e-17 0) (3 2.88777e-17 0) (3 5.60523e-17 0) (3 4.34743e-17 0) (3 3.08504e-17 0) (3 5.63594e-17 0) (3 1.27496e-17 0) (3 1.13132e-16 0) (3 5.84979e-17 0) (3 6.77626e-17 0) (3 9.90791e-17 0) (3 1.011e-16 0) (3 1.25228e-16 0) (3 1.27305e-16 0) (3 1.03512e-16 0) (3 2.03705e-17 0) (3 1.11319e-17 0) (3 -4.46107e-17 0) (3 -3.16583e-17 0) (3 -5.78381e-17 0) (3 -5.9816e-17 0) (3 -4.49464e-17 0) (3 1.3697e-16 0) (3 -1.59786e-16 0) (3 5.83852e-17 0) (3 3.77393e-17 0) (3 3.7811e-17 0) (3 -1.3259e-17 0) (3 -2.65686e-17 0) (3 1.14083e-17 0) (3 7.62008e-18 0) (3 2.29041e-17 0) (3 7.84058e-17 0) (3 1.39869e-16 0) (3 2.76439e-16 0) (3 2.15423e-16 0) (3 1.83079e-16 0) (3 1.21646e-16 0) (3 7.73854e-17 0) (3 -1.16304e-17 0) (3 3.70876e-31 0) (3 1.32327e-16 0) (3 -2.46343e-17 0) (3 -5.23444e-17 0) (3 -5.24334e-17 0) (3 -7.11597e-17 0) (3 -7.29782e-17 0) (3 -9.01034e-17 0) (3 -6.81189e-17 0) (3 -3.58237e-17 0) (3 -7.5188e-17 0) (3 -5.30645e-17 0) (3 -7.88765e-17 0) (3 -6.69889e-17 0) (3 5.1619e-17 0) (3 1.72361e-18 0) (3 -2.76256e-17 0) (3 -6.74545e-17 0) (3 -9.3561e-17 0) (3 -1.51e-16 0) (3 -1.46048e-16 0) (3 -1.20178e-16 0) (3 -1.4656e-16 0) (3 -2.04495e-16 0) (3 -2.55631e-16 0) (3 -1.52596e-16 0) (3 -1.31781e-16 0) (3 -1.10892e-16 0) (3 3.35027e-17 0) (3 7.24236e-17 0) (3 2.15887e-16 0) (3 -6.91361e-17 0) (3 -3.90694e-17 0) (3 1.90359e-16 0) (3 1.92482e-16 0) (3 1.46406e-16 0) (3 2.00328e-16 0) (3 2.38318e-16 0) (3 2.08231e-16 0) (3 1.81632e-16 0) (3 1.62143e-16 0) (3 2.16583e-16 0) (3 1.97087e-16 0) (3 2.11937e-16 0) (3 1.76029e-16 0) (3 1.7635e-16 0) (3 1.58459e-16 0) (3 1.66048e-16 0) (3 1.29792e-16 0) (3 6.22684e-17 0) (3 2.69715e-16 0) (3 5.69837e-17 0) (3 1.29217e-31 0) (3 -8.67149e-17 0) (3 1.44177e-16 0) (3 -2.22224e-17 0) (3 6.30807e-17 0) (3 -3.71756e-17 0) (3 8.38015e-17 0) (3 3.73149e-17 0) (3 5.42082e-17 0) (3 6.92923e-17 0) (3 8.2557e-17 0) (3 5.45153e-17 0) (3 -5.65018e-18 0) (3 -3.20784e-17 0) (3 -3.40299e-17 0) (3 -3.59888e-17 0) (3 8.35013e-17 0) (3 8.55621e-17 0) (3 1.54307e-16 0) (3 3.05387e-16 0) (3 1.10916e-16 0) (3 2.41418e-16 0) (3 3.05234e-16 0) (3 1.65414e-16 0) (3 1.65735e-16 0) (3 1.50609e-16 0) (3 -8.31893e-17 0) (3 1.99655e-16 0) (3 -2.11698e-16 0) (3 2.14058e-16 0) (3 9.91457e-17 0) (3 8.61151e-17 0) (3 1.03175e-16 0) (3 1.55874e-16 0) (3 1.40865e-16 0) (3 1.58106e-16 0) (3 1.85624e-16 0) (3 1.68883e-16 0) (3 1.62338e-16 0) (3 1.64329e-16 0) (3 1.18315e-16 0) (3 2.0612e-16 0) (3 1.54857e-16 0) (3 1.89597e-16 0) (3 1.76113e-16 0) (3 1.21072e-16 0) (3 1.28213e-16 0) (3 1.66621e-16 0) (3 1.87776e-16 0) (3 1.67204e-16 0) (3 1.77965e-16 0) (3 2.11486e-16 0) (3 1.89097e-16 0) (3 1.4558e-16 0) (3 1.4408e-16 0) (3 1.44335e-16 0) (3 1.19904e-16 0) (3 1.20117e-16 0) (3 1.221e-16 0) (3 1.48908e-16 0) (3 3.14331e-16 0) (3 1.83243e-16 0) (3 1.47926e-16 0) (3 1.58904e-16 0) (3 1.12685e-16 0) (3 3.04617e-17 0) (3 1.25657e-16 0) (3 1.24085e-16 0) (3 1.2431e-16 0) (3 1.73266e-16 0) (3 1.50075e-16 0) (3 1.75708e-16 0) (3 1.6514e-16 0) (3 1.41807e-16 0) (3 1.22032e-16 0) (3 3.83189e-17 0) (3 2.55928e-17 0) (3 -1.46514e-17 0) (3 -3.6696e-17 0) (3 -4.77928e-17 0) (3 -7.5505e-17 0) (3 -7.9335e-17 0) (3 -8.13307e-17 0) (3 -1.0926e-16 0) (3 -1.42859e-16 0) (3 -1.30114e-16 0) (3 -1.54567e-16 0) (3 -4.47779e-17 0) (3 -3.7385e-17 0) (3 -3.74553e-17 0) (3 -3.75259e-17 0) (3 1.07151e-16 0) (3 3.76679e-17 0) (3 3.77393e-17 0) (3 3.7811e-17 0) (3 3.78829e-17 0) (3 1.5182e-17 0) (3 1.33097e-17 0) (3 -3.81004e-17 0) (3 3.62648e-17 0) (3 5.73701e-18 0) (3 -3.44883e-17 0) (3 -1.3438e-16 0) (3 -1.11558e-16 0) (3 -1.52245e-16 0) (3 -3.86177e-17 0) (3 -6.19083e-17 0) (3 -3.29528e-17 0) (3 9.71092e-18 0) (3 -6.22714e-17 0) (3 -7.43186e-17 0) (3 2.48214e-16 0) (3 2.68932e-16 0) (3 2.67696e-16 0) (3 3.34342e-16 0) (3 3.21312e-16 0) (3 3.03129e-16 0) (3 2.74648e-16 0) (3 2.73411e-16 0) (3 2.70458e-16 0) (3 2.38344e-16 0) (3 3.36662e-16 0) (3 1.65181e-16 0) (3 2.08557e-16 0) (3 -5.1798e-18 0) (3 3.16517e-16 0) (3 5.54436e-17 0) (3 1.63149e-16 0) (3 3.47733e-17 0) (3 4.52843e-17 0) (3 2.82651e-16 0) (3 3.23347e-16 0) (3 3.01154e-16 0) (3 3.06947e-16 0) (3 2.91675e-16 0) (3 2.72828e-16 0) (3 2.27466e-16 0) (3 1.2365e-16 0) (3 1.11483e-16 0) (3 7.09088e-17 0) (3 1.42071e-16 0) (3 1.24534e-17 0) (3 -1.60402e-17 0) (3 -2.67816e-17 0) (3 -3.0407e-17 0) (3 -9.49688e-17 0) (3 -6.28284e-17 0) (3 -7.01352e-17 0) (3 -7.38653e-17 0) (3 -1.2273e-16 0) (3 -1.10296e-16 0) (3 -8.51371e-17 0) (3 -5.62566e-17 0) (3 -5.63594e-17 0) (3 -1.49352e-16 0) (3 -1.40503e-16 0) (3 -1.44417e-16 0) (3 -1.92299e-16 0) (3 -2.09167e-16 0) (3 -2.04039e-16 0) (3 -1.5101e-16 0) (3 -1.5129e-16 0) (3 -2.1072e-16 0) (3 -3.1852e-16 0) (3 -2.72731e-16 0) (3 -1.89595e-16 0) (3 -1.28496e-16 0) (3 -8.39586e-17 0) (3 -1.00939e-16 0) (3 -1.0862e-16 0) (3 -1.08825e-16 0) (3 -1.31589e-16 0) (3 -9.04029e-17 0) (3 -8.30264e-17 0) (3 -8.31841e-17 0) (3 -8.33424e-17 0) (3 -1.29047e-16 0) (3 -1.29294e-16 0) (3 -1.96217e-16 0) (3 -2.06137e-16 0) (3 -1.81672e-16 0) (3 -1.82022e-16 0) (3 -2.55322e-16 0) (3 -1.15405e-16 0) (3 -1.73443e-17 0) (3 8.49589e-17 0) (3 -1.0834e-16 0) (3 1.10489e-16 0) (3 9.71092e-17 0) (3 -1.36219e-17 0) (3 -1.5599e-17 0) (3 1.55345e-16 0) (3 1.42078e-16 0) (3 1.28765e-16 0) (3 1.08619e-16 0) (3 1.03704e-16 0) (3 1.00475e-16 0) (3 1.00648e-16 0) (3 8.71498e-17 0) (3 7.70291e-17 0) (3 6.34441e-17 0) (3 3.26356e-17 0) (3 1.15282e-16 0) (3 9.30751e-17 0) (3 3.4532e-17 0) (3 3.4592e-17 0) (3 -1.03957e-17 0) (3 -9.81583e-31 0) (3 4.17279e-17 0) (3 2.36872e-16 0) (3 -6.10665e-17 0) (3 -4.36955e-17 0) (3 -1.22563e-17 0) (3 -5.43734e-17 0) (3 1.22995e-17 0) (3 -1.76018e-18 0) (3 -4.58458e-17 0) (3 -5.47593e-17 0) (3 -5.48566e-17 0) (3 1.77272e-16 0) (3 -2.89469e-16 0) (3 -2.34835e-16 0) (3 -2.13869e-16 0) (3 -1.08912e-16 0) (3 -1.10896e-16 0) (3 -1.0572e-16 0) (3 -1.45403e-16 0) (3 -1.13295e-16 0) (3 -1.2431e-16 0) (3 -1.69657e-16 0) (3 -1.03064e-16 0) (3 -1.88388e-16 0) (3 -1.92361e-16 0) (3 -1.72714e-16 0) (3 -1.52995e-16 0) (3 -1.49626e-16 0) (3 -1.04199e-16 0) (3 -2.19771e-16 0) (3 -1.98158e-16 0) (3 -2.00362e-16 0) (3 -1.58376e-16 0) (3 -1.53135e-16 0) (3 -1.756e-16 0) (3 -1.20371e-16 0) (3 3.5251e-17 0) (3 -9.47977e-17 0) (3 3.16583e-17 0) (3 -2.16427e-16 0) (3 -8.41162e-17 0) (3 -1.04875e-16 0) (3 -1.05073e-16 0) (3 -1.29709e-16 0) (3 -1.29954e-16 0) (3 -1.30201e-16 0) (3 -1.32338e-16 0) (3 -1.30696e-16 0) (3 -3.79551e-17 0) (3 -8.36607e-17 0) (3 -8.57258e-17 0) (3 -1.22155e-16 0) (3 -1.39601e-16 0) (3 -1.57114e-16 0) (3 -1.63176e-16 0) (3 -1.4618e-16 0) (3 -1.83079e-16 0) (3 -2.70324e-16 0) (3 -2.1281e-16 0) (3 -2.11286e-16 0) (3 -1.92276e-16 0) (3 -1.8876e-16 0) (3 -1.80462e-16 0) (3 -4.22133e-17 0) (3 -1.18398e-17 0) (3 -1.18599e-17 0) (3 -7.1281e-17 0) (3 -3.57014e-17 0) (3 -7.49308e-17 0) (3 -6.14121e-17 0) (3 -1.8797e-17 0) (3 -7.18938e-17 0) (3 -6.34441e-17 0) (3 -3.43533e-17 0) (3 -5.50603e-17 0) (3 -3.44722e-17 0) (3 -3.4532e-17 0) (3 -1.90256e-17 0) (3 -1.73261e-18 0) (3 2.95057e-17 0) (3 3.65119e-17 0) (3 3.48341e-17 0) (3 -8.20036e-17 0) (3 -2.11486e-16 0) (3 -2.04855e-16 0) (3 -2.24509e-16 0) (3 -2.42476e-16 0) (3 -2.37625e-16 0) (3 -2.22176e-16 0) (3 -1.90774e-16 0) (3 -1.91113e-16 0) (3 -1.45363e-16 0) (3 -1.45622e-16 0) (3 -2.13487e-16 0) (3 -2.08522e-16 0) (3 -2.21394e-16 0) (3 -2.16426e-16 0) (3 -1.93521e-16 0) (3 -2.56699e-16 0) (3 -1.92422e-16 0) (3 -1.9277e-16 0) (3 -2.20193e-16 0) (3 -3.48971e-16 0) (3 -3.78588e-16 0) (3 -8.52923e-17 0) (3 -6.25407e-16 0) (3 -1.40245e-16 0) (3 -1.25905e-16 0) (3 -1.68181e-16 0) (3 -1.17211e-16 0) (3 8.25659e-17 0) (3 7.53656e-17 0) (3 3.31485e-17 0) (3 -5.535e-18 0) (3 -3.69685e-18 0) (3 -1.66668e-17 0) (3 -5.93701e-17 0) (3 -1.0595e-16 0) (3 -1.39669e-16 0) (3 -1.6232e-16 0) (3 -1.7384e-16 0) (3 -1.79785e-16 0) (3 -1.83877e-16 0) (3 -8.27129e-17 0) (3 -1.09237e-16 0) (3 -2.28323e-16 0) (3 -1.58806e-16 0) (3 -1.5532e-16 0) (3 -1.59411e-16 0) (3 -1.42604e-16 0) (3 -1.33351e-16 0) (3 -1.92776e-16 0) (3 -1.33864e-16 0) (3 -2.22258e-16 0) (3 -1.84292e-16 0) (3 -3.46216e-16 0) (3 -4.00846e-16 0) (3 -4.49896e-16 0) (3 -3.32757e-16 0) (3 -3.56666e-16 0) (3 -3.04923e-16 0) (3 -2.93843e-16 0) (3 -2.72544e-16 0) (3 -3.37706e-17 0) (3 8.457e-18 0) (3 1.18599e-17 0) (3 3.56405e-17 0) (3 3.40013e-17 0) (3 3.40595e-17 0) (3 3.41178e-17 0) (3 8.88586e-17 0) (3 2.39646e-17 0) (3 6.17294e-17 0) (3 6.18359e-17 0) (3 1.20444e-17 0) (3 3.27486e-17 0) (3 3.4532e-17 0) (3 3.28624e-17 0) (3 3.1187e-17 0) (3 3.2977e-17 0) (3 -2.78186e-17 0) (3 -3.30924e-17 0) (3 -1.22133e-17 0) (3 -3.49564e-17 0) (3 -3.50179e-17 0) (3 -6.13893e-17 0) (3 -1.4408e-16 0) (3 -1.33774e-16 0) (3 -4.76091e-17 0) (3 -1.05986e-17 0) (3 -1.2387e-17 0) (3 7.44542e-17 0) (3 7.81388e-17 0) (3 -1.24534e-16 0) (3 1.92482e-16 0) (3 3.92796e-17 0) (3 7.15458e-18 0) (3 1.07512e-17 0) (3 -1.07706e-17 0) (3 -1.11807e-32 0) (3 9.00797e-18 0) (3 1.08292e-17 0) (3 -5.60523e-17 0) (3 -9.05714e-18 0) (3 -7.25892e-18 0) (3 -5.63594e-17 0) (3 -4.55342e-17 0) (3 2.00718e-17 0) (3 -2.02915e-16 0) (3 5.49427e-18 0) (3 -8.99051e-17 0) (3 -5.69837e-17 0) (3 -1.27069e-16 0) (3 -1.1439e-16 0) (3 -1.84842e-17 0) (3 1.2963e-17 0) (3 -1.66978e-17 0) (3 -6.31985e-17 0) (3 -4.84186e-17 0) (3 -2.05232e-17 0) (3 -1.38324e-16 0) (3 -1.04875e-16 0) (3 -6.00414e-17 0) (3 -1.56027e-16 0) (3 -1.43138e-16 0) (3 -3.58523e-17 0) (3 -3.59204e-17 0) (3 -6.25068e-17 0) (3 -1.72696e-16 0) (3 -1.46406e-16 0) (3 -1.69547e-16 0) (3 -1.94684e-16 0) (3 -1.87409e-16 0) (3 -1.36037e-16 0) (3 -8.44674e-17 0) (3 -9.61711e-17 0) (3 -1.13702e-16 0) (3 -1.1006e-16 0) (3 -4.44966e-17 0) (3 1.35688e-17 0) (3 6.21499e-17 0) (3 6.03254e-17 0) (3 6.2474e-17 0) (3 -5.06559e-18 0) (3 -3.3828e-17 0) (3 -6.77711e-18 0) (3 4.92178e-17 0) (3 5.2702e-17 0) (3 5.27922e-17 0) (3 5.45885e-17 0) (3 7.17704e-17 0) (3 4.9641e-17 0) (3 1.73185e-16 0) (3 1.82072e-16 0) (3 1.85828e-16 0) (3 1.72361e-16 0) (3 1.69207e-16 0) (3 1.43557e-16 0) (3 1.43807e-16 0) (3 1.45793e-16 0) (3 1.23445e-16 0) (3 1.27145e-16 0) (3 1.25623e-16 0) (3 1.43321e-16 0) (3 1.03303e-16 0) (3 1.66628e-16 0) (3 1.35295e-16 0) (3 1.44335e-16 0) (3 1.21668e-16 0) (3 1.00686e-16 0) (3 1.2387e-16 0) (3 1.0459e-16 0) (3 1.15432e-16 0) (3 1.83243e-16 0) (3 1.85353e-16 0) (3 1.92827e-16 0) (3 7.87004e-17 0) (3 7.88421e-17 0) (3 7.89842e-17 0) (3 9.89086e-17 0) (3 1.02691e-16 0) (3 1.02877e-16 0) (3 1.66349e-16 0) (3 2.75337e-16 0) (3 2.86727e-16 0) (3 2.67252e-16 0) (3 1.52995e-16 0) (3 1.73347e-16 0) (3 1.59041e-16 0) (3 1.26368e-16 0) (3 4.03655e-17 0) (3 2.57346e-17 0) (3 3.1307e-17 0) (3 1.5129e-16 0) (3 1.53419e-16 0) (3 -5.18522e-17 0) (3 1.44715e-16 0) (3 2.02607e-16 0) (3 2.0671e-16 0) (3 1.82843e-16 0) (3 2.71041e-16 0) (3 3.82044e-16 0) (3 3.62125e-16 0) (3 3.02654e-16 0) (3 2.76859e-16 0) (3 3.00027e-16 0) (3 2.74129e-16 0) (3 1.81838e-16 0) (3 1.8598e-16 0) (3 9.88718e-17 0) (3 1.04776e-16 0) (3 2.0041e-16 0) (3 2.08445e-16 0) (3 2.08846e-16 0) (3 2.09249e-16 0) (3 2.44275e-16 0) (3 2.52456e-16 0) (3 2.85771e-16 0) (3 3.83058e-16 0) (3 3.58605e-16 0) (3 2.83559e-16 0) (3 3.09411e-16 0) (3 2.83996e-16 0) (3 5.23444e-17 0) (3 -8.457e-18 0) (3 -6.77711e-18 0) (3 -3.22462e-17 0) (3 4.08016e-17 0) (3 6.1307e-17 0) (3 9.3824e-17 0) (3 1.65755e-16 0) (3 1.90005e-16 0) (3 1.64612e-16 0) (3 1.52872e-16 0) (3 1.46254e-16 0) (3 1.53401e-16 0) (3 1.43308e-16 0) (3 1.64312e-16 0) (3 1.62865e-16 0) (3 1.63149e-16 0) (3 1.63434e-16 0) (3 1.65462e-16 0) (3 1.58773e-16 0) (3 1.90513e-16 0) (3 1.90848e-16 0) (3 1.91184e-16 0) (3 2.81132e-16 0) (3 2.04181e-16 0) (3 2.08069e-16 0) (3 2.80862e-16 0) (3 2.68974e-16 0) (3 2.12726e-16 0) (3 2.13106e-16 0) (3 2.15266e-16 0) (3 2.69118e-16 0) (3 2.51747e-16 0) (3 2.59354e-16 0) (3 2.63404e-16 0) (3 2.63879e-16 0) (3 2.31986e-16 0) (3 2.54025e-16 0) (3 2.65314e-16 0) (3 2.65796e-16 0) (3 3.4236e-16 0) (3 3.44799e-16 0) (3 3.39974e-16 0) (3 3.35132e-16 0) (3 3.37571e-16 0) (3 3.36363e-16 0) (3 3.64453e-16 0) (3 6.18327e-16 0) (3 4.79766e-16 0) (3 6.11406e-16 0) (3 5.99625e-16 0) (3 5.30498e-16 0) (3 5.75929e-16 0) (3 5.39896e-16 0) (3 5.42763e-16 0) (3 5.25156e-16 0) (3 4.90691e-16 0) (3 3.9815e-16 0) (3 4.79428e-16 0) (3 2.27032e-16 0) (3 4.13564e-16 0) (3 4.03046e-16 0) (3 3.56636e-16 0) (3 4.97214e-16 0) (3 2.57604e-16 0) (3 6.47135e-16 0) (3 1.88237e-16 0) (3 4.99115e-16 0) (3 3.53104e-16 0) (3 4.51312e-16 0) (3 3.83204e-16 0) (3 3.45548e-16 0) (3 3.78914e-16 0) (3 5.18402e-16 0) (3 3.82315e-16 0) (3 2.84391e-16 0) (3 2.51992e-16 0) (3 2.01987e-16 0) (3 1.61516e-16 0) (3 1.73477e-16 0) (3 1.03e-16 0) (3 1.21781e-16 0) (3 9.65738e-17 0) (3 4.58235e-17 0) (3 -3.40013e-18 0) (3 1.02178e-17 0) (3 1.02353e-17 0) (3 1.02529e-17 0) (3 3.59469e-17 0) (3 -3.42941e-17 0) (3 -1.20237e-17 0) (3 -1.03238e-17 0) (3 -1.03417e-17 0) (3 5.1798e-18 0) (3 1.7296e-17 0) (3 1.21283e-17 0) (3 9.8931e-17 0) (3 7.99785e-17 0) (3 7.83767e-17 0) (3 7.85141e-17 0) (3 8.21476e-17 0) (3 3.67688e-17 0) (3 1.19271e-16 0) (3 1.19481e-16 0) (3 1.63697e-16 0) (3 2.20413e-16 0) (3 2.36702e-16 0) (3 2.21196e-16 0) (3 2.16272e-16 0) (3 1.93571e-16 0) (3 1.92138e-16 0) (3 3.61795e-16 0) (3 -4.64214e-17 0) (3 3.72038e-16 0) (3 3.58373e-16 0) (3 3.46454e-16 0) (3 3.77651e-16 0) (3 3.56715e-16 0) (3 3.57362e-16 0) (3 3.58011e-16 0) (3 3.35114e-16 0) (3 3.35725e-16 0) (3 3.96334e-16 0) (3 4.06165e-16 0) (3 4.0691e-16 0) (3 4.07657e-16 0) (3 4.01081e-16 0) (3 3.39438e-16 0) (3 4.83443e-16 0) (3 4.56713e-16 0) (3 3.1734e-16 0) (3 3.17929e-16 0) (3 3.40743e-16 0) (3 2.80152e-16 0) (3 2.15618e-16 0) (3 2.17884e-16 0) (3 2.22024e-16 0) (3 2.16833e-16 0) (3 9.92566e-17 0) (3 1.08825e-16 0) (3 8.45927e-17 0) (3 1.09237e-16 0) (3 1.09444e-16 0) (3 1.30448e-16 0) (3 1.3259e-16 0) (3 1.67003e-16 0) (3 2.30067e-16 0) (3 5.29595e-16 0) (3 1.79415e-16 0) (3 1.95058e-16 0) (3 2.56746e-16 0) (3 2.57242e-16 0) (3 2.55815e-16 0) (3 2.58238e-16 0) (3 3.30181e-16 0) (3 2.10875e-16 0) (3 2.32608e-16 0) (3 2.33062e-16 0) (3 2.33518e-16 0) (3 2.36025e-16 0) (3 3.20821e-17 0) (3 3.21366e-17 0) (3 6.26883e-17 0) (3 1.54442e-16 0) (3 1.00304e-16 0) (3 9.70695e-17 0) (3 9.72358e-17 0) (3 8.88586e-17 0) (3 3.42351e-17 0) (3 4.62971e-17 0) (3 1.06495e-16 0) (3 8.25904e-17 0) (3 8.4457e-17 0) (3 6.38843e-17 0) (3 6.57249e-17 0) (3 -6.93045e-18 0) (3 -4.33908e-17 0) (3 -2.608e-17 0) (3 -1.91588e-17 0) (3 1.04685e-17 0) (3 -1.57304e-17 0) (3 6.82849e-17 0) (3 1.22779e-17 0) (3 1.22995e-17 0) (3 -3.59572e-31 0) (3 -5.46623e-17 0) (3 -4.23943e-17 0) (3 1.06174e-17 0) (3 -5.6727e-17 0) (3 3.37418e-17 0) (3 1.24534e-17 0) (3 1.24757e-17 0) (3 7.85592e-17 0) (3 6.26026e-17 0) (3 5.55478e-17 0) (3 2.10026e-16 0) (3 7.19335e-17 0) (3 8.82781e-17 0) (3 8.12187e-17 0) (3 8.13662e-17 0) (3 2.71714e-17 0) (3 3.26651e-17 0) (3 3.27248e-17 0) (3 4.73556e-17 0) (3 8.02872e-17 0) (3 5.66698e-17 0) (3 2.06951e-16 0) (3 -1.28436e-17 0) (3 3.67637e-17 0) (3 3.49901e-17 0) (3 1.2915e-17 0) (3 1.51571e-16 0) (3 4.62966e-17 0) (3 1.11319e-16 0) (3 5.76221e-17 0) (3 5.77299e-17 0) (3 2.79862e-17 0) (3 5.60775e-17 0) (3 8.24017e-17 0) (3 2.0264e-16 0) (3 3.13933e-16 0) (3 3.03227e-16 0) (3 3.05688e-16 0) (3 3.02488e-16 0) (3 2.76545e-16 0) (3 3.01743e-16 0) (3 2.41475e-16 0) (3 2.49557e-16 0) (3 2.53853e-16 0) (3 1.85497e-16 0) (3 1.41785e-16 0) (3 1.22862e-16 0) (3 1.44257e-16 0) (3 1.59953e-16 0) (3 1.56402e-16 0) (3 1.56706e-16 0) (3 1.99655e-16 0) (3 2.11698e-16 0) (3 3.34709e-16 0) (3 3.10207e-16 0) (3 -3.37706e-17 0) (3 -5.9199e-17 0) (3 -7.62425e-17 0) (3 -6.44923e-17 0) (3 8.50032e-18 0) (3 -1.19208e-17 0) (3 1.19412e-17 0) (3 6.83528e-18 0) (3 -3.42351e-17 0) (3 -6.85882e-17 0) (3 5.15299e-18 0) (3 -7.91491e-17 0) (3 -9.47987e-17 0) (3 -1.20862e-16 0) (3 -1.21072e-16 0) (3 -1.21283e-16 0) (3 -1.63149e-16 0) (3 -1.6865e-16 0) (3 -5.74763e-17 0) (3 -2.44266e-16 0) (3 -7.34085e-17 0) (3 -6.12813e-17 0) (3 -1.17517e-16 0) (3 -1.22995e-16 0) (3 -1.8834e-16 0) (3 -1.922e-16 0) (3 -2.36702e-16 0) (3 -2.035e-16 0) (3 -2.58817e-16 0) (3 -2.46848e-16 0) (3 -1.65452e-16 0) (3 -1.53273e-16 0) (3 -1.48191e-16 0) (3 -3.27322e-16 0) (3 -3.01033e-16 0) (3 -1.68739e-16 0) (3 -2.78742e-16 0) (3 -2.3781e-16 0) (3 -1.94925e-16 0) (3 -2.09744e-16 0) (3 -1.73897e-16 0) (3 -1.74214e-16 0) (3 -2.418e-16 0) (3 -2.03993e-16 0) (3 -1.51451e-16 0) (3 -1.84634e-16 0) (3 -1.75817e-16 0) (3 -1.88984e-16 0) (3 -3.65799e-16 0) (3 -6.07723e-17 0) (3 5.535e-17 0) (3 3.69685e-18 0) (3 -9.25932e-18 0) (3 -3.5251e-17 0) (3 -2.41641e-17 0) (3 -8.38015e-17 0) (3 5.41066e-17 0) (3 -3.7385e-17 0) (3 -4.86919e-17 0) (3 -6.00414e-17 0) (3 3.57169e-17 0) (3 3.57845e-17 0) (3 1.88696e-17 0) (3 4.91542e-17 0) (3 4.16712e-17 0) (3 -3.60574e-17 0) (3 -5.13373e-17 0) (3 -7.81058e-17 0) (3 -7.44382e-17 0) (3 -6.50195e-17 0) (3 1.43701e-16 0) (3 1.3246e-16 0) (3 6.15495e-17 0) (3 1.92715e-18 0) (3 -1.42885e-16 0) (3 -1.12209e-16 0) (3 -1.20181e-16 0) (3 -6.21499e-17 0) (3 -1.61516e-16 0) (3 -1.46326e-16 0) (3 -7.42953e-17 0) (3 -9.81012e-17 0) (3 -9.82681e-17 0) (3 -1.74808e-16 0) (3 -2.04008e-16 0) (3 -2.02654e-16 0) (3 -2.18354e-16 0) (3 -2.68285e-16 0) (3 -2.49917e-16 0) (3 -2.52062e-16 0) (3 -2.74826e-16 0) (3 -2.7186e-16 0) (3 -2.72331e-16 0) (3 -2.72803e-16 0) (3 -2.73277e-16 0) (3 -2.70287e-16 0) (3 -5.38046e-17 0) (3 -6.78079e-17 0) (3 -1.13211e-16 0) (3 -2.07626e-16 0) (3 -1.62547e-16 0) (3 -2.08357e-16 0) (3 -2.05216e-16 0) (3 -1.91521e-16 0) (3 -3.67878e-16 0) (3 -5.64256e-17 0) (3 -2.15504e-16 0) (3 -3.25601e-16 0) (3 -2.14499e-16 0) (3 -2.53951e-16 0) (3 -1.28092e-16 0) (3 -1.14063e-16 0) (3 -2.07111e-16 0) (3 -2.00328e-16 0) (3 -6.98827e-17 0) (3 -3.01576e-16 0) (3 -3.43483e-16 0) (3 -3.33295e-16 0) (3 -3.33899e-16 0) (3 -2.85686e-16 0) (3 -2.75337e-16 0) (3 -2.55877e-16 0) (3 -2.19983e-16 0) (3 -2.27671e-16 0) (3 -3.63117e-16 0) (3 -7.31224e-17 0) (3 -3.20499e-16 0) (3 -2.23845e-16 0) (3 -1.28673e-16 0) (3 -1.60218e-16 0) (3 -1.97415e-16 0) (3 -3.17929e-16 0) (3 -3.01854e-16 0) (3 -2.87574e-16 0) (3 -1.3755e-16 0) (3 -1.54567e-16 0) (3 -1.41797e-16 0) (3 -1.14024e-16 0) (3 3.37098e-17 0) (3 -7.50518e-17 0) (3 -1.99263e-16 0) (3 -1.84573e-16 0) (3 -1.81149e-16 0) (3 -3.23284e-16 0) (3 -3.9777e-16 0) (3 -3.75756e-16 0) (3 -4.24008e-16 0) (3 -3.31473e-16 0) (3 -2.71031e-16 0) (3 -2.29481e-16 0) (3 -2.31838e-16 0) (3 -2.30366e-16 0) (3 -3.00054e-16 0) (3 -3.35323e-16 0) (3 -2.87702e-16 0) (3 -2.99869e-16 0) (3 -3.81865e-16 0) (3 -1.65086e-16 0) (3 -5.54605e-16 0) (3 -4.34419e-16 0) (3 -1.8405e-16 0) (3 -1.65757e-16 0) (3 -2.08396e-16 0) (3 -1.84991e-16 0) (3 -2.48209e-16 0) (3 -2.36713e-16 0) (3 -2.1153e-16 0) (3 -2.06767e-16 0) (3 -2.20817e-16 0) (3 -2.72638e-16 0) (3 -2.73109e-16 0) (3 -2.73581e-16 0) (3 -2.74054e-16 0) (3 -2.55537e-16 0) (3 -2.50792e-16 0) (3 -2.42566e-16 0) (3 -3.43655e-16 0) (3 -3.26869e-16 0) (3 -3.13507e-16 0) (3 -1.53539e-16 0) (3 -3.86269e-16 0) (3 -3.48428e-16 0) (3 -2.82391e-16 0) (3 -3.81285e-16 0) (3 -3.13313e-16 0) (3 -4.02032e-16 0) (3 -3.00293e-16 0) (3 -2.81361e-16 0) (3 -2.00317e-16 0) (3 -2.16658e-16 0) (3 -2.29498e-16 0) (3 -2.15651e-16 0) (3 -3.26735e-16 0) (3 -1.43092e-17 0) (3 2.15024e-17 0) (3 2.87215e-17 0) (3 5.93452e-17 0) (3 -1.08096e-17 0) (3 3.60972e-17 0) (3 5.96685e-17 0) (3 3.44171e-17 0) (3 1.08884e-17 0) (3 5.63594e-17 0) (3 -1.82137e-18 0) (3 -1.04008e-16 0) (3 -5.30137e-17 0) (3 -5.49427e-17 0) (3 -9.54095e-17 0) (3 -1.13967e-16 0) (3 -1.93367e-16 0) (3 -2.23245e-16 0) (3 -2.29205e-16 0) (3 -2.01853e-16 0) (3 -2.02229e-16 0) (3 -2.36065e-16 0) (3 -2.25333e-16 0) (3 -2.81728e-16 0) (3 -7.477e-17 0) (3 -1.89149e-16 0) (3 -2.08269e-16 0) (3 -2.04902e-16 0) (3 -2.26007e-16 0) (3 -2.28323e-16 0) (3 -1.55025e-16 0) (3 -3.78829e-17 0) (3 -1.34741e-16 0) (3 -9.5069e-18 0) (3 -8.57258e-17 0) (3 -4.00821e-17 0) (3 -8.98799e-17 0) (3 -3.04647e-16 0) (3 -2.86037e-16 0) (3 -2.53892e-16 0) (3 -6.93772e-17 0) (3 -1.37093e-16 0) (3 -1.14144e-16 0) (3 -1.35688e-16 0) (3 -1.35953e-16 0) (3 -1.20651e-16 0) (3 -1.21811e-16 0) (3 -7.59839e-17 0) (3 -5.41248e-17 0) (3 -1.16905e-16 0) (3 -1.05224e-16 0) (3 -8.67033e-17 0) (3 -5.44951e-17 0) (3 -6.65297e-17 0) (3 -2.05058e-17 0) (3 1.88293e-17 0) (3 1.21266e-31 0) (3 1.37413e-17 0) (3 2.92508e-17 0) (3 4.48139e-17 0) (3 7.59705e-17 0) (3 5.53472e-17 0) (3 5.71762e-17 0) (3 -2.08276e-17 0) (3 -6.60692e-17 0) (3 3.48341e-18 0) (3 1.22133e-17 0) (3 1.04869e-17 0) (3 -1.05054e-17 0) (3 -7.01592e-18 0) (3 -1.05425e-17 0) (3 8.80091e-18 0) (3 1.80496e-31 0) (3 1.05986e-17 0) (3 1.06174e-17 0) (3 -5.49543e-17 0) (3 -7.99147e-17 0) (3 -1.72568e-16 0) (3 -1.72877e-16 0) (3 -1.48191e-16 0) (3 -1.80653e-16 0) (3 -6.09234e-17 0) (3 -5.74431e-17 0) (3 -1.43867e-17 0) (3 1.71151e-16 0) (3 1.58828e-16 0) (3 1.3561e-16 0) (3 1.03251e-16 0) (3 1.41549e-16 0) (3 3.9997e-17 0) (3 1.03818e-16 0) (3 9.85343e-17 0) (3 8.04346e-17 0) (3 1.04391e-16 0) (3 3.11916e-17 0) (3 -7.35274e-17 0) (3 -8.28714e-17 0) (3 -5.904e-17 0) (3 -5.91496e-17 0) (3 -5.92596e-17 0) (3 -1.29872e-16 0) (3 -1.30114e-16 0) (3 -1.02424e-16 0) (3 -1.54857e-16 0) (3 7.10315e-17 0) (3 -3.70808e-16 0) (3 -1.21959e-16 0) (3 -2.50018e-16 0) (3 -2.18474e-16 0) (3 -3.01914e-17 0) (3 -2.13632e-16 0) (3 -3.59888e-17 0) (3 -3.60574e-17 0) (3 3.80276e-17 0) (3 -1.00966e-16 0) (3 6.68035e-17 0) (3 2.10357e-17 0) (3 -3.44883e-17 0) (3 -4.99125e-17 0) (3 -6.53964e-17 0) (3 -3.66158e-17 0) (3 -7.91662e-17 0) (3 -8.5124e-17 0) (3 -6.97825e-17 0) (3 -3.69015e-17 0) (3 -3.69736e-17 0) (3 -5.89726e-17 0) (3 7.42953e-17 0) (3 6.7656e-17 0) (3 9.82681e-17 0) (3 1.84991e-16 0) (3 1.71707e-16 0) (3 1.61782e-16 0) (3 2.01295e-16 0) (3 4.95558e-17 0) (3 1.35229e-16 0) (3 1.76615e-16 0) (3 2.81697e-16 0) (3 3.33803e-16 0) (3 3.82642e-16 0) (3 3.41867e-16 0) (3 2.88843e-16 0) (3 3.20533e-16 0) (3 2.75966e-16 0) (3 3.42517e-16 0) (3 3.18732e-16 0) (3 2.58224e-16 0) (3 2.14982e-16 0) (3 2.10107e-16 0) (3 2.10478e-16 0) (3 2.10849e-16 0) (3 2.04181e-16 0) (3 3.40317e-16 0) (3 1.67811e-16 0) (3 2.44201e-16 0) (3 1.96772e-16 0) (3 1.22536e-16 0) (3 1.52999e-16 0) (3 1.01588e-16 0) (3 2.16038e-16 0) (3 1.9854e-16 0) (3 2.13232e-16 0) (3 1.75919e-16 0) (3 9.89086e-17 0) (3 8.64765e-17 0) (3 3.42923e-17 0) (3 -1.2657e-17 0) (3 5.61543e-17 0) (3 3.08504e-17 0) (3 -2.90887e-17 0) (3 -3.64274e-17 0) (3 -5.6566e-17 0) (3 -5.84979e-17 0) (3 9.15711e-18 0) (3 2.20176e-17 0) (3 8.08802e-17 0) (3 6.81387e-17 0) (3 -3.69e-18 0) (3 -1.10905e-17 0) (3 -9.4445e-17 0) (3 1.11319e-17 0) (3 -7.43511e-18 0) (3 -1.30358e-17 0) (3 -2.05232e-17 0) (3 -1.86925e-18 0) (3 3.1837e-17 0) (3 1.31341e-17 0) (3 1.87984e-18 0) (3 -1.31838e-17 0) (3 3.58523e-17 0) (3 -5.67164e-17 0) (3 -6.06126e-17 0) (3 -5.88304e-17 0) (3 -5.89428e-17 0) (3 6.28656e-17 0) (3 -2.04228e-16 0) (3 -1.81672e-16 0) (3 -1.57114e-16 0) (3 -1.51657e-16 0) (3 -1.32716e-16 0) (3 -1.52245e-16 0) (3 -8.49589e-17 0) (3 -8.5124e-17 0) (3 -8.33513e-17 0) (3 -7.3803e-17 0) (3 7.39473e-17 0) (3 1.23838e-16 0) (3 9.45577e-17 0) (3 9.64098e-17 0) (3 7.45482e-17 0) (3 7.29782e-17 0) (3 6.80026e-17 0) (3 5.9604e-17 0) (3 9.72358e-17 0) (3 6.83528e-17 0) (3 3.42351e-17 0) (3 3.25794e-17 0) (3 -1.0306e-17 0) (3 2.58095e-17 0) (3 -3.44722e-18 0) (3 -3.22041e-32 0) (3 1.03776e-17 0) (3 2.07913e-17 0) (3 2.77701e-17 0) (3 7.82399e-17 0) (3 -7.83767e-17 0) (3 2.1286e-16 0) (3 1.32834e-16 0) (3 1.27815e-16 0) (3 9.99769e-17 0) (3 1.03667e-16 0) (3 1.02091e-16 0) (3 5.81889e-17 0) (3 4.23943e-17 0) (3 2.30044e-17 0) (3 -1.06363e-17 0) (3 3.55176e-17 0) (3 -1.77906e-17 0) (3 3.38626e-17 0) (3 1.78544e-17 0) (3 -1.78865e-18 0) (3 -3.04617e-17 0) (3 -3.59019e-17 0) (3 -8.09252e-17 0) (3 -1.71151e-16 0) (3 -1.62437e-16 0) (3 -2.11552e-16 0) (3 -1.84766e-16 0) (3 -1.57881e-16 0) (3 -1.56352e-16 0) (3 -1.22032e-16 0) (3 -8.7586e-17 0) (3 -8.40907e-17 0) (3 -8.2414e-17 0) (3 -1.04583e-16 0) (3 -1.06615e-16 0) (3 -1.01287e-16 0) (3 -9.22499e-17 0) (3 -9.98149e-17 0) (3 -1.07408e-16 0) (3 -1.05753e-16 0) (3 -9.29389e-17 0) (3 3.72451e-17 0) (3 1.80977e-16 0) (3 -2.80387e-17 0) (3 -2.62187e-17 0) (3 -8.81859e-17 0) (3 6.01548e-17 0) (3 6.02686e-17 0) (3 2.45305e-17 0) (3 1.32338e-17 0) (3 1.3259e-17 0) (3 1.13865e-17 0) (3 -1.14083e-17 0) (3 -9.52509e-18 0) (3 -4.38994e-17 0) (3 -8.79675e-17 0) (3 5.93966e-17 0) (3 5.95111e-17 0) (3 -3.07748e-17 0) (3 2.10059e-16 0) (3 1.83434e-16 0) (3 1.85725e-16 0) (3 2.20978e-16 0) (3 2.50542e-16 0) (3 1.61516e-16 0) (3 1.97459e-16 0) (3 -3.37706e-17 0) (3 -5.41248e-17 0) (3 -3.38856e-17 0) (3 -1.18802e-16 0) (3 -1.19005e-16 0) (3 -1.2602e-16 0) (3 -1.12589e-16 0) (3 -8.71498e-17 0) (3 -1.64329e-16 0) (3 -5.31559e-17 0) (3 -2.93721e-16 0) (3 -2.63257e-16 0) (3 -2.77502e-16 0) (3 -2.60717e-16 0) (3 -1.78149e-16 0) (3 -2.30437e-16 0) (3 -1.44057e-16 0) (3 -1.89514e-16 0) (3 -1.77654e-16 0) (3 -1.41325e-16 0) (3 -1.03121e-16 0) (3 -1.03303e-16 0) (3 -9.2961e-17 0) (3 -8.08255e-17 0) (3 -7.92082e-17 0) (3 -1.23431e-16 0) (3 -1.11285e-16 0) (3 -1.45105e-16 0) (3 -1.18772e-16 0) (3 -7.81388e-17 0) (3 -1.03185e-16 0) (3 -3.56448e-17 0) (3 -1.14268e-16 0) (3 -1.34148e-16 0) (3 -2.07856e-16 0) (3 -1.72329e-16 0) (3 -1.67245e-16 0) (3 -1.47731e-16 0) (3 -1.66047e-16 0) (3 -9.76394e-17 0) (3 -1.97446e-16 0) (3 -1.56067e-16 0) (3 -5.81774e-17 0) (3 -7.83189e-17 0) (3 -8.02872e-17 0) (3 -5.66698e-17 0) (3 -1.282e-16 0) (3 -1.06418e-16 0) (3 -1.47055e-16 0) (3 -1.52852e-16 0) (3 -1.0701e-16 0) (3 -1.0536e-16 0) (3 2.3889e-16 0) (3 -5.19488e-17 0) (3 -1.48702e-17 0) (3 -1.4898e-17 0) (3 9.32873e-18 0) (3 7.477e-18 0) (3 5.6183e-17 0) (3 7.88044e-17 0) (3 7.51935e-17 0) (3 8.28694e-17 0) (3 8.30264e-17 0) (3 1.09652e-16 0) (3 9.66014e-17 0) (3 5.88304e-17 0) (3 1.42604e-16 0) (3 -1.29541e-16 0) (3 1.64146e-16 0) (3 1.31951e-16 0) (3 1.14961e-16 0) (3 1.88132e-16 0) (3 1.5195e-16 0) (3 1.349e-16 0) (3 1.69918e-16 0) (3 1.64444e-16 0) (3 1.31811e-16 0) (3 1.59259e-16 0) (3 3.69736e-17 0) (3 1.06469e-23 0) (3 -1.38459e-16 0) (3 -9.64098e-17 0) (3 -9.65738e-17 0) (3 -7.46753e-17 0) (3 -7.48028e-17 0) (3 -7.49308e-17 0) (3 -1.17706e-16 0) (3 -1.19617e-16 0) (3 -1.19823e-16 0) (3 -1.20029e-16 0) (3 -5.66829e-17 0) (3 -5.50603e-17 0) (3 -5.51556e-17 0) (3 -5.52513e-17 0) (3 -7.61025e-17 0) (3 5.19783e-18 0) (3 1.73563e-16 0) (3 1.02581e-16 0) (3 6.44431e-17 0) (3 1.04685e-17 0) (3 1.04869e-17 0) (3 2.27616e-17 0) (3 3.50796e-17 0) (3 4.5684e-17 0) (3 4.75249e-17 0) (3 5.11357e-17 0) (3 1.21884e-16 0) (3 1.09713e-16 0) (3 8.8636e-17 0) (3 6.92594e-17 0) (3 4.26973e-17 0) (3 2.85159e-17 0) (3 1.60689e-17 0) (3 -3.57729e-18 0) (3 -5.91315e-17 0) (3 -1.25657e-17 0) (3 -3.59668e-17 0) (3 1.08096e-17 0) (3 -3.42923e-17 0) (3 3.07383e-17 0) (3 -9.78171e-17 0) (3 2.54062e-17 0) (3 2.07257e-16 0) (3 -2.73205e-17 0) (3 -6.20401e-17 0) (3 -1.09684e-16 0) (3 -1.09885e-16 0) (3 -9.72443e-17 0) (3 -6.06601e-17 0) (3 -9.94456e-17 0) (3 -1.05165e-16 0) (3 -1.10905e-16 0) (3 -8.33338e-17 0) (3 1.11319e-17 0) (3 -1.85878e-18 0) (3 -8.19392e-17 0) (3 -2.94788e-16 0) (3 -1.06547e-16 0) (3 -1.79785e-16 0) (3 -3.56496e-17 0) (3 -3.00774e-17 0) (3 -5.2735e-17 0) (3 1.45296e-16 0) (3 -2.7602e-16 0) (3 1.98885e-16 0) (3 -2.4481e-16 0) (3 1.14083e-17 0) (3 -1.14301e-17 0) (3 -8.39815e-17 0) (3 -1.33864e-17 0) (3 -7.85568e-17 0) (3 -6.719e-17 0) (3 -3.26982e-17 0) (3 -1.349e-16 0) (3 -1.35162e-16 0) (3 -1.12209e-16 0) (3 -1.60887e-16 0) (3 -9.12827e-17 0) (3 -1.07029e-16 0) (3 -1.37399e-16 0) (3 -4.05247e-17 0) (3 9.64098e-17 0) (3 -4.74398e-17 0) (3 -6.44923e-17 0) (3 -5.44021e-17 0) (3 -5.44951e-17 0) (3 -7.67651e-17 0) (3 -7.68969e-17 0) (3 -7.70291e-17 0) (3 -7.71618e-17 0) (3 -9.96245e-17 0) (3 -9.97967e-17 0) (3 -9.99695e-17 0) (3 -1.00143e-16 0) (3 -1.62583e-16 0) (3 -2.09646e-16 0) (3 -1.99598e-16 0) (3 -1.4257e-16 0) (3 -1.25403e-16 0) (3 -1.20388e-16 0) (3 -1.08365e-16 0) (3 -4.72742e-17 0) (3 -5.43734e-17 0) (3 -9.95271e-31 0) (3 1.58416e-17 0) (3 7.0532e-17 0) (3 6.1825e-17 0) (3 4.60088e-17 0) (3 3.89998e-17 0) (3 3.37418e-17 0) (3 3.73602e-17 0) (3 -3.92093e-17 0) (3 -4.46359e-17 0) (3 -5.00821e-17 0) (3 -1.14679e-16 0) (3 -8.97548e-17 0) (3 -1.27682e-16 0) (3 -1.63945e-16 0) (3 -1.69657e-16 0) (3 -1.71773e-16 0) (3 -1.5216e-16 0) (3 -1.50623e-16 0) (3 -2.07257e-16 0) (3 -2.40421e-16 0) (3 -2.44511e-16 0) (3 -2.72381e-16 0) (3 -2.30759e-16 0) (3 -2.2568e-16 0) (3 -1.63599e-16 0) (3 -1.69426e-16 0) (3 -2.08485e-16 0) (3 -2.31053e-16 0) (3 -3.35187e-16 0) (3 -3.43233e-16 0) (3 -3.23427e-16 0) (3 -3.20308e-16 0) (3 -3.89941e-16 0) (3 -1.7384e-16 0) (3 -4.0639e-16 0) (3 -4.39053e-16 0) (3 -3.72208e-16 0) (3 -3.59728e-16 0) (3 -2.18888e-16 0) (3 -3.53532e-16 0) (3 -3.20111e-16 0) (3 -2.77072e-16 0) (3 -1.57815e-16 0) (3 -1.98122e-16 0) (3 -2.57671e-16 0) (3 -3.11711e-16 0) (3 -2.3567e-16 0) (3 -3.07154e-16 0) (3 -2.36581e-16 0) (3 -2.62092e-16 0) (3 -3.53352e-16 0) (3 -3.40496e-16 0) (3 -3.14021e-16 0) (3 -3.53478e-16 0) (3 -2.43248e-16 0) (3 -3.08992e-16 0) (3 5.57215e-17 0) (3 5.58162e-17 0) (3 5.59112e-17 0) (3 4.75207e-17 0) (3 3.23012e-17 0) (3 3.23565e-17 0) (3 3.24119e-17 0) (3 3.24676e-17 0) (3 3.25234e-17 0) (3 3.25794e-17 0) (3 -4.80946e-17 0) (3 -5.33396e-17 0) (3 -5.3432e-17 0) (3 -5.1798e-17 0) (3 -4.66992e-17 0) (3 -1.23015e-16 0) (3 -4.68621e-16 0) (3 -2.57322e-16 0) (3 -2.15971e-16 0) (3 -2.04137e-16 0) (3 -2.44695e-16 0) (3 -2.18862e-16 0) (3 -2.33279e-16 0) (3 -1.75708e-16 0) (3 -1.39054e-16 0) (3 -8.46384e-17 0) (3 -1.2365e-16 0) (3 -1.221e-16 0) (3 -1.22318e-16 0) (3 -1.2076e-16 0) (3 -1.03185e-16 0) (3 -1.01588e-16 0) (3 -1.07126e-16 0) (3 -1.21628e-16 0) (3 -1.21847e-16 0) (3 -1.50788e-16 0) (3 -2.01414e-16 0) (3 -3.31493e-16 0) (3 -2.95997e-16 0) (3 -3.09192e-16 0) (3 -2.86206e-16 0) (3 -3.41169e-16 0) (3 -4.29058e-16 0) (3 -3.07812e-16 0) (3 -4.34281e-16 0) (3 -3.34535e-16 0) (3 -3.16836e-16 0) (3 -3.92647e-16 0) (3 -2.61022e-16 0) (3 -2.63347e-16 0) (3 -2.6937e-16 0) (3 -1.14602e-16 0) (3 -3.38891e-16 0) (3 -4.4342e-16 0) (3 -4.83282e-16 0) (3 -4.67426e-16 0) (3 -4.49645e-16 0) (3 -3.77588e-16 0) (3 -3.20243e-16 0) (3 -4.87837e-16 0) (3 -4.6808e-16 0) (3 -5.19817e-16 0) (3 -1.37748e-16 0) (3 -6.80597e-16 0) (3 -5.85291e-16 0) (3 -3.85244e-16 0) (3 -2.73799e-16 0) (3 -2.72418e-16 0) (3 -3.07296e-16 0) (3 -5.04857e-16 0) (3 -4.27272e-16 0) (3 -4.31935e-16 0) (3 -3.40446e-16 0) (3 -2.77509e-16 0) (3 -2.49084e-16 0) (3 -2.6698e-16 0) (3 -2.22916e-16 0) (3 -3.76784e-16 0) (3 -3.63898e-16 0) (3 -4.11406e-16 0) ) ; boundaryField { inlet { type fixedValue; value uniform (3 0 0); } outlet { type zeroGradient; } bottom { type symmetryPlane; } top { type zeroGradient; } obstacle { type slip; } defaultFaces { type empty; } } // ************************************************************************* //
e7b242b4b9bcb9f8449af15d1b41691c2f7355da
f658b1b79782726539d06373e259111e9de88c3b
/第三次上机/T2.cpp
4a304030470085c57daee6d41e63ed6eb4eaee49
[]
no_license
Maydaytyh/OOP-Experiment
b67d3b80334cef4afea4a6ea69f0a24a1dd5f227
3fa59b6492541a3167806d3c72a84a4ba7693df9
refs/heads/master
2020-05-04T04:50:28.644446
2019-04-04T05:52:07
2019-04-04T05:52:07
178,975,105
2
0
null
null
null
null
UTF-8
C++
false
false
1,826
cpp
T2.cpp
/* * @Author: CucumicsMelon * @Date: 2019-03-25 10:24:26 * @Last Modified by: CucumicsMelon * @Last Modified time: 2019-03-25 11:40:37 */ /*思路: 用一个指针保存唯一的实例,无法在外部直接新建实例,只能使用外部接口(函数),函数中会判断是否已经存在实例。 */ #include <bits/stdc++.h> using namespace std; #define maxn 100000 #define rep(i, m, n) for (int i = m; i <= n; ++i) #define ll long long #define mem(a, b) memset(a, b, sizeof(a)) #ifndef ONLINE_JUDGE #define dbg(x) cout << #x << "=" << x << endl; #else #define dbg(x) #endif #define INF 0x3f3f3f3f class Single_ton { private: Single_ton()//设置为私有成员函数确保无法被外部直接调用,也就是能不能new一个对象得看我内部调用是否允许。 { puts("Yeah!You have done it sucessfully!\n");//每当调用构造函数时会提示创造对象成功 } public: static Single_ton *Object;//静态成员储存第一次构造出的对象 ~Single_ton() { } static Single_ton *Create_Object() { puts("WoW!You try to create an object!\n");//你正在试图创造对象! if (Object == NULL)//如果还没有创造过 { Object=new Single_ton();//此处调用构造函数 } else puts("Haha!You failed! There exactly existed an object!\n");//如果已经创造过了,不好意思,你失败了 return Object; } }; Single_ton* Single_ton::Object = NULL;//对静态变量初始化 int main() { //Single_ton SS; //Single_ton::Object = new Single_ton(); Single_ton S1 = *(Single_ton::Create_Object());//成功 Single_ton S2 = *(Single_ton::Create_Object());//失败 //查看运行结果可以知道,构造函数只被调用了一次,即如果试图多次调用构造,返回的都是一样的值。 }
c01d1ebeb6ae641b827e1a22cc15ac77b04d3a2d
eb4ba6bf51880eb8af06bcceddd96936cd5d409a
/libraries/entities/src/ZoneEntityItem.h
0744abf475ad41f2dba6063daeb485e3ccc68d12
[ "Apache-2.0" ]
permissive
adamrwoodbury/hifi
1526e8badca81d15bcf81b57361f2c69a36eba54
d7cc76e48bf6fec7ae4312176abf9397b6507561
refs/heads/master
2021-01-18T13:57:59.539942
2015-05-02T07:35:49
2015-05-02T07:35:49
null
0
0
null
null
null
null
UTF-8
C++
false
false
6,493
h
ZoneEntityItem.h
// // ZoneEntityItem.h // libraries/entities/src // // Created by Brad Hefta-Gaub on 12/4/13. // Copyright 2013 High Fidelity, Inc. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // #ifndef hifi_ZoneEntityItem_h #define hifi_ZoneEntityItem_h #include "EntityItem.h" class ZoneEntityItem : public EntityItem { public: static EntityItem* factory(const EntityItemID& entityID, const EntityItemProperties& properties); ZoneEntityItem(const EntityItemID& entityItemID, const EntityItemProperties& properties); ALLOW_INSTANTIATION // This class can be instantiated // methods for getting/setting all properties of an entity virtual EntityItemProperties getProperties() const; virtual bool setProperties(const EntityItemProperties& properties); // TODO: eventually only include properties changed since the params.lastViewFrustumSent time virtual EntityPropertyFlags getEntityProperties(EncodeBitstreamParams& params) const; virtual void appendSubclassData(OctreePacketData* packetData, EncodeBitstreamParams& params, EntityTreeElementExtraEncodeData* modelTreeElementExtraEncodeData, EntityPropertyFlags& requestedProperties, EntityPropertyFlags& propertyFlags, EntityPropertyFlags& propertiesDidntFit, int& propertyCount, OctreeElement::AppendState& appendState) const; virtual int readEntitySubclassDataFromBuffer(const unsigned char* data, int bytesLeftToRead, ReadBitstreamToTreeParams& args, EntityPropertyFlags& propertyFlags, bool overwriteLocalData); // NOTE: Apparently if you begin to return a shape type, then the physics system will prevent an avatar // from penetrating the walls of the entity. This fact will likely be important to Clement as he works // on better defining the shape/volume of a zone. //virtual ShapeType getShapeType() const { return SHAPE_TYPE_BOX; } xColor getKeyLightColor() const { xColor color = { _keyLightColor[RED_INDEX], _keyLightColor[GREEN_INDEX], _keyLightColor[BLUE_INDEX] }; return color; } void setKeyLightColor(const xColor& value) { _keyLightColor[RED_INDEX] = value.red; _keyLightColor[GREEN_INDEX] = value.green; _keyLightColor[BLUE_INDEX] = value.blue; } glm::vec3 getKeyLightColorVec3() const { const quint8 MAX_COLOR = 255; glm::vec3 color = { (float)_keyLightColor[RED_INDEX] / (float)MAX_COLOR, (float)_keyLightColor[GREEN_INDEX] / (float)MAX_COLOR, (float)_keyLightColor[BLUE_INDEX] / (float)MAX_COLOR }; return color; } float getKeyLightIntensity() const { return _keyLightIntensity; } void setKeyLightIntensity(float value) { _keyLightIntensity = value; } float getKeyLightAmbientIntensity() const { return _keyLightAmbientIntensity; } void setKeyLightAmbientIntensity(float value) { _keyLightAmbientIntensity = value; } const glm::vec3& getKeyLightDirection() const { return _keyLightDirection; } void setKeyLightDirection(const glm::vec3& value) { _keyLightDirection = value; } bool getStageSunModelEnabled() const { return _stageSunModelEnabled; } void setStageSunModelEnabled(bool value) { _stageSunModelEnabled = value; } float getStageLatitude() const { return _stageLatitude; } void setStageLatitude(float value) { _stageLatitude = value; } float getStageLongitude() const { return _stageLongitude; } void setStageLongitude(float value) { _stageLongitude = value; } float getStageAltitude() const { return _stageAltitude; } void setStageAltitude(float value) { _stageAltitude = value; } uint16_t getStageDay() const { return _stageDay; } void setStageDay(uint16_t value) { _stageDay = value; } float getStageHour() const { return _stageHour; } void setStageHour(float value) { _stageHour = value; } static bool getZonesArePickable() { return _zonesArePickable; } static void setZonesArePickable(bool value) { _zonesArePickable = value; } static bool getDrawZoneBoundaries() { return _drawZoneBoundaries; } static void setDrawZoneBoundaries(bool value) { _drawZoneBoundaries = value; } virtual bool isReadyToComputeShape() { return false; } void updateShapeType(ShapeType type) { _shapeType = type; } virtual ShapeType getShapeType() const; virtual bool hasCompoundShapeURL() const { return !_compoundShapeURL.isEmpty(); } const QString getCompoundShapeURL() const { return _compoundShapeURL; } virtual void setCompoundShapeURL(const QString& url); virtual bool supportsDetailedRayIntersection() const { return true; } virtual bool findDetailedRayIntersection(const glm::vec3& origin, const glm::vec3& direction, bool& keepSearching, OctreeElement*& element, float& distance, BoxFace& face, void** intersectedObject, bool precisionPicking) const; virtual void debugDump() const; static const xColor DEFAULT_KEYLIGHT_COLOR; static const float DEFAULT_KEYLIGHT_INTENSITY; static const float DEFAULT_KEYLIGHT_AMBIENT_INTENSITY; static const glm::vec3 DEFAULT_KEYLIGHT_DIRECTION; static const bool DEFAULT_STAGE_SUN_MODEL_ENABLED; static const float DEFAULT_STAGE_LATITUDE; static const float DEFAULT_STAGE_LONGITUDE; static const float DEFAULT_STAGE_ALTITUDE; static const quint16 DEFAULT_STAGE_DAY; static const float DEFAULT_STAGE_HOUR; static const ShapeType DEFAULT_SHAPE_TYPE; static const QString DEFAULT_COMPOUND_SHAPE_URL; protected: // properties of the "sun" in the zone rgbColor _keyLightColor; float _keyLightIntensity; float _keyLightAmbientIntensity; glm::vec3 _keyLightDirection; bool _stageSunModelEnabled; float _stageLatitude; float _stageLongitude; float _stageAltitude; uint16_t _stageDay; float _stageHour; ShapeType _shapeType = SHAPE_TYPE_NONE; QString _compoundShapeURL; static bool _drawZoneBoundaries; static bool _zonesArePickable; }; #endif // hifi_ZoneEntityItem_h
f2a11dcb7bf6b37f095eb41d0a95e6573197696e
6bac07ceda232029b6a9ea0144ad261311348699
/plugin_vc/game_vc/meta/meta.CTimer.h
ea9e0e924603c949a87408565c90edd621a562e0
[ "Zlib" ]
permissive
DK22Pac/plugin-sdk
ced6dc734846f33113e3596045b58febb7eb083c
b0ebc6e4f44c2d5f768b36c6a7a2a688e7e2b9d3
refs/heads/master
2023-08-17T06:36:25.363361
2023-08-10T05:19:16
2023-08-10T05:19:20
17,803,683
445
221
Zlib
2023-08-13T04:34:28
2014-03-16T16:40:08
C++
UTF-8
C++
false
false
18,760
h
meta.CTimer.h
/* Plugin-SDK (Grand Theft Auto Vice City) header file Authors: GTA Community. See more here https://github.com/DK22Pac/plugin-sdk Do not delete this comment block. Respect others' work! */ #include "PluginBase.h" namespace plugin { META_BEGIN(CTimer::EndUserPause) static int address; static int global_address; static const int id = 0x4D0D90; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0D90, 0x4D0DB0, 0x4D0C50>; // total references count: 10en (1), 11en (1), steam (1) using refs_t = RefList< 0x498FFA, GAME_10EN, H_CALL, 0x498E5F, 1, 0x49901B, GAME_11EN, H_CALL, 0x498E6F, 1, 0x498F1B, GAME_STEAM, H_CALL, 0x498D6F, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::StartUserPause) static int address; static int global_address; static const int id = 0x4D0DA0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0DA0, 0x4D0DC0, 0x4D0C60>; // total references count: 10en (1), 11en (1), steam (1) using refs_t = RefList< 0x4A3DF7, GAME_10EN, H_CALL, 0x4A3BCD, 1, 0x4A3E18, GAME_11EN, H_CALL, 0x4A3BEE, 1, 0x4A3CB6, GAME_STEAM, H_CALL, 0x4A3A8C, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Stop) static int address; static int global_address; static const int id = 0x4D0DB0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0DB0, 0x4D0DD0, 0x4D0C70>; // total references count: 10en (12), 11en (12), steam (12) using refs_t = RefList< 0x42BDA8, GAME_10EN, H_CALL, 0x42BB70, 1, 0x42C193, GAME_10EN, H_CALL, 0x42BB70, 2, 0x42C395, GAME_10EN, H_CALL, 0x42BB70, 3, 0x459093, GAME_10EN, H_CALL, 0x458EC0, 1, 0x45A9F8, GAME_10EN, H_CALL, 0x458EC0, 2, 0x4A3897, GAME_10EN, H_CALL, 0x4A3882, 1, 0x4A3A79, GAME_10EN, H_CALL, 0x4A3A13, 1, 0x4A4767, GAME_10EN, H_CALL, 0x4A4670, 1, 0x4A6698, GAME_10EN, H_CALL, 0x4A65D0, 1, 0x4BDD05, GAME_10EN, H_CALL, 0x4BCA90, 1, 0x600534, GAME_10EN, H_CALL, 0x5FFAB0, 1, 0x600582, GAME_10EN, H_CALL, 0x5FFAB0, 2, 0x42BDA8, GAME_11EN, H_CALL, 0x42BB70, 1, 0x42C193, GAME_11EN, H_CALL, 0x42BB70, 2, 0x42C395, GAME_11EN, H_CALL, 0x42BB70, 3, 0x459093, GAME_11EN, H_CALL, 0x458EC0, 1, 0x45A9F8, GAME_11EN, H_CALL, 0x458EC0, 2, 0x4A38B8, GAME_11EN, H_CALL, 0x4A38A3, 1, 0x4A3A9A, GAME_11EN, H_CALL, 0x4A3A34, 1, 0x4A4787, GAME_11EN, H_CALL, 0x4A4690, 1, 0x4A66B8, GAME_11EN, H_CALL, 0x4A65F0, 1, 0x4BDD25, GAME_11EN, H_CALL, 0x4BCAB0, 1, 0x600554, GAME_11EN, H_CALL, 0x5FFAD0, 1, 0x6005A2, GAME_11EN, H_CALL, 0x5FFAD0, 2, 0x42BD78, GAME_STEAM, H_CALL, 0x42BB40, 1, 0x42C163, GAME_STEAM, H_CALL, 0x42BB40, 2, 0x42C365, GAME_STEAM, H_CALL, 0x42BB40, 3, 0x458F73, GAME_STEAM, H_CALL, 0x458DA0, 1, 0x45A8D8, GAME_STEAM, H_CALL, 0x458DA0, 2, 0x4A3756, GAME_STEAM, H_CALL, 0x4A3741, 1, 0x4A3938, GAME_STEAM, H_CALL, 0x4A38D2, 1, 0x4A4623, GAME_STEAM, H_CALL, 0x4A44F0, 1, 0x4A6568, GAME_STEAM, H_CALL, 0x4A64A0, 1, 0x4BDBD5, GAME_STEAM, H_CALL, 0x4BC960, 1, 0x600194, GAME_STEAM, H_CALL, 0x5FF710, 1, 0x6001E2, GAME_STEAM, H_CALL, 0x5FF710, 2>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::GetIsSlowMotionActive) static int address; static int global_address; static const int id = 0x4D0DC0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0DC0, 0x4D0DE0, 0x4D0C80>; // total references count: 10en (5), 11en (5), steam (5) using refs_t = RefList< 0x5F724C, GAME_10EN, H_CALL, 0x5F7220, 1, 0x5F72A0, GAME_10EN, H_CALL, 0x5F7220, 2, 0x5F7340, GAME_10EN, H_CALL, 0x5F7220, 3, 0x5F749C, GAME_10EN, H_CALL, 0x5F7220, 4, 0x5FAB58, GAME_10EN, H_CALL, 0x5FA6F0, 1, 0x5F726C, GAME_11EN, H_CALL, 0x5F7240, 1, 0x5F72C0, GAME_11EN, H_CALL, 0x5F7240, 2, 0x5F7360, GAME_11EN, H_CALL, 0x5F7240, 3, 0x5F74BC, GAME_11EN, H_CALL, 0x5F7240, 4, 0x5FAB78, GAME_11EN, H_CALL, 0x5FA710, 1, 0x5F6EAC, GAME_STEAM, H_CALL, 0x5F6E80, 1, 0x5F6F00, GAME_STEAM, H_CALL, 0x5F6E80, 2, 0x5F6FA0, GAME_STEAM, H_CALL, 0x5F6E80, 3, 0x5F70FC, GAME_STEAM, H_CALL, 0x5F6E80, 4, 0x5FA7B8, GAME_STEAM, H_CALL, 0x5FA350, 1>; using def_t = bool(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::GetCurrentTimeInCycles) static int address; static int global_address; static const int id = 0x4D0DF0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0DF0, 0x4D0E10, 0x4D0CB0>; // total references count: 10en (15), 11en (15), steam (15) using refs_t = RefList< 0x40C205, GAME_10EN, H_CALL, 0x40C1E0, 1, 0x40C69A, GAME_10EN, H_CALL, 0x40C1E0, 2, 0x40C796, GAME_10EN, H_CALL, 0x40C770, 1, 0x40C8EC, GAME_10EN, H_CALL, 0x40C770, 2, 0x4A4491, GAME_10EN, H_CALL, 0x4A4410, 1, 0x4A44A8, GAME_10EN, H_CALL, 0x4A4410, 2, 0x4A455D, GAME_10EN, H_CALL, 0x4A4410, 3, 0x4A4577, GAME_10EN, H_CALL, 0x4A4410, 4, 0x600449, GAME_10EN, H_CALL, 0x5FFAB0, 1, 0x61E3AD, GAME_10EN, H_CALL, 0x61E340, 1, 0x61E419, GAME_10EN, H_CALL, 0x61E340, 2, 0x61E5B4, GAME_10EN, H_CALL, 0x61E4E0, 1, 0x61E626, GAME_10EN, H_CALL, 0x61E4E0, 2, 0x61E7BD, GAME_10EN, H_CALL, 0x61E710, 1, 0x61E829, GAME_10EN, H_CALL, 0x61E710, 2, 0x40C205, GAME_11EN, H_CALL, 0x40C1E0, 1, 0x40C69A, GAME_11EN, H_CALL, 0x40C1E0, 2, 0x40C796, GAME_11EN, H_CALL, 0x40C770, 1, 0x40C8EC, GAME_11EN, H_CALL, 0x40C770, 2, 0x4A44B1, GAME_11EN, H_CALL, 0x4A4430, 1, 0x4A44C8, GAME_11EN, H_CALL, 0x4A4430, 2, 0x4A457D, GAME_11EN, H_CALL, 0x4A4430, 3, 0x4A4597, GAME_11EN, H_CALL, 0x4A4430, 4, 0x600469, GAME_11EN, H_CALL, 0x5FFAD0, 1, 0x61E38D, GAME_11EN, H_CALL, 0x61E320, 1, 0x61E3F9, GAME_11EN, H_CALL, 0x61E320, 2, 0x61E594, GAME_11EN, H_CALL, 0x61E4C0, 1, 0x61E606, GAME_11EN, H_CALL, 0x61E4C0, 2, 0x61E79D, GAME_11EN, H_CALL, 0x61E6F0, 1, 0x61E809, GAME_11EN, H_CALL, 0x61E6F0, 2, 0x40C205, GAME_STEAM, H_CALL, 0x40C1E0, 1, 0x40C69A, GAME_STEAM, H_CALL, 0x40C1E0, 2, 0x40C796, GAME_STEAM, H_CALL, 0x40C770, 1, 0x40C8EC, GAME_STEAM, H_CALL, 0x40C770, 2, 0x4A4304, GAME_STEAM, H_CALL, 0x4A42D0, 1, 0x4A431B, GAME_STEAM, H_CALL, 0x4A42D0, 2, 0x4A43D0, GAME_STEAM, H_CALL, 0x4A42D0, 3, 0x4A43EA, GAME_STEAM, H_CALL, 0x4A42D0, 4, 0x6000A9, GAME_STEAM, H_CALL, 0x5FF710, 1, 0x61DFED, GAME_STEAM, H_CALL, 0x61DF80, 1, 0x61E059, GAME_STEAM, H_CALL, 0x61DF80, 2, 0x61E1F4, GAME_STEAM, H_CALL, 0x61E120, 1, 0x61E266, GAME_STEAM, H_CALL, 0x61E120, 2, 0x61E3FD, GAME_STEAM, H_CALL, 0x61E350, 1, 0x61E469, GAME_STEAM, H_CALL, 0x61E350, 2>; using def_t = unsigned int(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::GetCyclesPerMillisecond) static int address; static int global_address; static const int id = 0x4D0E30; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0E30, 0x4D0E50, 0x4D0CF0>; // total references count: 10en (15), 11en (15), steam (15) using refs_t = RefList< 0x40C1FE, GAME_10EN, H_CALL, 0x40C1E0, 1, 0x40C693, GAME_10EN, H_CALL, 0x40C1E0, 2, 0x40C78F, GAME_10EN, H_CALL, 0x40C770, 1, 0x40C8E5, GAME_10EN, H_CALL, 0x40C770, 2, 0x4A448A, GAME_10EN, H_CALL, 0x4A4410, 1, 0x4A44A1, GAME_10EN, H_CALL, 0x4A4410, 2, 0x4A4556, GAME_10EN, H_CALL, 0x4A4410, 3, 0x4A4570, GAME_10EN, H_CALL, 0x4A4410, 4, 0x60042C, GAME_10EN, H_CALL, 0x5FFAB0, 1, 0x61E390, GAME_10EN, H_CALL, 0x61E340, 1, 0x61E3FC, GAME_10EN, H_CALL, 0x61E340, 2, 0x61E597, GAME_10EN, H_CALL, 0x61E4E0, 1, 0x61E609, GAME_10EN, H_CALL, 0x61E4E0, 2, 0x61E7A0, GAME_10EN, H_CALL, 0x61E710, 1, 0x61E80C, GAME_10EN, H_CALL, 0x61E710, 2, 0x40C1FE, GAME_11EN, H_CALL, 0x40C1E0, 1, 0x40C693, GAME_11EN, H_CALL, 0x40C1E0, 2, 0x40C78F, GAME_11EN, H_CALL, 0x40C770, 1, 0x40C8E5, GAME_11EN, H_CALL, 0x40C770, 2, 0x4A44AA, GAME_11EN, H_CALL, 0x4A4430, 1, 0x4A44C1, GAME_11EN, H_CALL, 0x4A4430, 2, 0x4A4576, GAME_11EN, H_CALL, 0x4A4430, 3, 0x4A4590, GAME_11EN, H_CALL, 0x4A4430, 4, 0x60044C, GAME_11EN, H_CALL, 0x5FFAD0, 1, 0x61E370, GAME_11EN, H_CALL, 0x61E320, 1, 0x61E3DC, GAME_11EN, H_CALL, 0x61E320, 2, 0x61E577, GAME_11EN, H_CALL, 0x61E4C0, 1, 0x61E5E9, GAME_11EN, H_CALL, 0x61E4C0, 2, 0x61E780, GAME_11EN, H_CALL, 0x61E6F0, 1, 0x61E7EC, GAME_11EN, H_CALL, 0x61E6F0, 2, 0x40C1FE, GAME_STEAM, H_CALL, 0x40C1E0, 1, 0x40C693, GAME_STEAM, H_CALL, 0x40C1E0, 2, 0x40C78F, GAME_STEAM, H_CALL, 0x40C770, 1, 0x40C8E5, GAME_STEAM, H_CALL, 0x40C770, 2, 0x4A42FD, GAME_STEAM, H_CALL, 0x4A42D0, 1, 0x4A4314, GAME_STEAM, H_CALL, 0x4A42D0, 2, 0x4A43C9, GAME_STEAM, H_CALL, 0x4A42D0, 3, 0x4A43E3, GAME_STEAM, H_CALL, 0x4A42D0, 4, 0x60008C, GAME_STEAM, H_CALL, 0x5FF710, 1, 0x61DFD0, GAME_STEAM, H_CALL, 0x61DF80, 1, 0x61E03C, GAME_STEAM, H_CALL, 0x61DF80, 2, 0x61E1D7, GAME_STEAM, H_CALL, 0x61E120, 1, 0x61E249, GAME_STEAM, H_CALL, 0x61E120, 2, 0x61E3E0, GAME_STEAM, H_CALL, 0x61E350, 1, 0x61E44C, GAME_STEAM, H_CALL, 0x61E350, 2>; using def_t = int(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Resume) static int address; static int global_address; static const int id = 0x4D0E50; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0E50, 0x4D0E70, 0x4D0D10>; // total references count: 10en (7), 11en (7), steam (7) using refs_t = RefList< 0x406CE3, GAME_10EN, H_CALL, 0x4069D0, 1, 0x40704E, GAME_10EN, H_CALL, 0x406D30, 1, 0x40E242, GAME_10EN, H_CALL, 0x40DFB0, 1, 0x42B453, GAME_10EN, H_CALL, 0x42AE70, 1, 0x585498, GAME_10EN, H_CALL, 0x585150, 1, 0x608CC2, GAME_10EN, H_CALL, 0x6084C0, 1, 0x62A34E, GAME_10EN, H_CALL, 0x62A230, 1, 0x406CE3, GAME_11EN, H_CALL, 0x4069D0, 1, 0x40704E, GAME_11EN, H_CALL, 0x406D30, 1, 0x40E242, GAME_11EN, H_CALL, 0x40DFB0, 1, 0x42B453, GAME_11EN, H_CALL, 0x42AE70, 1, 0x5854B8, GAME_11EN, H_CALL, 0x585170, 1, 0x608CA2, GAME_11EN, H_CALL, 0x6084A0, 1, 0x62A39E, GAME_11EN, H_CALL, 0x62A280, 1, 0x406CE3, GAME_STEAM, H_CALL, 0x4069D0, 1, 0x40704E, GAME_STEAM, H_CALL, 0x406D30, 1, 0x40E242, GAME_STEAM, H_CALL, 0x40DFB0, 1, 0x42B423, GAME_STEAM, H_CALL, 0x42AE40, 1, 0x5852C8, GAME_STEAM, H_CALL, 0x584F80, 1, 0x6088E2, GAME_STEAM, H_CALL, 0x6080E0, 1, 0x62A00E, GAME_STEAM, H_CALL, 0x629EF0, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Suspend) static int address; static int global_address; static const int id = 0x4D0ED0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0ED0, 0x4D0EF0, 0x4D0D90>; // total references count: 10en (7), 11en (7), steam (7) using refs_t = RefList< 0x4069E8, GAME_10EN, H_CALL, 0x4069D0, 1, 0x406D45, GAME_10EN, H_CALL, 0x406D30, 1, 0x40DFE4, GAME_10EN, H_CALL, 0x40DFB0, 1, 0x42B357, GAME_10EN, H_CALL, 0x42AE70, 1, 0x58528C, GAME_10EN, H_CALL, 0x585150, 1, 0x608C60, GAME_10EN, H_CALL, 0x6084C0, 1, 0x62A341, GAME_10EN, H_CALL, 0x62A230, 1, 0x4069E8, GAME_11EN, H_CALL, 0x4069D0, 1, 0x406D45, GAME_11EN, H_CALL, 0x406D30, 1, 0x40DFE4, GAME_11EN, H_CALL, 0x40DFB0, 1, 0x42B357, GAME_11EN, H_CALL, 0x42AE70, 1, 0x5852AC, GAME_11EN, H_CALL, 0x585170, 1, 0x608C40, GAME_11EN, H_CALL, 0x6084A0, 1, 0x62A391, GAME_11EN, H_CALL, 0x62A280, 1, 0x4069E8, GAME_STEAM, H_CALL, 0x4069D0, 1, 0x406D45, GAME_STEAM, H_CALL, 0x406D30, 1, 0x40DFE4, GAME_STEAM, H_CALL, 0x40DFB0, 1, 0x42B327, GAME_STEAM, H_CALL, 0x42AE40, 1, 0x5850BC, GAME_STEAM, H_CALL, 0x584F80, 1, 0x608880, GAME_STEAM, H_CALL, 0x6080E0, 1, 0x62A001, GAME_STEAM, H_CALL, 0x629EF0, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Update) static int address; static int global_address; static const int id = 0x4D0F30; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D0F30, 0x4D0F50, 0x4D0DF0>; // total references count: 10en (14), 11en (14), steam (14) using refs_t = RefList< 0x406503, GAME_10EN, H_CALL, 0x4063B0, 1, 0x406508, GAME_10EN, H_CALL, 0x4063B0, 2, 0x42BE05, GAME_10EN, H_CALL, 0x42BB70, 1, 0x42C1F0, GAME_10EN, H_CALL, 0x42BB70, 2, 0x42C3F2, GAME_10EN, H_CALL, 0x42BB70, 3, 0x4590A0, GAME_10EN, H_CALL, 0x458EC0, 1, 0x45AA32, GAME_10EN, H_CALL, 0x458EC0, 2, 0x498FFF, GAME_10EN, H_CALL, 0x498E5F, 1, 0x4A38D2, GAME_10EN, H_CALL, 0x4A3882, 1, 0x4A3BBD, GAME_10EN, H_CALL, 0x4A3A13, 1, 0x4A478C, GAME_10EN, H_CALL, 0x4A4670, 1, 0x4A5C6A, GAME_10EN, H_CALL, 0x4A5C60, 1, 0x4A5D87, GAME_10EN, H_CALL, 0x4A5D80, 1, 0x4BDD31, GAME_10EN, H_CALL, 0x4BCA90, 1, 0x406503, GAME_11EN, H_CALL, 0x4063B0, 1, 0x406508, GAME_11EN, H_CALL, 0x4063B0, 2, 0x42BE05, GAME_11EN, H_CALL, 0x42BB70, 1, 0x42C1F0, GAME_11EN, H_CALL, 0x42BB70, 2, 0x42C3F2, GAME_11EN, H_CALL, 0x42BB70, 3, 0x4590A0, GAME_11EN, H_CALL, 0x458EC0, 1, 0x45AA32, GAME_11EN, H_CALL, 0x458EC0, 2, 0x499020, GAME_11EN, H_CALL, 0x498E6F, 1, 0x4A38F3, GAME_11EN, H_CALL, 0x4A38A3, 1, 0x4A3BDE, GAME_11EN, H_CALL, 0x4A3A34, 1, 0x4A47AC, GAME_11EN, H_CALL, 0x4A4690, 1, 0x4A5C8A, GAME_11EN, H_CALL, 0x4A5C80, 1, 0x4A5DA7, GAME_11EN, H_CALL, 0x4A5DA0, 1, 0x4BDD51, GAME_11EN, H_CALL, 0x4BCAB0, 1, 0x406503, GAME_STEAM, H_CALL, 0x4063B0, 1, 0x406508, GAME_STEAM, H_CALL, 0x4063B0, 2, 0x42BDD5, GAME_STEAM, H_CALL, 0x42BB40, 1, 0x42C1C0, GAME_STEAM, H_CALL, 0x42BB40, 2, 0x42C3C2, GAME_STEAM, H_CALL, 0x42BB40, 3, 0x458F80, GAME_STEAM, H_CALL, 0x458DA0, 1, 0x45A912, GAME_STEAM, H_CALL, 0x458DA0, 2, 0x498F20, GAME_STEAM, H_CALL, 0x498D6F, 1, 0x4A3791, GAME_STEAM, H_CALL, 0x4A3741, 1, 0x4A3A7C, GAME_STEAM, H_CALL, 0x4A38D2, 1, 0x4A4648, GAME_STEAM, H_CALL, 0x4A44F0, 1, 0x4A5B3A, GAME_STEAM, H_CALL, 0x4A5B30, 1, 0x4A5C57, GAME_STEAM, H_CALL, 0x4A5C50, 1, 0x4BDC01, GAME_STEAM, H_CALL, 0x4BC960, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Shutdown) static int address; static int global_address; static const int id = 0x4D12F0; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D12F0, 0x4D1310, 0x4D11B0>; // total references count: 10en (1), 11en (1), steam (1) using refs_t = RefList< 0x4A480D, GAME_10EN, H_CALL, 0x4A47B0, 1, 0x4A482D, GAME_11EN, H_CALL, 0x4A47D0, 1, 0x4A46CD, GAME_STEAM, H_CALL, 0x4A4670, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END META_BEGIN(CTimer::Initialise) static int address; static int global_address; static const int id = 0x4D1300; static const bool is_virtual = false; static const int vtable_index = -1; using mv_addresses_t = MvAddresses<0x4D1300, 0x4D1320, 0x4D11C0>; // total references count: 10en (4), 11en (4), steam (4) using refs_t = RefList< 0x4A4691, GAME_10EN, H_CALL, 0x4A4670, 1, 0x4A476C, GAME_10EN, H_CALL, 0x4A4670, 2, 0x4A4939, GAME_10EN, H_CALL, 0x4A4850, 1, 0x4A502A, GAME_10EN, H_CALL, 0x4A5020, 1, 0x4A46B1, GAME_11EN, H_CALL, 0x4A4690, 1, 0x4A478C, GAME_11EN, H_CALL, 0x4A4690, 2, 0x4A4959, GAME_11EN, H_CALL, 0x4A4870, 1, 0x4A504A, GAME_11EN, H_CALL, 0x4A5040, 1, 0x4A4511, GAME_STEAM, H_CALL, 0x4A44F0, 1, 0x4A4628, GAME_STEAM, H_CALL, 0x4A44F0, 2, 0x4A47F9, GAME_STEAM, H_CALL, 0x4A4710, 1, 0x4A4EFA, GAME_STEAM, H_CALL, 0x4A4EF0, 1>; using def_t = void(); static const int cb_priority = PRIORITY_BEFORE; using calling_convention_t = CallingConventions::Cdecl; using args_t = ArgPick<ArgTypes<>>; META_END }
d875e4c94a55de44cfc4b64029e2b81738d3eecc
be1c1f921c8245d0af8c32f329ac773a75e248cc
/include/lbann/layers/layer.hpp
a19a8185ca921542458d85fcaddc7d76878956e9
[ "Apache-2.0" ]
permissive
trb413/lbann
cac341013dccb16698bdd02429b0d4a14e2ccde8
c8aa1c948f09b1b52e71f64ad4b6a2f25a49a0db
refs/heads/develop
2020-03-17T08:22:42.848312
2018-05-14T22:44:32
2018-05-14T22:44:32
96,580,344
0
0
null
2017-07-07T22:13:39
2017-07-07T22:13:39
null
UTF-8
C++
false
false
21,565
hpp
layer.hpp
//////////////////////////////////////////////////////////////////////////////// // Copyright (c) 2014-2016, Lawrence Livermore National Security, LLC. // Produced at the Lawrence Livermore National Laboratory. // Written by the LBANN Research Team (B. Van Essen, et al.) listed in // the CONTRIBUTORS file. <lbann-dev@llnl.gov> // // LLNL-CODE-697807. // All rights reserved. // // This file is part of LBANN: Livermore Big Artificial Neural Network // Toolkit. For details, see http://software.llnl.gov/LBANN or // https://github.com/LLNL/LBANN. // // Licensed under the Apache License, Version 2.0 (the "Licensee"); you // may not use this file except in compliance with the License. You may // obtain a copy of the License at: // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or // implied. See the License for the specific language governing // permissions and limitations under the license. //////////////////////////////////////////////////////////////////////////////// #ifndef LBANN_LAYER_HPP_INCLUDED #define LBANN_LAYER_HPP_INCLUDED #include "lbann/base.hpp" #include "lbann/comm.hpp" #include "lbann/utils/summary.hpp" #include "lbann/optimizers/optimizer.hpp" #include "lbann/utils/exception.hpp" #include "lbann/utils/cudnn_wrapper.hpp" #include "lbann/utils/timer.hpp" #include "lbann/io/persist.hpp" #include <lbann.pb.h> #include <string> #include <vector> namespace lbann { // Forward declaration class model; /** Abstract base class for neural network layers. * A layer takes input tensors ("previous activations") and applies a * mathematical operation to obtain output tensors * ("activations"). This operation often has trainable parameters * called "weights." The previous activations are recieved from * "parent layers" and the activations are sent to "child layers," * making each layer a node in a directed graph. The layer graph and * the weights are managed by a neural network model class. A layer * should also be able to take objective function gradients * w.r.t. the activations ("previous error signals") and compute the * objective function gradients w.r.t. the previous activations * ("error signals") and w.r.t. the weights. This allows the model to * perform automatic differentiation and to apply first-order * optimization methods to the weights. */ class Layer { public: Layer(lbann_comm *comm); Layer(const Layer& other); Layer& operator=(const Layer& other); virtual ~Layer(); /** Copy function. * This function dynamically allocates memory for a layer instance * and instantiates a copy. The caller is responsible for * deallocating the instance. */ virtual Layer* copy() const = 0; /** Get the layer type's name. * A layer type name should be brief, human-readable description of * the layer's mathematical operation. */ virtual std::string get_type() const = 0; /** Get the layer instance's name. * Each layer in a model should have a unique, preferably * human-readable, name. */ inline std::string get_name() const { return m_name; } /** Set the layer instance's name. * Each layer in a model should have a unique, preferably * human-readable, name. */ inline void set_name(const std::string name) { m_name = name; } /** Get a human-readable description of the layer parameters. */ virtual std::string get_description() const; /** Get a human-readable description of the activation tensors. * Activation tensors are stored in distributed matrices where each * column corresponds to a mini-batch sample. Within each column, * the data is packed w.r.t. the last tensor dimension, then * w.r.t. the penultimate dimension, and so on. 3D tensors are * assumed to be 2D images in NCHW format. */ virtual std::string get_topo_description() const; /** Forward propagation step. * Apply a mathematical operation to the previous activations to * obtain the activations. */ virtual void forward_prop(); /** Backward propagation step. * Given the objective function gradients w.r.t. the activations * (the previous error signals), compute the gradients w.r.t. the * previous activations (the error signals) and w.r.t. the * weights. This is essentially an application of the chain * rule. Note that the objective function may have terms that are * independent of the activations, so we add to the gradients * rather than overwriting them. This means the error signals and * weight gradients must be cleared before performing backward * propagation (see the clear_error_signals function). */ virtual void back_prop(); /** Update step. * Update the layer's internal members. Note that the optimization * step for the weights happens elsewhere. */ virtual bool update(); /** Set the error signal tensors to zero. * The error signals are resized for the current mini-batch size. */ virtual void clear_error_signals(int mini_batch_size); virtual void summarize_stats(lbann_summary& summarizer, int step); virtual void summarize_matrices(lbann_summary& summarizer, int step); /** Setup layer members. * By default, this calls the setup_pointers, setup_dims, * setup_matrices, setup_data, and setup_gpu (if needed) * functions. Unless the setup_pointers function has been replaced * in an inherited class, it is assumed that pointers to * parent/child layers have already been initialized. * * If the layer has already been setup, this function should * destroy all layer members and reinitialize them. However, it is * not guaranteed that derived classes will obey this * behavior. Caveat emptor. */ virtual void setup(); /** Check that the setup is reasonable. */ virtual void check_setup(); /** Get data layout of the data tensors. * We assume that the data layouts of the previous activations, * activations, previous error signals, and error signals are the * same. Each concrete layer that is templated on its data layout * should override this function to return its template parameter. */ virtual data_layout get_data_layout() const = 0; /** Get the device allocation for the data tensors. * We assume that the decice allocation of the previous activations, * activations, previous error signals, and error signals are the * same. Each concrete layer that is templated on its device allocation * should override this function to return its template parameter. */ virtual El::Device get_device_allocation() const = 0; /** Get a human-readable description of the data_layout */ std::string get_data_layout_string(data_layout d) const; /** Get a human-readable description of the device allocation */ std::string get_device_allocation_string(El::Device dev) const; /** Get a short human-readable description of the device allocation */ std::string get_device_allocation_string_short(El::Device dev) const; /** Get the dimensions of a previous activations tensor. */ virtual std::vector<int> get_prev_neuron_dims(int parent_index = 0) const { return m_prev_neuron_dims; } /** Get the size of a previous activations tensor. */ virtual int get_num_prev_neurons(int parent_index = 0) const { return m_num_prev_neurons; } /** Get the number of dimensions of a previous activations tensor. */ virtual int get_num_prev_neuron_dims(int parent_index = 0) const { return m_num_prev_neuron_dims; } /** Get the dimensions of an activations tensor. */ virtual std::vector<int> get_neuron_dims(int child_index = 0) const { return m_neuron_dims; } /** Get the size of an activations tensor. */ virtual int get_num_neurons(int child_index = 0) const { return m_num_neurons; } /** Get the number of dimensions of an activations tensor. */ virtual int get_num_neuron_dims(int child_index = 0) const { return m_num_neuron_dims; } /** Reset layer stat counters. */ virtual void reset_counters(); /** Whether the layer is using a GPU implementation. */ inline bool using_gpus() const { return m_using_gpus; } /** To make sure copying between host and devices is complete */ void synchronize() const; /** Get expected number of parent layers. * A negative value indicates no limit. */ inline int get_expected_num_parent_layers() const { return m_expected_num_parent_layers; } /** Get expected number of child layers. * A negative value indicates no limit. */ inline int get_expected_num_child_layers() const { return m_expected_num_child_layers; } /** Return the model that manages this layer. */ inline model* get_model() const { return m_model; } /** Set the model that manages this layer. */ inline void set_model(model* m) { m_model = m; } virtual El::Matrix<El::Int>* get_sample_indices_per_mb() { return nullptr; }; virtual bool save_to_checkpoint_shared(persist& p) const; virtual bool load_from_checkpoint_shared(persist& p); virtual bool save_to_checkpoint_distributed(persist& p) const; virtual bool load_from_checkpoint_distributed(persist& p); /** Write layer to proto file */ virtual void write_proto(lbann_data::Layer* proto) const; /** Send forward propagation output to a child layer. * On output, fp_output is either a matrix view or copy of the * appropriate activation tensor. */ virtual void get_fp_output(AbsDistMat& fp_output, const Layer* child) const; /** Send backward propagation output to a parent layer. * On output, bp_output is either a matrix view or copy of the * appropriate error signal tensor. */ virtual void get_bp_output(AbsDistMat& bp_output, const Layer* parent) const; /** Get dimensions of forward propagation output to a child layer. * Returns the dimensions of the appropriate activations tensor. */ virtual std::vector<int> fp_output_dims(const Layer* child = nullptr) const { return m_neuron_dims; } /** Add to the layer's error signal. */ virtual void add_to_error_signal(const AbsDistMat& error_signals, DataType scale = DataType(1), int parent_index = 0) { El::Axpy(scale, error_signals, *m_error_signals[parent_index]); } /** Get parent layers. */ inline std::vector<const Layer*>& get_parent_layers() { return m_parent_layers; } /** Get parent layers. (const) */ inline const std::vector<const Layer*>& get_parent_layers() const { return m_parent_layers; } /** Get child layers. */ inline std::vector<const Layer*>& get_child_layers() { return m_child_layers; } /** Get child layers. (const) */ inline const std::vector<const Layer*>& get_child_layers() const { return m_child_layers; } /** Get number of parent layers. */ inline int get_num_parents() const { return get_parent_layers().size(); } /** Get number of child layers. */ inline int get_num_children() const { return get_child_layers().size(); } /** Get names in a particular list of layers */ static std::string get_layer_names(const std::vector<const Layer*>& list); std::string get_child_names() const { return get_layer_names(m_child_layers); } std::string get_parent_names() const { return get_layer_names(m_parent_layers); } /** Add a parent layer. * Does nothing if parent is a null pointer, the same layer, or * already a parent. */ void add_parent_layer(const Layer* parent); /** Add a child layer. * Does nothing if child is a null pointer, the same layer, or * already a child. */ void add_child_layer(const Layer* child); /** Remove all parent layers. * Parent layers are not deallocated. */ void clear_parent_layers() { get_parent_layers().clear(); } /** Remove all child layers. * Child layers are not deallocated. */ void clear_child_layers() { get_child_layers().clear(); } /** Get list of pointers to other layers. */ virtual std::vector<Layer*> get_layer_pointers(); /** Set list of pointers to other layers. */ virtual void set_layer_pointers(std::vector<Layer*> layers); /** Get references to weights. */ inline std::vector<weights*>& get_weights() { return m_weights; } /** Get references to weights. (const) */ inline const std::vector<weights*>& get_weights() const { return m_weights; } /** Set list of pointers to weights. */ inline void set_weights(std::vector<weights*> w) { get_weights() = w; } /** Replace weights with another Layer's weights*/ void replace_weights(Layer* other_layer); /** Get previous activation tensor. */ AbsDistMat& get_prev_activations(int parent_index = 0); /** Get activation tensor. */ AbsDistMat& get_activations(int child_index = 0); /** Get previous error signal tensor. */ AbsDistMat& get_prev_error_signals(int child_index = 0); /** Get error signal tensor. */ AbsDistMat& get_error_signals(int parent_index = 0); /** Get previous activation tensor. (const) */ const AbsDistMat& get_prev_activations(int parent_index = 0) const; /** Get activation tensor. (const) */ const AbsDistMat& get_activations(int child_index = 0) const; /** Get previous error signal tensor. (const) */ const AbsDistMat& get_prev_error_signals(int child_index = 0) const; /** Get error signal tensor. (const) */ const AbsDistMat& get_error_signals(int parent_index = 0) const; /** Get local portion of previous activation tensor. */ AbsMat& get_local_prev_activations(int parent_index = 0); /** Get local portion of activation tensor. */ AbsMat& get_local_activations(int child_index = 0); /** Get local portion of previous error signal tensor. */ AbsMat& get_local_prev_error_signals(int child_index = 0); /** Get local portion of error signal tensor. */ AbsMat& get_local_error_signals(int parent_index = 0); /** Get local portion of previous activation tensor. (const) */ const AbsMat& get_local_prev_activations(int parent_index = 0) const; /** Get local portion of activation tensor. (const) */ const AbsMat& get_local_activations(int child_index = 0) const; /** Get local portion of previous error signal tensor. (const) */ const AbsMat& get_local_prev_error_signals(int child_index = 0) const; /** Get local portion of error signal tensor. (const) */ const AbsMat& get_local_error_signals(int parent_index = 0) const; /** Get reference to LBANN communicator. */ lbann_comm* get_comm() const { return m_comm; } /** Get reference to cuDNN manager. */ cudnn::cudnn_manager* get_cudnn_manager() const { return m_cudnn; } void freeze(); void unfreeze(); bool is_frozen() const; protected: /** Reference to LBANN communicator. */ lbann_comm *m_comm; /** Dimensions of activation tensor. * If a derived class has more than one activation tensor, it is * responsible for its own interpretation. */ std::vector<int> m_neuron_dims; /** Size of activation tensor. */ int m_num_neurons; /** Number of dimensions of activation tensor. */ int m_num_neuron_dims; /** Dimensions of previous activation tensor. * If a derived class has more than one previous activation tensor, * it is responsible for its own interpretation. */ std::vector<int> m_prev_neuron_dims; /** Size of previous activation tensor. */ int m_num_prev_neurons; /** Number of dimensions of previous activation tensor. */ int m_num_prev_neuron_dims; /** Previous activation matrices. * Forward propagation inputs from each parent layer. These are * typically matrix views where each column is a flattened tensor * corresponding to a mini-batch sample. The matrices are owned by * the layer. */ std::vector<AbsDistMat*> m_prev_activations; /** Activation matrices. * Forward propagation outputs to each child layer. These are * typically matrices where each column is a flattened tensor * corresponding to a mini-batch sample. The matrices are owned by * the layer. */ std::vector<AbsDistMat*> m_activations; /** Error signal matrices. * Backward propagation inputs from each child layer. These are * typically matrix views where each column is a flattened tensor * corresponding to a mini-batch sample. The matrices are owned by * the layer. */ std::vector<AbsDistMat*> m_prev_error_signals; /** Error signal matrices. * Backward propagation outputs to each parent layer. These are * typically matrices where each column is a flattened tensor * corresponding to a mini-batch sample. The matrices are owned by * the layer. */ std::vector<AbsDistMat*> m_error_signals; /** References to layer weights. */ std::vector<weights*> m_weights; /** References to parent layers. */ std::vector<const Layer*> m_parent_layers; /** References to child layers. */ std::vector<const Layer*> m_child_layers; /** Expected number of parent layers. * A negative value indicates no limit. */ int m_expected_num_parent_layers = 1; /** Expected number of child layers. * A negative value indicates no limit. */ int m_expected_num_child_layers = 1; /** Reference to model managing this layer. */ model *m_model = nullptr; /** Setup data for forward propagation. * Base method gets previous activations from parent layers and * resizes activations for the current mini-batch size. */ virtual void fp_setup_data(int mini_batch_size); /** Setup data for forward propagation. * Base method gets previous error signals from child layers. The * error signals are resized for the current mini-batch size in the * clear_error_signals function. */ virtual void bp_setup_data(int mini_batch_size); #ifdef LBANN_HAS_CUDNN /** Pin host memory if needed for GPU memory transfers. */ virtual void pin_data(); #endif // LBANN_HAS_CUDNN /** Setup pointers to parent and child layers. * Called by the setup function. The base method checks that the * number of parents and children are valid. Pointers to the * parent/child layers are assumed to be already initialized. */ virtual void setup_pointers(); /** Setup tensor dimensions * Called by the setup function. The base method sets the * dimensions of the activation tensors equal to the dimensions of * the first previous activation tensor. */ virtual void setup_dims(); /** Instantiate distributed matrices. * If the layer has already been setup, this function should * destroy all matrices and reinstantiate them. However, it is not * guaranteed that derived classes will obey this behavior. */ virtual void setup_matrices(const El::Grid& grid); /** Setup layer data. * Called by the setup function. The base method sets the previous * activation, activation, previous error signal, and error signal * matrices to zero matrices with the proper dimensions. Matrix * buffers are pinned if needed for GPU transfers. */ virtual void setup_data(); /** Setup GPU objects. * Called by the setup function if GPUs are enabled. The base * method initializes GPU matrices for the previous activations, * activations, previous error signals, and error signals. It also * initializes cuDNN tensor descriptors. */ virtual void setup_gpu(); /** Perform the computation for the forward propagation step. */ virtual void fp_compute() = 0; /** Perform the computation for the backward propagation step. */ virtual void bp_compute() = 0; /** Perform the computation for the update step. * Returns false if the layer must reset for a new training epoch. */ virtual bool update_compute() { return true; } /** Reference to cuDNN manager. */ cudnn::cudnn_manager *m_cudnn; /** Avoid back prop if frozen */ bool m_frozen; #ifdef LBANN_HAS_CUDNN /** Number of mini-batch samples per GPU. */ int m_mini_batch_size_per_gpu; /** Maximum number of mini-batch samples per GPU. */ int m_max_mini_batch_size_per_gpu; /** cuDNN descriptor for first previous activation tensor. */ cudnnTensorDescriptor_t m_prev_activations_cudnn_desc; /** cuDNN descriptor for first activations tensor. */ cudnnTensorDescriptor_t m_activations_cudnn_desc; /** cuDNN descriptor for first previous error signal tensor. */ cudnnTensorDescriptor_t m_prev_error_signals_cudnn_desc; /** cuDNN descriptor for first error signal tensor. */ cudnnTensorDescriptor_t m_error_signals_cudnn_desc; #endif // LBANN_HAS_CUDNN /** Time spent in forward propagation. */ EvalType m_fp_time; /** Time spent in the forward propagation computation. */ EvalType m_fp_compute_time; /** Time spent in backward propagation. */ EvalType m_bp_time; /** Time spent in the backward propagation computation. */ EvalType m_bp_compute_time; /** Time spent in updates. */ EvalType m_update_time; /** Layer instance's name. * Each layer in a model should have a unique, preferably * human-readable, name. */ std::string m_name; private: /** Whether current layer is using a GPU implementation. */ bool m_using_gpus; /** Instantiate distributed matrices. */ template <data_layout T, El::Device Dev> void instantiate_matrices(const El::Grid& grid); /** Deallocate distributed matrices. */ void deallocate_matrices(); }; } // namespace lbann #endif // LBANN_LAYER_HPP_INCLUDED
a851a5a8fe7d68b9f58efe07dbdd67d788d69917
587aee470280d68ea04e6dc97ac5a852783100c8
/proj2/BASIC/running.h
aee5992f7db5766fd8484e0db901bd416f609b9f
[]
no_license
YuichanNoKareshi/sophomore-1st-semester
0137cd273f68347a31090b1fa21a71075083e7b5
7d49ae1fa548cdcb46d2aaca176d8afbfb4f7c77
refs/heads/master
2023-03-23T02:07:58.258033
2021-03-12T16:22:27
2021-03-12T16:22:27
347,116,499
0
1
null
null
null
null
UTF-8
C++
false
false
2,244
h
running.h
#ifndef RUNNING_H #define RUNNING_H #include <QMainWindow> #include <QObject> #include <QWidget> #include <QMap> #include <QEventLoop> #include <list> #include <iostream> #include "expression.h" using namespace std; struct numnode { numnode* left; numnode* right; int x; char s; numnode (int x=0,char s=' ',numnode* l=nullptr,numnode* r=nullptr) { this->x=x; this->s=s; left=l; right=r; } numnode():left(nullptr),right(nullptr) {} ~numnode () {} }; struct opnode { opnode* left; opnode* right; char s; opnode (char s,opnode* l=nullptr,opnode* r=nullptr) { this->s=s; left=l; right=r; } opnode():left(nullptr),right(nullptr) {} ~opnode () {} }; /*class Tree { private: NODE* root; public: Tree () {} Tree (NODE* root) {this->root=root;} };*/ class running : public QObject { Q_OBJECT private: struct node//map中的值 { statement s; QString movement; node(statement s=statement::REM,QString movement="") { this->s=s; this->movement=movement; } }; struct Node//list中的值 { QString key; int value; Node (QString key,int value) { this->key=key; this->value=value; } }; bool isInputing; QString Inputnum;//用户input的数 QEventLoop loop; QMap<int,node> mapp; list<Node> List; list<numnode> numlist;//数字列表 list<opnode> oplist;//操作符列表 public: running(); ~running (){} bool isExpressionValid(QString expression);//用来检验表达式格式对不对 bool isNodeExist(QString key0); int NodeValue(QString key0); bool pushop(char op); int mi(int a,int b);//乘方运算 bool let_func(QString movement); bool if_func(bool &isTrue,int &des,QString movement); bool value_of(int &num,QString movemont); public slots: void run(QMap<int,node> mapp); void getInput(QString word); void com(int c,QString movement); signals: void validfailed(); void writeToConsole(QString msg); void setExpisInputing(bool is); }; #endif // RUNNING_H
3d2c78f6e4db37c5f72f328d5b9808f0c879103d
c8fcc1acf73585045a5c7213cfb9f90e4c1e809e
/CodeForces/439C.cpp
5daf4cdeb8c4ba4a365c58d11ea878dba2d69075
[]
no_license
Jonariguez/ACM_Code
6db4396b20d0b0aeef30e4d47b51fb5e3ec48e03
465a11746d577197772f64aa11209eebd5bfcdd3
refs/heads/master
2020-03-24T07:09:53.482953
2018-11-19T09:21:33
2018-11-19T09:21:33
142,554,816
3
0
null
null
null
null
UTF-8
C++
false
false
3,698
cpp
439C.cpp
/**************** *PID:439c div2 *Auth:Jonariguez ***************** */ #define lson k*2,l,m #define rson k*2+1,m+1,r #define rep(i,s,e) for(i=(s);i<=(e);i++) #define For(j,s,e) For(j=(s);j<(e);j++) #define sc(x) scanf("%d",&x) #define In(x) scanf("%I64d",&x) #define pf(x) printf("%d",x) #define pfn(x) printf("%d\n",(x)) #define Pf(x) printf("%I64d",(x)) #define Pfn(x) printf("%I64d\n",(x)) #define Pc printf(" ") #define PY puts("YES") #define PN puts("NO") #include <stdio.h> #include <string.h> #include <string> #include <math.h> #include <set> #include <map> #include <stack> #include <queue> #include <vector> #include <iostream> #include <algorithm> using namespace std; typedef long long LL; typedef int Ll; Ll quick_pow(Ll a,Ll b,Ll MOD){a%=MOD;Ll res=1;while(b){if(b&1)res=(res*a)%MOD;b/=2;a=(a*a)%MOD;}return res;} const int maxn=100000+10; int a[maxn]; vector<int> odd,eve; int main() { int i,j,n,k,p; while(scanf("%d%d%d",&n,&k,&p)!=EOF){ odd.clear();eve.clear(); int ji=0,ou=0; for(i=1;i<=n;i++){ scanf("%d",&a[i]); if(a[i]&1){ ji++;odd.push_back(a[i]); }else { ou++;eve.push_back(a[i]); } } int q=k-p; if(ji<q || ji>=q && (ji-q)&1){ puts("NO");continue; } if(q+(ji-q)/2+ou<k){ puts("NO");continue; } PY; if(p==0){ for(i=0;i<k-1;i++) printf("1 %d\n",odd[i]); printf("%d",n-k+1); printf(" %d",odd[k-1]); for(i=0;i<eve.size();i++) printf(" %d",eve[i]); puts("");continue; }else if(q==0){ if(eve.size()>=k-1){ for(i=0;i<k-1;i++) printf("1 %d\n",eve[i]); printf("%d",n-k+1); for(;i<eve.size();i++) printf(" %d",eve[i]); for(i=0;i<odd.size();i++) printf(" %d",odd[i]); puts("");continue; }else { int cnt=0; for(i=0;i<eve.size();i++){ printf("1 %d\n",eve[i]); cnt++; } int temp=eve.size(); j=0; for(i=temp;i<=k-1;i++){ printf("2 "); // for(;j<odd.size();j+=2) printf("%d %d\n",odd[j],odd[j+1]); cnt+=2;j+=2; } if(n-cnt>0){ printf("%d",n-cnt); for(;j<odd.size();j++) printf(" %d",odd[j]); puts(""); } continue; } } int cnt=0; for(i=0;i<q;i++){ printf("1 %d\n",odd[i]); cnt++; } if(ou<p){ for(i=0;i<eve.size();i++){ printf("1 %d\n",eve[i]); cnt++; } int c=eve.size()+1; for(i=q;c<p && i<odd.size();i+=2){ printf("2 %d %d\n",odd[i],odd[i+1]); c++;cnt+=2; } printf("%d",n-cnt); for(;i<odd.size();i++) printf(" %d",odd[i]); puts(""); }else { for(i=0;i<p-1;i++){ printf("1 %d\n",eve[i]);cnt++; } printf("%d",n-cnt); for(;i<eve.size();i++) printf(" %d",eve[i]); for(i=q;i<odd.size();i++) printf(" %d",odd[i]); puts(""); } } return 0; } /* 8 4 4 1 1 1 1 1 1 1 1 */
d7a90ed184eb29fd2bc0ce19ff8f77381b5283f6
4d9464be3945a1ebc327ac6acba75fe51c532411
/tests/VlcStreamGrabberTestData.h
38f0ff7cee20aecabc7934478d19346d70a7daa3
[ "MIT" ]
permissive
qiqihuang/libvlc-stream-grabber
afa79df357d9c705917c73690f725b222eadbaaf
1671c00746fbe43992c825e354100ca15d4a148c
refs/heads/master
2021-03-14T20:08:48.592292
2018-02-06T13:54:30
2018-02-06T13:54:30
null
0
0
null
null
null
null
UTF-8
C++
false
false
346
h
VlcStreamGrabberTestData.h
#ifndef _VLC_STREAM_GRABBER_TEST_DATA_H_ #define _VLC_STREAM_GRABBER_TEST_DATA_H_ #include <string> using namespace std; namespace Data { const string SampleVideoPath = "../../data/SampleVideo_1280x720_1mb.mp4"; const string SampleAudioPath = "../../data/Vivaldi - Spring from Four Seasons.mp3"; } #endif // _VLC_STREAM_GRABBER_TEST_DATA_H_
7105c2236e63e063df5b9864a2d6b429eab7bbe9
9987fded6026ace187753eaa3e520d0bb72047a0
/isis/src/kaguya/objs/KaguyaMiCamera/KaguyaMiCamera.cpp
de4ba37cf95b97b9a773504f27d829088a58985a
[ "CC0-1.0", "LicenseRef-scancode-public-domain" ]
permissive
kberryUSGS/ISIS3
1345e6727746e2ebc348058ff3ec47c252928604
b6aba8c38db54d84b1eb5807a08d12190bf8634e
refs/heads/dev
2021-07-17T16:53:37.490510
2021-03-13T00:09:53
2021-03-13T00:09:53
118,936,778
0
1
Unlicense
2020-03-31T19:44:30
2018-01-25T16:17:20
C++
UTF-8
C++
false
false
3,931
cpp
KaguyaMiCamera.cpp
/** This is free and unencumbered software released into the public domain. The authors of ISIS do not claim copyright on the contents of this file. For more details about the LICENSE terms and the AUTHORS, you will find files of those names at the top level of this repository. **/ /* SPDX-License-Identifier: CC0-1.0 */ #include "KaguyaMiCamera.h" #include <iomanip> #include <QString> #include "CameraFocalPlaneMap.h" #include "IException.h" #include "IString.h" #include "iTime.h" #include "LineScanCameraDetectorMap.h" #include "LineScanCameraGroundMap.h" #include "LineScanCameraSkyMap.h" #include "KaguyaMiCameraDistortionMap.h" #include "NaifStatus.h" using namespace std; namespace Isis { /** * Constructor for the Kaguya MI Camera Model * * @param lab Pvl Label to create the camera model from * * @internal * @history 2012-06-14 Orrin Thomas - original version */ KaguyaMiCamera::KaguyaMiCamera(Cube &cube) : LineScanCamera(cube) { m_spacecraftNameLong = "Kaguya"; m_spacecraftNameShort = "Kaguya"; int ikCode = naifIkCode(); // https://darts.isas.jaxa.jp/pub/spice/SELENE/kernels/ik/SEL_MI_V01.TI // MI-VIS instrument kernel codes -131331 through -131335 if (ikCode <= -131331 && ikCode >= -131335) { m_instrumentNameLong = "Multi Band Imager Visible"; m_instrumentNameShort = "MI-VIS"; } // MI-NIR instrument kernel codes -131341 through -131344 else if (ikCode <= -131341 && ikCode >= -131344) { m_instrumentNameLong = "Multi Band Imager Infrared"; m_instrumentNameShort = "MI-NIR"; } else { QString msg = QString::number(ikCode); msg += " is not a supported instrument kernel code for Kaguya."; throw IException(IException::Programmer, msg, _FILEINFO_); } NaifStatus::CheckErrors(); // Set up the camera info from ik/iak kernels SetFocalLength(); //Kaguya IK kernal uses INS-131???_PIXEL_SIZE instead of PIXEL_PITCH QString ikernKey = "INS" + toString(naifIkCode()) + "_PIXEL_SIZE"; SetPixelPitch(getDouble(ikernKey)); // Get the start time from labels Pvl &lab = *cube.label(); PvlGroup &inst = lab.findGroup("Instrument", Pvl::Traverse); QString stime = (QString)inst["StartTime"]; SpiceDouble etStart=0; if(stime != "NULL") { etStart = iTime(stime).Et(); } else { //TODO throw an error if "StartTime" keyword is absent } NaifStatus::CheckErrors(); // Get other info from labels double lineRate = (double) inst["CorrectedSamplingInterval"] / 1000.0; setTime(etStart); // Setup detector map LineScanCameraDetectorMap *detectorMap = new LineScanCameraDetectorMap(this, etStart, lineRate); detectorMap->SetDetectorSampleSumming(1.0); detectorMap->SetStartingDetectorSample(1.0); // Setup focal plane map CameraFocalPlaneMap *focalMap = new CameraFocalPlaneMap(this, naifIkCode()); // Retrieve boresight location from instrument kernel (IK) (addendum?) ikernKey = "INS" + toString(naifIkCode()) + "_CENTER"; double sampleBoreSight = getDouble(ikernKey,0); double lineBoreSight = getDouble(ikernKey,1)-1.0; focalMap->SetDetectorOrigin(sampleBoreSight, lineBoreSight); focalMap->SetDetectorOffset(0.0, 0.0); KaguyaMiCameraDistortionMap *distMap = new KaguyaMiCameraDistortionMap(this); distMap->SetDistortion(naifIkCode()); // Setup the ground and sky map new LineScanCameraGroundMap(this); new LineScanCameraSkyMap(this); LoadCache(); NaifStatus::CheckErrors(); } } /** * This is the function that is called in order to instantiate a * KaguyaMi object. * * @param lab Cube labels * * @return Isis::Camera* KaguyaMiCamera * @internal * @history 2012-06-14 Orrin Thomas - original version */ extern "C" Isis::Camera *KaguyaMiCameraPlugin(Isis::Cube &cube) { return new Isis::KaguyaMiCamera(cube); }
671617b96a2648ca24844cf9a954901a4d08c4f2
b88af9122415060c3a6bd71e6cfad098373127df
/test/tiles/tile_node_test.cpp
db403174016067b8a49ee8163f240057fe0d7a5e
[ "MIT" ]
permissive
shunjilin/SlidingTilesPuzzle
014d95a42d197e8ee046f81971493c586abca4d4
cff6e75b58ee41c379f97b20c89d50d8d4d8c416
refs/heads/master
2020-03-20T14:16:17.963410
2019-06-23T14:19:14
2019-06-23T14:19:14
137,481,039
5
1
MIT
2018-11-21T00:38:57
2018-06-15T11:43:30
C++
UTF-8
C++
false
false
6,328
cpp
tile_node_test.cpp
#include "tile_node.hpp" #include <string> #include <sstream> #include <gmock/gmock.h> #include <gtest/gtest.h> using namespace Tiles; class FifteenPuzzleNode: public testing::Test { public: static int const WIDTH = 4; static int const HEIGHT = 4; static int const N_TILES = WIDTH*HEIGHT; std::array<uint8_t, N_TILES> initial_board = std::array<uint8_t, N_TILES> ({{1, 2, 3, 7, 4, 5, 6, 0, 8, 9, 10, 11, 12, 13, 14, 15}}); // initial board /* 1 2 3 7 4 5 6 0 8 9 10 11 12 13 14 15 */ // goal board /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 */ TileNode<WIDTH, HEIGHT> node = TileNode<WIDTH, HEIGHT>(initial_board); }; TEST_F(FifteenPuzzleNode, InitializeTileNode) { ASSERT_THAT(node.board, testing::ElementsAre(1, 2, 3, 7, 4, 5, 6, 0, 8, 9, 10, 11, 12, 13, 14, 15)); } TEST_F(FifteenPuzzleNode, InitializeGoalNode) { std::array<uint8_t, N_TILES> goal_board( {{1, 2, 3, 7, 4, 5, 6, 0, 8, 9, 10, 11, 12, 13, 14, 15}} ); TileNode<WIDTH, HEIGHT>::setGoalBoard(goal_board); ASSERT_THAT((TileNode<WIDTH, HEIGHT>::goal_node.board), testing::ElementsAreArray(goal_board)); } TEST_F(FifteenPuzzleNode, GetCost) { ASSERT_EQ(getG(node), 0); } TEST_F(FifteenPuzzleNode, GetChildNodes) { auto child_nodes = getChildNodes(node); EXPECT_THAT(child_nodes[UP]->board, testing::ElementsAre(1, 2, 3, 0, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)); EXPECT_THAT(child_nodes[DOWN]->board, testing::ElementsAre(1, 2, 3, 7, 4, 5, 6, 11, 8, 9, 10, 0, 12, 13, 14, 15)); EXPECT_THAT(child_nodes[LEFT]->board, testing::ElementsAre(1, 2, 3, 7, 4, 5, 0, 6, 8, 9, 10, 11, 12, 13, 14, 15)); EXPECT_FALSE(child_nodes[RIGHT].has_value()); } TEST_F(FifteenPuzzleNode, ChildNodesIncreaseCost) { auto child_nodes = getChildNodes(node); ASSERT_EQ(getG(*child_nodes[DOWN]), getG(node) + 1); } TEST_F(FifteenPuzzleNode, CachePreviousMove) { auto child_nodes = getChildNodes(node); ASSERT_EQ(child_nodes[DOWN]->prev_move, DOWN); } TEST_F(FifteenPuzzleNode, DoNotRegenerateParentNode) { auto child_nodes = getChildNodes(node); auto grandchild_nodes = getChildNodes(*child_nodes[DOWN]); ASSERT_FALSE(grandchild_nodes[UP].has_value()); } TEST_F(FifteenPuzzleNode, GetParentNode) { auto child_node = getChildNodes(node)[DOWN]; ASSERT_EQ(getParent(*child_node), node); } TEST_F(FifteenPuzzleNode, Node20Bytes) { ASSERT_EQ(sizeof(node), 20); } class TwentyFourPuzzleNode: public testing::Test { public: static int const WIDTH = 5; static int const HEIGHT = 5; static int const N_TILES = WIDTH*HEIGHT; std::array<uint8_t, N_TILES> initial_board = std::array<uint8_t, N_TILES> ({{1, 2, 3, 4, 0, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24}}); // initial board /* 1 2 3 4 0 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 */ // goal board /* 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 */ TileNode<WIDTH, HEIGHT> node = TileNode<WIDTH, HEIGHT>(initial_board); }; TEST_F(TwentyFourPuzzleNode, InitializeTileNode) { ASSERT_THAT(node.board, testing::ElementsAre(1, 2, 3, 4, 0, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24)); } TEST_F(TwentyFourPuzzleNode, InitializeGoalNode) { std::array<uint8_t, N_TILES> goal_board( {{1, 2, 3, 4, 0, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24}} ); TileNode<WIDTH, HEIGHT>::setGoalBoard(goal_board); ASSERT_THAT((TileNode<WIDTH, HEIGHT>::goal_node.board), testing::ElementsAreArray(goal_board)); } TEST_F(TwentyFourPuzzleNode, GetCost) { ASSERT_EQ(getG(node), 0); } TEST_F(TwentyFourPuzzleNode, GetChildNodes) { auto child_nodes = getChildNodes(node); EXPECT_FALSE(child_nodes[UP].has_value()); EXPECT_THAT(child_nodes[DOWN]->board, testing::ElementsAre(1, 2, 3, 4, 9, 5, 6, 7, 8, 0, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24)); EXPECT_THAT(child_nodes[LEFT]->board, testing::ElementsAre(1, 2, 3, 0, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24)); EXPECT_FALSE(child_nodes[RIGHT].has_value()); } TEST_F(TwentyFourPuzzleNode, ChildNodesIncreaseCost) { auto child_nodes = getChildNodes(node); ASSERT_EQ(getG(*child_nodes[DOWN]), getG(node) + 1); } TEST_F(TwentyFourPuzzleNode, CachePreviousMove) { auto child_nodes = getChildNodes(node); ASSERT_EQ(child_nodes[DOWN]->prev_move, DOWN); } TEST_F(TwentyFourPuzzleNode, DoNotRegenerateParentNode) { auto child_nodes = getChildNodes(node); auto grandchild_nodes = getChildNodes(*child_nodes[DOWN]); ASSERT_FALSE(grandchild_nodes[UP].has_value()); } TEST_F(TwentyFourPuzzleNode, GetParentNode) { auto child_node = getChildNodes(node)[DOWN]; ASSERT_EQ(getParent(*child_node), node); } TEST_F(TwentyFourPuzzleNode, Node29Bytes) { ASSERT_EQ(sizeof(node), 29); } int main(int argc, char *argv[]) { testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); }
1c15239e36749caae0fa961732983269fb7f3339
d0a039c4df11b50e2781fcc0fc9b4bc301d8e67a
/Codeforces/977A Wrong Subtraction.cpp
ac6825e67c1022280269db2b8f902b15a6fc4995
[]
no_license
Somrat-Hossen/Problem-Solution
0574165710d329864567efdb5be2a823ce41152b
d20db61222d0eed5bc2b054de331d65f0391f400
refs/heads/master
2021-05-12T17:43:48.145286
2020-01-01T13:14:01
2020-01-01T13:14:01
117,053,427
0
1
null
null
null
null
UTF-8
C++
false
false
291
cpp
977A Wrong Subtraction.cpp
#include<bits/stdc++.h> using namespace std; int main() { int n,i,m; cin>>n>>m; while(m--) { if(n%10==0) { n/=10; } else { n--; } } cout<<n<<endl; return 0; }
f73f7455795ac7fa9e0e52970daa8cb4ffa1c41b
24c2bc00cb802a8d3bfa2cd759165a3a441e71a8
/src/GRworkbench/atlas.hpp
bdbc70f8697816b0eac7a8f819b6aa6767a2f29c
[]
no_license
grmath/grworkbench
0b6ba5afa62ba673cffd661974352f712a3c8681
bc1bbb83378ba2fb61f3b58a5c371a4276756fa1
refs/heads/master
2023-06-23T06:34:47.684603
2013-04-29T03:06:04
2013-04-29T03:06:04
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,034
hpp
atlas.hpp
#pragma once #include <map> #include <set> #include <boost/function.hpp> #include <boost/optional.hpp> #include <memory> #include <lift/differential.hpp> #include "nvector.hpp" namespace grwb { using std::map; using std::pair; using std::set; using boost::function; using boost::optional; using std::shared_ptr; using lift::differential; typedef function<optional<nvector<nvector<differential<double, nvector<double> > > > >(const nvector<differential<double, nvector<double> > >&)> chart; typedef function<optional<nvector<differential<double, nvector<double> > > >(const nvector<differential<double, nvector<double> > >&)> inter_chart_map; inline map<pair<std::shared_ptr<chart>, std::shared_ptr<chart> >, std::shared_ptr<inter_chart_map> >& inter_chart_maps() { static map<pair<std::shared_ptr<chart>, std::shared_ptr<chart> >, std::shared_ptr<inter_chart_map> > _; return _; }; inline set<std::shared_ptr<chart> >& charts() { static set<std::shared_ptr<chart> > _; return _; } }
c50629eb0f4126557aea80fed778b036c3d0de86
8af09dbc2c8b5e774e821eafb4d78f9264dbd655
/setInital.cpp
1016cdc1868be9c4f8129b27c862d3d7a660e026
[]
no_license
kalasxel/jetCylMHD
db1367caa5691e31e6c074dd567de38dd77955d4
076ee642d9aa48e17d8dc0056c252be6fff786c1
refs/heads/master
2020-04-06T07:03:25.945421
2016-08-10T12:30:22
2016-08-10T12:30:22
64,547,633
0
0
null
null
null
null
UTF-8
C++
false
false
2,796
cpp
setInital.cpp
#include <iostream> #include <cmath> #include "Param.h" #include "CFullVec.h" #include "CHlld.h" double setGridR(double gR[NR+2]) {{ for(int n=0; n<NR+2; n++) { gR[n] = (n-1)*DR; } }} double setGridZ(double gZ[NZ+2]) {{ for(int m=0; m<NZ+2; m++) { gZ[m] = (m-1)*DZ; } }} int NfromR(double R) {{ return static_cast<int>((R-RI)/DR)+1; }} int NfromZ(double Z) {{ return static_cast<int>((Z-ZI)/DZ)+1; }} double differ(10); double nn_in(2e17), Vx_in(0), Vy_in(0), Vz_in(5e6), Bx_in(0), By_in(15e2), Bz_in(0), T_in(5); double nn_out(7e16), Vx_out(0), Vy_out(0), Vz_out(0), Bx_out(0), By_out(0), Bz_out(0), T_out(1); double thick=0.3*(RF-RI); int njm(0), njp(njm + NfromR(thick)); int mjm(0), mjp( NfromZ((RF-RI)/7e-1) ); void setInital(FullVec **A) {{ int n(3); int m(3); for( m=mjm; m<mjp; m++) { for( n=0; n<njm; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } for( n; n<njp; n++) { double Bp, gR[NR+2]; setGridR(gR); Bp = (By_in/thick)*gR[n]; A[n][m].setVecT(nn_in, Vx_in,Vy_in,Vz_in, Bx_in,Bp,Bz_in, T_in); } for( n; n<NR+1; n++) { double Bp, gR[NR+2]; setGridR(gR); Bp = (By_in*thick)/gR[n]; A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,Bp,Bz_out, T_out); } } for( m; m<NZ+1; m++) { for( n=0; n<njm; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } for( n; n<njp; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } for( n; n<NR+1; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } } for(int m=0; m<mjm; m++) { for( n=0; n<njm; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } for( n; n<njp; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } for( n; n<NR+1; n++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); } } /* double gR[NR+2]; setGridR(gR); double gZ[NZ+2]; setGridZ(gZ); for(int n=0 ; n<NR+2; n++) { for(int m=0; m<NZ+2; m++) { A[n][m].setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); //A[n][m].B = gR[n]*gZ[m]; //A[n][m].D = -gZ[m]*gZ[m]; //A[n][m].B = gR[n]*gR[n]*gZ[m]; //A[n][m].D = -gZ[m]*gZ[m]*gR[n]; int alpha = 0; A[n][m].B = pow(gR[n],alpha+1)*pow(gZ[m],alpha+1); A[n][m].D = -pow(gR[n],alpha)*pow(gZ[m],alpha+2); } } */ }} void setBound(FullVec **U) {{ FullVec R1, R2, Z1, Z2; R1.setVecT(nn_out, Vx_out,Vy_out,Vy_out, Bx_out,By_out,Bz_out, T_out); R2=R1; Z2=R1; Z1=R1; for(int n=0; n<NR+2; n++) { U[n][0] = Z1; U[n][NZ+1] = Z2; } for(int m=0; m<NZ+2; m++) { U[0][m] = R1; U[NR+1][m] = R2; } }}
2473feb7f1ee322d0b3245245d375a061516420a
f2efb1161e629d2c769c7adc296c595d2e04f51a
/Algorithms/Two Pointers/container-with-most-water.cpp
0653df0cf6295acd1394b849bd83a7da08088840
[]
no_license
singhashish-26/Leetcode
8ee7a2319a6720e70e0b448acaaad86f0bfb7115
401b80de47796d25f5f69cb1d69c4783680e11ba
refs/heads/master
2021-05-26T16:21:27.607763
2020-08-13T12:12:03
2020-08-13T12:12:03
254,135,088
0
0
null
null
null
null
UTF-8
C++
false
false
730
cpp
container-with-most-water.cpp
#https://leetcode.com/problems/container-with-most-water/ class Solution { public: int maxArea(vector<int>& height) { int i=0, j=height.size()-1; int mx=-1,cap; while(i<j) { cap= min(height[i],height[j])*(j-i); mx= max(mx,cap); if(height[i]<height[j]) { i++; continue; } if(height[i]>height[j]) { j--; continue; } if(height[i]==height[j]) { if(height[i+1]>=height[j-1]) i++; else j--; } } return mx; } };
7772c9423b97eb7a20f33c41455824b584f42000
15c30fa139c24b698e3395ec4ad161a280f08d04
/WS_Atmega328p/WS_Atmega328p.ino
91f3af107006433acf37a87f1520d744ee9f4811
[]
no_license
plasticChair/Arduino
11e247e7f987f5a9bdabb24b8e3d9cee8a216ad6
703b8e82caa60ab0ffa8994386729313a2c1c52a
refs/heads/master
2020-03-27T08:29:28.851366
2019-04-28T08:13:57
2019-04-28T08:13:57
146,260,028
0
2
null
null
null
null
UTF-8
C++
false
false
9,861
ino
WS_Atmega328p.ino
// Visual Micro is in vMicro>General>Tutorial Mode // /* Name: WS_Attiny.ino Created: 1/27/2019 8:13:08 PM Author: Scott */ #include "WS_Atmega328p.h" //#include "Adafruit_FRAM_I2C.h" extern void RTC_SetAlarm_AneInterval(); extern void RTC_SetAlarm_MeasInterval(); int BuffFull = 0; volatile bool led2Cntrl = 0; bool toggle = 0; // The setup() function runs once each time the micro-controller starts void setup() { //setup_timer2(); Serial.begin(115200); Serial.println("------Starting-------"); setup_BME280(); setup_battMang(); setup_fram(); init_vars(); init_GPIO(); setup_pwrSave(); fram.write8(FRAM_MEM_POINTER_Addr,0); fram.write8(FRAM_NUM_P0INTS_Addr, 0); Wire.begin(); //setup_RTC(); //Set Time RTC.set(10, 1, 1, 1, 1, 1,19); RTC_SetAlarm_MeasInterval(); //RTC_SetAlarm_AneInterval(); //byte set(byte seconds_in, byte minutes_in, byte hour_in, byte wday_in, byte day_in, byte month_in, byte year_in); setup_watchpuppy(); GPIO_dance(); Serial.println("Done with Setup"); //sleep(); //delay(5); } // Add the main program code into the continuous loop() function void loop() { float tempSpeed = 0.0; int tempDir = 0; int Ane_ErrorStatus = 0; // Serial.println("IN LOOP"); //MstrCntrl.serviceRTCISR = 1; /*--------------------------------------*/ /* ------------ Store Data ------------*/ //MstrISR.serviceRTCISR = 0; if (MstrISR.serviceRTCISR) { disable_timer2(); //disable INT PulseISR detachInterrupt(digitalPinToInterrupt(IOCntrl.ANE_Pulse)); // Reset RTC Alarm Serial.println("---woke---"); printDateTime(); //RTC_SetAlarm_MeasInterval(); //Check if 15 mins elapsed breakTime(RTC.get(), MstrCntrl.time); if ((MstrCntrl.time.Minute - MstrCntrl.prevtime.Minute) >= MstrCntrl.Server_Int) { MstrCntrl.prevtime = MstrCntrl.time; MstrCntrl.Server_Tx_En = 1; } //Interval Elapsed, Start collecting data MstrCntrl.ANE_enable = 1; digitalWrite(IOCntrl.ANE_En, !MstrCntrl.ANE_enable); RTC_SetAlarm_AneInterval(); MstrISR.pulseSkip = 1; //delay(2000); //Go to Sleep sleep(); //wake up printDateTime(); RTC_SetAlarm_MeasInterval(); //Serial.println("3"); enable_timer2(); delay(10); /*---------------------------------------------------------------------------------------*/ // Read wind data Ane_ErrorStatus = anemometer.read(sampledData.speed, sampledData.dir); //Serial.println(Ane_ErrorStatus); //error detect if (Ane_ErrorStatus < 4) { delay(100); anemometer.read(tempSpeed, tempDir); } // MstrCntrl.ANE_enable = 0; digitalWrite(IOCntrl.ANE_En, !MstrCntrl.ANE_enable); Serial.print("Wind info:" + String(sampledData.speed) + ", " + String(sampledData.dir) + ", " + String(sampledData.gustMax)); //Serial.println(String(MstrData.gustBuff[7]) + ", " + String(MstrData.gustBuff[6]) + ", " + String(MstrData.gustBuff[5]) + ", " + String(MstrData.gustBuff[4]) + ", " + String(MstrData.gustBuff[3]) + ", " + String(MstrData.gustBuff[2]) + ", " + String(MstrData.gustBuff[1]) + ", " + String(MstrData.gustBuff[0]) ); /*---------------------------------------------------------------------------------------*/ //Get data Serial.print("Got temps: "); BME_Force(); sampledData.temp = BME.readTempC(); sampledData.press = BME.readFloatPressure()/100.0; sampledData.humid = BME.readFloatHumidity(); Serial.println(sampledData.temp); /*-----------------*/ //Check battery level sampledData.batteryV = pwr_mgmt.voltage(); sampledData.batteryP = pwr_mgmt.accuratePercent(); Serial.println(sampledData.batteryV); Serial.println(sampledData.batteryP); /*-----------------*/ //Store Time MstrData.weather.year = (byte)(MstrCntrl.time.Year - 49); MstrData.weather.month = (byte)(MstrCntrl.time.Month); MstrData.weather.day = (uint8_t)(MstrCntrl.time.Day); MstrData.weather.hour = (uint8_t)(MstrCntrl.time.Hour); MstrData.weather.minute = (uint8_t)(MstrCntrl.time.Minute); MstrData.weather.second = (uint8_t)(MstrCntrl.time.Second+2); //Account for 2 second delay for Anemometer /*---------------------------------------------------------------------------------------*/ //Low Power Mode LP_mode_check(); /*---------------------------------------------------------------------------------------*/ MstrData.weather.speed = (unsigned int)floatLimit(&sampledData.speed , wxSF.windSF , 0 , 114 , 0); MstrData.weather.dir = 0xff & tempDir; MstrData.weather.gustMax = (unsigned int)floatLimit(&sampledData.gustMax , wxSF.gustSF , 0 , 2047, 0); MstrData.weather.temp = (unsigned int)floatLimit(&sampledData.temp , wxSF.tempSF , wxSF.tempOff , 65 , -30); MstrData.weather.press = (unsigned int)floatLimit(&sampledData.press , wxSF.pressSF , wxSF.pressOff, 1100, 900); //hPa MstrData.weather.humid = (unsigned int)floatLimit(&sampledData.humid , wxSF.humidSF , 0 , 100 , 0); MstrData.weather.batteryV = (unsigned int)floatLimit(&sampledData.batteryV , wxSF.batteryVSF, wxSF.battOff , 4.2 , 3); MstrData.weather.batteryP = (unsigned int)floatLimit(&sampledData.batteryP , wxSF.batteryPSF, 0 , 100 , 0); MstrData.weather.info = 0; storeData.weather = MstrData.weather; Serial.println("Stored Data"); delay(10); //Write to FRAM MstrCntrl.FRAM_Idx = fram.read8(FRAM_NUM_P0INTS_Addr); MstrCntrl.FRAM_Idx != (fram.read8(FRAM_NUM_P0INTS_Addr+1) << 8); Serial.println("Mem pointer: " + String(MstrCntrl.FRAM_Idx)); for (int ii = 0; ii < wxPackageSize; ii++) { fram.write8(MstrCntrl.FRAM_Idx*FRAM_DATA_OFFSET + FRAM_CNTRL_OFFSET, storeData.TxData[ii]); } MstrCntrl.FRAM_Idx++; fram.write8(FRAM_NUM_P0INTS_Addr, MstrCntrl.FRAM_Idx & 0xFF); fram.write8(FRAM_NUM_P0INTS_Addr+1, MstrCntrl.FRAM_Idx >> 8); /* Serial.println("-----DeCODE----"); Serial.println(storeData.weather.year); Serial.println(storeData.weather.month); Serial.println(storeData.weather.day); Serial.println(storeData.weather.hour); Serial.println(storeData.weather.minute); Serial.println(storeData.weather.second); Serial.println(storeData.weather.dir); Serial.println("floats"); Serial.println((float)storeData.weather.speed * 0.1114); Serial.println((float)storeData.weather.gustMax * 6.9423); Serial.println("BME"); Serial.println((float)storeData.weather.temp * 0.0929 -30); Serial.println(((float)storeData.weather.press *0.1955 +900)*100); Serial.println((float)storeData.weather.humid *0.0978); Serial.println("BATT"); Serial.println(storeData.weather.batteryV ); Serial.println(((float)storeData.weather.batteryV *0.0047)+3); Serial.println(storeData.weather.batteryP ); Serial.println((float)storeData.weather.batteryP *0.3922); */ MstrISR.serviceRTCISR = 0; Serial.println("----------Saved Data---------"); delay(20); attachInterrupt(digitalPinToInterrupt(IOCntrl.ANE_Pulse), PulseISRRoutine, FALLING); MstrISR.pulseSkip = 1; //Restart Timer2 //enable_timer2(); } MstrCntrl.Server_Tx_En = 0; /*---------------------------------------*/ // Server Send /*---------------------------------------*/ if (MstrCntrl.Server_Tx_En) { //RTC_ClearAlarm_Interval2(); //Read RAM one line at time MstrCntrl.FRAM_Idx = 0; MstrCntrl.FRAM_Idx = fram.read8(FRAM_NUM_P0INTS_Addr); MstrCntrl.FRAM_Idx |= (fram.read8(FRAM_NUM_P0INTS_Addr+1) << 8); for (int ii = 0; ii < MstrCntrl.FRAM_Idx; ii++) { for (int kk = 0; kk < wxPackageSize; kk++) { storeData.TxData[kk] = fram.read8(kk + FRAM_DATA_OFFSET + ii * FRAM_DATA_OFFSET); //Delete FRAM data fram.write8(kk + FRAM_DATA_OFFSET + ii * FRAM_DATA_OFFSET, 0); } //Send data to GSM Module } MstrCntrl.FRAM_NumPoints = 0; MstrCntrl.FRAM_Idx = 0; MstrCntrl.Server_Tx_En = 0; } /*----------------------------------------*/ /* ------------ Pulse Detect ------------*/ /*----------------------------------------*/ if (MstrISR.servicePulseISR) { digitalWrite(11, HIGH); MstrData.gustBuff[MstrCntrl.PulseBuffIdx] = (MstrISR.pulseDt); MstrCntrl.PulseBuffIdx++; if (MstrCntrl.PulseBuffIdx >= PulseBuffSize) { MstrCntrl.PulseBuffIdx = 0; BuffFull = 1; } avgGustData(); //Serial.println("--------------"); //Serial.println(MstrData.gustAvg); //Serial.println(MstrISR.pulseDt); if (BuffFull) { findRunningPeaks(); // Serial.print("-----"); // Serial.println(MstrData.gustMax); sampledData.gustMax = MstrData.gustMax; } delay(2); MstrISR.servicePulseISR = 0; digitalWrite(11, LOW); } //watch puppy if (MstrISR.WP_Alert == 1) { digitalWrite(IOCntrl.DONE, HIGH); delay(1); digitalWrite(IOCntrl.DONE, LOW); MstrISR.WP_Alert = 0; } sleep(); } /*------------------------------------------*/ /*--------------- ISR Routine --------------*/ /*------------------------------------------*/ void PulseISRRoutine() { if (MstrISR.pulseSkip) { MstrISR.pulseCt = millis(); MstrISR.pulseSkip = 0; } else { MstrISR.pulseCt = millis(); MstrISR.pulseDt = MstrISR.pulseCt - MstrISR.pulsePt; if (MstrISR.pulseDt > maxGustLimuS) { MstrISR.pulsePt = MstrISR.pulseCt; if (MstrISR.pulseDt > minGustLimuS) { MstrISR.pulseDt = minGustLimuS; MstrISR.servicePulseISR = 1; } else { MstrISR.servicePulseISR = 1; } } } EIFR = bit(INTF1); } void RTCISRRoutine() { MstrISR.serviceRTCISR = 1; MstrISR.RTC_count++; EIFR = bit(INTF0); } ISR(PCINT2_vect) // handle pin change interrupt for D0 to D7 here { if (digitalRead(IOCntrl.BATT_ALRT) == 0) { Serial.println("Low Battery!"); delay(5); } } ISR(PCINT1_vect) // handle pin change interrupt for D0 to D7 here { if (digitalRead(IOCntrl.WAKE) == 0) { Serial.println("Got Alert"); MstrISR.WP_Alert = 1; } }
9b9d4b62d5fe95ff4e82e48448e317c0ba006859
02f2f3a5460f9c068bcb1a77a6de80f618f6c0b0
/CG/src/Labels.hpp
241bb6e126a93dcb6cd7e078e3a61a9fffeb9b90
[]
no_license
lquatrin/CGT3-3D_Camera_Orto_Perspec
2e669d0622394187932b781f3a6166da461db217
225287c54f15b8fc06845dbbc5456e6a4a46e02d
refs/heads/master
2021-03-12T20:32:10.188371
2012-10-07T22:28:20
2012-10-07T22:28:20
null
0
0
null
null
null
null
UTF-8
C++
false
false
2,720
hpp
Labels.hpp
#ifndef __LABELS__CG___ #define __LABELS__CG___ #include <SCV/Label.h> class LabelsCam : public scv::Label { public: LabelsCam() : scv::Label(scv::Point(30, 100), "Coordinates of the camera:") { } ~LabelsCam() {} protected: private: }; class LabelXCam : public scv::Label { public: LabelXCam() : scv::Label(scv::Point(30, 115), "X: ") { } ~LabelXCam() {} protected: private: }; class LabelColorsCam0 : public scv::Label { public: LabelColorsCam0() : scv::Label(scv::Point(30,170), "Axis Colors:") { } ~LabelColorsCam0() {} protected: private: }; class LabelColorsCam : public scv::Label { public: LabelColorsCam() : scv::Label(scv::Point(30,185), "X: Red Y: Green Z: Blue") { } ~LabelColorsCam() {} protected: private: }; class LabelYCam : public scv::Label { public: LabelYCam() : scv::Label(scv::Point(30, 130), "Y: ") { } ~LabelYCam() {} protected: private: }; class LabelZCam : public scv::Label { public: LabelZCam() : scv::Label(scv::Point(30, 145), "Z: ") { } ~LabelZCam() {} protected: private: }; class Label0 : public scv::Label { public: Label0() : scv::Label(scv::Point(50, 225), "(o, l), (i, k), (u, j) -> Rotation") { } ~Label0() {} protected: private: }; class Label1 : public scv::Label { public: Label1() : scv::Label(scv::Point(40, 240), "(w, s), (a, d), (q, e) -> Translation") { } ~Label1() {} protected: private: }; class Label10 : public scv::Label { public: Label10() : scv::Label(scv::Point(90, 255), "Mouse Buttons:") { } ~Label10() {} protected: private: }; class Label12 : public scv::Label { public: Label12() : scv::Label(scv::Point(33, 270), "Left(Hold) e wheelUp/Down -> Translation") { } ~Label12() {} protected: private: }; class Label11 : public scv::Label { public: Label11() : scv::Label(scv::Point(45, 285), "Right(Hold) e Middle(Hold) -> Rotation") { } ~Label11() {} protected: private: }; class Label2 : public scv::Label { public: Label2() : scv::Label(scv::Point(100, 210), "Commands:") { } ~Label2() {} protected: private: }; class Label3 : public scv::Label { public: Label3() : scv::Label(scv::Point(60, 14), "Choose Projection:") { } ~Label3() {} protected: private: }; class Label4 : public scv::Label { public: Label4() : scv::Label(scv::Point(55, 55), "Object/Plane to draw:") { } ~Label4() {} protected: private: }; #endif
3579f78dfe4b57fac1aef7b76768c067d605ee72
88136cff99ea0e1b66756e11ae881be4d2a8abfa
/src/hamiltonian_msckf.h
36a78b5999274fb992c4aab1bf79e8784363f531
[ "BSD-3-Clause" ]
permissive
chengwei920412/right_msckf
2ba76763feec156d0e526e9948c73a3c6ff3a78b
65dca839c4a709aca03e06a083415206d5646403
refs/heads/master
2022-03-31T02:25:56.638788
2019-12-22T05:29:48
2019-12-22T05:29:48
null
0
0
null
null
null
null
UTF-8
C++
false
false
23,880
h
hamiltonian_msckf.h
#pragma once #include <Eigen/Geometry> #include <unordered_map> #include <unordered_set> #include <vector> #include <list> #include <deque> #include "core.h" namespace msckf { struct IMUMeas { Vec3d acc; Vec3d gyro; }; struct Feature2D { int64_t id = 0; Vec2d norm_coord; //img coordinates in normalized form }; struct Landmark { EIGEN_MAKE_ALIGNED_OPERATOR_NEW; int64_t id = 0; // same as Feature std::vector<Vec2d, Eigen::aligned_allocator<Vec2d>> projs; std::vector<int64_t> camera_ids; int64_t cam_id_first; int64_t cam_id_last; int GetNumTracks() { return projs.size(); } Vec3d pos_W; //Position in World bool have_pos = false; }; struct CamState { EIGEN_MAKE_ALIGNED_OPERATOR_NEW; int64_t cam_id = -1; double time = 0; std::vector<int64_t> landmark_ids; Vec3d pos; Eigen::Quaterniond quat; }; struct Landmark_To_Residualize { Landmark landmark; std::unordered_map<int64_t, CamState> connected_cams; }; struct State { int num_cam_clones; // order follows MSCKF paper // quat,b_g,vel,b_a,pos,clone1(quat,pos),clone2(quat,pos),...,cloneN(quat,pos) VecXd state_vec; MatXd imu_covar; //covariance of quat-imu_pos MatXd cams_covar; MatXd imu_cam_covar; MatXd P; std::deque<CamState> cam_states; //state indexes to get values const int quat_idx = 0; const int bg_idx = 4; const int vel_idx = 7; const int ba_idx = 10; const int pos_idx = 13; const int clone_start_idx = 16; //indexes in error state. Almost exact same except the quaternion error state is of size 3 const int quat_error_idx = 0; const int bg_error_idx = 3; const int vel_error_idx = 6; const int ba_error_idx = 9; const int pos_error_idx = 12; State(); State(int num_cam_clones); Eigen::Quaterniond GetQuat(); Vec3d GetGyroBias(); Vec3d GetAccelBias(); Vec3d GetPos(); Vec3d GetVel(); Eigen::Quaterniond GetCloneQuat(int n_clone); Vec3d GetClonePos(int n_clone); }; class HamiltonianMSCKF { public: State state; int64_t latest_cam_id; //Camera offsets Eigen::Quaterniond q_IMU_C; Vec3d p_IMU_C; int max_track_length = 10; double total_time = 0; // ---------------------------- IMU --------------------------------------------------- double sigma_gyr_2 = Square(1e-4); double sigma_acc_2 = Square(1e-2); double sigma_bg_drift_2 = Square(3.6733e-5); double sigma_ba_drift_2 = Square(7e-4); double tau_bg{50.0}; double tau_ba{100.0}; // Initial Uncertainty double sigma_pos_init{1e-12}; double sigma_vel_init{1e-6}; double sigma_att_init{1e-6 * deg2rad}; double sigma_ba_init{1e-6}; double sigma_bg_init{3.6733e-5}; double tau_acc_bias{0}; double tau_gyr_bias{0}; Vec3d pos_imu_b_B{Vec3d::Zero()}; VecXd noise_vec; // Matrices Eigen::Matrix<double, 12, 12> R_imu{Eigen::Matrix<double, 12, 12>::Identity()}; // ---------------------------- VO and LCVO --------------------------------------------- double sigma_vo_feature_u{0.01}; //FIXME get this value double sigma_vo_feature_v{0.01}; //FIXME get this value double sigma_lcvo_pos{0.05}; double sigma_lcvo_att{2 * deg2rad}; // Adaptation in MSC-EKF double sigma_vo_fu_ad{0.01}; double sigma_vo_fv_ad{0.01}; VecXd error_vo_pred{VecXd::Zero(2, 1)}; bool use_observability_augmentation = false; //================================ MSC EKF Necessary Matrices ========================================================== //------------ Propagate -------------------------- Mat15x15d F_k; Mat15x12d G_k; Mat15x15d Phi_k; Mat15x15d Q_k; Mat15x15d Phi_k_propagated; //--------------- Update -------------------------- MatXd S_k; MatXd H_k; MatXd R_k; MatXd K_k; VecXd residual; VecXd delta_state; std::unordered_map<int64_t, Landmark> map_id_landmark; std::unordered_set<int64_t> feature_ids_to_remove; double noise_pixel_sigma; void Propogate(const IMUMeas& meas, double dt) { Vec3d acc_meas = meas.acc; Vec3d gyro_meas = meas.gyro; Vec3d unbiased_accel_B = acc_meas - state.GetAccelBias(); Vec3d unbiased_gyro_B = gyro_meas - state.GetGyroBias(); Mat33d rot_matrix = state.GetQuat().toRotationMatrix(); //RK4 } Vec3d grav; void Update(); void PropogateStateRK4(State& x, Vec3d& unbiased_acc, Vec3d& unbiased_gyro, Vec3d& gravity, double dt) { // Current state Eigen::Quaterniond q0 = state.GetQuat(); Vec3d pos0 = state.GetPos(); Vec3d vel0 = state.GetVel(); Mat33d Rwb0 = q0.toRotationMatrix(); //RK4 //q_dot=0.5*q*w=0.5*omega(w)*q // v_dot=R*(acc_m-acc_b)+gravity // p_dot=v //k1 Vec4d q1_dot = 0.5 * OmegaEigenQuat(unbiased_gyro) * q0.coeffs(); Vec3d p1_dot = vel0; Vec3d v1_dot = Rwb0 * (unbiased_acc) + gravity; Vec4d q_k1 = q1_dot * dt; Vec3d p_k1 = p1_dot * dt; Vec3d v_k1 = v1_dot * dt; Vec4d q1 = q0.coeffs() + q_k1 * 0.5; Vec3d v1 = vel0 + v_k1 * 0.5; // Eigen::Quaterniond q1_eig(q1.data()); q1_eig.normalize(); // // //k2 Vec4d q2_dot = 0.5 * OmegaEigenQuat(unbiased_gyro) * q1_eig.coeffs(); Vec3d p2_dot = v1; Vec3d v2_dot = q1_eig.toRotationMatrix() * unbiased_acc + gravity; Vec4d q_k2 = q2_dot * dt; Vec3d p_k2 = p2_dot * dt; Vec3d v_k2 = v2_dot * dt; Vec4d q2 = q0.coeffs() + q_k2 * 0.5; Vec3d v2 = vel0 + v_k2 * 0.5; // Eigen::Quaterniond q2_eig(q2.data()); q2_eig.normalize(); //k3 Vec4d q3_dot = 0.5 * OmegaEigenQuat(unbiased_gyro) * q2_eig.coeffs(); Vec3d p3_dot = v2; Vec3d v3_dot = q2_eig.toRotationMatrix() * unbiased_acc + gravity; Vec4d q_k3 = q3_dot * dt; Vec3d p_k3 = p3_dot * dt; Vec3d v_k3 = v3_dot * dt; Vec4d q3 = q0.coeffs() + q_k3; Vec3d v3 = vel0 + v_k3; Eigen::Quaterniond q3_eig(q3.data()); q3_eig.normalize(); Vec4d q4_dot = 0.5 * OmegaEigenQuat(unbiased_gyro) * q3_eig.coeffs(); Vec3d p4_dot = v3; Vec3d v4_dot = q3_eig.toRotationMatrix() * unbiased_acc + gravity; Vec4d q_k4 = q4_dot * dt; Vec3d p_k4 = p4_dot * dt; Vec3d v_k4 = v4_dot * dt; // Sum Vec3d p = pos0 + (1 / 6.0) * (p_k1 + 2 * p_k2 + 2 * p_k3 + p_k4); Vec3d v = vel0 + (1 / 6.0) * (v_k1 + 2 * v_k2 + 2 * v_k3 + v_k4); Vec4d q = q0.coeffs() + (1 / 6.0) * (q_k1 + 2 * q_k2 + 2 * q_k3 + q_k4); Eigen::Quaterniond q_eig(q.data()); } void CalcIMUDerivatives(State& x, Vec3d& pos_dx, Vec3d& vel_dx, Eigen::Quaterniond& quat_dx, Vec3d& unbiased_acc, Vec3d& unbiased_gyro) { // From equations 236 in Sola Page 54 pos_dx = x.GetVel(); vel_dx = x.GetQuat().toRotationMatrix() * (unbiased_acc) + grav; //quat_dx=x.GetQuat()*unbiased_gyro*0.5; // Vec3 gyro = gyro_accel.head<3>(); // Vec3 accel = gyro_accel.tail<3>(); // // Vec3 gyro_calib = imu_.Cg() * gyro - X.bg; // \hat\omega in the doc // Vec3 accel_calib = imu_.Ca() * accel - X.ba; // \hat\alpha in the doc // // // jacobian w.r.t. error state // Mat3 R = X.Rsb.matrix(); // // Eigen::Matrix<number_t, 3, 9> dW_dCg; // for (int i = 0; i < 3; ++i) { // // NOTE: use the raw measurement (gyro) here. NOT the calibrated one // // (gyro_calib)!!! // dW_dCg.block<1, 3>(i, 3 * i) = gyro; // } // // Eigen::Matrix<number_t, 3, 9> dV_dRCa = dAB_dA<3, 3>(accel); // Eigen::Matrix<number_t, 9, 9> dRCa_dCafm = dAB_dB<3, 3>(R); // fm: full matrix // Eigen::Matrix<number_t, 9, 6> dCafm_dCa = dA_dAu<number_t, 3>(); // full matrix w.r.t. upper triangle // Eigen::Matrix<number_t, 3, 6> dV_dCa = dV_dRCa * dRCa_dCafm * dCafm_dCa; // // Mat3 dW_dW = -hat(gyro_calib); // // static Mat3 dW_dbg = -I3; // // // static Mat3 dT_dV = I3; // // Mat3 dV_dW = -R * hat(accel_calib); // Mat3 dV_dba = -R; // // Mat3 dV_dWg = -R * hat(g_); // effective dimension: 3x2, since Wg is 2-dim // // Mat2 dWg_dWg = Mat2::Identity(); } void CalcProcessCovDerivatives(State& x, MatXd& F, Vec3d& unbiased_acc, Vec3d& unbiased_gyro) { MatXd F_k(18, 18); Mat33d gyro_skew = CreateSkew(unbiased_gyro); Mat33d acc_skew = CreateSkew(unbiased_acc); Mat33d R = x.GetQuat().toRotationMatrix(); F_k.setZero(); // Velocity Jacobians // Jacobian velocity w.r.t Rotation body to earth Mat33d dV_dtheta = -R * acc_skew; // Jacobian velocity w.r.t. bias_acc Mat33d dV_daccb = -R; // Rotation Jacobians Mat33d dQ_dtheta = -gyro_skew; Mat33d dQ_dgyrob = -Mat33d::Identity(); // Position Jacobians Mat33d dP_dv = Mat33d::Identity(); // Set the blocks in the F matrix F_k.block<3, 3>(x.pos_error_idx, x.vel_error_idx) = dP_dv; F_k.block<3, 3>(state.quat_error_idx, state.quat_error_idx) = dQ_dtheta; F_k.block<3, 3>(state.quat_error_idx, state.bg_error_idx) = dQ_dgyrob; F_k.block<3, 3>(state.vel_error_idx, state.quat_error_idx) = dV_dtheta; F_k.block<3, 3>(state.vel_error_idx, state.ba_error_idx) = dV_daccb; double dt;// FIXEME MatXd Fdt = F * dt; auto Fdt2 = Fdt * Fdt; auto Fdt3 = Fdt2 * Fdt; MatXd Phi = Fdt + 0.5 * Fdt2 + (1. / 6.) * Fdt3; MatXd G_k(15, 12); G_k.setZero(); // Jacobians with respect to noise G_k.block<3, 3>(0, 0) = -Mat33d::Identity(); // dQ_dng G_k.block<3, 3>(3, 3) = Mat33d::Identity(); // dGyroBias_dng G_k.block<3, 3>(6, 6) = -R; // dV_dnacc G_k.block<3, 3>(9, 9) = Mat33d::Identity(); // dAccBias_dnacc MatXd Qc(12, 12); double dt2 = dt * dt; //According to Sola Qc.block(0, 0, 3, 3) = sigma_gyr_2 / dt2 * Eigen::Matrix<double, 3, 3>::Identity(); Qc.block(3, 3, 3, 3) = sigma_bg_drift_2 / dt * Eigen::Matrix<double, 3, 3>::Identity(); Qc.block(6, 6, 3, 3) = sigma_acc_2 / dt2 * Eigen::Matrix<double, 3, 3>::Identity(); Qc.block(9, 9, 3, 3) = sigma_ba_drift_2 / dt * Eigen::Matrix<double, 3, 3>::Identity(); MatXd P = Phi * state.imu_covar * Phi.transpose() + G_k * Qc * G_k.transpose(); } void UpdateFeatures(const std::vector<Vec2d, Eigen::aligned_allocator<Vec2d>>& projs, const std::vector<int64_t>& ids) { assert(ids.size() == projs.size()); for (int idx = 0; idx < projs.size(); ++idx) { const int64_t id = ids[idx]; const Vec2d& proj = projs[idx]; auto iter = map_id_landmark.find(id); //Means new feature. Landmark is created if (iter == map_id_landmark.end()) { Landmark l; l.id = id; l.projs.push_back(proj); l.cam_id_first = latest_cam_id + 1; l.cam_id_last = latest_cam_id + 1; auto& cur_cam_state = (state.cam_states.back()); cur_cam_state.landmark_ids.emplace_back(id); } else { auto& landmark = iter->second; landmark.projs.push_back(proj); auto& cur_cam_state = (state.cam_states.back()); cur_cam_state.landmark_ids.emplace_back(id); landmark.cam_id_last = cur_cam_state.cam_id; } } //Check if any Features have reached max length and mark them to be removed for (auto& iter: map_id_landmark) { auto& landmark = iter.second; if (landmark.projs.size() > max_track_length) { feature_ids_to_remove.insert(landmark.id); } } } bool CheckLandMarkValidity(const Landmark_To_Residualize& l) { return true; } void Marginilize() { int total_obs = 0; if (feature_ids_to_remove.size() == 0) { return; } std::vector<Landmark_To_Residualize> valid_tracks; for (const auto feature_id:feature_ids_to_remove) { auto iter = map_id_landmark.find(feature_id); assert(iter != map_id_landmark.end()); Landmark_To_Residualize track; Landmark l = std::move(iter->second); map_id_landmark.erase(iter); //Find all cameras connected to this landmark. Also remove any projections that don't have a camera state. // This can happen if the camera state has been pruned std::vector<Vec2d, Eigen::aligned_allocator<Vec2d>> valid_projs; std::vector<int64_t> valid_cam_ids; for (int idx = 0; idx < l.camera_ids.size(); ++idx) { int cam_id = l.camera_ids[idx]; for (auto& cam:state.cam_states) { if (cam_id == cam.cam_id) { valid_projs.emplace_back(l.projs[idx]); valid_cam_ids.emplace_back(cam_id); track.connected_cams[cam.cam_id] = cam; break; } } } //Copy over landmark info and valid projs to track track.landmark = l; track.landmark.projs = valid_projs; track.landmark.camera_ids = valid_cam_ids; bool valid = CheckLandMarkValidity(track); if (!valid) { continue; } bool triang_result = TriangulateFeature(track); if (triang_result) { valid_tracks.push_back(track); } } if (valid_tracks.empty()) { return; } int num_valid = valid_tracks.size(); MatXd H_o = MatXd::Zero(2 * total_obs - 3 * num_valid, 15 + 6 * state.cam_states.size()); MatXd R_o = MatXd::Zero(2 * total_obs - 3 * num_valid, 2 * total_obs - 3 * num_valid); VecXd r_o(2 * total_obs - 3 * num_valid); int matrix_index = 0; // The index to navigate the above matrices for (auto& track:valid_tracks) { int num_obs = track.landmark.projs.size(); //Calculate Residual VecXd residuals = ComputeTrackResidual(track); // Noise Matrix MatXd R_j = MatXd::Identity(residuals.size() / 2, residuals.size() / 2) * noise_pixel_sigma; MatXd H_x_j, H_f_j; ComputeJacobians(track, H_x_j, H_f_j); // Perform the NullSpace Marginilization. Computes A as seen in MSCKF Eq 23 Eigen::JacobiSVD<MatXd> svd_helper(H_f_j, Eigen::ComputeFullU | Eigen::ComputeThinV); MatXd A = svd_helper.matrixU().rightCols(H_f_j.rows() - 3); MatXd H_o_j = A.transpose() * H_x_j; VecXd r_o_j = A.transpose() * residuals; MatXd R_o_j = A.transpose() * R_j * A; assert(r_o_j.size() == (2 * num_obs - 3)); // See MSCKF paper right after Eq 24 assert(H_o_j.rows() == r_o_j.rows()); if (true) { // add the gating test here r_o.segment(matrix_index, r_o_j.size()) = r_o_j; H_o.block(matrix_index, 0, H_o_j.rows(), H_o_j.cols()) = H_o_j; R_o.block(matrix_index, matrix_index, R_o_j.rows(), R_o_j.cols()) = R_o_j; matrix_index += H_o_j.rows(); } } H_o.conservativeResize(matrix_index, H_o.cols()); r_o.conservativeResize(matrix_index); R_o.conservativeResize(matrix_index, matrix_index); // Perform Measurement Update MeasurementUpdate(H_o, r_o, R_o); } VecXd ComputeTrackResidual(Landmark_To_Residualize& track) { VecXd residuals(track.landmark.projs.size() * 2); int iter = 0; for (int idx = 0; idx < track.landmark.projs.size(); idx++) { const auto& obs = track.landmark.projs[idx]; auto cam_id = track.landmark.camera_ids[idx]; const Vec3d& pt3D = track.landmark.pos_W; const auto& cam_state = track.connected_cams[cam_id]; Mat44d T_wc = BuildTransform(cam_state.quat, cam_state.pos); Mat44d T_cw = InvertTransform(T_wc); Vec3d p_f_C = T_wc.block<3, 3>(0, 0) * pt3D + T_wc.block<3, 1>(0, 3); Vec2d projection = p_f_C.template head<2>() / p_f_C(2); Vec2d res = obs - projection; residuals[2 * idx] = res[0]; residuals[2 * idx + 1] = res[1]; } return residuals; } void ComputeJacobians(const Landmark_To_Residualize& track, MatXd& H_x_j, MatXd& H_f_j) { int n_obs = track.landmark.projs.size(); H_f_j = MatXd::Zero(2 * n_obs, 3); H_x_j = MatXd::Zero(2 * n_obs, 15 + 6 * state.cam_states.size()); Mat33d R_wi = state.GetQuat().toRotationMatrix(); //Rotation of IMU from World Mat33d R_ic = q_IMU_C.toRotationMatrix(); //Rotation of Camera from IMU Mat33d R_wc = R_wi * R_ic; for (int c_i = 0; c_i < n_obs; c_i++) { const int64_t cam_id = track.landmark.camera_ids[c_i]; const Vec3d& pt3D = track.landmark.pos_W; const auto& camera_state = track.connected_cams.at(cam_id); // need at for const // Find index of camera in current list int cam_index = -1; for (int idx = 0; idx < state.cam_states.size(); ++idx) { if (state.cam_states[idx].cam_id == cam_id) { cam_index = idx; break; } } assert(cam_index != -1); Vec3d p_f_C = camera_state.quat.toRotationMatrix() * (pt3D - camera_state.pos); double X, Y, Z; X = p_f_C(0); Y = p_f_C(1); Z = p_f_C(2); // See Jacobian in MSCKF paper. Also is same in VINS-Mono Projection Factor Eigen::Matrix<double, 2, 3> J_i; J_i << 1, 0, -X / Z, 0, 1, -Y / Z; J_i *= 1 / Z; Eigen::Matrix<double, 3, 6> dPcam_dstate = Eigen::Matrix<double, 3, 6>::Zero(); // Jacobian w.r.t. Camera Orientation dPcam_dstate.leftCols(3) = -R_wc.transpose(); // Jacobian w.r.t. Camera Position dPcam_dstate.rightCols(3) = CreateSkew(p_f_C); Eigen::Matrix<double, 2, 6> Jac = J_i * dPcam_dstate; // Jacobian w.r.t to the point in world Eigen::Matrix<double, 2, 3> dPc_dPw = J_i * R_wc.transpose(); if (use_observability_augmentation) { return; } else { H_f_j.block<2, 3>(2 * c_i, 0) = dPc_dPw; H_x_j.block<2, 6>(2 * c_i, 15 + 6 * (cam_index)) = Jac; } } } bool TriangulateFeature(Landmark_To_Residualize& track); void MeasurementUpdate(const MatXd& H_o, const MatXd& r_o, const MatXd& R_o) { if (r_o.size() != 0) { // Build MSCKF covariance matrix MatXd P = MatXd::Zero(15 + state.cams_covar.rows(), 15 + state.cams_covar.cols()); P.template block<15, 15>(0, 0) = state.imu_covar; if (state.cams_covar.rows() != 0) { P.block(0, 15, 15, state.imu_cam_covar.cols()) = state.imu_cam_covar; P.block(15, 0, state.imu_cam_covar.cols(), 15) = state.imu_cam_covar.transpose(); P.block(15, 15, state.cams_covar.rows(), state.cams_covar.cols()) = state.cams_covar; } MatXd T_H, Q_1, R_n; VecXd r_n; // Put residuals in update-worthy form // Calculates T_H matrix according to Mourikis 2007 Eigen::HouseholderQR<MatXd> qr(H_o); MatXd Q = qr.householderQ(); MatXd R = qr.matrixQR().template triangularView<Eigen::Upper>(); VecXd nonZeroRows = R.rowwise().any(); int numNonZeroRows = nonZeroRows.sum(); T_H = MatXd::Zero(numNonZeroRows, R.cols()); Q_1 = MatXd::Zero(Q.rows(), numNonZeroRows); size_t counter = 0; for (size_t r_ind = 0; r_ind < R.rows(); r_ind++) { if (nonZeroRows(r_ind) == 1.0) { T_H.row(counter) = R.row(r_ind); Q_1.col(counter) = Q.col(r_ind); counter++; if (counter > numNonZeroRows) { //ROS_ERROR("More non zero rows than expected in QR decomp"); } } } r_n = Q_1.transpose() * r_o; R_n = Q_1.transpose() * R_o * Q_1; // Calculate Kalman Gain MatXd temp = T_H * P * T_H.transpose() + R_n; MatXd K = (P * T_H.transpose()) * temp.inverse(); // State Correction VecXd deltaX = K * r_n; // // Update IMU state (from updateState matlab function defined in MSCKF.m) // Eigen::Quaterniond q_IG_up = buildUpdateQuat(deltaX.template head<3>()) * state..q_IG; // // imu_state_.q_IG = q_IG_up; // // imu_state_.b_g += deltaX.template segment<3>(3); // imu_state_.b_a += deltaX.template segment<3>(9); // imu_state_.v_I_G += deltaX.template segment<3>(6); // imu_state_.p_I_G += deltaX.template segment<3>(12); // // // Update Camera<_S> states // for (size_t c_i = 0; c_i < cam_states_.size(); c_i++) { // Quaterniond q_CG_up = buildUpdateQuat(deltaX.template segment<3>(15 + 6 * c_i)) * // cam_states_[c_i].q_CG; // cam_states_[c_i].q_CG = q_CG_up.normalized(); // cam_states_[c_i].p_C_G += deltaX.template segment<3>(18 + 6 * c_i); // } // // // Covariance correction // MatXd tempMat = MatXd::Identity(15 + 6 * cam_states_.size(), // 15 + 6 * cam_states_.size()) - // K * T_H; // // MatXd P_corrected, P_corrected_transpose; // P_corrected = tempMat * P * tempMat.transpose() + K * R_n * K.transpose(); // // Enforce symmetry // P_corrected_transpose = P_corrected.transpose(); // P_corrected += P_corrected_transpose; // P_corrected /= 2; // // if (P_corrected.rows() - 15 != state.cams_covar.rows()) { // std::cout << "[P:" << P_corrected.rows() << "," << P_corrected.cols() << "]"; // std::cout << "[state.cams_covar:" << state.cams_covar.rows() << "," << state.cams_covar.cols() << "]"; // std::cout << std::endl; // } // // // TODO : Verify need for eig check on P_corrected here (doesn't seem too // // important for now) // state.imu_covar = P_corrected.template block<15, 15>(0, 0); // // // TODO: Check here // state.cams_covar = P_corrected.block(15, 15, P_corrected.rows() - 15, // P_corrected.cols() - 15); // state.imu_cam_covar = P_corrected.block(0, 15, 15, P_corrected.cols() - 15); return; } else return; } void AugmentState() { // T_wc = T_wi*T_ic // w=world,c=camera,i=imu/body // T=Rt // Q_wc=Q_wi*Q_ic Eigen::Quaterniond cam_quat = state.GetQuat() * q_IMU_C; // cam_quat.normalize(); // ensure it is unit quaternion // t_wc= t_wi+ R_wi*t_ic Vec3d cam_pose = state.GetPos() + state.GetQuat() * p_IMU_C; CamState cam; cam.pos = cam_pose; cam.quat = cam_quat; state.cam_states.push_back(cam); if (state.cam_states.size() > 0) { state.P.resize(15 + state.cams_covar.rows(), 15 + state.cams_covar.cols()); state.P.block<15, 15>(0, 0) = state.imu_covar; state.P.block(0, 15, 15, state.cams_covar.cols()) = state.imu_covar; state.P.block(15, 0, state.cams_covar.rows(), 15) = state.imu_covar.transpose(); state.P.block(15, 15, state.cams_covar.rows(), state.cams_covar.cols()) = state.cams_covar; } else { state.P = state.imu_covar; } // Size is 6 since minimal Jacobian pose is 6(quat=3,pos=3) MatXd Jac = MatXd::Zero(6, 15 + 6 * state.cam_states.size()); // Follows the format seen in Mourikis MSCKF Eq 16 // Jacobians are with Body to Earth using Q_wc=Q_wi*Q_ic and t_wc= t_wi+ R_wi*t_ic Mat33d dQC_dQI = q_IMU_C.toRotationMatrix(); // Jac of cam_quat w.r.t imu_quat Mat33d s = CreateSkew(p_IMU_C); Mat33d dPC_dQI = -state.GetQuat().toRotationMatrix() * s; // Jac of cam_position with respect to imu_quat // derivative of this can be found in Bloesh primer Mat33d dPC_dPI = Mat33d::Identity(); // Jac of cam_position w.r.t imu position Jac.block<3, 3>(0, state.quat_error_idx) = dQC_dQI; Jac.block<3, 3>(3, state.quat_error_idx) = dPC_dQI; Jac.block<3, 3>(3, state.pos_error_idx) = dPC_dPI; int n_cams = state.cam_states.size(); MatXd tempMat = MatXd::Identity(15 + 6 * n_cams + 6, 15 + 6 * n_cams); tempMat.block(15 + 6 * n_cams, 0, 6, 15 + 6 * n_cams) = Jac; MatXd P_aug = tempMat * state.P * tempMat.transpose(); MatXd P_aug_sym = (P_aug + P_aug.transpose()) / 2.0; state.cam_states.push_back(cam); state.imu_covar = P_aug_sym.block<15, 15>(0, 0); state.cams_covar.resize(P_aug_sym.rows() - 15, P_aug_sym.cols() - 15); state.cams_covar = P_aug.block(15, 15, P_aug_sym.rows() - 15, P_aug_sym.cols() - 15); } }; }
708ffe4164e1053150300d33e6b8c4bf231f2d0b
59df5d1c3e43dd19ffac8e28575042d910843ef2
/Module_01/ex04/ex04.cpp
6d8d4ac59d52342814eaf86a1179b8790ba57240
[]
no_license
ctycho/Introduction_to_Cpp
00114a1378e62f4bf86e6e11eff6bd78394d02ed
29eb4924219c6fee75148f196435f539252b6d9e
refs/heads/master
2023-05-31T13:28:03.908246
2021-06-28T12:43:24
2021-06-28T12:43:24
376,754,167
0
0
null
null
null
null
UTF-8
C++
false
false
1,133
cpp
ex04.cpp
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ex04.cpp :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: ctycho <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2021/05/27 09:46:50 by ctycho #+# #+# */ /* Updated: 2021/05/27 09:46:52 by ctycho ### ########.fr */ /* */ /* ************************************************************************** */ #include <iostream> #include <string> int main() { std::string s = "HI THIS IS BRAIN"; std::string *ptr = &s; std::string &ref = s; std::cout << *ptr << std::endl; std::cout << ref << std::endl; }
29c238d24903cc12f863ce15b8cba5c2210baf2d
69e2ba977ee203ffeb14cf23d0cba9725bbf73a9
/Optimization_Interface/main.cpp
c265bb66f95b0dea40f7a5f14474fff01769fff8
[]
no_license
mceowen/optgui
70599b8702b2c712a6807ec65ca465f287f38b78
73650c5427c5b3d0a1ffa5c62422c61a04a42be3
refs/heads/master
2020-07-08T13:02:21.359429
2019-09-11T17:40:42
2019-09-11T17:40:42
203,681,058
0
0
null
null
null
null
UTF-8
C++
false
false
497
cpp
main.cpp
// TITLE: Optimization_Interface/main.cpp // AUTHORS: Daniel Sullivan, Miki Szmuk // LAB: Autonomous Controls Lab (ACL) // LICENSE: Copyright 2018, All Rights Reserved // Runs main event loop #include <QApplication> #include "main_window.h" using interface::MainWindow; int main(int argc, char *argv[]) { // Initialize application QApplication app(argc, argv); // Create main window MainWindow window; window.show(); // Run event loop return app.exec(); }
d1caa6a2e754a59a692ffaf486817acd64eebf0f
d7c94f4a713aaf0fbb3dbb9b56c9f6945e0479c1
/URI Online Judge/uri2703.cpp
52cfc5cc55704a2cec57836192a39ac4765c64f1
[]
no_license
fonte-nele/Competitive-Programming
2dabb4aab6ce2e6dc552885464fefdd485f9218c
faf0c6077ae0115f121968f7b70f4d68f9ce922b
refs/heads/master
2021-06-28T09:24:07.708562
2020-12-27T14:45:15
2020-12-27T14:45:15
193,268,717
3
0
null
null
null
null
UTF-8
C++
false
false
2,141
cpp
uri2703.cpp
#include <bits/stdc++.h> #define f(inicio, fim) for(int i = inicio; i < fim; i++) #define fr(inicio, fim) for(int j = inicio; j < fim; j++) using namespace std; #define mp make_pair #define pb push_back #define db(x) cerr << #x << " == " << x << endl; #define _ << " " << typedef long long ll; typedef vector<int> vi; typedef pair<int,int> ii; const long double EPS = 1e-9; const int N=1e5+5; const int MOD=1e9+7; const int INF=0x3f3f3f3f; int n, r, ans; ll cost; int sp[30][N], m[30][N], h[N], vis[N]; set<ii> roads; map<ii, int> wt; vector<int> adj[N]; void mst() { priority_queue<pair<int, ii>> pq; pq.push(mp(0, mp(1, 1))); while(!pq.empty()) { int a, b, c; c = -pq.top().first; a = pq.top().second.first; b = pq.top().second.second; pq.pop(); if(vis[b]) continue; cost += c; vis[b] = 1; roads.insert(mp(a,b)); h[b] = h[a] + 1; sp[0][b] = a; m[0][b] = c; for(int v : adj[b]) { pq.push(mp(-wt[mp(b,v)], mp(b, v))); } } } int lca(int a, int b) { int ans = 0; if(h[a] > h[b]) swap(a, b); for(int i=19; i>=0; i--) if((1<<i) & (h[b] - h[a])) { ans = max(ans, m[i][b]); b = sp[i][b]; } if(b == a) return ans; for(int i=19; i>=0; i--) if(sp[i][a] != sp[i][b]) { ans = max(ans, m[i][a]); ans = max(ans, m[i][b]); a = sp[i][a]; b = sp[i][b]; } ans = max(ans, m[0][a]); ans = max(ans, m[0][b]); return ans; } int main () { ios_base::sync_with_stdio(false); cin.tie(NULL); scanf("%d %d", &n, &r); for(int i=0; i<r; i++) { int u, v, c; scanf("%d %d %d", &u, &v, &c); adj[u].pb(v); adj[v].pb(u); wt[mp(u,v)] = wt[mp(v,u)] = c; } mst(); for(int i=1; i<20; i++) { for(int j=1; j<=n; j++) { sp[i][j] = sp[i-1][sp[i-1][j]]; m[i][j] = max(m[i-1][sp[i-1][j]], m[i-1][j]); } } int q; scanf("%d", &q); for(int i=0; i<q; i++) { int u, v; scanf("%d %d", &u, &v); if(roads.count(mp(v,u)) or roads.count(mp(u,v))) { printf("%lld\n", cost); } else { printf("%lld\n", cost + wt[mp(u,v)] - lca(u,v)); } } return 0; }
a40e59d34e32c8705ea4b6a717c76838f465bade
c13c121d96fdd8682982854f43e50be011863aa1
/Code/Engine/core/ReflectionLoader.cpp
50cf9543536415ac82672f25e14dbbcc9378c09d
[]
no_license
paksas/Tamy
14fe8e2ff5633ced9b24c855c6e06776bf221c10
6e4bd2f14d54cc718ed12734a3ae0ad52337cf40
refs/heads/master
2020-06-03T08:06:09.511028
2015-03-21T20:37:03
2015-03-21T20:37:03
25,319,755
0
1
null
null
null
null
UTF-8
C++
false
false
9,160
cpp
ReflectionLoader.cpp
#include "core/ReflectionLoader.h" #include "core/InStream.h" #include "core/InArrayStream.h" #include "core/InRawArrayStream.h" #include "core/ReflectionType.h" #include "core/ReflectionObject.h" #include "core/ReflectionObjectsTracker.h" #include "core/ResourcesManager.h" #include "core/ReflectionSerializationMacros.h" #include "core/MemoryRouter.h" #include "core/DefaultAllocator.h" /////////////////////////////////////////////////////////////////////////////// ReflectionLoader::ReflectionLoader( ReflectionObjectsTracker* tracker ) : m_instancesTracker( tracker ) { } /////////////////////////////////////////////////////////////////////////////// ReflectionLoader::~ReflectionLoader() { // remove the remaining unread objects for ( std::list< ReflectionObject* >::iterator it = m_loadedObjects.begin(); it != m_loadedObjects.end(); ++it ) { delete *it; } m_loadedObjects.clear(); } /////////////////////////////////////////////////////////////////////////////// void ReflectionLoader::deserialize( InStream& inStream, std::vector< FilePath >* outDependenciesToLoad, std::vector< FilePath >* outRemappedDependencies ) { // 1. check if it's indeed one of our resources and it's version number uint magicNo; inStream >> magicNo; if ( magicNo != TAMY_ARCHIVE_MAGIC_NO ) { return; } // 2. load external dependencies uint firstExternalDependencyIdx = loadExternalDependencies( inStream, outDependenciesToLoad, outRemappedDependencies ); // 3. load internal dependencies bool result = loadInternalDependencies( inStream, firstExternalDependencyIdx ); if ( !result ) { // no dependencies restored - bail return; } // 4. load the indices of serialized objects uint serializedObjectsCount = 0; inStream >> serializedObjectsCount; if ( serializedObjectsCount == 0 ) { // no serialized objects - something's wrong ASSERT_MSG( serializedObjectsCount > 0, "There are no serialized objects indices, even though we managed to load some dependencies" ); // delete the deserialized dependencies for ( std::vector< ReflectionObject* >::iterator it = m_dependencies.begin(); it != m_dependencies.end(); ++it ) { delete *it; } m_dependencies.clear(); return; } // 5. deserialize the objects for ( uint i = 0; i < serializedObjectsCount; ++i ) { uint serializedObjectIdx = -1; inStream >> serializedObjectIdx; ReflectionObject* obj = m_dependencies[serializedObjectIdx]; if ( obj ) { m_loadedObjects.push_back( obj ); } } // 6. copy all encountered dependencies to the list of all objects this loader's ever loaded uint dependenciesCount = m_dependencies.size(); for ( uint i = 0; i < dependenciesCount; ++i ) { ReflectionObject* obj = m_dependencies[i]; if ( obj ) { m_allLoadedObjects.push_back( obj ); } } // 7. clean temporary data m_dependencies.clear(); } /////////////////////////////////////////////////////////////////////////////// uint ReflectionLoader::loadExternalDependencies( InStream& stream, std::vector< FilePath >* outDependenciesToLoad, std::vector< FilePath >* outRemappedDependencies ) { uint remappingStartOffset = 0; // load the skip size first - if no array was specified for the results, we'll just skip this section of the stream uint skipSize = 0; stream >> skipSize; if ( outDependenciesToLoad && outRemappedDependencies ) { remappingStartOffset = outRemappedDependencies->size(); // deserialize the dependencies uint dependenciesCount = 0; stream >> dependenciesCount; for ( uint i = 0; i < dependenciesCount; ++i ) { FilePath path; stream >> path; // append the path to the list of remapped dependencies - it's a huge continuous array where every loaded resource // will append its own external dependencies and its internal pointers will be remapped to point to that // very area in the array outRemappedDependencies->push_back( path ); // as for the list of additional dependencies to load, we need to make sure // the path doesn't duplicate any of the existing entries. Only then can we add it there bool isUnique = true; uint currDependenciesCount = outDependenciesToLoad->size(); for ( uint j = 0; j < currDependenciesCount; ++j ) { if ( (*outDependenciesToLoad)[j] == path ) { isUnique = false; break; } } if ( isUnique ) { outDependenciesToLoad->push_back( path ); } } } else { // skip the dependencies stream.skip( skipSize ); } return remappingStartOffset; } /////////////////////////////////////////////////////////////////////////////// bool ReflectionLoader::loadInternalDependencies( InStream& stream, uint firstExternalDependencyIdx ) { uint dependenciesCount = 0; stream >> dependenciesCount; if ( dependenciesCount == 0 ) { return false; } MemoryRouter& memRouter = TSingleton< MemoryRouter >::getInstance(); for ( uint i = 0; i < dependenciesCount; ++i ) { // first load the dependency id ReflectionObject::UniqueId objId; stream >> objId; uint skipSize = 0; stream >> skipSize; byte* dataBuf = (byte*)memRouter.alloc( skipSize, AM_DEFAULT, &memRouter.m_defaultAllocator ); stream.load( dataBuf, skipSize ); InRawArrayStream objStream( dataBuf, skipSize ); // if we are using an instances tracker, so see if such an object already // exists in the system, maybe there's no need deserializing it ReflectionObject* dependency = NULL; if ( m_instancesTracker && ( dependency = m_instancesTracker->findInstance( objId ) ) != NULL ) { // yep - it's there, just take the existing instance and skip that part of the stream } else { // this is a new instance - load it dependency = SerializableReflectionType::load< ReflectionObject >( objStream ); // and if we're using an instances tracker, add it to it if ( m_instancesTracker && dependency ) { m_instancesTracker->trackInstance( dependency ); } } // cleanup memRouter.dealloc( dataBuf, AM_DEFAULT ); m_dependencies.push_back( dependency ); } // store the remapping offset for the callback m_externalDependenciesOffset = firstExternalDependencyIdx; // now that we have the dependencies, it's time to map them in the loaded objects, // and remap the external dependency pointers to match the dependencies order stored in the array 'outExternalDependencies' for ( uint i = 0; i < dependenciesCount; ++i ) { ReflectionObject* object = m_dependencies[i]; if ( object ) { restoreDependencies( object ); } } return true; } /////////////////////////////////////////////////////////////////////////////// void ReflectionLoader::restoreDependencies( ReflectionObject* object ) const { const SerializableReflectionType& objType = object->getVirtualRTTI(); // create a list of classes in the inheritance hierarchy and start restoring their dependencies std::list< const SerializableReflectionType* > reflectionTypesList; objType.mapTypesHierarchy( reflectionTypesList ); // restore the dependencies on particular subtypes Array< byte > tempSerializationDataBuf; while( !reflectionTypesList.empty() ) { const SerializableReflectionType* nextType = reflectionTypesList.front(); reflectionTypesList.pop_front(); unsigned int membersCount = nextType->m_memberFields.size(); for ( uint i = 0; i < membersCount; ++i ) { ReflectionTypeComponent* member = nextType->m_memberFields[i]; member->restoreDependencies( object, *this ); } } } /////////////////////////////////////////////////////////////////////////////// ReflectionObject* ReflectionLoader::findDependency( uint dependencyIdx, bool& outWasFound ) const { outWasFound = false; if ( IS_DEPENDENCY_NULL( dependencyIdx ) ) { // this is a NULL reference return NULL; } else { bool isExternal = false; uint extractedDependencyIdx; EXTRACT_DEPENDENCY_INDEX( dependencyIdx, extractedDependencyIdx, isExternal ); if ( isExternal ) { // remap the external dependencies by the remapping offset in this pass uint remappedIdx = CREATE_EXTERNAL_DEPENDENCY_INDEX( extractedDependencyIdx + m_externalDependenciesOffset ); return ( ReflectionObject* )remappedIdx; } else { outWasFound = true; return extractedDependencyIdx < m_dependencies.size() ? m_dependencies[extractedDependencyIdx] : NULL; } return NULL; } } ///////////////////////////////////////////////////////////////////////////////